diff --git a/frontik/app.py b/frontik/app.py index f633b345b..ed2ba196b 100644 --- a/frontik/app.py +++ b/frontik/app.py @@ -23,6 +23,7 @@ from frontik.debug import get_frontik_and_apps_versions from frontik.handler import PageHandler, get_current_handler from frontik.handler_asgi import execute_page +from frontik.handler_return_values import ReturnedValueHandlers, get_default_returned_value_handlers from frontik.integrations.statsd import StatsDClient, StatsDClientStub, create_statsd_client from frontik.options import options from frontik.process import WorkerState @@ -73,16 +74,15 @@ class FrontikApplication: class DefaultConfig: pass - def __init__(self, app_module_name: Optional[str] = None) -> None: + def __init__(self) -> None: self.start_time = time.time() - self.app_module_name: Optional[str] = app_module_name - if app_module_name is None: # for tests - app_module = importlib.import_module(self.__class__.__module__) - else: - app_module = importlib.import_module(app_module_name) + self.app_module_name: str = self.__class__.__module__ + app_module = importlib.import_module(self.app_module_name) self.app_root = os.path.dirname(str(app_module.__file__)) - self.app_name = app_module.__name__ + if options.service_name is None: + options.service_name = self.app_module_name.rsplit('.', 1)[-1] + self.app_name = options.service_name self.config = self.application_config() @@ -99,14 +99,15 @@ def __init__(self, app_module_name: Optional[str] = None) -> None: master_done = multiprocessing.Value(c_bool, False) count_down_lock = multiprocessing.Lock() self.worker_state = WorkerState(init_workers_count_down, master_done, count_down_lock) # type: ignore + self.returned_value_handlers: ReturnedValueHandlers = get_default_returned_value_handlers() - import_all_pages(app_module_name) + import_all_pages(self.app_module_name) self.ui_methods: dict = {} self.ui_modules: dict = {} self.settings: dict = {} - self.app = FrontikAsgiApp() + self.asgi_app = FrontikAsgiApp() def __call__(self, tornado_request: httputil.HTTPServerRequest) -> Optional[Awaitable[None]]: # for making more asgi, reimplement tornado.http1connection._server_request_loop and ._read_message @@ -118,9 +119,9 @@ async def _serve_tornado_request( frontik_app: FrontikApplication, _tornado_request: httputil.HTTPServerRequest, _request_id: str, - app: FrontikAsgiApp, + asgi_app: FrontikAsgiApp, ) -> None: - status, reason, headers, data = await execute_page(frontik_app, _tornado_request, _request_id, app) + status, reason, headers, data = await execute_page(frontik_app, _tornado_request, _request_id, asgi_app) assert _tornado_request.connection is not None _tornado_request.connection.set_close_callback(None) # type: ignore @@ -130,7 +131,7 @@ async def _serve_tornado_request( _tornado_request.connection.finish() return await future - return asyncio.create_task(_serve_tornado_request(self, tornado_request, request_id, self.app)) + return asyncio.create_task(_serve_tornado_request(self, tornado_request, request_id, self.asgi_app)) def create_upstream_manager( self, diff --git a/frontik/balancing_client.py b/frontik/balancing_client.py index c5a830077..1cc66eeb7 100644 --- a/frontik/balancing_client.py +++ b/frontik/balancing_client.py @@ -41,7 +41,7 @@ def modify_http_client_request(request: Request, balanced_request: RequestBuilde def get_http_client(modify_request_hook=None): - def _get_http_client(request: Request) -> HttpClient: + async def _get_http_client(request: Request) -> HttpClient: hook = modify_request_hook or partial(modify_http_client_request, request) http_client = request['http_client_factory'].get_http_client( diff --git a/frontik/debug.py b/frontik/debug.py index e32c019e7..76df3e328 100644 --- a/frontik/debug.py +++ b/frontik/debug.py @@ -521,6 +521,8 @@ def get_frontik_and_apps_versions(application: FrontikApplication) -> etree.Elem etree.SubElement(versions, 'aiohttp').text = aiohttp.__version__ etree.SubElement(versions, 'python').text = sys.version.replace('\n', '') etree.SubElement(versions, 'event_loop').text = str(type(asyncio.get_event_loop())).split("'")[1] - etree.SubElement(versions, 'application', name=application.app_name).extend(application.application_version_xml()) + etree.SubElement(versions, 'application', name=application.app_module_name).extend( + application.application_version_xml() + ) return versions diff --git a/frontik/handler.py b/frontik/handler.py index 6a6301d7a..1905cd98c 100644 --- a/frontik/handler.py +++ b/frontik/handler.py @@ -33,6 +33,7 @@ from frontik.json_builder import FrontikJsonDecodeError, json_decode from frontik.loggers import CUSTOM_JSON_EXTRA, JSON_REQUESTS_LOGGER from frontik.loggers.stages import StagesLogger +from frontik.options import options from frontik.timeout_tracking import get_timeout_checker from frontik.util import gather_dict, make_url from frontik.validator import BaseValidationModel, Validators @@ -45,6 +46,7 @@ from tornado.httputil import HTTPHeaders, HTTPServerRequest from frontik.app import FrontikApplication + from frontik.handler_return_values import ReturnedValue, ReturnedValueHandlers from frontik.integrations.statsd import StatsDClient, StatsDClientStub @@ -53,6 +55,14 @@ def __init__(self, wait_finish_group: bool = False) -> None: self.wait_finish_group = wait_finish_group +class RedirectSignal(Exception): + pass + + +class FinishSignal(Exception): + pass + + class HTTPErrorWithPostprocessors(tornado.web.HTTPError): pass @@ -92,6 +102,8 @@ def _fail_fast_policy(fail_fast: bool, waited: bool, host: str, path: str) -> bo class PageHandler(RequestHandler): + returned_value_handlers: ReturnedValueHandlers = [] + def __init__( self, application: FrontikApplication, @@ -109,6 +121,9 @@ def __init__( self.route = route self.debug_mode = debug_mode self.path_params = path_params + for _name, _value in path_params.items(): + if _value: + request.arguments.setdefault(_name, []).append(_value) # type: ignore super().__init__(application, request) # type: ignore @@ -117,6 +132,9 @@ def __init__( for integration in application.available_integrations: integration.initialize_handler(self) + if not self.returned_value_handlers: + self.returned_value_handlers = list(application.returned_value_handlers) + self.stages_logger = StagesLogger(request._start_time, self.statsd_client) self._render_postprocessors: list = [] @@ -314,7 +332,8 @@ def redirect(self, url: str, *args: Any, allow_protocol_relative: bool = False, # This is only reachable under certain configurations. raise tornado.web.HTTPError(403, 'cannot redirect path with two initial slashes') self.log.info('redirecting to: %s', url) - return super().redirect(url, *args, **kwargs) + super().redirect(url, *args, **kwargs) + raise RedirectSignal() @property def json_body(self): @@ -346,12 +365,25 @@ def add_future(cls, future: Future, callback: Callable) -> None: # Requests handling - async def my_execute(self) -> tuple[int, str, HTTPHeaders, bytes]: + async def execute(self) -> tuple[int, str, HTTPHeaders, bytes]: + if ( + self.request.method + not in ( + 'GET', + 'HEAD', + 'OPTIONS', + ) + and options.xsrf_cookies + ): + self.check_xsrf_cookie() + await super()._execute([], b'', b'') + try: - await super()._execute([], b'', b'') - except Exception as ex: - self._handle_request_exception(ex) - return await self.handler_result_future # status, reason, headers, chunk + return await asyncio.wait_for(self.handler_result_future, timeout=5.0) + except TimeoutError: + self.log.error('handler was never finished') + self.send_error() + return self.handler_result_future.result() async def get(self, *args, **kwargs): await self._execute_page() @@ -368,9 +400,6 @@ async def delete(self, *args, **kwargs): async def head(self, *args, **kwargs): await self._execute_page() - def options(self, *args, **kwargs): - self.return_405() - async def _execute_page(self) -> None: self.stages_logger.commit_stage('prepare') @@ -388,7 +417,10 @@ async def _execute_page(self) -> None: raise RuntimeError(f'dependency solving failed: {errors}') assert self.route.dependant.call is not None - await self.route.dependant.call(**values) + returned_value: ReturnedValue = await self.route.dependant.call(**values) + + for returned_value_handler in self.returned_value_handlers: + returned_value_handler(self, returned_value) self._handler_finished_notification() await self.finish_group.get_gathering_future() @@ -398,12 +430,6 @@ async def _execute_page(self) -> None: if render_result is not None: self.write(render_result) - def return_405(self) -> None: - allowed_methods = [name for name in ('get', 'post', 'put', 'delete') if f'{name}_page' in vars(self.__class__)] - self.set_header('Allow', ', '.join(allowed_methods)) - self.set_status(405) - self.finish() - def get_page_fail_fast(self, request_result: RequestResult) -> None: self.__return_error(request_result.status_code, error_info={'is_fail_fast': True}) @@ -517,6 +543,10 @@ def _handle_request_exception(self, e: BaseException) -> None: if self._finished and not isinstance(e, Finish): return + if isinstance(e, FinishSignal): + # Not an error; request was finished explicitly + return + if isinstance(e, FailFastError): request = e.failed_result.request @@ -626,12 +656,12 @@ def finish(self, chunk: Optional[Union[str, bytes, dict]] = None) -> Future[None content_length = sum(len(part) for part in self._write_buffer) self.set_header('Content-Length', content_length) - future = self.flush(include_footers=True) + self._flush() self._finished = True self.on_finish() - return future + raise FinishSignal() - def flush(self, include_footers: bool = False) -> Future[None]: + def _flush(self) -> None: assert self.request.connection is not None chunk = b''.join(self._write_buffer) self._write_buffer = [] @@ -646,10 +676,6 @@ def flush(self, include_footers: bool = False) -> Future[None]: self.handler_result_future.set_result((self._status_code, self._reason, self._headers, chunk)) - future = Future() # type: Future[None] - future.set_result(None) - return future - # postprocessors def set_mandatory_header(self, name: str, value: str) -> None: diff --git a/frontik/handler_asgi.py b/frontik/handler_asgi.py index 9694145da..870445da2 100644 --- a/frontik/handler_asgi.py +++ b/frontik/handler_asgi.py @@ -23,7 +23,10 @@ async def execute_page( - frontik_app: FrontikApplication, tornado_request: httputil.HTTPServerRequest, request_id: str, app: FrontikAsgiApp + frontik_app: FrontikApplication, + tornado_request: httputil.HTTPServerRequest, + request_id: str, + asgi_app: FrontikAsgiApp, ) -> tuple[int, str, HTTPHeaders, bytes]: with request_context.request_context(request_id), request_limiter(frontik_app.statsd_client) as accepted: log.info('requested url: %s', tornado_request.uri) @@ -40,7 +43,7 @@ async def execute_page( assert debug_mode.failed_auth_header is not None status, reason, headers, data = make_debug_auth_failed_response(debug_mode.failed_auth_header) elif route is None: - status, reason, headers, data = make_not_found_response(frontik_app, tornado_request.path) + status, reason, headers, data = await make_not_found_response(frontik_app, tornado_request) else: request_context.set_handler_name(f'{route.endpoint.__module__}.{route.endpoint.__name__}') @@ -53,7 +56,7 @@ async def execute_page( scope, receive, send = convert_tornado_request_to_asgi( frontik_app, tornado_request, route, path_params, debug_mode, result ) - await app(scope, receive, send) + await asgi_app(scope, receive, send) status = result['status'] reason = httputil.responses.get(status, 'Unknown') @@ -78,19 +81,23 @@ async def execute_page( return status, reason, headers, data -def make_not_found_response(frontik_app: FrontikApplication, path: str) -> tuple[int, str, HTTPHeaders, bytes]: - allowed_methods = get_allowed_methods(path) +async def make_not_found_response( + frontik_app: FrontikApplication, tornado_request: httputil.HTTPServerRequest +) -> tuple[int, str, HTTPHeaders, bytes]: + allowed_methods = get_allowed_methods(tornado_request.path.strip('/')) + default_headers = get_default_headers() if allowed_methods: status = 405 - headers = get_default_headers() - headers['Allow'] = ', '.join(allowed_methods) + headers = {'Allow': ', '.join(allowed_methods)} data = b'' elif hasattr(frontik_app, 'application_404_handler'): - status, headers, data = frontik_app.application_404_handler() + status, headers, data = await frontik_app.application_404_handler(tornado_request) else: status, headers, data = build_error_data(404, 'Not Found') + default_headers.update(headers) + reason = httputil.responses.get(status, 'Unknown') return status, reason, HTTPHeaders(headers), data @@ -114,8 +121,7 @@ def make_not_accepted_response() -> tuple[int, str, HTTPHeaders, bytes]: def build_error_data( status_code: int = 500, message: Optional[str] = 'Internal Server Error' ) -> tuple[int, dict, bytes]: - headers = get_default_headers() - headers['Content-Type'] = media_types.TEXT_HTML + headers = {'Content-Type': media_types.TEXT_HTML} data = f'{status_code}: {message}{status_code}: {message}'.encode() return status_code, headers, data @@ -129,7 +135,7 @@ async def legacy_process_request( debug_mode: DebugMode, ) -> tuple[int, str, HTTPHeaders, bytes]: handler: PageHandler = page_cls(frontik_app, tornado_request, route, debug_mode, path_params) - return await handler.my_execute() + return await handler.execute() def convert_tornado_request_to_asgi( diff --git a/frontik/handler_return_values.py b/frontik/handler_return_values.py new file mode 100644 index 000000000..ebeaa4de9 --- /dev/null +++ b/frontik/handler_return_values.py @@ -0,0 +1,28 @@ +from collections.abc import Callable, Collection +from typing import Any + +from pydantic import BaseModel + +from frontik import media_types +from frontik.handler import PageHandler +from frontik.json_builder import json_encode + +ReturnedValue = Any +ReturnedValueHandler = Callable[[PageHandler, ReturnedValue], Any] +ReturnedValueHandlers = Collection[ReturnedValueHandler] + + +def write_json_response_from_dict(handler: PageHandler, value: Any) -> None: + if isinstance(value, dict): + handler.set_header('Content-Type', media_types.APPLICATION_JSON) + handler.text = json_encode(value) + + +def write_json_response_from_pydantic(handler: PageHandler, value: BaseModel) -> None: + if isinstance(value, BaseModel): + handler.set_header('Content-Type', media_types.APPLICATION_JSON) + handler.text = value.model_dump_json() + + +def get_default_returned_value_handlers() -> ReturnedValueHandlers: + return [write_json_response_from_dict, write_json_response_from_pydantic] diff --git a/frontik/integrations/statsd.py b/frontik/integrations/statsd.py index 01c4be340..6c2648ebb 100644 --- a/frontik/integrations/statsd.py +++ b/frontik/integrations/statsd.py @@ -210,6 +210,6 @@ def create_statsd_client(options: Options, app: FrontikApplication) -> Union[Sta options.statsd_port, options.statsd_default_periodic_send_interval_sec, options.statsd_max_udp_size, - app=app.app_name, + app=app.app_module_name, ) return statsd_client diff --git a/frontik/json_builder.py b/frontik/json_builder.py index 9c98054e4..00d1349a9 100644 --- a/frontik/json_builder.py +++ b/frontik/json_builder.py @@ -130,7 +130,7 @@ def to_bytes(self) -> bytes: return json_encode_bytes(self._concat_chunks()) -def get_json_builder(request: Request) -> JsonBuilder: +async def get_json_builder(request: Request) -> JsonBuilder: return request['json_builder'] diff --git a/frontik/options.py b/frontik/options.py index a1b4e534c..fd65f210b 100644 --- a/frontik/options.py +++ b/frontik/options.py @@ -8,7 +8,6 @@ @dataclass class Options: - app: Optional[str] = None app_class: Optional[str] = None workers: int = 1 init_workers_timeout_sec: int = 60 @@ -17,6 +16,7 @@ class Options: reuse_port: bool = True xheaders: bool = False validate_request_id: bool = False + xsrf_cookies: bool = False config: Optional[str] = None host: str = '0.0.0.0' @@ -90,6 +90,7 @@ class Options: send_timeout_stats_interval_ms: int = 60000 # consul options + service_name: Optional[str] = None consul_enabled: bool = True consul_host: str = '127.0.0.1' consul_port: Optional[int] = None diff --git a/frontik/routing.py b/frontik/routing.py index 2a4efce41..7e228ecce 100644 --- a/frontik/routing.py +++ b/frontik/routing.py @@ -22,77 +22,77 @@ class FrontikRouter(APIRouter): - def __init__(self, *args: Any, **kwargs: Any) -> None: - super().__init__(*args, **kwargs) + def __init__(self, *, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> None: + super().__init__(**kwargs) routers.append(self) self._cls: Optional[Type[PageHandler]] = None - self._path: Optional[str] = None + self._base_cls: Optional[Type[PageHandler]] = cls def get(self, path: str, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> Callable: - self._path, self._cls = path, cls + self._cls = self._base_cls or cls return super().get(path, **kwargs) def post(self, path: str, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> Callable: - self._path, self._cls = path, cls + self._cls = self._base_cls or cls return super().post(path, **kwargs) def put(self, path: str, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> Callable: - self._path, self._cls = path, cls + self._cls = self._base_cls or cls return super().put(path, **kwargs) def delete(self, path: str, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> Callable: - self._path, self._cls = path, cls + self._cls = self._base_cls or cls return super().delete(path, **kwargs) def head(self, path: str, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> Callable: - self._path, self._cls = path, cls + self._cls = self._base_cls or cls return super().head(path, **kwargs) def add_api_route(self, *args, **kwargs): super().add_api_route(*args, **kwargs) route: APIRoute = self.routes[-1] # type: ignore method = next(iter(route.methods), None) + path = route.path.strip('/') - if _plain_routes.get((self._path, method), None) is not None: - raise RuntimeError(f'route for {method} {self._path} exists') + if _plain_routes.get((path, method), None) is not None: + raise RuntimeError(f'route for {method} {path} already exists') - _plain_routes[(self._path, method)] = (route, self._cls) # we need our routing, for get route object - self._cls, self._path = None, None + _plain_routes[(path, method)] = (route, self._cls) # we need our routing, for get route object class FrontikRegexRouter(APIRouter): - def __init__(self, *args: Any, **kwargs: Any) -> None: - super().__init__(*args, **kwargs) + def __init__(self, *, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> None: + super().__init__(**kwargs) routers.append(self) self._cls: Optional[Type[PageHandler]] = None - self._path: Optional[str] = None + self._base_cls: Optional[Type[PageHandler]] = cls def get(self, path: str, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> Callable: - self._path, self._cls = path, cls + self._cls = self._base_cls or cls return super().get(path, **kwargs) def post(self, path: str, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> Callable: - self._path, self._cls = path, cls + self._cls = self._base_cls or cls return super().post(path, **kwargs) def put(self, path: str, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> Callable: - self._path, self._cls = path, cls + self._cls = self._base_cls or cls return super().put(path, **kwargs) def delete(self, path: str, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> Callable: - self._path, self._cls = path, cls + self._cls = self._base_cls or cls return super().delete(path, **kwargs) def head(self, path: str, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> Callable: - self._path, self._cls = path, cls + self._cls = self._base_cls or cls return super().head(path, **kwargs) - def add_api_route(self, *args, **kwargs): + def add_api_route(self, *args: Any, cls: Optional[Type[PageHandler]] = None, **kwargs: Any) -> None: super().add_api_route(*args, **kwargs) + self._cls = self._base_cls or cls or self._cls + route = self.routes[-1] - _regex_mapping.append((re.compile(self._path), self.routes[-1], self._cls)) # type: ignore - - self._cls, self._path = None, None + _regex_mapping.append((re.compile(route.path), route, self._cls)) # type: ignore def _iter_submodules(path: MutableSequence[str], prefix: str = '') -> Generator: @@ -111,13 +111,15 @@ def _iter_submodules(path: MutableSequence[str], prefix: str = '') -> Generator: yield from _iter_submodules(paths, name + '.') -def import_all_pages(app_module: Optional[str]) -> None: +def import_all_pages(app_module: str) -> None: """Import all pages on startup""" - if app_module is None: + try: + pages_package = importlib.import_module(f'{app_module}.pages') + except ModuleNotFoundError: + routing_logger.warning('There is no pages module') return - pages_package = importlib.import_module(f'{app_module}.pages') for _, name, __ in _iter_submodules(pages_package.__path__): full_name = pages_package.__name__ + '.' + name try: @@ -125,8 +127,7 @@ def import_all_pages(app_module: Optional[str]) -> None: except ModuleNotFoundError: continue except Exception as ex: - routing_logger.error('failed on import page %s %s', full_name, ex) - continue + raise RuntimeError('failed on import page %s %s', full_name, ex) router = FrontikRouter() @@ -147,23 +148,23 @@ def _find_regex_route( def find_route(path: str, method: str) -> tuple[APIRoute, type, dict]: route: APIRoute - route, page_cls = _plain_routes.get((path, method), (None, None)) - path_params: dict = {} + route, page_cls, path_params = _find_regex_route(path, method) # type: ignore if route is None: - route, page_cls, path_params = _find_regex_route(path, method) + route, page_cls = _plain_routes.get((path.strip('/'), method), (None, None)) + path_params = {} if route is None: routing_logger.error('match for request url %s "%s" not found', method, path) return None, None, None - return route, page_cls, path_params + return route, page_cls, path_params # type: ignore def get_allowed_methods(path: str) -> list[str]: allowed_methods = [] for method in ('GET', 'POST', 'PUT', 'DELETE', 'HEAD'): - route, page_cls = _plain_routes.get((path, method), (None, None)) + route, _ = _plain_routes.get((path, method), (None, None)) if route is not None: allowed_methods.append(method) diff --git a/frontik/server.py b/frontik/server.py index 3657eba07..d7a11b3af 100644 --- a/frontik/server.py +++ b/frontik/server.py @@ -10,8 +10,9 @@ from concurrent.futures import ThreadPoolExecutor from functools import partial from threading import Lock -from typing import Any, Callable, Optional, Union +from typing import Callable, Optional, Union +import anyio import tornado.autoreload from http_client.balancing import Upstream from tornado.httpserver import HTTPServer @@ -28,33 +29,23 @@ def main(config_file: Optional[str] = None) -> None: parse_configs(config_files=config_file) - if options.app is None: - log.exception('no frontik application present (`app` option is not specified)') + if options.app_class is None: + log.exception('no frontik application present (`app_class` option is not specified)') sys.exit(1) - log.info('starting application %s', options.app) + log.info('starting application %s', options.app_class) try: - app_module = importlib.import_module(options.app) - app_class_name = None - app_module_name = options.app - except Exception: - try: - app_module_name, app_class_name = options.app.rsplit('.', 1) - app_module = importlib.import_module(app_module_name) - except Exception as e: - log.exception('failed to import application module "%s": %s', options.app, e) - - sys.exit(1) - - if app_class_name is not None and not hasattr(app_module, app_class_name): - log.exception('application class "%s" not found', options.app_class) + app_module_name, app_class_name = options.app_class.rsplit('.', 1) + app_module = importlib.import_module(app_module_name) + except Exception as e: + log.exception('failed to import application "%s": %s', options.app_class, e) sys.exit(1) application = getattr(app_module, app_class_name) if app_class_name is not None else FrontikApplication try: - app = application(app_module_name) + app = application() gc.disable() gc.collect() @@ -173,38 +164,8 @@ async def _deinit_app(app: FrontikApplication) -> None: log.exception('failed to deinit, deinit returned: %s', e) -class RequestCancelledMiddleware: - # https://github.com/tiangolo/fastapi/discussions/11360 - def __init__(self, app): - self.app = app - - async def __call__(self, scope, receive, send): - if scope['type'] != 'http': - await self.app(scope, receive, send) - return - - queue: asyncio.Queue = asyncio.Queue() - - async def message_poller(_sentinel: Any, _handler_task: Any) -> Any: - nonlocal queue - while True: - message = await receive() - if message['type'] == 'http.disconnect': - _handler_task.cancel() - return _sentinel - - await queue.put(message) - - sentinel = object() - handler_task = asyncio.create_task(self.app(scope, queue.get, send)) - poller_task = asyncio.create_task(message_poller(sentinel, handler_task)) - poller_task.done() - - try: - return await handler_task - except asyncio.CancelledError: - pass +def anyio_noop(*_args, **_kwargs): + raise RuntimeError(f'trying to use non async {_args[0]}') -def anyio_noop(*_args, **_kwargs): - raise RuntimeError(f'trying to use {_args[0]}') +anyio.to_thread.run_sync = anyio_noop diff --git a/frontik/testing.py b/frontik/testing.py index 3d1245aa2..828737813 100644 --- a/frontik/testing.py +++ b/frontik/testing.py @@ -11,6 +11,7 @@ from lxml import etree from tornado.escape import utf8 from tornado.httpserver import HTTPServer +from tornado.testing import AsyncHTTPTestCase from tornado_mock.httpclient import patch_http_client, set_stub from yarl import URL @@ -227,3 +228,78 @@ def guess_content_type_headers(file_name: str) -> dict[str, str]: if file_name.endswith('.proto'): return {'Content-Type': APPLICATION_PROTOBUF} return {} + + +class FrontikTestCase(AsyncHTTPTestCase): + """Deprecated, use FrontikTestBase instead""" + + def __init__(self, *args, **kwargs): + self._app: FrontikApplication # type: ignore + super().__init__(*args, **kwargs) + + def get_http_client(self): + """Overrides `AsyncHTTPTestCase.get_http_client` to separate unit test HTTPClient + from application HTTPClient. + + This allows mocking HTTP requests made by application in unit tests. + """ + self.forced_client = AIOHttpClientWrapper() + return self.forced_client + + def fetch(self, path: str, query: Optional[dict] = None, **kwargs: Any) -> RequestResult: # type: ignore + """Extends `AsyncHTTPTestCase.fetch` method with `query` kwarg. + This argument accepts a `dict` of request query parameters that will be encoded + and added to request path. + Any additional kwargs will be passed to `AsyncHTTPTestCase.fetch`. + """ + query = {} if query is None else query + return super().fetch(make_url(path, **query), **kwargs) + + def fetch_xml(self, path: str, query: Optional[dict] = None, **kwargs: Any) -> etree.Element: + """Fetch the request and parse xml document from response body.""" + return etree.fromstring(utf8(self.fetch(path, query, **kwargs).raw_body)) + + def fetch_json(self, path: str, query: Optional[dict] = None, **kwargs: Any) -> Any: + """Fetch the request and parse JSON tree from response body.""" + return json.loads(self.fetch(path, query, **kwargs).raw_body) + + def patch_app_http_client(self, app: FrontikApplication) -> None: + """Patches application HTTPClient to enable requests stubbing.""" + patch_http_client(app.http_client) + + def set_stub( + self, + url: str, + request_method: str = 'GET', + response_function: Optional[Callable] = None, + response_file: Optional[str] = None, + response_body: Any = '', + response_code: int = 200, + response_headers: Any = None, + response_body_processor: Callable = safe_template, + **kwargs: Any, + ) -> None: + set_stub( + self._app.http_client, + url, + request_method, + response_function, + response_file, + response_body, + response_code, + response_headers, + response_body_processor, + **kwargs, + ) + + def tearDown(self) -> None: + if self._app.http_client is not None: + self.io_loop.run_sync(self._app.http_client.client_session.close) + if self.forced_client is not None: + self.io_loop.run_sync(self.forced_client.client_session.close) + super().tearDown() + + def configure_app(self, **kwargs: Any) -> None: + """Updates or adds options to application config.""" + for name, val in kwargs.items(): + setattr(self._app.config, name, val) diff --git a/poetry.lock b/poetry.lock index af39c14b2..b17a9c635 100644 --- a/poetry.lock +++ b/poetry.lock @@ -263,24 +263,24 @@ tests-no-zope = ["attrs[tests-mypy]", "cloudpickle", "hypothesis", "pympler", "p [[package]] name = "cachetools" -version = "5.3.3" +version = "5.4.0" description = "Extensible memoizing collections and decorators" optional = false python-versions = ">=3.7" files = [ - {file = "cachetools-5.3.3-py3-none-any.whl", hash = "sha256:0abad1021d3f8325b2fc1d2e9c8b9c9d57b04c3932657a72465447332c24d945"}, - {file = "cachetools-5.3.3.tar.gz", hash = "sha256:ba29e2dfa0b8b556606f097407ed1aa62080ee108ab0dc5ec9d6a723a007d105"}, + {file = "cachetools-5.4.0-py3-none-any.whl", hash = "sha256:3ae3b49a3d5e28a77a0be2b37dbcb89005058959cb2323858c2657c4a8cab474"}, + {file = "cachetools-5.4.0.tar.gz", hash = "sha256:b8adc2e7c07f105ced7bc56dbb6dfbe7c4a00acce20e2227b3f355be89bc6827"}, ] [[package]] name = "certifi" -version = "2024.6.2" +version = "2024.7.4" description = "Python package for providing Mozilla's CA Bundle." optional = false python-versions = ">=3.6" files = [ - {file = "certifi-2024.6.2-py3-none-any.whl", hash = "sha256:ddc6c8ce995e6987e7faf5e3f1b02b302836a0e5d98ece18392cb1a36c72ad56"}, - {file = "certifi-2024.6.2.tar.gz", hash = "sha256:3cd43f1c6fa7dedc5899d69d3ad0398fd018ad1a17fba83ddaf78aa46c747516"}, + {file = "certifi-2024.7.4-py3-none-any.whl", hash = "sha256:c198e21b1289c2ab85ee4e67bb4b4ef3ead0892059901a8d5b622f24a1101e90"}, + {file = "certifi-2024.7.4.tar.gz", hash = "sha256:5a1e7645bc0ec61a09e26c36f6106dd4cf40c6db3a1fb6352b0244e7fb057c7b"}, ] [[package]] @@ -502,65 +502,65 @@ grpc = ["grpcio (>=1.44.0,<2.0.0.dev0)"] [[package]] name = "grpcio" -version = "1.64.1" +version = "1.65.1" description = "HTTP/2-based RPC framework" optional = false python-versions = ">=3.8" files = [ - {file = "grpcio-1.64.1-cp310-cp310-linux_armv7l.whl", hash = "sha256:55697ecec192bc3f2f3cc13a295ab670f51de29884ca9ae6cd6247df55df2502"}, - {file = "grpcio-1.64.1-cp310-cp310-macosx_12_0_universal2.whl", hash = "sha256:3b64ae304c175671efdaa7ec9ae2cc36996b681eb63ca39c464958396697daff"}, - {file = "grpcio-1.64.1-cp310-cp310-manylinux_2_17_aarch64.whl", hash = "sha256:bac71b4b28bc9af61efcdc7630b166440bbfbaa80940c9a697271b5e1dabbc61"}, - {file = "grpcio-1.64.1-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6c024ffc22d6dc59000faf8ad781696d81e8e38f4078cb0f2630b4a3cf231a90"}, - {file = "grpcio-1.64.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e7cd5c1325f6808b8ae31657d281aadb2a51ac11ab081ae335f4f7fc44c1721d"}, - {file = "grpcio-1.64.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:0a2813093ddb27418a4c99f9b1c223fab0b053157176a64cc9db0f4557b69bd9"}, - {file = "grpcio-1.64.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:2981c7365a9353f9b5c864595c510c983251b1ab403e05b1ccc70a3d9541a73b"}, - {file = "grpcio-1.64.1-cp310-cp310-win32.whl", hash = "sha256:1262402af5a511c245c3ae918167eca57342c72320dffae5d9b51840c4b2f86d"}, - {file = "grpcio-1.64.1-cp310-cp310-win_amd64.whl", hash = "sha256:19264fc964576ddb065368cae953f8d0514ecc6cb3da8903766d9fb9d4554c33"}, - {file = "grpcio-1.64.1-cp311-cp311-linux_armv7l.whl", hash = "sha256:58b1041e7c870bb30ee41d3090cbd6f0851f30ae4eb68228955d973d3efa2e61"}, - {file = "grpcio-1.64.1-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:bbc5b1d78a7822b0a84c6f8917faa986c1a744e65d762ef6d8be9d75677af2ca"}, - {file = "grpcio-1.64.1-cp311-cp311-manylinux_2_17_aarch64.whl", hash = "sha256:5841dd1f284bd1b3d8a6eca3a7f062b06f1eec09b184397e1d1d43447e89a7ae"}, - {file = "grpcio-1.64.1-cp311-cp311-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:8caee47e970b92b3dd948371230fcceb80d3f2277b3bf7fbd7c0564e7d39068e"}, - {file = "grpcio-1.64.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:73819689c169417a4f978e562d24f2def2be75739c4bed1992435d007819da1b"}, - {file = "grpcio-1.64.1-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:6503b64c8b2dfad299749cad1b595c650c91e5b2c8a1b775380fcf8d2cbba1e9"}, - {file = "grpcio-1.64.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:1de403fc1305fd96cfa75e83be3dee8538f2413a6b1685b8452301c7ba33c294"}, - {file = "grpcio-1.64.1-cp311-cp311-win32.whl", hash = "sha256:d4d29cc612e1332237877dfa7fe687157973aab1d63bd0f84cf06692f04c0367"}, - {file = "grpcio-1.64.1-cp311-cp311-win_amd64.whl", hash = "sha256:5e56462b05a6f860b72f0fa50dca06d5b26543a4e88d0396259a07dc30f4e5aa"}, - {file = "grpcio-1.64.1-cp312-cp312-linux_armv7l.whl", hash = "sha256:4657d24c8063e6095f850b68f2d1ba3b39f2b287a38242dcabc166453e950c59"}, - {file = "grpcio-1.64.1-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:62b4e6eb7bf901719fce0ca83e3ed474ae5022bb3827b0a501e056458c51c0a1"}, - {file = "grpcio-1.64.1-cp312-cp312-manylinux_2_17_aarch64.whl", hash = "sha256:ee73a2f5ca4ba44fa33b4d7d2c71e2c8a9e9f78d53f6507ad68e7d2ad5f64a22"}, - {file = "grpcio-1.64.1-cp312-cp312-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:198908f9b22e2672a998870355e226a725aeab327ac4e6ff3a1399792ece4762"}, - {file = "grpcio-1.64.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:39b9d0acaa8d835a6566c640f48b50054f422d03e77e49716d4c4e8e279665a1"}, - {file = "grpcio-1.64.1-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:5e42634a989c3aa6049f132266faf6b949ec2a6f7d302dbb5c15395b77d757eb"}, - {file = "grpcio-1.64.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:b1a82e0b9b3022799c336e1fc0f6210adc019ae84efb7321d668129d28ee1efb"}, - {file = "grpcio-1.64.1-cp312-cp312-win32.whl", hash = "sha256:55260032b95c49bee69a423c2f5365baa9369d2f7d233e933564d8a47b893027"}, - {file = "grpcio-1.64.1-cp312-cp312-win_amd64.whl", hash = "sha256:c1a786ac592b47573a5bb7e35665c08064a5d77ab88a076eec11f8ae86b3e3f6"}, - {file = "grpcio-1.64.1-cp38-cp38-linux_armv7l.whl", hash = "sha256:a011ac6c03cfe162ff2b727bcb530567826cec85eb8d4ad2bfb4bd023287a52d"}, - {file = "grpcio-1.64.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:4d6dab6124225496010bd22690f2d9bd35c7cbb267b3f14e7a3eb05c911325d4"}, - {file = "grpcio-1.64.1-cp38-cp38-manylinux_2_17_aarch64.whl", hash = "sha256:a5e771d0252e871ce194d0fdcafd13971f1aae0ddacc5f25615030d5df55c3a2"}, - {file = "grpcio-1.64.1-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:2c3c1b90ab93fed424e454e93c0ed0b9d552bdf1b0929712b094f5ecfe7a23ad"}, - {file = "grpcio-1.64.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:20405cb8b13fd779135df23fabadc53b86522d0f1cba8cca0e87968587f50650"}, - {file = "grpcio-1.64.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:0cc79c982ccb2feec8aad0e8fb0d168bcbca85bc77b080d0d3c5f2f15c24ea8f"}, - {file = "grpcio-1.64.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:a3a035c37ce7565b8f4f35ff683a4db34d24e53dc487e47438e434eb3f701b2a"}, - {file = "grpcio-1.64.1-cp38-cp38-win32.whl", hash = "sha256:1257b76748612aca0f89beec7fa0615727fd6f2a1ad580a9638816a4b2eb18fd"}, - {file = "grpcio-1.64.1-cp38-cp38-win_amd64.whl", hash = "sha256:0a12ddb1678ebc6a84ec6b0487feac020ee2b1659cbe69b80f06dbffdb249122"}, - {file = "grpcio-1.64.1-cp39-cp39-linux_armv7l.whl", hash = "sha256:75dbbf415026d2862192fe1b28d71f209e2fd87079d98470db90bebe57b33179"}, - {file = "grpcio-1.64.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e3d9f8d1221baa0ced7ec7322a981e28deb23749c76eeeb3d33e18b72935ab62"}, - {file = "grpcio-1.64.1-cp39-cp39-manylinux_2_17_aarch64.whl", hash = "sha256:5f8b75f64d5d324c565b263c67dbe4f0af595635bbdd93bb1a88189fc62ed2e5"}, - {file = "grpcio-1.64.1-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:c84ad903d0d94311a2b7eea608da163dace97c5fe9412ea311e72c3684925602"}, - {file = "grpcio-1.64.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:940e3ec884520155f68a3b712d045e077d61c520a195d1a5932c531f11883489"}, - {file = "grpcio-1.64.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:f10193c69fc9d3d726e83bbf0f3d316f1847c3071c8c93d8090cf5f326b14309"}, - {file = "grpcio-1.64.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:ac15b6c2c80a4d1338b04d42a02d376a53395ddf0ec9ab157cbaf44191f3ffdd"}, - {file = "grpcio-1.64.1-cp39-cp39-win32.whl", hash = "sha256:03b43d0ccf99c557ec671c7dede64f023c7da9bb632ac65dbc57f166e4970040"}, - {file = "grpcio-1.64.1-cp39-cp39-win_amd64.whl", hash = "sha256:ed6091fa0adcc7e4ff944090cf203a52da35c37a130efa564ded02b7aff63bcd"}, - {file = "grpcio-1.64.1.tar.gz", hash = "sha256:8d51dd1c59d5fa0f34266b80a3805ec29a1f26425c2a54736133f6d87fc4968a"}, + {file = "grpcio-1.65.1-cp310-cp310-linux_armv7l.whl", hash = "sha256:3dc5f928815b8972fb83b78d8db5039559f39e004ec93ebac316403fe031a062"}, + {file = "grpcio-1.65.1-cp310-cp310-macosx_12_0_universal2.whl", hash = "sha256:8333ca46053c35484c9f2f7e8d8ec98c1383a8675a449163cea31a2076d93de8"}, + {file = "grpcio-1.65.1-cp310-cp310-manylinux_2_17_aarch64.whl", hash = "sha256:7af64838b6e615fff0ec711960ed9b6ee83086edfa8c32670eafb736f169d719"}, + {file = "grpcio-1.65.1-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:dbb64b4166362d9326f7efbf75b1c72106c1aa87f13a8c8b56a1224fac152f5c"}, + {file = "grpcio-1.65.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a8422dc13ad93ec8caa2612b5032a2b9cd6421c13ed87f54db4a3a2c93afaf77"}, + {file = "grpcio-1.65.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:4effc0562b6c65d4add6a873ca132e46ba5e5a46f07c93502c37a9ae7f043857"}, + {file = "grpcio-1.65.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:a6c71575a2fedf259724981fd73a18906513d2f306169c46262a5bae956e6364"}, + {file = "grpcio-1.65.1-cp310-cp310-win32.whl", hash = "sha256:34966cf526ef0ea616e008d40d989463e3db157abb213b2f20c6ce0ae7928875"}, + {file = "grpcio-1.65.1-cp310-cp310-win_amd64.whl", hash = "sha256:ca931de5dd6d9eb94ff19a2c9434b23923bce6f767179fef04dfa991f282eaad"}, + {file = "grpcio-1.65.1-cp311-cp311-linux_armv7l.whl", hash = "sha256:bbb46330cc643ecf10bd9bd4ca8e7419a14b6b9dedd05f671c90fb2c813c6037"}, + {file = "grpcio-1.65.1-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:d827a6fb9215b961eb73459ad7977edb9e748b23e3407d21c845d1d8ef6597e5"}, + {file = "grpcio-1.65.1-cp311-cp311-manylinux_2_17_aarch64.whl", hash = "sha256:6e71aed8835f8d9fbcb84babc93a9da95955d1685021cceb7089f4f1e717d719"}, + {file = "grpcio-1.65.1-cp311-cp311-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:9a1c84560b3b2d34695c9ba53ab0264e2802721c530678a8f0a227951f453462"}, + {file = "grpcio-1.65.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:27adee2338d697e71143ed147fe286c05810965d5d30ec14dd09c22479bfe48a"}, + {file = "grpcio-1.65.1-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:f62652ddcadc75d0e7aa629e96bb61658f85a993e748333715b4ab667192e4e8"}, + {file = "grpcio-1.65.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:71a05fd814700dd9cb7d9a507f2f6a1ef85866733ccaf557eedacec32d65e4c2"}, + {file = "grpcio-1.65.1-cp311-cp311-win32.whl", hash = "sha256:b590f1ad056294dfaeac0b7e1b71d3d5ace638d8dd1f1147ce4bd13458783ba8"}, + {file = "grpcio-1.65.1-cp311-cp311-win_amd64.whl", hash = "sha256:12e9bdf3b5fd48e5fbe5b3da382ad8f97c08b47969f3cca81dd9b36b86ed39e2"}, + {file = "grpcio-1.65.1-cp312-cp312-linux_armv7l.whl", hash = "sha256:54cb822e177374b318b233e54b6856c692c24cdbd5a3ba5335f18a47396bac8f"}, + {file = "grpcio-1.65.1-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:aaf3c54419a28d45bd1681372029f40e5bfb58e5265e3882eaf21e4a5f81a119"}, + {file = "grpcio-1.65.1-cp312-cp312-manylinux_2_17_aarch64.whl", hash = "sha256:557de35bdfbe8bafea0a003dbd0f4da6d89223ac6c4c7549d78e20f92ead95d9"}, + {file = "grpcio-1.65.1-cp312-cp312-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:8bfd95ef3b097f0cc86ade54eafefa1c8ed623aa01a26fbbdcd1a3650494dd11"}, + {file = "grpcio-1.65.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9e6a8f3d6c41e6b642870afe6cafbaf7b61c57317f9ec66d0efdaf19db992b90"}, + {file = "grpcio-1.65.1-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:1faaf7355ceed07ceaef0b9dcefa4c98daf1dd8840ed75c2de128c3f4a4d859d"}, + {file = "grpcio-1.65.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:60f1f38eed830488ad2a1b11579ef0f345ff16fffdad1d24d9fbc97ba31804ff"}, + {file = "grpcio-1.65.1-cp312-cp312-win32.whl", hash = "sha256:e75acfa52daf5ea0712e8aa82f0003bba964de7ae22c26d208cbd7bc08500177"}, + {file = "grpcio-1.65.1-cp312-cp312-win_amd64.whl", hash = "sha256:ff5a84907e51924973aa05ed8759210d8cdae7ffcf9e44fd17646cf4a902df59"}, + {file = "grpcio-1.65.1-cp38-cp38-linux_armv7l.whl", hash = "sha256:1fbd6331f18c3acd7e09d17fd840c096f56eaf0ef830fbd50af45ae9dc8dfd83"}, + {file = "grpcio-1.65.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:de5b6be29116e094c5ef9d9e4252e7eb143e3d5f6bd6d50a78075553ab4930b0"}, + {file = "grpcio-1.65.1-cp38-cp38-manylinux_2_17_aarch64.whl", hash = "sha256:e4a3cdba62b2d6aeae6027ae65f350de6dc082b72e6215eccf82628e79efe9ba"}, + {file = "grpcio-1.65.1-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:941c4869aa229d88706b78187d60d66aca77fe5c32518b79e3c3e03fc26109a2"}, + {file = "grpcio-1.65.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f40cebe5edb518d78b8131e87cb83b3ee688984de38a232024b9b44e74ee53d3"}, + {file = "grpcio-1.65.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:2ca684ba331fb249d8a1ce88db5394e70dbcd96e58d8c4b7e0d7b141a453dce9"}, + {file = "grpcio-1.65.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:8558f0083ddaf5de64a59c790bffd7568e353914c0c551eae2955f54ee4b857f"}, + {file = "grpcio-1.65.1-cp38-cp38-win32.whl", hash = "sha256:8d8143a3e3966f85dce6c5cc45387ec36552174ba5712c5dc6fcc0898fb324c0"}, + {file = "grpcio-1.65.1-cp38-cp38-win_amd64.whl", hash = "sha256:76e81a86424d6ca1ce7c16b15bdd6a964a42b40544bf796a48da241fdaf61153"}, + {file = "grpcio-1.65.1-cp39-cp39-linux_armv7l.whl", hash = "sha256:cb5175f45c980ff418998723ea1b3869cce3766d2ab4e4916fbd3cedbc9d0ed3"}, + {file = "grpcio-1.65.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:b12c1aa7b95abe73b3e04e052c8b362655b41c7798da69f1eaf8d186c7d204df"}, + {file = "grpcio-1.65.1-cp39-cp39-manylinux_2_17_aarch64.whl", hash = "sha256:3019fb50128b21a5e018d89569ffaaaa361680e1346c2f261bb84a91082eb3d3"}, + {file = "grpcio-1.65.1-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7ae15275ed98ea267f64ee9ddedf8ecd5306a5b5bb87972a48bfe24af24153e8"}, + {file = "grpcio-1.65.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5f096ffb881f37e8d4f958b63c74bfc400c7cebd7a944b027357cd2fb8d91a57"}, + {file = "grpcio-1.65.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:2f56b5a68fdcf17a0a1d524bf177218c3c69b3947cb239ea222c6f1867c3ab68"}, + {file = "grpcio-1.65.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:941596d419b9736ab548aa0feb5bbba922f98872668847bf0720b42d1d227b9e"}, + {file = "grpcio-1.65.1-cp39-cp39-win32.whl", hash = "sha256:5fd7337a823b890215f07d429f4f193d24b80d62a5485cf88ee06648591a0c57"}, + {file = "grpcio-1.65.1-cp39-cp39-win_amd64.whl", hash = "sha256:1bceeec568372cbebf554eae1b436b06c2ff24cfaf04afade729fb9035408c6c"}, + {file = "grpcio-1.65.1.tar.gz", hash = "sha256:3c492301988cd720cd145d84e17318d45af342e29ef93141228f9cd73222368b"}, ] [package.extras] -protobuf = ["grpcio-tools (>=1.64.1)"] +protobuf = ["grpcio-tools (>=1.65.1)"] [[package]] name = "http-client" -version = "2.1.14" +version = "2.1.15" description = "Balancing http client around aiohttp" optional = false python-versions = "~=3.9" @@ -576,8 +576,8 @@ yarl = "1.9.2" [package.source] type = "git" url = "https://github.com/hhru/balancing-http-client.git" -reference = "2.1.14" -resolved_reference = "a64a31f40bf632feec2da6d210d1123006738dff" +reference = "2.1.15" +resolved_reference = "4cb3b320e7b4fd2c5e4fc05ed42acd981c89ae25" [[package]] name = "idna" @@ -1187,57 +1187,62 @@ files = [ [[package]] name = "orjson" -version = "3.10.5" +version = "3.10.6" description = "Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy" optional = false python-versions = ">=3.8" files = [ - {file = "orjson-3.10.5-cp310-cp310-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl", hash = "sha256:545d493c1f560d5ccfc134803ceb8955a14c3fcb47bbb4b2fee0232646d0b932"}, - {file = "orjson-3.10.5-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f4324929c2dd917598212bfd554757feca3e5e0fa60da08be11b4aa8b90013c1"}, - {file = "orjson-3.10.5-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:8c13ca5e2ddded0ce6a927ea5a9f27cae77eee4c75547b4297252cb20c4d30e6"}, - {file = "orjson-3.10.5-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b6c8e30adfa52c025f042a87f450a6b9ea29649d828e0fec4858ed5e6caecf63"}, - {file = "orjson-3.10.5-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:338fd4f071b242f26e9ca802f443edc588fa4ab60bfa81f38beaedf42eda226c"}, - {file = "orjson-3.10.5-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:6970ed7a3126cfed873c5d21ece1cd5d6f83ca6c9afb71bbae21a0b034588d96"}, - {file = "orjson-3.10.5-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:235dadefb793ad12f7fa11e98a480db1f7c6469ff9e3da5e73c7809c700d746b"}, - {file = "orjson-3.10.5-cp310-none-win32.whl", hash = "sha256:be79e2393679eda6a590638abda16d167754393f5d0850dcbca2d0c3735cebe2"}, - {file = "orjson-3.10.5-cp310-none-win_amd64.whl", hash = "sha256:c4a65310ccb5c9910c47b078ba78e2787cb3878cdded1702ac3d0da71ddc5228"}, - {file = "orjson-3.10.5-cp311-cp311-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl", hash = "sha256:cdf7365063e80899ae3a697def1277c17a7df7ccfc979990a403dfe77bb54d40"}, - {file = "orjson-3.10.5-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6b68742c469745d0e6ca5724506858f75e2f1e5b59a4315861f9e2b1df77775a"}, - {file = "orjson-3.10.5-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:7d10cc1b594951522e35a3463da19e899abe6ca95f3c84c69e9e901e0bd93d38"}, - {file = "orjson-3.10.5-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dcbe82b35d1ac43b0d84072408330fd3295c2896973112d495e7234f7e3da2e1"}, - {file = "orjson-3.10.5-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c0eb7e0c75e1e486c7563fe231b40fdd658a035ae125c6ba651ca3b07936f5"}, - {file = "orjson-3.10.5-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:53ed1c879b10de56f35daf06dbc4a0d9a5db98f6ee853c2dbd3ee9d13e6f302f"}, - {file = "orjson-3.10.5-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:099e81a5975237fda3100f918839af95f42f981447ba8f47adb7b6a3cdb078fa"}, - {file = "orjson-3.10.5-cp311-none-win32.whl", hash = "sha256:1146bf85ea37ac421594107195db8bc77104f74bc83e8ee21a2e58596bfb2f04"}, - {file = "orjson-3.10.5-cp311-none-win_amd64.whl", hash = "sha256:36a10f43c5f3a55c2f680efe07aa93ef4a342d2960dd2b1b7ea2dd764fe4a37c"}, - {file = "orjson-3.10.5-cp312-cp312-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl", hash = "sha256:68f85ecae7af14a585a563ac741b0547a3f291de81cd1e20903e79f25170458f"}, - {file = "orjson-3.10.5-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:28afa96f496474ce60d3340fe8d9a263aa93ea01201cd2bad844c45cd21f5268"}, - {file = "orjson-3.10.5-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:9cd684927af3e11b6e754df80b9ffafd9fb6adcaa9d3e8fdd5891be5a5cad51e"}, - {file = "orjson-3.10.5-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3d21b9983da032505f7050795e98b5d9eee0df903258951566ecc358f6696969"}, - {file = "orjson-3.10.5-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1ad1de7fef79736dde8c3554e75361ec351158a906d747bd901a52a5c9c8d24b"}, - {file = "orjson-3.10.5-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:2d97531cdfe9bdd76d492e69800afd97e5930cb0da6a825646667b2c6c6c0211"}, - {file = "orjson-3.10.5-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:d69858c32f09c3e1ce44b617b3ebba1aba030e777000ebdf72b0d8e365d0b2b3"}, - {file = "orjson-3.10.5-cp312-none-win32.whl", hash = "sha256:64c9cc089f127e5875901ac05e5c25aa13cfa5dbbbd9602bda51e5c611d6e3e2"}, - {file = "orjson-3.10.5-cp312-none-win_amd64.whl", hash = "sha256:b2efbd67feff8c1f7728937c0d7f6ca8c25ec81373dc8db4ef394c1d93d13dc5"}, - {file = "orjson-3.10.5-cp38-cp38-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl", hash = "sha256:03b565c3b93f5d6e001db48b747d31ea3819b89abf041ee10ac6988886d18e01"}, - {file = "orjson-3.10.5-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:584c902ec19ab7928fd5add1783c909094cc53f31ac7acfada817b0847975f26"}, - {file = "orjson-3.10.5-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:5a35455cc0b0b3a1eaf67224035f5388591ec72b9b6136d66b49a553ce9eb1e6"}, - {file = "orjson-3.10.5-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1670fe88b116c2745a3a30b0f099b699a02bb3482c2591514baf5433819e4f4d"}, - {file = "orjson-3.10.5-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:185c394ef45b18b9a7d8e8f333606e2e8194a50c6e3c664215aae8cf42c5385e"}, - {file = "orjson-3.10.5-cp38-cp38-musllinux_1_2_aarch64.whl", hash = "sha256:ca0b3a94ac8d3886c9581b9f9de3ce858263865fdaa383fbc31c310b9eac07c9"}, - {file = "orjson-3.10.5-cp38-cp38-musllinux_1_2_x86_64.whl", hash = "sha256:dfc91d4720d48e2a709e9c368d5125b4b5899dced34b5400c3837dadc7d6271b"}, - {file = "orjson-3.10.5-cp38-none-win32.whl", hash = "sha256:c05f16701ab2a4ca146d0bca950af254cb7c02f3c01fca8efbbad82d23b3d9d4"}, - {file = "orjson-3.10.5-cp38-none-win_amd64.whl", hash = "sha256:8a11d459338f96a9aa7f232ba95679fc0c7cedbd1b990d736467894210205c09"}, - {file = "orjson-3.10.5-cp39-cp39-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl", hash = "sha256:85c89131d7b3218db1b24c4abecea92fd6c7f9fab87441cfc342d3acc725d807"}, - {file = "orjson-3.10.5-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:fb66215277a230c456f9038d5e2d84778141643207f85336ef8d2a9da26bd7ca"}, - {file = "orjson-3.10.5-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:51bbcdea96cdefa4a9b4461e690c75ad4e33796530d182bdd5c38980202c134a"}, - {file = "orjson-3.10.5-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbead71dbe65f959b7bd8cf91e0e11d5338033eba34c114f69078d59827ee139"}, - {file = "orjson-3.10.5-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5df58d206e78c40da118a8c14fc189207fffdcb1f21b3b4c9c0c18e839b5a214"}, - {file = "orjson-3.10.5-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:c4057c3b511bb8aef605616bd3f1f002a697c7e4da6adf095ca5b84c0fd43595"}, - {file = "orjson-3.10.5-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:b39e006b00c57125ab974362e740c14a0c6a66ff695bff44615dcf4a70ce2b86"}, - {file = "orjson-3.10.5-cp39-none-win32.whl", hash = "sha256:eded5138cc565a9d618e111c6d5c2547bbdd951114eb822f7f6309e04db0fb47"}, - {file = "orjson-3.10.5-cp39-none-win_amd64.whl", hash = "sha256:cc28e90a7cae7fcba2493953cff61da5a52950e78dc2dacfe931a317ee3d8de7"}, - {file = "orjson-3.10.5.tar.gz", hash = "sha256:7a5baef8a4284405d96c90c7c62b755e9ef1ada84c2406c24a9ebec86b89f46d"}, + {file = "orjson-3.10.6-cp310-cp310-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl", hash = "sha256:fb0ee33124db6eaa517d00890fc1a55c3bfe1cf78ba4a8899d71a06f2d6ff5c7"}, + {file = "orjson-3.10.6-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9c1c4b53b24a4c06547ce43e5fee6ec4e0d8fe2d597f4647fc033fd205707365"}, + {file = "orjson-3.10.6-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:eadc8fd310edb4bdbd333374f2c8fec6794bbbae99b592f448d8214a5e4050c0"}, + {file = "orjson-3.10.6-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:61272a5aec2b2661f4fa2b37c907ce9701e821b2c1285d5c3ab0207ebd358d38"}, + {file = "orjson-3.10.6-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:57985ee7e91d6214c837936dc1608f40f330a6b88bb13f5a57ce5257807da143"}, + {file = "orjson-3.10.6-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:633a3b31d9d7c9f02d49c4ab4d0a86065c4a6f6adc297d63d272e043472acab5"}, + {file = "orjson-3.10.6-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:1c680b269d33ec444afe2bdc647c9eb73166fa47a16d9a75ee56a374f4a45f43"}, + {file = "orjson-3.10.6-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:f759503a97a6ace19e55461395ab0d618b5a117e8d0fbb20e70cfd68a47327f2"}, + {file = "orjson-3.10.6-cp310-none-win32.whl", hash = "sha256:95a0cce17f969fb5391762e5719575217bd10ac5a189d1979442ee54456393f3"}, + {file = "orjson-3.10.6-cp310-none-win_amd64.whl", hash = "sha256:df25d9271270ba2133cc88ee83c318372bdc0f2cd6f32e7a450809a111efc45c"}, + {file = "orjson-3.10.6-cp311-cp311-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl", hash = "sha256:b1ec490e10d2a77c345def52599311849fc063ae0e67cf4f84528073152bb2ba"}, + {file = "orjson-3.10.6-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:55d43d3feb8f19d07e9f01e5b9be4f28801cf7c60d0fa0d279951b18fae1932b"}, + {file = "orjson-3.10.6-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:ac3045267e98fe749408eee1593a142e02357c5c99be0802185ef2170086a863"}, + {file = "orjson-3.10.6-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c27bc6a28ae95923350ab382c57113abd38f3928af3c80be6f2ba7eb8d8db0b0"}, + {file = "orjson-3.10.6-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:d27456491ca79532d11e507cadca37fb8c9324a3976294f68fb1eff2dc6ced5a"}, + {file = "orjson-3.10.6-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:05ac3d3916023745aa3b3b388e91b9166be1ca02b7c7e41045da6d12985685f0"}, + {file = "orjson-3.10.6-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:1335d4ef59ab85cab66fe73fd7a4e881c298ee7f63ede918b7faa1b27cbe5212"}, + {file = "orjson-3.10.6-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:4bbc6d0af24c1575edc79994c20e1b29e6fb3c6a570371306db0993ecf144dc5"}, + {file = "orjson-3.10.6-cp311-none-win32.whl", hash = "sha256:450e39ab1f7694465060a0550b3f6d328d20297bf2e06aa947b97c21e5241fbd"}, + {file = "orjson-3.10.6-cp311-none-win_amd64.whl", hash = "sha256:227df19441372610b20e05bdb906e1742ec2ad7a66ac8350dcfd29a63014a83b"}, + {file = "orjson-3.10.6-cp312-cp312-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl", hash = "sha256:ea2977b21f8d5d9b758bb3f344a75e55ca78e3ff85595d248eee813ae23ecdfb"}, + {file = "orjson-3.10.6-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b6f3d167d13a16ed263b52dbfedff52c962bfd3d270b46b7518365bcc2121eed"}, + {file = "orjson-3.10.6-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:f710f346e4c44a4e8bdf23daa974faede58f83334289df80bc9cd12fe82573c7"}, + {file = "orjson-3.10.6-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:7275664f84e027dcb1ad5200b8b18373e9c669b2a9ec33d410c40f5ccf4b257e"}, + {file = "orjson-3.10.6-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0943e4c701196b23c240b3d10ed8ecd674f03089198cf503105b474a4f77f21f"}, + {file = "orjson-3.10.6-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:446dee5a491b5bc7d8f825d80d9637e7af43f86a331207b9c9610e2f93fee22a"}, + {file = "orjson-3.10.6-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:64c81456d2a050d380786413786b057983892db105516639cb5d3ee3c7fd5148"}, + {file = "orjson-3.10.6-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:960db0e31c4e52fa0fc3ecbaea5b2d3b58f379e32a95ae6b0ebeaa25b93dfd34"}, + {file = "orjson-3.10.6-cp312-none-win32.whl", hash = "sha256:a6ea7afb5b30b2317e0bee03c8d34c8181bc5a36f2afd4d0952f378972c4efd5"}, + {file = "orjson-3.10.6-cp312-none-win_amd64.whl", hash = "sha256:874ce88264b7e655dde4aeaacdc8fd772a7962faadfb41abe63e2a4861abc3dc"}, + {file = "orjson-3.10.6-cp38-cp38-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl", hash = "sha256:66680eae4c4e7fc193d91cfc1353ad6d01b4801ae9b5314f17e11ba55e934183"}, + {file = "orjson-3.10.6-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:caff75b425db5ef8e8f23af93c80f072f97b4fb3afd4af44482905c9f588da28"}, + {file = "orjson-3.10.6-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:3722fddb821b6036fd2a3c814f6bd9b57a89dc6337b9924ecd614ebce3271394"}, + {file = "orjson-3.10.6-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c2c116072a8533f2fec435fde4d134610f806bdac20188c7bd2081f3e9e0133f"}, + {file = "orjson-3.10.6-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:6eeb13218c8cf34c61912e9df2de2853f1d009de0e46ea09ccdf3d757896af0a"}, + {file = "orjson-3.10.6-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:965a916373382674e323c957d560b953d81d7a8603fbeee26f7b8248638bd48b"}, + {file = "orjson-3.10.6-cp38-cp38-musllinux_1_2_aarch64.whl", hash = "sha256:03c95484d53ed8e479cade8628c9cea00fd9d67f5554764a1110e0d5aa2de96e"}, + {file = "orjson-3.10.6-cp38-cp38-musllinux_1_2_x86_64.whl", hash = "sha256:e060748a04cccf1e0a6f2358dffea9c080b849a4a68c28b1b907f272b5127e9b"}, + {file = "orjson-3.10.6-cp38-none-win32.whl", hash = "sha256:738dbe3ef909c4b019d69afc19caf6b5ed0e2f1c786b5d6215fbb7539246e4c6"}, + {file = "orjson-3.10.6-cp38-none-win_amd64.whl", hash = "sha256:d40f839dddf6a7d77114fe6b8a70218556408c71d4d6e29413bb5f150a692ff7"}, + {file = "orjson-3.10.6-cp39-cp39-macosx_10_15_x86_64.macosx_11_0_arm64.macosx_10_15_universal2.whl", hash = "sha256:697a35a083c4f834807a6232b3e62c8b280f7a44ad0b759fd4dce748951e70db"}, + {file = "orjson-3.10.6-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:fd502f96bf5ea9a61cbc0b2b5900d0dd68aa0da197179042bdd2be67e51a1e4b"}, + {file = "orjson-3.10.6-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:f215789fb1667cdc874c1b8af6a84dc939fd802bf293a8334fce185c79cd359b"}, + {file = "orjson-3.10.6-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a2debd8ddce948a8c0938c8c93ade191d2f4ba4649a54302a7da905a81f00b56"}, + {file = "orjson-3.10.6-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5410111d7b6681d4b0d65e0f58a13be588d01b473822483f77f513c7f93bd3b2"}, + {file = "orjson-3.10.6-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bb1f28a137337fdc18384079fa5726810681055b32b92253fa15ae5656e1dddb"}, + {file = "orjson-3.10.6-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:bf2fbbce5fe7cd1aa177ea3eab2b8e6a6bc6e8592e4279ed3db2d62e57c0e1b2"}, + {file = "orjson-3.10.6-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:79b9b9e33bd4c517445a62b90ca0cc279b0f1f3970655c3df9e608bc3f91741a"}, + {file = "orjson-3.10.6-cp39-none-win32.whl", hash = "sha256:30b0a09a2014e621b1adf66a4f705f0809358350a757508ee80209b2d8dae219"}, + {file = "orjson-3.10.6-cp39-none-win_amd64.whl", hash = "sha256:49e3bc615652617d463069f91b867a4458114c5b104e13b7ae6872e5f79d0844"}, + {file = "orjson-3.10.6.tar.gz", hash = "sha256:e54b63d0a7c6c54a5f5f726bc93a2078111ef060fec4ecbf34c5db800ca3b3a7"}, ] [[package]] @@ -1284,22 +1289,22 @@ testing = ["pytest", "pytest-benchmark"] [[package]] name = "protobuf" -version = "4.25.3" +version = "4.25.4" description = "" optional = false python-versions = ">=3.8" files = [ - {file = "protobuf-4.25.3-cp310-abi3-win32.whl", hash = "sha256:d4198877797a83cbfe9bffa3803602bbe1625dc30d8a097365dbc762e5790faa"}, - {file = "protobuf-4.25.3-cp310-abi3-win_amd64.whl", hash = "sha256:209ba4cc916bab46f64e56b85b090607a676f66b473e6b762e6f1d9d591eb2e8"}, - {file = "protobuf-4.25.3-cp37-abi3-macosx_10_9_universal2.whl", hash = "sha256:f1279ab38ecbfae7e456a108c5c0681e4956d5b1090027c1de0f934dfdb4b35c"}, - {file = "protobuf-4.25.3-cp37-abi3-manylinux2014_aarch64.whl", hash = "sha256:e7cb0ae90dd83727f0c0718634ed56837bfeeee29a5f82a7514c03ee1364c019"}, - {file = "protobuf-4.25.3-cp37-abi3-manylinux2014_x86_64.whl", hash = "sha256:7c8daa26095f82482307bc717364e7c13f4f1c99659be82890dcfc215194554d"}, - {file = "protobuf-4.25.3-cp38-cp38-win32.whl", hash = "sha256:f4f118245c4a087776e0a8408be33cf09f6c547442c00395fbfb116fac2f8ac2"}, - {file = "protobuf-4.25.3-cp38-cp38-win_amd64.whl", hash = "sha256:c053062984e61144385022e53678fbded7aea14ebb3e0305ae3592fb219ccfa4"}, - {file = "protobuf-4.25.3-cp39-cp39-win32.whl", hash = "sha256:19b270aeaa0099f16d3ca02628546b8baefe2955bbe23224aaf856134eccf1e4"}, - {file = "protobuf-4.25.3-cp39-cp39-win_amd64.whl", hash = "sha256:e3c97a1555fd6388f857770ff8b9703083de6bf1f9274a002a332d65fbb56c8c"}, - {file = "protobuf-4.25.3-py3-none-any.whl", hash = "sha256:f0700d54bcf45424477e46a9f0944155b46fb0639d69728739c0e47bab83f2b9"}, - {file = "protobuf-4.25.3.tar.gz", hash = "sha256:25b5d0b42fd000320bd7830b349e3b696435f3b329810427a6bcce6a5492cc5c"}, + {file = "protobuf-4.25.4-cp310-abi3-win32.whl", hash = "sha256:db9fd45183e1a67722cafa5c1da3e85c6492a5383f127c86c4c4aa4845867dc4"}, + {file = "protobuf-4.25.4-cp310-abi3-win_amd64.whl", hash = "sha256:ba3d8504116a921af46499471c63a85260c1a5fc23333154a427a310e015d26d"}, + {file = "protobuf-4.25.4-cp37-abi3-macosx_10_9_universal2.whl", hash = "sha256:eecd41bfc0e4b1bd3fa7909ed93dd14dd5567b98c941d6c1ad08fdcab3d6884b"}, + {file = "protobuf-4.25.4-cp37-abi3-manylinux2014_aarch64.whl", hash = "sha256:4c8a70fdcb995dcf6c8966cfa3a29101916f7225e9afe3ced4395359955d3835"}, + {file = "protobuf-4.25.4-cp37-abi3-manylinux2014_x86_64.whl", hash = "sha256:3319e073562e2515c6ddc643eb92ce20809f5d8f10fead3332f71c63be6a7040"}, + {file = "protobuf-4.25.4-cp38-cp38-win32.whl", hash = "sha256:7e372cbbda66a63ebca18f8ffaa6948455dfecc4e9c1029312f6c2edcd86c4e1"}, + {file = "protobuf-4.25.4-cp38-cp38-win_amd64.whl", hash = "sha256:051e97ce9fa6067a4546e75cb14f90cf0232dcb3e3d508c448b8d0e4265b61c1"}, + {file = "protobuf-4.25.4-cp39-cp39-win32.whl", hash = "sha256:90bf6fd378494eb698805bbbe7afe6c5d12c8e17fca817a646cd6a1818c696ca"}, + {file = "protobuf-4.25.4-cp39-cp39-win_amd64.whl", hash = "sha256:ac79a48d6b99dfed2729ccccee547b34a1d3d63289c71cef056653a846a2240f"}, + {file = "protobuf-4.25.4-py3-none-any.whl", hash = "sha256:bfbebc1c8e4793cfd58589acfb8a1026be0003e852b9da7db5a4285bde996978"}, + {file = "protobuf-4.25.4.tar.gz", hash = "sha256:0dc4a62cc4052a036ee2204d26fe4d835c62827c855c8a03f29fe6da146b380d"}, ] [[package]] @@ -1315,109 +1320,122 @@ files = [ [[package]] name = "pydantic" -version = "2.7.4" +version = "2.8.2" description = "Data validation using Python type hints" optional = false python-versions = ">=3.8" files = [ - {file = "pydantic-2.7.4-py3-none-any.whl", hash = "sha256:ee8538d41ccb9c0a9ad3e0e5f07bf15ed8015b481ced539a1759d8cc89ae90d0"}, - {file = "pydantic-2.7.4.tar.gz", hash = "sha256:0c84efd9548d545f63ac0060c1e4d39bb9b14db8b3c0652338aecc07b5adec52"}, + {file = "pydantic-2.8.2-py3-none-any.whl", hash = "sha256:73ee9fddd406dc318b885c7a2eab8a6472b68b8fb5ba8150949fc3db939f23c8"}, + {file = "pydantic-2.8.2.tar.gz", hash = "sha256:6f62c13d067b0755ad1c21a34bdd06c0c12625a22b0fc09c6b149816604f7c2a"}, ] [package.dependencies] annotated-types = ">=0.4.0" -pydantic-core = "2.18.4" -typing-extensions = ">=4.6.1" +pydantic-core = "2.20.1" +typing-extensions = [ + {version = ">=4.12.2", markers = "python_version >= \"3.13\""}, + {version = ">=4.6.1", markers = "python_version < \"3.13\""}, +] [package.extras] email = ["email-validator (>=2.0.0)"] [[package]] name = "pydantic-core" -version = "2.18.4" +version = "2.20.1" description = "Core functionality for Pydantic validation and serialization" optional = false python-versions = ">=3.8" files = [ - {file = "pydantic_core-2.18.4-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:f76d0ad001edd426b92233d45c746fd08f467d56100fd8f30e9ace4b005266e4"}, - {file = "pydantic_core-2.18.4-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:59ff3e89f4eaf14050c8022011862df275b552caef8082e37b542b066ce1ff26"}, - {file = "pydantic_core-2.18.4-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a55b5b16c839df1070bc113c1f7f94a0af4433fcfa1b41799ce7606e5c79ce0a"}, - {file = "pydantic_core-2.18.4-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:4d0dcc59664fcb8974b356fe0a18a672d6d7cf9f54746c05f43275fc48636851"}, - {file = "pydantic_core-2.18.4-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:8951eee36c57cd128f779e641e21eb40bc5073eb28b2d23f33eb0ef14ffb3f5d"}, - {file = "pydantic_core-2.18.4-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:4701b19f7e3a06ea655513f7938de6f108123bf7c86bbebb1196eb9bd35cf724"}, - {file = "pydantic_core-2.18.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e00a3f196329e08e43d99b79b286d60ce46bed10f2280d25a1718399457e06be"}, - {file = "pydantic_core-2.18.4-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:97736815b9cc893b2b7f663628e63f436018b75f44854c8027040e05230eeddb"}, - {file = "pydantic_core-2.18.4-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:6891a2ae0e8692679c07728819b6e2b822fb30ca7445f67bbf6509b25a96332c"}, - {file = "pydantic_core-2.18.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:bc4ff9805858bd54d1a20efff925ccd89c9d2e7cf4986144b30802bf78091c3e"}, - {file = "pydantic_core-2.18.4-cp310-none-win32.whl", hash = "sha256:1b4de2e51bbcb61fdebd0ab86ef28062704f62c82bbf4addc4e37fa4b00b7cbc"}, - {file = "pydantic_core-2.18.4-cp310-none-win_amd64.whl", hash = "sha256:6a750aec7bf431517a9fd78cb93c97b9b0c496090fee84a47a0d23668976b4b0"}, - {file = "pydantic_core-2.18.4-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:942ba11e7dfb66dc70f9ae66b33452f51ac7bb90676da39a7345e99ffb55402d"}, - {file = "pydantic_core-2.18.4-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:b2ebef0e0b4454320274f5e83a41844c63438fdc874ea40a8b5b4ecb7693f1c4"}, - {file = "pydantic_core-2.18.4-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a642295cd0c8df1b86fc3dced1d067874c353a188dc8e0f744626d49e9aa51c4"}, - {file = "pydantic_core-2.18.4-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:5f09baa656c904807e832cf9cce799c6460c450c4ad80803517032da0cd062e2"}, - {file = "pydantic_core-2.18.4-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:98906207f29bc2c459ff64fa007afd10a8c8ac080f7e4d5beff4c97086a3dabd"}, - {file = "pydantic_core-2.18.4-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:19894b95aacfa98e7cb093cd7881a0c76f55731efad31073db4521e2b6ff5b7d"}, - {file = "pydantic_core-2.18.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0fbbdc827fe5e42e4d196c746b890b3d72876bdbf160b0eafe9f0334525119c8"}, - {file = "pydantic_core-2.18.4-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:f85d05aa0918283cf29a30b547b4df2fbb56b45b135f9e35b6807cb28bc47951"}, - {file = "pydantic_core-2.18.4-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:e85637bc8fe81ddb73fda9e56bab24560bdddfa98aa64f87aaa4e4b6730c23d2"}, - {file = "pydantic_core-2.18.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:2f5966897e5461f818e136b8451d0551a2e77259eb0f73a837027b47dc95dab9"}, - {file = "pydantic_core-2.18.4-cp311-none-win32.whl", hash = "sha256:44c7486a4228413c317952e9d89598bcdfb06399735e49e0f8df643e1ccd0558"}, - {file = "pydantic_core-2.18.4-cp311-none-win_amd64.whl", hash = "sha256:8a7164fe2005d03c64fd3b85649891cd4953a8de53107940bf272500ba8a788b"}, - {file = "pydantic_core-2.18.4-cp311-none-win_arm64.whl", hash = "sha256:4e99bc050fe65c450344421017f98298a97cefc18c53bb2f7b3531eb39bc7805"}, - {file = "pydantic_core-2.18.4-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:6f5c4d41b2771c730ea1c34e458e781b18cc668d194958e0112455fff4e402b2"}, - {file = "pydantic_core-2.18.4-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:2fdf2156aa3d017fddf8aea5adfba9f777db1d6022d392b682d2a8329e087cef"}, - {file = "pydantic_core-2.18.4-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4748321b5078216070b151d5271ef3e7cc905ab170bbfd27d5c83ee3ec436695"}, - {file = "pydantic_core-2.18.4-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:847a35c4d58721c5dc3dba599878ebbdfd96784f3fb8bb2c356e123bdcd73f34"}, - {file = "pydantic_core-2.18.4-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3c40d4eaad41f78e3bbda31b89edc46a3f3dc6e171bf0ecf097ff7a0ffff7cb1"}, - {file = "pydantic_core-2.18.4-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:21a5e440dbe315ab9825fcd459b8814bb92b27c974cbc23c3e8baa2b76890077"}, - {file = "pydantic_core-2.18.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:01dd777215e2aa86dfd664daed5957704b769e726626393438f9c87690ce78c3"}, - {file = "pydantic_core-2.18.4-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:4b06beb3b3f1479d32befd1f3079cc47b34fa2da62457cdf6c963393340b56e9"}, - {file = "pydantic_core-2.18.4-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:564d7922e4b13a16b98772441879fcdcbe82ff50daa622d681dd682175ea918c"}, - {file = "pydantic_core-2.18.4-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:0eb2a4f660fcd8e2b1c90ad566db2b98d7f3f4717c64fe0a83e0adb39766d5b8"}, - {file = "pydantic_core-2.18.4-cp312-none-win32.whl", hash = "sha256:8b8bab4c97248095ae0c4455b5a1cd1cdd96e4e4769306ab19dda135ea4cdb07"}, - {file = "pydantic_core-2.18.4-cp312-none-win_amd64.whl", hash = "sha256:14601cdb733d741b8958224030e2bfe21a4a881fb3dd6fbb21f071cabd48fa0a"}, - {file = "pydantic_core-2.18.4-cp312-none-win_arm64.whl", hash = "sha256:c1322d7dd74713dcc157a2b7898a564ab091ca6c58302d5c7b4c07296e3fd00f"}, - {file = "pydantic_core-2.18.4-cp38-cp38-macosx_10_12_x86_64.whl", hash = "sha256:823be1deb01793da05ecb0484d6c9e20baebb39bd42b5d72636ae9cf8350dbd2"}, - {file = "pydantic_core-2.18.4-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:ebef0dd9bf9b812bf75bda96743f2a6c5734a02092ae7f721c048d156d5fabae"}, - {file = "pydantic_core-2.18.4-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ae1d6df168efb88d7d522664693607b80b4080be6750c913eefb77e34c12c71a"}, - {file = "pydantic_core-2.18.4-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:f9899c94762343f2cc2fc64c13e7cae4c3cc65cdfc87dd810a31654c9b7358cc"}, - {file = "pydantic_core-2.18.4-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:99457f184ad90235cfe8461c4d70ab7dd2680e28821c29eca00252ba90308c78"}, - {file = "pydantic_core-2.18.4-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:18f469a3d2a2fdafe99296a87e8a4c37748b5080a26b806a707f25a902c040a8"}, - {file = "pydantic_core-2.18.4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b7cdf28938ac6b8b49ae5e92f2735056a7ba99c9b110a474473fd71185c1af5d"}, - {file = "pydantic_core-2.18.4-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:938cb21650855054dc54dfd9120a851c974f95450f00683399006aa6e8abb057"}, - {file = "pydantic_core-2.18.4-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:44cd83ab6a51da80fb5adbd9560e26018e2ac7826f9626bc06ca3dc074cd198b"}, - {file = "pydantic_core-2.18.4-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:972658f4a72d02b8abfa2581d92d59f59897d2e9f7e708fdabe922f9087773af"}, - {file = "pydantic_core-2.18.4-cp38-none-win32.whl", hash = "sha256:1d886dc848e60cb7666f771e406acae54ab279b9f1e4143babc9c2258213daa2"}, - {file = "pydantic_core-2.18.4-cp38-none-win_amd64.whl", hash = "sha256:bb4462bd43c2460774914b8525f79b00f8f407c945d50881568f294c1d9b4443"}, - {file = "pydantic_core-2.18.4-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:44a688331d4a4e2129140a8118479443bd6f1905231138971372fcde37e43528"}, - {file = "pydantic_core-2.18.4-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:a2fdd81edd64342c85ac7cf2753ccae0b79bf2dfa063785503cb85a7d3593223"}, - {file = "pydantic_core-2.18.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:86110d7e1907ab36691f80b33eb2da87d780f4739ae773e5fc83fb272f88825f"}, - {file = "pydantic_core-2.18.4-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:46387e38bd641b3ee5ce247563b60c5ca098da9c56c75c157a05eaa0933ed154"}, - {file = "pydantic_core-2.18.4-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:123c3cec203e3f5ac7b000bd82235f1a3eced8665b63d18be751f115588fea30"}, - {file = "pydantic_core-2.18.4-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dc1803ac5c32ec324c5261c7209e8f8ce88e83254c4e1aebdc8b0a39f9ddb443"}, - {file = "pydantic_core-2.18.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:53db086f9f6ab2b4061958d9c276d1dbe3690e8dd727d6abf2321d6cce37fa94"}, - {file = "pydantic_core-2.18.4-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:abc267fa9837245cc28ea6929f19fa335f3dc330a35d2e45509b6566dc18be23"}, - {file = "pydantic_core-2.18.4-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:a0d829524aaefdebccb869eed855e2d04c21d2d7479b6cada7ace5448416597b"}, - {file = "pydantic_core-2.18.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:509daade3b8649f80d4e5ff21aa5673e4ebe58590b25fe42fac5f0f52c6f034a"}, - {file = "pydantic_core-2.18.4-cp39-none-win32.whl", hash = "sha256:ca26a1e73c48cfc54c4a76ff78df3727b9d9f4ccc8dbee4ae3f73306a591676d"}, - {file = "pydantic_core-2.18.4-cp39-none-win_amd64.whl", hash = "sha256:c67598100338d5d985db1b3d21f3619ef392e185e71b8d52bceacc4a7771ea7e"}, - {file = "pydantic_core-2.18.4-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:574d92eac874f7f4db0ca653514d823a0d22e2354359d0759e3f6a406db5d55d"}, - {file = "pydantic_core-2.18.4-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:1f4d26ceb5eb9eed4af91bebeae4b06c3fb28966ca3a8fb765208cf6b51102ab"}, - {file = "pydantic_core-2.18.4-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77450e6d20016ec41f43ca4a6c63e9fdde03f0ae3fe90e7c27bdbeaece8b1ed4"}, - {file = "pydantic_core-2.18.4-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d323a01da91851a4f17bf592faf46149c9169d68430b3146dcba2bb5e5719abc"}, - {file = "pydantic_core-2.18.4-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:43d447dd2ae072a0065389092a231283f62d960030ecd27565672bd40746c507"}, - {file = "pydantic_core-2.18.4-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:578e24f761f3b425834f297b9935e1ce2e30f51400964ce4801002435a1b41ef"}, - {file = "pydantic_core-2.18.4-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:81b5efb2f126454586d0f40c4d834010979cb80785173d1586df845a632e4e6d"}, - {file = "pydantic_core-2.18.4-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:ab86ce7c8f9bea87b9d12c7f0af71102acbf5ecbc66c17796cff45dae54ef9a5"}, - {file = "pydantic_core-2.18.4-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:90afc12421df2b1b4dcc975f814e21bc1754640d502a2fbcc6d41e77af5ec312"}, - {file = "pydantic_core-2.18.4-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:51991a89639a912c17bef4b45c87bd83593aee0437d8102556af4885811d59f5"}, - {file = "pydantic_core-2.18.4-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:293afe532740370aba8c060882f7d26cfd00c94cae32fd2e212a3a6e3b7bc15e"}, - {file = "pydantic_core-2.18.4-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b48ece5bde2e768197a2d0f6e925f9d7e3e826f0ad2271120f8144a9db18d5c8"}, - {file = "pydantic_core-2.18.4-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:eae237477a873ab46e8dd748e515c72c0c804fb380fbe6c85533c7de51f23a8f"}, - {file = "pydantic_core-2.18.4-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:834b5230b5dfc0c1ec37b2fda433b271cbbc0e507560b5d1588e2cc1148cf1ce"}, - {file = "pydantic_core-2.18.4-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:e858ac0a25074ba4bce653f9b5d0a85b7456eaddadc0ce82d3878c22489fa4ee"}, - {file = "pydantic_core-2.18.4-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:2fd41f6eff4c20778d717af1cc50eca52f5afe7805ee530a4fbd0bae284f16e9"}, - {file = "pydantic_core-2.18.4.tar.gz", hash = "sha256:ec3beeada09ff865c344ff3bc2f427f5e6c26401cc6113d77e372c3fdac73864"}, + {file = "pydantic_core-2.20.1-cp310-cp310-macosx_10_12_x86_64.whl", hash = "sha256:3acae97ffd19bf091c72df4d726d552c473f3576409b2a7ca36b2f535ffff4a3"}, + {file = "pydantic_core-2.20.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:41f4c96227a67a013e7de5ff8f20fb496ce573893b7f4f2707d065907bffdbd6"}, + {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5f239eb799a2081495ea659d8d4a43a8f42cd1fe9ff2e7e436295c38a10c286a"}, + {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:53e431da3fc53360db73eedf6f7124d1076e1b4ee4276b36fb25514544ceb4a3"}, + {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:f1f62b2413c3a0e846c3b838b2ecd6c7a19ec6793b2a522745b0869e37ab5bc1"}, + {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5d41e6daee2813ecceea8eda38062d69e280b39df793f5a942fa515b8ed67953"}, + {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3d482efec8b7dc6bfaedc0f166b2ce349df0011f5d2f1f25537ced4cfc34fd98"}, + {file = "pydantic_core-2.20.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:e93e1a4b4b33daed65d781a57a522ff153dcf748dee70b40c7258c5861e1768a"}, + {file = "pydantic_core-2.20.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:e7c4ea22b6739b162c9ecaaa41d718dfad48a244909fe7ef4b54c0b530effc5a"}, + {file = "pydantic_core-2.20.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:4f2790949cf385d985a31984907fecb3896999329103df4e4983a4a41e13e840"}, + {file = "pydantic_core-2.20.1-cp310-none-win32.whl", hash = "sha256:5e999ba8dd90e93d57410c5e67ebb67ffcaadcea0ad973240fdfd3a135506250"}, + {file = "pydantic_core-2.20.1-cp310-none-win_amd64.whl", hash = "sha256:512ecfbefef6dac7bc5eaaf46177b2de58cdf7acac8793fe033b24ece0b9566c"}, + {file = "pydantic_core-2.20.1-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:d2a8fa9d6d6f891f3deec72f5cc668e6f66b188ab14bb1ab52422fe8e644f312"}, + {file = "pydantic_core-2.20.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:175873691124f3d0da55aeea1d90660a6ea7a3cfea137c38afa0a5ffabe37b88"}, + {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:37eee5b638f0e0dcd18d21f59b679686bbd18917b87db0193ae36f9c23c355fc"}, + {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:25e9185e2d06c16ee438ed39bf62935ec436474a6ac4f9358524220f1b236e43"}, + {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:150906b40ff188a3260cbee25380e7494ee85048584998c1e66df0c7a11c17a6"}, + {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:8ad4aeb3e9a97286573c03df758fc7627aecdd02f1da04516a86dc159bf70121"}, + {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d3f3ed29cd9f978c604708511a1f9c2fdcb6c38b9aae36a51905b8811ee5cbf1"}, + {file = "pydantic_core-2.20.1-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:b0dae11d8f5ded51699c74d9548dcc5938e0804cc8298ec0aa0da95c21fff57b"}, + {file = "pydantic_core-2.20.1-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:faa6b09ee09433b87992fb5a2859efd1c264ddc37280d2dd5db502126d0e7f27"}, + {file = "pydantic_core-2.20.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:9dc1b507c12eb0481d071f3c1808f0529ad41dc415d0ca11f7ebfc666e66a18b"}, + {file = "pydantic_core-2.20.1-cp311-none-win32.whl", hash = "sha256:fa2fddcb7107e0d1808086ca306dcade7df60a13a6c347a7acf1ec139aa6789a"}, + {file = "pydantic_core-2.20.1-cp311-none-win_amd64.whl", hash = "sha256:40a783fb7ee353c50bd3853e626f15677ea527ae556429453685ae32280c19c2"}, + {file = "pydantic_core-2.20.1-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:595ba5be69b35777474fa07f80fc260ea71255656191adb22a8c53aba4479231"}, + {file = "pydantic_core-2.20.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:a4f55095ad087474999ee28d3398bae183a66be4823f753cd7d67dd0153427c9"}, + {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f9aa05d09ecf4c75157197f27cdc9cfaeb7c5f15021c6373932bf3e124af029f"}, + {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:e97fdf088d4b31ff4ba35db26d9cc472ac7ef4a2ff2badeabf8d727b3377fc52"}, + {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:bc633a9fe1eb87e250b5c57d389cf28998e4292336926b0b6cdaee353f89a237"}, + {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:d573faf8eb7e6b1cbbcb4f5b247c60ca8be39fe2c674495df0eb4318303137fe"}, + {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:26dc97754b57d2fd00ac2b24dfa341abffc380b823211994c4efac7f13b9e90e"}, + {file = "pydantic_core-2.20.1-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:33499e85e739a4b60c9dac710c20a08dc73cb3240c9a0e22325e671b27b70d24"}, + {file = "pydantic_core-2.20.1-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:bebb4d6715c814597f85297c332297c6ce81e29436125ca59d1159b07f423eb1"}, + {file = "pydantic_core-2.20.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:516d9227919612425c8ef1c9b869bbbee249bc91912c8aaffb66116c0b447ebd"}, + {file = "pydantic_core-2.20.1-cp312-none-win32.whl", hash = "sha256:469f29f9093c9d834432034d33f5fe45699e664f12a13bf38c04967ce233d688"}, + {file = "pydantic_core-2.20.1-cp312-none-win_amd64.whl", hash = "sha256:035ede2e16da7281041f0e626459bcae33ed998cca6a0a007a5ebb73414ac72d"}, + {file = "pydantic_core-2.20.1-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:0827505a5c87e8aa285dc31e9ec7f4a17c81a813d45f70b1d9164e03a813a686"}, + {file = "pydantic_core-2.20.1-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:19c0fa39fa154e7e0b7f82f88ef85faa2a4c23cc65aae2f5aea625e3c13c735a"}, + {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4aa223cd1e36b642092c326d694d8bf59b71ddddc94cdb752bbbb1c5c91d833b"}, + {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:c336a6d235522a62fef872c6295a42ecb0c4e1d0f1a3e500fe949415761b8a19"}, + {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:7eb6a0587eded33aeefea9f916899d42b1799b7b14b8f8ff2753c0ac1741edac"}, + {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:70c8daf4faca8da5a6d655f9af86faf6ec2e1768f4b8b9d0226c02f3d6209703"}, + {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e9fa4c9bf273ca41f940bceb86922a7667cd5bf90e95dbb157cbb8441008482c"}, + {file = "pydantic_core-2.20.1-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:11b71d67b4725e7e2a9f6e9c0ac1239bbc0c48cce3dc59f98635efc57d6dac83"}, + {file = "pydantic_core-2.20.1-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:270755f15174fb983890c49881e93f8f1b80f0b5e3a3cc1394a255706cabd203"}, + {file = "pydantic_core-2.20.1-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:c81131869240e3e568916ef4c307f8b99583efaa60a8112ef27a366eefba8ef0"}, + {file = "pydantic_core-2.20.1-cp313-none-win32.whl", hash = "sha256:b91ced227c41aa29c672814f50dbb05ec93536abf8f43cd14ec9521ea09afe4e"}, + {file = "pydantic_core-2.20.1-cp313-none-win_amd64.whl", hash = "sha256:65db0f2eefcaad1a3950f498aabb4875c8890438bc80b19362cf633b87a8ab20"}, + {file = "pydantic_core-2.20.1-cp38-cp38-macosx_10_12_x86_64.whl", hash = "sha256:4745f4ac52cc6686390c40eaa01d48b18997cb130833154801a442323cc78f91"}, + {file = "pydantic_core-2.20.1-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:a8ad4c766d3f33ba8fd692f9aa297c9058970530a32c728a2c4bfd2616d3358b"}, + {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:41e81317dd6a0127cabce83c0c9c3fbecceae981c8391e6f1dec88a77c8a569a"}, + {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:04024d270cf63f586ad41fff13fde4311c4fc13ea74676962c876d9577bcc78f"}, + {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:eaad4ff2de1c3823fddf82f41121bdf453d922e9a238642b1dedb33c4e4f98ad"}, + {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:26ab812fa0c845df815e506be30337e2df27e88399b985d0bb4e3ecfe72df31c"}, + {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3c5ebac750d9d5f2706654c638c041635c385596caf68f81342011ddfa1e5598"}, + {file = "pydantic_core-2.20.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:2aafc5a503855ea5885559eae883978c9b6d8c8993d67766ee73d82e841300dd"}, + {file = "pydantic_core-2.20.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:4868f6bd7c9d98904b748a2653031fc9c2f85b6237009d475b1008bfaeb0a5aa"}, + {file = "pydantic_core-2.20.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:aa2f457b4af386254372dfa78a2eda2563680d982422641a85f271c859df1987"}, + {file = "pydantic_core-2.20.1-cp38-none-win32.whl", hash = "sha256:225b67a1f6d602de0ce7f6c1c3ae89a4aa25d3de9be857999e9124f15dab486a"}, + {file = "pydantic_core-2.20.1-cp38-none-win_amd64.whl", hash = "sha256:6b507132dcfc0dea440cce23ee2182c0ce7aba7054576efc65634f080dbe9434"}, + {file = "pydantic_core-2.20.1-cp39-cp39-macosx_10_12_x86_64.whl", hash = "sha256:b03f7941783b4c4a26051846dea594628b38f6940a2fdc0df00b221aed39314c"}, + {file = "pydantic_core-2.20.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:1eedfeb6089ed3fad42e81a67755846ad4dcc14d73698c120a82e4ccf0f1f9f6"}, + {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:635fee4e041ab9c479e31edda27fcf966ea9614fff1317e280d99eb3e5ab6fe2"}, + {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:77bf3ac639c1ff567ae3b47f8d4cc3dc20f9966a2a6dd2311dcc055d3d04fb8a"}, + {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:7ed1b0132f24beeec5a78b67d9388656d03e6a7c837394f99257e2d55b461611"}, + {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c6514f963b023aeee506678a1cf821fe31159b925c4b76fe2afa94cc70b3222b"}, + {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10d4204d8ca33146e761c79f83cc861df20e7ae9f6487ca290a97702daf56006"}, + {file = "pydantic_core-2.20.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:2d036c7187b9422ae5b262badb87a20a49eb6c5238b2004e96d4da1231badef1"}, + {file = "pydantic_core-2.20.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:9ebfef07dbe1d93efb94b4700f2d278494e9162565a54f124c404a5656d7ff09"}, + {file = "pydantic_core-2.20.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:6b9d9bb600328a1ce523ab4f454859e9d439150abb0906c5a1983c146580ebab"}, + {file = "pydantic_core-2.20.1-cp39-none-win32.whl", hash = "sha256:784c1214cb6dd1e3b15dd8b91b9a53852aed16671cc3fbe4786f4f1db07089e2"}, + {file = "pydantic_core-2.20.1-cp39-none-win_amd64.whl", hash = "sha256:d2fe69c5434391727efa54b47a1e7986bb0186e72a41b203df8f5b0a19a4f669"}, + {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:a45f84b09ac9c3d35dfcf6a27fd0634d30d183205230a0ebe8373a0e8cfa0906"}, + {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-macosx_11_0_arm64.whl", hash = "sha256:d02a72df14dfdbaf228424573a07af10637bd490f0901cee872c4f434a735b94"}, + {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d2b27e6af28f07e2f195552b37d7d66b150adbaa39a6d327766ffd695799780f"}, + {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:084659fac3c83fd674596612aeff6041a18402f1e1bc19ca39e417d554468482"}, + {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:242b8feb3c493ab78be289c034a1f659e8826e2233786e36f2893a950a719bb6"}, + {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:38cf1c40a921d05c5edc61a785c0ddb4bed67827069f535d794ce6bcded919fc"}, + {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:e0bbdd76ce9aa5d4209d65f2b27fc6e5ef1312ae6c5333c26db3f5ade53a1e99"}, + {file = "pydantic_core-2.20.1-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:254ec27fdb5b1ee60684f91683be95e5133c994cc54e86a0b0963afa25c8f8a6"}, + {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:407653af5617f0757261ae249d3fba09504d7a71ab36ac057c938572d1bc9331"}, + {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-macosx_11_0_arm64.whl", hash = "sha256:c693e916709c2465b02ca0ad7b387c4f8423d1db7b4649c551f27a529181c5ad"}, + {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5b5ff4911aea936a47d9376fd3ab17e970cc543d1b68921886e7f64bd28308d1"}, + {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:177f55a886d74f1808763976ac4efd29b7ed15c69f4d838bbd74d9d09cf6fa86"}, + {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:964faa8a861d2664f0c7ab0c181af0bea66098b1919439815ca8803ef136fc4e"}, + {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:4dd484681c15e6b9a977c785a345d3e378d72678fd5f1f3c0509608da24f2ac0"}, + {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:f6d6cff3538391e8486a431569b77921adfcdef14eb18fbf19b7c0a5294d4e6a"}, + {file = "pydantic_core-2.20.1-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:a6d511cc297ff0883bc3708b465ff82d7560193169a8b93260f74ecb0a5e08a7"}, + {file = "pydantic_core-2.20.1.tar.gz", hash = "sha256:26ca695eeee5f9f1aeeb211ffc12f10bcb6f71e2989988fda61dabd65db878d4"}, ] [package.dependencies] @@ -1606,18 +1624,19 @@ tornado = ["tornado (>=5)"] [[package]] name = "setuptools" -version = "70.1.1" +version = "72.1.0" description = "Easily download, build, install, upgrade, and uninstall Python packages" optional = false python-versions = ">=3.8" files = [ - {file = "setuptools-70.1.1-py3-none-any.whl", hash = "sha256:a58a8fde0541dab0419750bcc521fbdf8585f6e5cb41909df3a472ef7b81ca95"}, - {file = "setuptools-70.1.1.tar.gz", hash = "sha256:937a48c7cdb7a21eb53cd7f9b59e525503aa8abaf3584c730dc5f7a5bec3a650"}, + {file = "setuptools-72.1.0-py3-none-any.whl", hash = "sha256:5a03e1860cf56bb6ef48ce186b0e557fdba433237481a9a625176c2831be15d1"}, + {file = "setuptools-72.1.0.tar.gz", hash = "sha256:8d243eff56d095e5817f796ede6ae32941278f542e0f941867cc05ae52b162ec"}, ] [package.extras] -docs = ["furo", "jaraco.packaging (>=9.3)", "jaraco.tidelift (>=1.4)", "pygments-github-lexers (==0.0.5)", "pyproject-hooks (!=1.1)", "rst.linker (>=1.9)", "sphinx (>=3.5)", "sphinx-favicon", "sphinx-inline-tabs", "sphinx-lint", "sphinx-notfound-page (>=1,<2)", "sphinx-reredirects", "sphinxcontrib-towncrier"] -testing = ["build[virtualenv] (>=1.0.3)", "filelock (>=3.4.0)", "importlib-metadata", "ini2toml[lite] (>=0.14)", "jaraco.develop (>=7.21)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "jaraco.test", "mypy (==1.10.0)", "packaging (>=23.2)", "pip (>=19.1)", "pyproject-hooks (!=1.1)", "pytest (>=6,!=8.1.1)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=2.2)", "pytest-home (>=0.5)", "pytest-mypy", "pytest-perf", "pytest-ruff (>=0.3.2)", "pytest-subprocess", "pytest-timeout", "pytest-xdist (>=3)", "tomli", "tomli-w (>=1.0.0)", "virtualenv (>=13.0.0)", "wheel"] +core = ["importlib-metadata (>=6)", "importlib-resources (>=5.10.2)", "jaraco.text (>=3.7)", "more-itertools (>=8.8)", "ordered-set (>=3.1.1)", "packaging (>=24)", "platformdirs (>=2.6.2)", "tomli (>=2.0.1)", "wheel (>=0.43.0)"] +doc = ["furo", "jaraco.packaging (>=9.3)", "jaraco.tidelift (>=1.4)", "pygments-github-lexers (==0.0.5)", "pyproject-hooks (!=1.1)", "rst.linker (>=1.9)", "sphinx (>=3.5)", "sphinx-favicon", "sphinx-inline-tabs", "sphinx-lint", "sphinx-notfound-page (>=1,<2)", "sphinx-reredirects", "sphinxcontrib-towncrier"] +test = ["build[virtualenv] (>=1.0.3)", "filelock (>=3.4.0)", "importlib-metadata", "ini2toml[lite] (>=0.14)", "jaraco.develop (>=7.21)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "jaraco.test", "mypy (==1.11.*)", "packaging (>=23.2)", "pip (>=19.1)", "pyproject-hooks (!=1.1)", "pytest (>=6,!=8.1.*)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=2.2)", "pytest-home (>=0.5)", "pytest-mypy", "pytest-perf", "pytest-ruff (<0.4)", "pytest-ruff (>=0.2.1)", "pytest-ruff (>=0.3.2)", "pytest-subprocess", "pytest-timeout", "pytest-xdist (>=3)", "tomli", "tomli-w (>=1.0.0)", "virtualenv (>=13.0.0)", "wheel"] [[package]] name = "six" @@ -1981,4 +2000,4 @@ testing = ["aioresponses", "tornado-httpclient-mock"] [metadata] lock-version = "2.0" python-versions = "~=3.9" -content-hash = "76a5450bc58bbbd4cc77a3f432306993e2713174498a5ea473427ead08555593" +content-hash = "1c5b2fc2edeea79c99a2ca3f1788ad557b6ec1ce882f141c1d14cad786104fe0" diff --git a/pyproject.toml b/pyproject.toml index 6fa16a2d0..e2fd49940 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -22,7 +22,7 @@ lxml = '4.9.2' pydantic = '^2.3.0' tornado = '6.3.3' orjson = '*' -http-client = {git = 'https://github.com/hhru/balancing-http-client.git', tag = '2.1.14'} +http-client = {git = 'https://github.com/hhru/balancing-http-client.git', tag = '2.1.15'} python-consul2-hh = {git = 'https://github.com/hhru/python-consul2', tag = 'v0.2.10'} opentelemetry-sdk = '1.25.0' opentelemetry-api = '1.25.0' diff --git a/tests/conftest.py b/tests/conftest.py index 57565d417..5f12b03b5 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -2,15 +2,6 @@ import pytest -# @pytest.fixture(scope='session') -# def event_loop(): -# loop = asyncio.new_event_loop() -# asyncio.set_event_loop(loop) -# yield loop -# loop.close() - -# pytest_asyncio.plugin.event_loop = event_loop - @pytest.fixture(scope='session', autouse=True) def _teardown_module() -> Iterator[None]: @@ -35,12 +26,3 @@ def _teardown_module() -> Iterator[None]: frontik_balancer_app.stop() frontik_broken_balancer_app.stop() frontik_consul_mock_app.stop() - - -# def pytest_addoption(parser): -# parser.addoption('--files_for_lint', action='store', default='') -# -# -# @pytest.fixture(scope='session') -# def files_for_lint(pytestconfig): -# return pytestconfig.getoption('files_for_lint') diff --git a/tests/instances.py b/tests/instances.py index c2ee20601..bad7162eb 100644 --- a/tests/instances.py +++ b/tests/instances.py @@ -157,48 +157,48 @@ def get_page_text(self, page: str, notpl: bool = False, method: Callable = reque common_frontik_start_options = f'--{options.STDERR_LOG_OPTION_NAME}=True' frontik_consul_mock_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.consul_mock_app.TestApplication ' + f'{FRONTIK_RUN} --app_class=tests.projects.consul_mock_app.TestApplication ' f' --config={TEST_PROJECTS}/frontik_consul_mock.cfg {common_frontik_start_options}', ) frontik_consul_mock_app.start() frontik_test_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.test_app.TestApplication ' + f'{FRONTIK_RUN} --app_class=tests.projects.test_app.TestApplication ' f' --config={TEST_PROJECTS}/frontik_debug.cfg {common_frontik_start_options} ' f' --consul_port={frontik_consul_mock_app.port}', ) frontik_re_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.re_app.TestApplication ' + f'{FRONTIK_RUN} --app_class=tests.projects.re_app.TestApplication ' f' --config={TEST_PROJECTS}/frontik_debug.cfg {common_frontik_start_options} ' f' --consul_port={frontik_consul_mock_app.port}', ) frontik_no_debug_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.no_debug_app ' + f'{FRONTIK_RUN} --app_class=tests.projects.no_debug_app.TestApplication ' f' --config={TEST_PROJECTS}/frontik_no_debug.cfg {common_frontik_start_options} ' f' --consul_port={frontik_consul_mock_app.port} ', ) frontik_broken_config_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.broken_config_app.TestApplication ' + f'{FRONTIK_RUN} --app_class=tests.projects.broken_config_app.TestApplication ' f' --config={TEST_PROJECTS}/frontik_debug.cfg {common_frontik_start_options} ' f' --consul_port={frontik_consul_mock_app.port}', ) frontik_broken_init_async_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.broken_async_init_app.TestApplication ' + f'{FRONTIK_RUN} --app_class=tests.projects.broken_async_init_app.TestApplication ' f' --config={TEST_PROJECTS}/frontik_debug.cfg {common_frontik_start_options} ' f' --consul_port={frontik_consul_mock_app.port}', ) frontik_balancer_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.balancer_app ' + f'{FRONTIK_RUN} --app_class=tests.projects.balancer_app.TestApplication ' f' --config={TEST_PROJECTS}/frontik_no_debug.cfg {common_frontik_start_options} ' f' --consul_port={frontik_consul_mock_app.port}', ) frontik_broken_balancer_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.broken_balancer_app ' + f'{FRONTIK_RUN} --app_class=tests.projects.broken_balancer_app.TestApplication ' f' --config={TEST_PROJECTS}/frontik_debug.cfg {common_frontik_start_options} ' f' --consul_port={frontik_consul_mock_app.port}', ) diff --git a/tests/projects/consul_mock_app/__init__.py b/tests/projects/consul_mock_app/__init__.py index 186883ef3..2c037145b 100644 --- a/tests/projects/consul_mock_app/__init__.py +++ b/tests/projects/consul_mock_app/__init__.py @@ -4,7 +4,7 @@ class TestApplication(FrontikApplication): - def __init__(self, app_module_name: str): - super().__init__(app_module_name) + def __init__(self): + super().__init__() self.registration_call_counter: Counter = Counter() self.deregistration_call_counter: Counter = Counter() diff --git a/tests/projects/frontik_consul_mock.cfg b/tests/projects/frontik_consul_mock.cfg index 4f2b559dd..84653bf73 100644 --- a/tests/projects/frontik_consul_mock.cfg +++ b/tests/projects/frontik_consul_mock.cfg @@ -1,6 +1,5 @@ host = '127.0.0.1' -app_class = 'TestApplication' max_active_handlers = 5 debug = False diff --git a/tests/projects/frontik_debug.cfg b/tests/projects/frontik_debug.cfg index d7550962f..4e6a2f71c 100644 --- a/tests/projects/frontik_debug.cfg +++ b/tests/projects/frontik_debug.cfg @@ -3,8 +3,6 @@ host = '127.0.0.1' datacenter = 'test' http_client_allow_cross_datacenter_requests = True -app_class = 'TestApplication' - debug = True log_level = 'warning' diff --git a/tests/projects/frontik_no_debug.cfg b/tests/projects/frontik_no_debug.cfg index c28054f9e..2e2ddc05b 100644 --- a/tests/projects/frontik_no_debug.cfg +++ b/tests/projects/frontik_no_debug.cfg @@ -1,6 +1,5 @@ host = '127.0.0.1' -app_class = 'TestApplication' max_active_handlers = 5 debug = False diff --git a/tests/projects/re_app/__init__.py b/tests/projects/re_app/__init__.py index 7478f8667..4486aa9bc 100644 --- a/tests/projects/re_app/__init__.py +++ b/tests/projects/re_app/__init__.py @@ -7,7 +7,7 @@ class TestApplication(FrontikApplication): - def application_404_handler(self): + async def application_404_handler(self, _request): return 404, get_default_headers(), b'404' def get_jinja_environment(self): diff --git a/tests/projects/test_app/__init__.py b/tests/projects/test_app/__init__.py index 3bf2fab5f..13cf0c87e 100644 --- a/tests/projects/test_app/__init__.py +++ b/tests/projects/test_app/__init__.py @@ -7,9 +7,9 @@ class TestApplication(FrontikApplication): - def __init__(self, app_module_name: str): + def __init__(self): bootstrap_logger('custom_logger', logging.DEBUG, False) - super().__init__(app_module_name) + super().__init__() async def init(self): await super().init() diff --git a/tests/projects/test_app/pages/error_on_import.py b/tests/projects/test_app/pages/error_on_import.py deleted file mode 100644 index 876fc1320..000000000 --- a/tests/projects/test_app/pages/error_on_import.py +++ /dev/null @@ -1,2 +0,0 @@ -msg = 'error on import' -raise ValueError(msg) diff --git a/tests/test_consul_registration.py b/tests/test_consul_registration.py index f7fd85778..d6b8e7aeb 100644 --- a/tests/test_consul_registration.py +++ b/tests/test_consul_registration.py @@ -10,24 +10,24 @@ class TestConsulRegistration: def setup_method(self): self.consul_mock = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.consul_mock_app.TestApplication {common_frontik_start_options} ' + f'{FRONTIK_RUN} --app_class=tests.projects.consul_mock_app.TestApplication {common_frontik_start_options} ' f' --config={TEST_PROJECTS}/frontik_consul_mock.cfg', ) self.consul_mock.start() self.frontik_single_worker_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.no_debug_app {common_frontik_start_options} ' + f'{FRONTIK_RUN} --app_class=tests.projects.no_debug_app.TestApplication {common_frontik_start_options} ' f' --config={TEST_PROJECTS}/frontik_no_debug.cfg --consul_port={self.consul_mock.port} ' f' --consul_enabled=True' f' --fail_start_on_empty_upstream=False', ) self.frontik_multiple_worker_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.no_debug_app {common_frontik_start_options} ' + f'{FRONTIK_RUN} --app_class=tests.projects.no_debug_app.TestApplication {common_frontik_start_options} ' f' --config={TEST_PROJECTS}/frontik_no_debug.cfg --consul_port={self.consul_mock.port} --workers=3' f' --consul_enabled=True' f' --fail_start_on_empty_upstream=False', ) self.frontik_multiple_worker_app_timeout_barrier = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.no_debug_app {common_frontik_start_options} ' + f'{FRONTIK_RUN} --app_class=tests.projects.no_debug_app.TestApplication {common_frontik_start_options} ' f' --config={TEST_PROJECTS}/frontik_no_debug.cfg --consul_port={self.consul_mock.port} --workers=3' f' --init_workers_timeout_sec=0' f' --consul_enabled=True' diff --git a/tests/test_file_logging.py b/tests/test_file_logging.py index a1137c90e..9d594d334 100644 --- a/tests/test_file_logging.py +++ b/tests/test_file_logging.py @@ -14,7 +14,7 @@ class TestLogToFile(unittest.TestCase): def setUp(self) -> None: self.tmp_log_dir = tempfile.mkdtemp() self.service = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.consul_mock_app.TestApplication {common_frontik_start_options} ' + f'{FRONTIK_RUN} --app_class=tests.projects.consul_mock_app.TestApplication {common_frontik_start_options} ' f' --config={TEST_PROJECTS}/frontik_consul_mock.cfg --log_dir={self.tmp_log_dir} --log_level=debug', allow_to_create_log_files=True, ) diff --git a/tests/test_kafka_integration.py b/tests/test_kafka_integration.py index a29baa1f5..020b487fa 100644 --- a/tests/test_kafka_integration.py +++ b/tests/test_kafka_integration.py @@ -13,7 +13,7 @@ class TestKafkaIntegration: def test_kafka(self): response_json = frontik_test_app.get_page_json('kafka') - assert response_json['metrics_requests']['app'] == 'tests.projects.test_app.TestApplication' + assert response_json['metrics_requests']['app'] == 'test_app' assert response_json['metrics_requests']['dc'] == 'externalRequest' assert 'hostname' in response_json['metrics_requests'] assert 'requestId' in response_json['metrics_requests'] diff --git a/tests/test_logging.py b/tests/test_logging.py index 04f019900..050811876 100644 --- a/tests/test_logging.py +++ b/tests/test_logging.py @@ -26,9 +26,9 @@ def setup_class(cls): port = cls.s.getsockname()[1] cls.test_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.test_app.TestApplication --config={TEST_PROJECTS}/frontik_debug.cfg ' - f'--syslog=true --consul_enabled=False --syslog_host=127.0.0.1 --syslog_tag=test' - f' --log_level=debug --syslog_port={port}', + f'{FRONTIK_RUN} --app_class=tests.projects.test_app.TestApplication ' + f'--config={TEST_PROJECTS}/frontik_debug.cfg --syslog=true --consul_enabled=False --syslog_host=127.0.0.1 ' + f'--syslog_tag=test --log_level=debug --syslog_port={port}', ) @classmethod diff --git a/tests/test_service_discovery.py b/tests/test_service_discovery.py index ac1163a4c..fba7a5892 100644 --- a/tests/test_service_discovery.py +++ b/tests/test_service_discovery.py @@ -8,18 +8,18 @@ class TestServiceDiscovery: def setup_method(self) -> None: self.consul_mock = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.consul_mock_app.TestApplication {common_frontik_start_options} ' + f'{FRONTIK_RUN} --app_class=tests.projects.consul_mock_app.TestApplication {common_frontik_start_options} ' f' --config={TEST_PROJECTS}/frontik_consul_mock.cfg', ) self.consul_mock.start() self.frontik_single_worker_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.no_debug_app {common_frontik_start_options} ' + f'{FRONTIK_RUN} --app_class=tests.projects.no_debug_app.TestApplication {common_frontik_start_options} ' f' --config={TEST_PROJECTS}/frontik_no_debug.cfg --consul_port={self.consul_mock.port} ' f' --consul_enabled=True' f' --fail_start_on_empty_upstream=False', ) self.frontik_multiple_worker_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.no_debug_app {common_frontik_start_options} ' + f'{FRONTIK_RUN} --app_class=tests.projects.no_debug_app.TestApplication {common_frontik_start_options} ' f' --config={TEST_PROJECTS}/frontik_no_debug.cfg --consul_port={self.consul_mock.port} --workers=3' f' --consul_enabled=True' f' --fail_start_on_empty_upstream=False', diff --git a/tests/test_service_start.py b/tests/test_service_start.py index d6b979e31..b8f9f7922 100644 --- a/tests/test_service_start.py +++ b/tests/test_service_start.py @@ -4,6 +4,7 @@ from tests.instances import FrontikTestInstance FRONTIK_RUN = f'{FRONTIK_ROOT}/frontik-test' +TEST_PROJECTS = f'{FRONTIK_ROOT}/tests/projects' class TestServiceStart(unittest.TestCase): @@ -16,5 +17,6 @@ def app_run(self, parameters: str) -> None: def test_app(self) -> None: self.app_run( - f'{FRONTIK_RUN} --app=tests.projects.test_app.TestApplication --syslog=false --consul_enabled=False', + f'{FRONTIK_RUN} --app_class=tests.projects.test_app.TestApplication --syslog=false --consul_enabled=False ' + f'--config={TEST_PROJECTS}/frontik_debug.cfg', ) diff --git a/tests/test_statsd_integration.py b/tests/test_statsd_integration.py index df2da8ae0..9a4dad7a0 100644 --- a/tests/test_statsd_integration.py +++ b/tests/test_statsd_integration.py @@ -18,7 +18,8 @@ def test_send_to_statsd(self): port = statsd_socket.getsockname()[1] test_app = FrontikTestInstance( - f'{FRONTIK_RUN} --app=tests.projects.test_app.TestApplication --config={TEST_PROJECTS}/frontik_debug.cfg ' + f'{FRONTIK_RUN} --app_class=tests.projects.test_app.TestApplication ' + f'--config={TEST_PROJECTS}/frontik_debug.cfg ' f'--statsd_host=127.0.0.1 --consul_enabled=False --statsd_port={port}', ) diff --git a/tests/test_telemetry.py b/tests/test_telemetry.py index 6964de345..0dfe4b612 100644 --- a/tests/test_telemetry.py +++ b/tests/test_telemetry.py @@ -83,7 +83,7 @@ async def get_page_b(handler=get_current_handler()): def make_otel_provider() -> TracerProvider: resource = Resource( attributes={ - ResourceAttributes.SERVICE_NAME: options.app, # type: ignore + ResourceAttributes.SERVICE_NAME: options.service_name, # type: ignore ResourceAttributes.SERVICE_VERSION: '1.2.3', ResourceAttributes.HOST_NAME: options.node_name, ResourceAttributes.CLOUD_REGION: 'test',