CheeseAPI 2.0.3__tar.gz → 2.0.4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/route.py +3 -1
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/scheduler.py +8 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/PKG-INFO +1 -1
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/pyproject.toml +1 -1
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/.gitignore +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/__init__.py +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/app.py +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/cors.py +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/file.py +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/printer.py +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/request.py +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/response.py +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/signal.py +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/validator.py +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/CheeseAPI/websocket.py +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/LICENSE +0 -0
- {cheeseapi-2.0.3 → cheeseapi-2.0.4}/README.md +0 -0
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import re, uuid
|
|
2
2
|
from typing import Literal, TypedDict, Callable, TYPE_CHECKING, AsyncIterable, Union
|
|
3
3
|
|
|
4
|
+
from urllib.parse import unquote
|
|
5
|
+
|
|
4
6
|
from CheeseAPI.cors import CORS
|
|
5
7
|
|
|
6
8
|
if TYPE_CHECKING:
|
|
@@ -252,7 +254,7 @@ class RouteProxy:
|
|
|
252
254
|
i = 1
|
|
253
255
|
for key, type in self.app.route._proxy.dynamic_routes[_path][method]['params'].items():
|
|
254
256
|
value = match.group(i)
|
|
255
|
-
_params[key] = type(value)
|
|
257
|
+
_params[key] = type(unquote(value))
|
|
256
258
|
i += 1
|
|
257
259
|
return self.app.route._proxy.dynamic_routes[_path][method], _params
|
|
258
260
|
else:
|
|
@@ -158,6 +158,14 @@ class SchedulerProxy:
|
|
|
158
158
|
|
|
159
159
|
self._tasks: dict[str, Task] = {}
|
|
160
160
|
|
|
161
|
+
def __getstate__(self):
|
|
162
|
+
return {
|
|
163
|
+
'app': self.app
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
def __setstate__(self, state):
|
|
167
|
+
self.app = state['app']
|
|
168
|
+
|
|
161
169
|
def add(self, fn: Callable | None = None, *, interval_time: float | None = None, first_run_timer: datetime.datetime | None = None, expected_run_num: int | None = None, key: str | None = None, run_type: Literal['THREAD', 'PROCESS'] = 'THREAD', args: tuple = (), kwargs: dict = {}, auto_remove: bool = False):
|
|
162
170
|
if fn is not None:
|
|
163
171
|
task = Task(fn, interval_time = interval_time, first_run_timer = first_run_timer, expected_run_num = expected_run_num, key = key, run_type = run_type, args = args, kwargs = kwargs, auto_remove = auto_remove)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|