ez-a-sync 0.24.11__tar.gz → 0.24.13__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of ez-a-sync might be problematic. Click here for more details.
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/PKG-INFO +1 -1
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/prio_semaphore.c +35 -41
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/prio_semaphore.pyx +4 -4
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/ez_a_sync.egg-info/PKG-INFO +1 -1
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/ez_a_sync.egg-info/SOURCES.txt +1 -0
- ez_a_sync-0.24.13/tests/test_smart.py +15 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/.coverage +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/.github/workflows/black.yaml +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/.github/workflows/codeql.yaml +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/.github/workflows/docs.yaml +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/.github/workflows/mypy.yaml +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/.github/workflows/pytest.yaml +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/.github/workflows/release.yaml +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/.gitignore +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/.sourcery.yaml +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/LICENSE.txt +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/MANIFEST.in +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/Makefile +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/README.md +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/TODO +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/ENVIRONMENT_VARIABLES.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/__init__.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/__init__.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/_smart.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/_typing.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/__init__.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_descriptor.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_flags.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_flags.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_flags.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_helpers.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_helpers.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_helpers.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_helpers.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_kwargs.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_kwargs.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_kwargs.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/_meta.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/abstract.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/abstract.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/abstract.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/base.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/base.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/base.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/config.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/decorator.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/flags.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/function.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/function.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/function.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/method.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/method.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/method.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/method.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/modifiers/__init__.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/modifiers/cache/__init__.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/modifiers/cache/memory.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/modifiers/limiter.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/modifiers/manager.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/modifiers/manager.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/modifiers/manager.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/modifiers/semaphores.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/property.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/property.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/property.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/a_sync/singleton.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/aliases.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/__init__.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/as_completed.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/as_completed.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/as_completed.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/as_completed.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/create_task.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/create_task.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/create_task.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/create_task.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/gather.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/gather.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/asyncio/gather.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/exceptions.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/executor.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/future.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/iter.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/iter.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/iter.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/__init__.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/__init__.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/_debug.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/_debug.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/_debug.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/_debug.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/_loggable.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/_loggable.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/_loggable.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/_loggable.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/__init__.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/__init__.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/counter.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/counter.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/counter.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/counter.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/event.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/event.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/event.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/event.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/prio_semaphore.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/prio_semaphore.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/semaphore.c +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/semaphore.pxd +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/semaphore.pyi +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/locks/semaphore.pyx +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/primitives/queue.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/py.typed +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/sphinx/__init__.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/sphinx/ext.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/task.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/utils/__init__.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/a_sync/utils/iterators.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/Makefile +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/alabaster.css +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/basic.css +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/custom.css +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/doctools.js +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/documentation_options.js +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/file.png +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/language_data.js +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/minus.png +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/plus.png +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/pygments.css +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/searchtools.js +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/_build/html/_static/sphinx_highlight.js +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/conf.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/index.rst +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/docs/make.bat +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/ez_a_sync.egg-info/dependency_links.txt +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/ez_a_sync.egg-info/not-zip-safe +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/ez_a_sync.egg-info/requires.txt +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/ez_a_sync.egg-info/top_level.txt +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/pyproject.yaml +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/requirements-dev.txt +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/requirements.txt +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/setup.cfg +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/setup.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/__init__.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/a_sync/test_abstract.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/a_sync/test_base.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/a_sync/test_cache.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/a_sync/test_decorator.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/a_sync/test_limiter.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/a_sync/test_meta.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/a_sync/test_modified.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/a_sync/test_singleton.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/asyncio/test_as_completed.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/asyncio/test_create_task.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/asyncio/test_gather.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/conftest.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/executor.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/fixtures.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/primitives/test_counter.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/primitives/test_event.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/primitives/test_prio_semaphore.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/primitives/test_queue.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/primitives/test_semaphore.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/task/test_task.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/task/test_task_mapping_views.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/test_executor.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/test_future.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/test_helpers.py +0 -0
- {ez_a_sync-0.24.11 → ez_a_sync-0.24.13}/tests/test_iter.py +0 -0
|
@@ -3405,7 +3405,7 @@ static const char __pyx_k_AbstractPrioritySemaphore_locke[] = "_AbstractPriority
|
|
|
3405
3405
|
static const char __pyx_k_Acquires_the_semaphore_for_this[] = "Acquires the semaphore for this context manager.\n\n If the internal counter is larger than zero on entry,\n decrement it by one and return True immediately. If it is\n zero on entry, block, waiting until some other coroutine has\n called release() to make it larger than 0, and then return\n True.\n\n This method overrides :meth:`Semaphore.acquire` to handle priority-based logic.\n\n Examples:\n >>> context_manager = _AbstractPrioritySemaphoreContextManager(parent, priority=1)\n >>> await context_manager.acquire()\n ";
|
|
3406
3406
|
static const char __pyx_k_Acquires_the_semaphore_with_the[] = "Acquires the semaphore with the top priority.\n\n This method overrides :meth:`Semaphore.acquire` to handle priority-based logic.\n\n Examples:\n >>> semaphore = _AbstractPrioritySemaphore(5)\n >>> await semaphore.acquire()\n ";
|
|
3407
3407
|
static const char __pyx_k_Initializes_the_context_manager[] = "Initializes the context manager for a specific priority.\n\n Args:\n parent: The parent semaphore.\n priority: The priority associated with this context manager.\n name: An optional name for the context manager, used for debugging.\n\n Examples:\n >>> parent_semaphore = _AbstractPrioritySemaphore(5)\n >>> context_manager = _AbstractPrioritySemaphoreContextManager(parent_semaphore, priority=1)\n ";
|
|
3408
|
-
static const char __pyx_k_PrioritySemaphoreContextManager[] = "
|
|
3408
|
+
static const char __pyx_k_PrioritySemaphoreContextManager[] = "_PrioritySemaphoreContextManager";
|
|
3409
3409
|
static const char __pyx_k_Releases_the_semaphore_for_this[] = "Releases the semaphore for this context manager.\n\n This method overrides :meth:`Semaphore.release` to handle priority-based logic.\n\n Examples:\n >>> context_manager = _AbstractPrioritySemaphoreContextManager(parent, priority=1)\n >>> context_manager.release()\n ";
|
|
3410
3410
|
static const char __pyx_k_This_module_provides_priority_b[] = "\nThis module provides priority-based semaphore implementations. These semaphores allow \nwaiters to be assigned priorities, ensuring that higher priority waiters are \nprocessed before lower priority ones.\n";
|
|
3411
3411
|
static const char __pyx_k_Checks_if_the_semaphore_is_locke[] = "Checks if the semaphore is locked.\n\n Returns:\n True if the semaphore cannot be acquired immediately, False otherwise.\n\n Examples:\n >>> semaphore = _AbstractPrioritySemaphore(5)\n >>> semaphore.locked()\n ";
|
|
@@ -3436,10 +3436,9 @@ static const char __pyx_k_AbstractPrioritySemaphore__wake_2[] = "_AbstractPriori
|
|
|
3436
3436
|
static const char __pyx_k_AbstractPrioritySemaphore_acqui_2[] = "_AbstractPrioritySemaphore.acquire (line 108)";
|
|
3437
3437
|
static const char __pyx_k_AbstractPrioritySemaphore_c_loc_2[] = "_AbstractPrioritySemaphore.c_locked.<locals>.genexpr";
|
|
3438
3438
|
static const char __pyx_k_AbstractPrioritySemaphore_locke_2[] = "_AbstractPrioritySemaphore.locked (line 151)";
|
|
3439
|
-
static const char __pyx_k_PrioritySemaphoreContextManager_2[] = "_PrioritySemaphoreContextManager";
|
|
3440
|
-
static const char __pyx_k_PrioritySemaphoreContextManager_3[] = "_PrioritySemaphoreContextManager.
|
|
3441
|
-
static const char __pyx_k_PrioritySemaphoreContextManager_4[] = "_PrioritySemaphoreContextManager.
|
|
3442
|
-
static const char __pyx_k_PrioritySemaphoreContextManager_5[] = "_PrioritySemaphoreContextManager.__lt__ (line 400)";
|
|
3439
|
+
static const char __pyx_k_PrioritySemaphoreContextManager_2[] = "_PrioritySemaphoreContextManager.__reduce_cython__";
|
|
3440
|
+
static const char __pyx_k_PrioritySemaphoreContextManager_3[] = "_PrioritySemaphoreContextManager.__setstate_cython__";
|
|
3441
|
+
static const char __pyx_k_PrioritySemaphoreContextManager_4[] = "_PrioritySemaphoreContextManager.__lt__ (line 400)";
|
|
3443
3442
|
static const char __pyx_k_AbstractPrioritySemaphoreContex_10[] = "_AbstractPrioritySemaphoreContextManager.__reduce_cython__";
|
|
3444
3443
|
static const char __pyx_k_AbstractPrioritySemaphoreContex_11[] = "_AbstractPrioritySemaphoreContextManager.__setstate_cython__";
|
|
3445
3444
|
static const char __pyx_k_AbstractPrioritySemaphoreContex_12[] = "_AbstractPrioritySemaphoreContextManager.__init__ (line 266)";
|
|
@@ -3612,8 +3611,7 @@ typedef struct {
|
|
|
3612
3611
|
PyObject *__pyx_n_s_PrioritySemaphoreContextManager;
|
|
3613
3612
|
PyObject *__pyx_n_s_PrioritySemaphoreContextManager_2;
|
|
3614
3613
|
PyObject *__pyx_n_s_PrioritySemaphoreContextManager_3;
|
|
3615
|
-
PyObject *
|
|
3616
|
-
PyObject *__pyx_kp_u_PrioritySemaphoreContextManager_5;
|
|
3614
|
+
PyObject *__pyx_kp_u_PrioritySemaphoreContextManager_4;
|
|
3617
3615
|
PyObject *__pyx_kp_u_PrioritySemaphore___getitem___li;
|
|
3618
3616
|
PyObject *__pyx_n_s_PrioritySemaphore___reduce_cytho;
|
|
3619
3617
|
PyObject *__pyx_n_s_PrioritySemaphore___setstate_cyt;
|
|
@@ -3923,8 +3921,7 @@ static int __pyx_m_clear(PyObject *m) {
|
|
|
3923
3921
|
Py_CLEAR(clear_module_state->__pyx_n_s_PrioritySemaphoreContextManager);
|
|
3924
3922
|
Py_CLEAR(clear_module_state->__pyx_n_s_PrioritySemaphoreContextManager_2);
|
|
3925
3923
|
Py_CLEAR(clear_module_state->__pyx_n_s_PrioritySemaphoreContextManager_3);
|
|
3926
|
-
Py_CLEAR(clear_module_state->
|
|
3927
|
-
Py_CLEAR(clear_module_state->__pyx_kp_u_PrioritySemaphoreContextManager_5);
|
|
3924
|
+
Py_CLEAR(clear_module_state->__pyx_kp_u_PrioritySemaphoreContextManager_4);
|
|
3928
3925
|
Py_CLEAR(clear_module_state->__pyx_kp_u_PrioritySemaphore___getitem___li);
|
|
3929
3926
|
Py_CLEAR(clear_module_state->__pyx_n_s_PrioritySemaphore___reduce_cytho);
|
|
3930
3927
|
Py_CLEAR(clear_module_state->__pyx_n_s_PrioritySemaphore___setstate_cyt);
|
|
@@ -4212,8 +4209,7 @@ static int __pyx_m_traverse(PyObject *m, visitproc visit, void *arg) {
|
|
|
4212
4209
|
Py_VISIT(traverse_module_state->__pyx_n_s_PrioritySemaphoreContextManager);
|
|
4213
4210
|
Py_VISIT(traverse_module_state->__pyx_n_s_PrioritySemaphoreContextManager_2);
|
|
4214
4211
|
Py_VISIT(traverse_module_state->__pyx_n_s_PrioritySemaphoreContextManager_3);
|
|
4215
|
-
Py_VISIT(traverse_module_state->
|
|
4216
|
-
Py_VISIT(traverse_module_state->__pyx_kp_u_PrioritySemaphoreContextManager_5);
|
|
4212
|
+
Py_VISIT(traverse_module_state->__pyx_kp_u_PrioritySemaphoreContextManager_4);
|
|
4217
4213
|
Py_VISIT(traverse_module_state->__pyx_kp_u_PrioritySemaphore___getitem___li);
|
|
4218
4214
|
Py_VISIT(traverse_module_state->__pyx_n_s_PrioritySemaphore___reduce_cytho);
|
|
4219
4215
|
Py_VISIT(traverse_module_state->__pyx_n_s_PrioritySemaphore___setstate_cyt);
|
|
@@ -4517,8 +4513,7 @@ static int __pyx_m_traverse(PyObject *m, visitproc visit, void *arg) {
|
|
|
4517
4513
|
#define __pyx_n_s_PrioritySemaphoreContextManager __pyx_mstate_global->__pyx_n_s_PrioritySemaphoreContextManager
|
|
4518
4514
|
#define __pyx_n_s_PrioritySemaphoreContextManager_2 __pyx_mstate_global->__pyx_n_s_PrioritySemaphoreContextManager_2
|
|
4519
4515
|
#define __pyx_n_s_PrioritySemaphoreContextManager_3 __pyx_mstate_global->__pyx_n_s_PrioritySemaphoreContextManager_3
|
|
4520
|
-
#define
|
|
4521
|
-
#define __pyx_kp_u_PrioritySemaphoreContextManager_5 __pyx_mstate_global->__pyx_kp_u_PrioritySemaphoreContextManager_5
|
|
4516
|
+
#define __pyx_kp_u_PrioritySemaphoreContextManager_4 __pyx_mstate_global->__pyx_kp_u_PrioritySemaphoreContextManager_4
|
|
4522
4517
|
#define __pyx_kp_u_PrioritySemaphore___getitem___li __pyx_mstate_global->__pyx_kp_u_PrioritySemaphore___getitem___li
|
|
4523
4518
|
#define __pyx_n_s_PrioritySemaphore___reduce_cytho __pyx_mstate_global->__pyx_n_s_PrioritySemaphore___reduce_cytho
|
|
4524
4519
|
#define __pyx_n_s_PrioritySemaphore___setstate_cyt __pyx_mstate_global->__pyx_n_s_PrioritySemaphore___setstate_cyt
|
|
@@ -9857,8 +9852,8 @@ static PyObject *__pyx_gb_6a_sync_10primitives_5locks_14prio_semaphore_40_Abstra
|
|
|
9857
9852
|
* async def __acquire(self) -> Literal[True]:
|
|
9858
9853
|
* cdef object loop, fut
|
|
9859
9854
|
* while self._parent._Semaphore__value <= 0: # <<<<<<<<<<<<<<
|
|
9860
|
-
* if self.
|
|
9861
|
-
* self.
|
|
9855
|
+
* if self._AbstractPrioritySemaphoreContextManager__waiters is None:
|
|
9856
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters = deque()
|
|
9862
9857
|
*/
|
|
9863
9858
|
__Pyx_TraceLine(351,0,__PYX_ERR(0, 351, __pyx_L1_error))
|
|
9864
9859
|
while (1) {
|
|
@@ -9868,8 +9863,8 @@ static PyObject *__pyx_gb_6a_sync_10primitives_5locks_14prio_semaphore_40_Abstra
|
|
|
9868
9863
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":352
|
|
9869
9864
|
* cdef object loop, fut
|
|
9870
9865
|
* while self._parent._Semaphore__value <= 0:
|
|
9871
|
-
* if self.
|
|
9872
|
-
* self.
|
|
9866
|
+
* if self._AbstractPrioritySemaphoreContextManager__waiters is None: # <<<<<<<<<<<<<<
|
|
9867
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters = deque()
|
|
9873
9868
|
* fut = (self.__loop or self._c_get_loop()).create_future()
|
|
9874
9869
|
*/
|
|
9875
9870
|
__Pyx_TraceLine(352,0,__PYX_ERR(0, 352, __pyx_L1_error))
|
|
@@ -9881,10 +9876,10 @@ static PyObject *__pyx_gb_6a_sync_10primitives_5locks_14prio_semaphore_40_Abstra
|
|
|
9881
9876
|
|
|
9882
9877
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":353
|
|
9883
9878
|
* while self._parent._Semaphore__value <= 0:
|
|
9884
|
-
* if self.
|
|
9885
|
-
* self.
|
|
9879
|
+
* if self._AbstractPrioritySemaphoreContextManager__waiters is None:
|
|
9880
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters = deque() # <<<<<<<<<<<<<<
|
|
9886
9881
|
* fut = (self.__loop or self._c_get_loop()).create_future()
|
|
9887
|
-
* self.
|
|
9882
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters.append(fut)
|
|
9888
9883
|
*/
|
|
9889
9884
|
__Pyx_TraceLine(353,0,__PYX_ERR(0, 353, __pyx_L1_error))
|
|
9890
9885
|
__Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_deque); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 353, __pyx_L1_error)
|
|
@@ -9917,17 +9912,17 @@ static PyObject *__pyx_gb_6a_sync_10primitives_5locks_14prio_semaphore_40_Abstra
|
|
|
9917
9912
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":352
|
|
9918
9913
|
* cdef object loop, fut
|
|
9919
9914
|
* while self._parent._Semaphore__value <= 0:
|
|
9920
|
-
* if self.
|
|
9921
|
-
* self.
|
|
9915
|
+
* if self._AbstractPrioritySemaphoreContextManager__waiters is None: # <<<<<<<<<<<<<<
|
|
9916
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters = deque()
|
|
9922
9917
|
* fut = (self.__loop or self._c_get_loop()).create_future()
|
|
9923
9918
|
*/
|
|
9924
9919
|
}
|
|
9925
9920
|
|
|
9926
9921
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":354
|
|
9927
|
-
* if self.
|
|
9928
|
-
* self.
|
|
9922
|
+
* if self._AbstractPrioritySemaphoreContextManager__waiters is None:
|
|
9923
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters = deque()
|
|
9929
9924
|
* fut = (self.__loop or self._c_get_loop()).create_future() # <<<<<<<<<<<<<<
|
|
9930
|
-
* self.
|
|
9925
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters.append(fut)
|
|
9931
9926
|
* self._parent._potential_lost_waiters.append(fut)
|
|
9932
9927
|
*/
|
|
9933
9928
|
__Pyx_TraceLine(354,0,__PYX_ERR(0, 354, __pyx_L1_error))
|
|
@@ -9979,9 +9974,9 @@ static PyObject *__pyx_gb_6a_sync_10primitives_5locks_14prio_semaphore_40_Abstra
|
|
|
9979
9974
|
__pyx_t_2 = 0;
|
|
9980
9975
|
|
|
9981
9976
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":355
|
|
9982
|
-
* self.
|
|
9977
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters = deque()
|
|
9983
9978
|
* fut = (self.__loop or self._c_get_loop()).create_future()
|
|
9984
|
-
* self.
|
|
9979
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters.append(fut) # <<<<<<<<<<<<<<
|
|
9985
9980
|
* self._parent._potential_lost_waiters.append(fut)
|
|
9986
9981
|
* try:
|
|
9987
9982
|
*/
|
|
@@ -9993,7 +9988,7 @@ static PyObject *__pyx_gb_6a_sync_10primitives_5locks_14prio_semaphore_40_Abstra
|
|
|
9993
9988
|
|
|
9994
9989
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":356
|
|
9995
9990
|
* fut = (self.__loop or self._c_get_loop()).create_future()
|
|
9996
|
-
* self.
|
|
9991
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters.append(fut)
|
|
9997
9992
|
* self._parent._potential_lost_waiters.append(fut) # <<<<<<<<<<<<<<
|
|
9998
9993
|
* try:
|
|
9999
9994
|
* await fut
|
|
@@ -10006,7 +10001,7 @@ static PyObject *__pyx_gb_6a_sync_10primitives_5locks_14prio_semaphore_40_Abstra
|
|
|
10006
10001
|
__pyx_t_6 = __Pyx_PyList_Append(__pyx_cur_scope->__pyx_v_self->_parent->_potential_lost_waiters, __pyx_cur_scope->__pyx_v_fut); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 356, __pyx_L1_error)
|
|
10007
10002
|
|
|
10008
10003
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":357
|
|
10009
|
-
* self.
|
|
10004
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters.append(fut)
|
|
10010
10005
|
* self._parent._potential_lost_waiters.append(fut)
|
|
10011
10006
|
* try: # <<<<<<<<<<<<<<
|
|
10012
10007
|
* await fut
|
|
@@ -10064,7 +10059,7 @@ static PyObject *__pyx_gb_6a_sync_10primitives_5locks_14prio_semaphore_40_Abstra
|
|
|
10064
10059
|
}
|
|
10065
10060
|
|
|
10066
10061
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":357
|
|
10067
|
-
* self.
|
|
10062
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters.append(fut)
|
|
10068
10063
|
* self._parent._potential_lost_waiters.append(fut)
|
|
10069
10064
|
* try: # <<<<<<<<<<<<<<
|
|
10070
10065
|
* await fut
|
|
@@ -10234,7 +10229,7 @@ static PyObject *__pyx_gb_6a_sync_10primitives_5locks_14prio_semaphore_40_Abstra
|
|
|
10234
10229
|
}
|
|
10235
10230
|
|
|
10236
10231
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":357
|
|
10237
|
-
* self.
|
|
10232
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters.append(fut)
|
|
10238
10233
|
* self._parent._potential_lost_waiters.append(fut)
|
|
10239
10234
|
* try: # <<<<<<<<<<<<<<
|
|
10240
10235
|
* await fut
|
|
@@ -11085,7 +11080,7 @@ static int __pyx_pf_6a_sync_10primitives_5locks_14prio_semaphore_32_PrioritySema
|
|
|
11085
11080
|
* def __cinit__(self):
|
|
11086
11081
|
* self._priority_name = "priority" # <<<<<<<<<<<<<<
|
|
11087
11082
|
* # Semaphore.__cinit__(self)
|
|
11088
|
-
* self.
|
|
11083
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters = deque()
|
|
11089
11084
|
*/
|
|
11090
11085
|
__Pyx_TraceLine(395,0,__PYX_ERR(0, 395, __pyx_L1_error))
|
|
11091
11086
|
__Pyx_INCREF(__pyx_n_u_priority_2);
|
|
@@ -11097,7 +11092,7 @@ static int __pyx_pf_6a_sync_10primitives_5locks_14prio_semaphore_32_PrioritySema
|
|
|
11097
11092
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":397
|
|
11098
11093
|
* self._priority_name = "priority"
|
|
11099
11094
|
* # Semaphore.__cinit__(self)
|
|
11100
|
-
* self.
|
|
11095
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters = deque() # <<<<<<<<<<<<<<
|
|
11101
11096
|
* self._decorated: Set[str] = set()
|
|
11102
11097
|
*
|
|
11103
11098
|
*/
|
|
@@ -11126,12 +11121,12 @@ static int __pyx_pf_6a_sync_10primitives_5locks_14prio_semaphore_32_PrioritySema
|
|
|
11126
11121
|
__Pyx_GOTREF(__pyx_t_1);
|
|
11127
11122
|
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
|
|
11128
11123
|
}
|
|
11129
|
-
if (__Pyx_PyObject_SetAttrStr(((PyObject *)__pyx_v_self),
|
|
11124
|
+
if (__Pyx_PyObject_SetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_AbstractPrioritySemaphoreContex_3, __pyx_t_1) < 0) __PYX_ERR(0, 397, __pyx_L1_error)
|
|
11130
11125
|
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
|
|
11131
11126
|
|
|
11132
11127
|
/* "a_sync/primitives/locks/prio_semaphore.pyx":398
|
|
11133
11128
|
* # Semaphore.__cinit__(self)
|
|
11134
|
-
* self.
|
|
11129
|
+
* self._AbstractPrioritySemaphoreContextManager__waiters = deque()
|
|
11135
11130
|
* self._decorated: Set[str] = set() # <<<<<<<<<<<<<<
|
|
11136
11131
|
*
|
|
11137
11132
|
* def __lt__(self, _PrioritySemaphoreContextManager other) -> bool:
|
|
@@ -15076,8 +15071,7 @@ static int __Pyx_CreateStringTabAndInitStrings(void) {
|
|
|
15076
15071
|
{&__pyx_n_s_PrioritySemaphoreContextManager, __pyx_k_PrioritySemaphoreContextManager, sizeof(__pyx_k_PrioritySemaphoreContextManager), 0, 0, 1, 1},
|
|
15077
15072
|
{&__pyx_n_s_PrioritySemaphoreContextManager_2, __pyx_k_PrioritySemaphoreContextManager_2, sizeof(__pyx_k_PrioritySemaphoreContextManager_2), 0, 0, 1, 1},
|
|
15078
15073
|
{&__pyx_n_s_PrioritySemaphoreContextManager_3, __pyx_k_PrioritySemaphoreContextManager_3, sizeof(__pyx_k_PrioritySemaphoreContextManager_3), 0, 0, 1, 1},
|
|
15079
|
-
{&
|
|
15080
|
-
{&__pyx_kp_u_PrioritySemaphoreContextManager_5, __pyx_k_PrioritySemaphoreContextManager_5, sizeof(__pyx_k_PrioritySemaphoreContextManager_5), 0, 1, 0, 0},
|
|
15074
|
+
{&__pyx_kp_u_PrioritySemaphoreContextManager_4, __pyx_k_PrioritySemaphoreContextManager_4, sizeof(__pyx_k_PrioritySemaphoreContextManager_4), 0, 1, 0, 0},
|
|
15081
15075
|
{&__pyx_kp_u_PrioritySemaphore___getitem___li, __pyx_k_PrioritySemaphore___getitem___li, sizeof(__pyx_k_PrioritySemaphore___getitem___li), 0, 1, 0, 0},
|
|
15082
15076
|
{&__pyx_n_s_PrioritySemaphore___reduce_cytho, __pyx_k_PrioritySemaphore___reduce_cytho, sizeof(__pyx_k_PrioritySemaphore___reduce_cytho), 0, 0, 1, 1},
|
|
15083
15077
|
{&__pyx_n_s_PrioritySemaphore___setstate_cyt, __pyx_k_PrioritySemaphore___setstate_cyt, sizeof(__pyx_k_PrioritySemaphore___setstate_cyt), 0, 0, 1, 1},
|
|
@@ -15715,7 +15709,7 @@ static int __Pyx_modinit_type_init_code(void) {
|
|
|
15715
15709
|
#if !CYTHON_COMPILING_IN_LIMITED_API
|
|
15716
15710
|
if (__Pyx_MergeVtables(__pyx_ptype_6a_sync_10primitives_5locks_14prio_semaphore__PrioritySemaphoreContextManager) < 0) __PYX_ERR(0, 391, __pyx_L1_error)
|
|
15717
15711
|
#endif
|
|
15718
|
-
if (PyObject_SetAttr(__pyx_m,
|
|
15712
|
+
if (PyObject_SetAttr(__pyx_m, __pyx_n_s_PrioritySemaphoreContextManager, (PyObject *) __pyx_ptype_6a_sync_10primitives_5locks_14prio_semaphore__PrioritySemaphoreContextManager) < 0) __PYX_ERR(0, 391, __pyx_L1_error)
|
|
15719
15713
|
#if !CYTHON_COMPILING_IN_LIMITED_API
|
|
15720
15714
|
if (__Pyx_setup_reduce((PyObject *) __pyx_ptype_6a_sync_10primitives_5locks_14prio_semaphore__PrioritySemaphoreContextManager) < 0) __PYX_ERR(0, 391, __pyx_L1_error)
|
|
15721
15715
|
#endif
|
|
@@ -16720,7 +16714,7 @@ if (!__Pyx_RefNanny) {
|
|
|
16720
16714
|
* def __setstate_cython__(self, __pyx_state):
|
|
16721
16715
|
*/
|
|
16722
16716
|
__Pyx_TraceLine(1,0,__PYX_ERR(1, 1, __pyx_L1_error))
|
|
16723
|
-
__pyx_t_3 = __Pyx_CyFunction_New(&__pyx_mdef_6a_sync_10primitives_5locks_14prio_semaphore_32_PrioritySemaphoreContextManager_5__reduce_cython__, __Pyx_CYFUNCTION_CCLASS,
|
|
16717
|
+
__pyx_t_3 = __Pyx_CyFunction_New(&__pyx_mdef_6a_sync_10primitives_5locks_14prio_semaphore_32_PrioritySemaphoreContextManager_5__reduce_cython__, __Pyx_CYFUNCTION_CCLASS, __pyx_n_s_PrioritySemaphoreContextManager_2, NULL, __pyx_n_s_a_sync_primitives_locks_prio_sem, __pyx_d, ((PyObject *)__pyx_codeobj__21)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1, __pyx_L1_error)
|
|
16724
16718
|
__Pyx_GOTREF(__pyx_t_3);
|
|
16725
16719
|
if (PyDict_SetItem(__pyx_d, __pyx_n_s_reduce_cython, __pyx_t_3) < 0) __PYX_ERR(1, 1, __pyx_L1_error)
|
|
16726
16720
|
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
|
|
@@ -16732,7 +16726,7 @@ if (!__Pyx_RefNanny) {
|
|
|
16732
16726
|
* raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
|
|
16733
16727
|
*/
|
|
16734
16728
|
__Pyx_TraceLine(3,0,__PYX_ERR(1, 3, __pyx_L1_error))
|
|
16735
|
-
__pyx_t_3 = __Pyx_CyFunction_New(&__pyx_mdef_6a_sync_10primitives_5locks_14prio_semaphore_32_PrioritySemaphoreContextManager_7__setstate_cython__, __Pyx_CYFUNCTION_CCLASS,
|
|
16729
|
+
__pyx_t_3 = __Pyx_CyFunction_New(&__pyx_mdef_6a_sync_10primitives_5locks_14prio_semaphore_32_PrioritySemaphoreContextManager_7__setstate_cython__, __Pyx_CYFUNCTION_CCLASS, __pyx_n_s_PrioritySemaphoreContextManager_3, NULL, __pyx_n_s_a_sync_primitives_locks_prio_sem, __pyx_d, ((PyObject *)__pyx_codeobj__22)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3, __pyx_L1_error)
|
|
16736
16730
|
__Pyx_GOTREF(__pyx_t_3);
|
|
16737
16731
|
if (PyDict_SetItem(__pyx_d, __pyx_n_s_setstate_cython, __pyx_t_3) < 0) __PYX_ERR(1, 3, __pyx_L1_error)
|
|
16738
16732
|
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
|
|
@@ -16823,7 +16817,7 @@ if (!__Pyx_RefNanny) {
|
|
|
16823
16817
|
if (PyDict_SetItem(__pyx_t_3, __pyx_kp_u_AbstractPrioritySemaphoreContex_13, __pyx_kp_u_Compares_this_context_manager_wi) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
|
|
16824
16818
|
if (PyDict_SetItem(__pyx_t_3, __pyx_kp_u_AbstractPrioritySemaphoreContex_14, __pyx_kp_u_Acquires_the_semaphore_for_this) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
|
|
16825
16819
|
if (PyDict_SetItem(__pyx_t_3, __pyx_kp_u_AbstractPrioritySemaphoreContex_15, __pyx_kp_u_Releases_the_semaphore_for_this) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
|
|
16826
|
-
if (PyDict_SetItem(__pyx_t_3,
|
|
16820
|
+
if (PyDict_SetItem(__pyx_t_3, __pyx_kp_u_PrioritySemaphoreContextManager_4, __pyx_kp_u_Compares_this_context_manager_wi) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
|
|
16827
16821
|
if (PyDict_SetItem(__pyx_t_3, __pyx_kp_u_PrioritySemaphore___getitem___li, __pyx_kp_u_Gets_the_context_manager_for_a_g) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
|
|
16828
16822
|
if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_3) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
|
|
16829
16823
|
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
|
|
@@ -349,10 +349,10 @@ cdef class _AbstractPrioritySemaphoreContextManager(Semaphore):
|
|
|
349
349
|
async def __acquire(self) -> Literal[True]:
|
|
350
350
|
cdef object loop, fut
|
|
351
351
|
while self._parent._Semaphore__value <= 0:
|
|
352
|
-
if self.
|
|
353
|
-
self.
|
|
352
|
+
if self._AbstractPrioritySemaphoreContextManager__waiters is None:
|
|
353
|
+
self._AbstractPrioritySemaphoreContextManager__waiters = deque()
|
|
354
354
|
fut = (self.__loop or self._c_get_loop()).create_future()
|
|
355
|
-
self.
|
|
355
|
+
self._AbstractPrioritySemaphoreContextManager__waiters.append(fut)
|
|
356
356
|
self._parent._potential_lost_waiters.append(fut)
|
|
357
357
|
try:
|
|
358
358
|
await fut
|
|
@@ -394,7 +394,7 @@ cdef class _PrioritySemaphoreContextManager(_AbstractPrioritySemaphoreContextMan
|
|
|
394
394
|
def __cinit__(self):
|
|
395
395
|
self._priority_name = "priority"
|
|
396
396
|
# Semaphore.__cinit__(self)
|
|
397
|
-
self.
|
|
397
|
+
self._AbstractPrioritySemaphoreContextManager__waiters = deque()
|
|
398
398
|
self._decorated: Set[str] = set()
|
|
399
399
|
|
|
400
400
|
def __lt__(self, _PrioritySemaphoreContextManager other) -> bool:
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import asyncio
|
|
2
|
+
import pytest
|
|
3
|
+
|
|
4
|
+
from a_sync._smart import SmartTask
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
@pytest.mark.asyncio_cooperative
|
|
8
|
+
async def test_smart_task_await():
|
|
9
|
+
await SmartTask(asyncio.sleep(0.1), loop=None)
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
@pytest.mark.asyncio_cooperative
|
|
13
|
+
async def test_smart_task_name():
|
|
14
|
+
t = SmartTask(asyncio.sleep(0.1), loop=None, name="test")
|
|
15
|
+
assert t.get_name() == "test"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|