From feed916f4688588594faf65beb5dc33cec20d514 Mon Sep 17 00:00:00 2001 From: Roman Mogylatov Date: Sun, 10 Jan 2021 19:26:15 -0500 Subject: [PATCH] Async resources and injections (#352) * Add support of async injections into wiring * Add support of async functions and async generators for resources * Update resource provider typing stub for stutdown * Add resource base class for async resources * Fix tests * Add tests for async injections in wiring @inject * Refactor provider tests * Add tests for async resources * Rework async resources callbacks to .add_done_callback() style (fixes pypy3 issue) * Add awaits into async resource class test * Refactor FastAPI tests * Implement async resources initialization in container * Move container async resource tests to a separate module for Python 3.6+ * Fix init async resources in container on Python 2 * Add first dirty async injections implementation * Fix isawaitable error * Turm asyncio import to conditional for safer Py2 usage * Refactor kwargs injections * Implement positional injections, add tests and make refactoring * Implement attribute injections and add tests * Add singleton implementation + tests for all singleton types * Implement injections in thread-local and thread-safe singleton providers * Update .provided + fix resource concurent initialization issue * Implement async mode for Dependency provider * Add async mode for the provider * Add overload for Factory typing * Add typing stubs for async resource * Refactor abstract* providers __call__() * Add async mode API + tests * Add typing stubs & tests for async mode API * Add tests for async mode auto configuration * Refactor Provider.__call__() to use async mode api * Refactor Dependency provider to use async mode api * Add tests for Dependency provider async mode * Add support of async mode for FactoryAggregate provider + tests * Refactor Singleton provider to use async mode api * Refactor ThreadSafeSingleton provider to use async mode api * Refactor ThreadLocalSingleton provider to use async mode api * Finish Singleton refactoring to use async mode api * Refactor Resource provider to use async mode api * Add Provider.async_() method + tests * Add typing stubs for async_() method + tests * Refactor Singleton typing stubs to return singleton from argument methods * Refactor provider typing stubs * Improve resource typing stub * Add tests for async context kwargs injections * Fix typo in resource provider tests * Cover shutdown of not initialized resource * Add test to cover resource initialization with an error * Fix Singleton and ThreadLocalSingleton to handle initialization errors * Add FastAPI + Redis example * Make cosmetic fixes to FastAPI + Redis example * Add missing development requirements * Update module docblock in fastapi + redis example * Add FastAPI + Redis example docs * Add references to FastAPI + Redis example * Refactor resource docs * Add asynchronous resources docs * Refactor wiring docs * Add async injections docs for wiring * Add async injections page and update docs index, readme, and key features pages * Add providers async injections example * Add docs on provider async mode enabling * Reword async provider docs * Add provider async mode docs * Add cross links to async docs * Mute flake8 errors in async provider examples * Update changelog * Make cosmetic fix to containers.pyx --- README.rst | 5 +- docs/examples/fastapi-redis.rst | 98 + docs/examples/index.rst | 1 + docs/index.rst | 1 + docs/introduction/di_in_python.rst | 1 + docs/introduction/key_features.rst | 1 + docs/main/changelog.rst | 4 + docs/providers/async.rst | 108 + docs/providers/images/async_mode.png | Bin 0 -> 12700 bytes docs/providers/index.rst | 1 + docs/providers/resource.rst | 132 +- docs/wiring.rst | 95 +- examples/miniapps/fastapi-redis/Dockerfile | 10 + examples/miniapps/fastapi-redis/README.rst | 89 + .../miniapps/fastapi-redis/docker-compose.yml | 21 + .../fastapi-redis/fastapiredis/__init__.py | 1 + .../fastapi-redis/fastapiredis/application.py | 25 + .../fastapi-redis/fastapiredis/containers.py | 21 + .../fastapi-redis/fastapiredis/redis.py | 12 + .../fastapi-redis/fastapiredis/services.py | 12 + .../fastapi-redis/fastapiredis/tests.py | 28 + .../miniapps/fastapi-redis/requirements.txt | 10 + examples/providers/async.py | 37 + examples/providers/async_overriding.py | 32 + requirements-dev.txt | 3 + setup.cfg | 2 + src/dependency_injector/containers.c | 8138 +++- src/dependency_injector/containers.pxd | 3 + src/dependency_injector/containers.pyi | 18 +- src/dependency_injector/containers.pyx | 33 +- src/dependency_injector/providers.c | 36985 ++++++++++------ src/dependency_injector/providers.pxd | 192 +- src/dependency_injector/providers.pyi | 149 +- src/dependency_injector/providers.pyx | 385 +- src/dependency_injector/resources.py | 11 + src/dependency_injector/wiring.py | 19 +- tests/typing/callable.py | 6 + tests/typing/delegate.py | 6 + tests/typing/dependency.py | 6 + tests/typing/dict.py | 10 + tests/typing/factory.py | 6 + tests/typing/list.py | 9 + tests/typing/object.py | 6 + tests/typing/provider.py | 9 + tests/typing/resource.py | 58 +- tests/typing/selector.py | 14 +- tests/typing/singleton.py | 6 + tests/unit/asyncutils.py | 57 + .../test_dynamic_async_resources_py36.py | 71 + tests/unit/containers/test_dynamic_py2_py3.py | 4 - tests/unit/providers/test_async_py36.py | 818 + tests/unit/providers/test_coroutines_py35.py | 62 +- .../unit/providers/test_factories_py2_py3.py | 18 + tests/unit/providers/test_resource_py35.py | 207 +- .../samples/wiringsamples/asyncinjections.py | 50 + tests/unit/wiring/test_wiring_py36.py | 62 + tests/unit/wiring/test_wiringfastapi_py36.py | 64 +- 57 files changed, 33044 insertions(+), 15188 deletions(-) create mode 100644 docs/examples/fastapi-redis.rst create mode 100644 docs/providers/async.rst create mode 100644 docs/providers/images/async_mode.png create mode 100644 examples/miniapps/fastapi-redis/Dockerfile create mode 100644 examples/miniapps/fastapi-redis/README.rst create mode 100644 examples/miniapps/fastapi-redis/docker-compose.yml create mode 100644 examples/miniapps/fastapi-redis/fastapiredis/__init__.py create mode 100644 examples/miniapps/fastapi-redis/fastapiredis/application.py create mode 100644 examples/miniapps/fastapi-redis/fastapiredis/containers.py create mode 100644 examples/miniapps/fastapi-redis/fastapiredis/redis.py create mode 100644 examples/miniapps/fastapi-redis/fastapiredis/services.py create mode 100644 examples/miniapps/fastapi-redis/fastapiredis/tests.py create mode 100644 examples/miniapps/fastapi-redis/requirements.txt create mode 100644 examples/providers/async.py create mode 100644 examples/providers/async_overriding.py create mode 100644 tests/unit/asyncutils.py create mode 100644 tests/unit/containers/test_dynamic_async_resources_py36.py create mode 100644 tests/unit/providers/test_async_py36.py create mode 100644 tests/unit/samples/wiringsamples/asyncinjections.py diff --git a/README.rst b/README.rst index 4af89beb..edceb4a1 100644 --- a/README.rst +++ b/README.rst @@ -70,6 +70,8 @@ Key features of the ``Dependency Injector``: - **Wiring**. Injects dependencies into functions and methods. Helps integrating with other frameworks: Django, Flask, Aiohttp, Sanic, FastAPI, etc. See `Wiring `_. +- **Asynchronous**. Supports asynchronous injections. + See `Asynchronous injections `_. - **Typing**. Provides typing stubs, ``mypy``-friendly. See `Typing and mypy `_. - **Performance**. Fast. Written in ``Cython``. @@ -157,6 +159,8 @@ Choose one of the following: - `Flask example `_ - `Aiohttp example `_ - `Sanic example `_ +- `FastAPI example `_ +- `FastAPI + Redis example `_ Tutorials --------- @@ -223,4 +227,3 @@ Want to contribute? .. |tell| unicode:: U+1F4AC .. tell sign .. |fork| unicode:: U+1F500 .. fork sign .. |pull| unicode:: U+2B05 U+FE0F .. pull sign - diff --git a/docs/examples/fastapi-redis.rst b/docs/examples/fastapi-redis.rst new file mode 100644 index 00000000..2e120cc8 --- /dev/null +++ b/docs/examples/fastapi-redis.rst @@ -0,0 +1,98 @@ +.. _fastapi-redis-example: + +FastAPI + Redis example +======================= + +.. meta:: + :keywords: Python,Dependency Injection,FastAPI,Redis,Example + :description: This example demonstrates a usage of the FastAPI, Redis, and Dependency Injector. + +This example shows how to use ``Dependency Injector`` with `FastAPI `_ and +`Redis `_. + +The source code is available on the `Github `_. + +See also: + +- Provider :ref:`async-injections` +- Resource provider :ref:`resource-async-initializers` +- Wiring :ref:`async-injections-wiring` + +Application structure +--------------------- + +Application has next structure: + +.. code-block:: bash + + ./ + ├── fastapiredis/ + │ ├── __init__.py + │ ├── application.py + │ ├── containers.py + │ ├── redis.py + │ ├── services.py + │ └── tests.py + ├── docker-compose.yml + ├── Dockerfile + └── requirements.txt + +Redis +----- + +Module ``redis`` defines Redis connection pool initialization and shutdown. See ``fastapiredis/redis.py``: + +.. literalinclude:: ../../examples/miniapps/fastapi-redis/fastapiredis/redis.py + :language: python + +Service +------- + +Module ``services`` contains example service. Service has a dependency on Redis connection pool. +It uses it for getting and setting a key asynchronously. Real life service will do something more meaningful. +See ``fastapiredis/services.py``: + +.. literalinclude:: ../../examples/miniapps/fastapi-redis/fastapiredis/services.py + :language: python + +Container +--------- + +Declarative container wires example service with Redis connection pool. See ``fastapiredis/containers.py``: + +.. literalinclude:: ../../examples/miniapps/fastapi-redis/fastapiredis/containers.py + :language: python + +Application +----------- + +Module ``application`` creates ``FastAPI`` app, setup endpoint, and init container. + +Endpoint ``index`` has a dependency on example service. The dependency is injected using :ref:`wiring` feature. + +Listing of ``fastapiredis/application.py``: + +.. literalinclude:: ../../examples/miniapps/fastapi-redis/fastapiredis/application.py + :language: python + +Tests +----- + +Tests use :ref:`provider-overriding` feature to replace example service with a mock. See ``fastapiredis/tests.py``: + +.. literalinclude:: ../../examples/miniapps/fastapi-redis/fastapiredis/tests.py + :language: python + :emphasize-lines: 24 + +Sources +------- + +The source code is available on the `Github `_. + +See also: + +- Provider :ref:`async-injections` +- Resource provider :ref:`resource-async-initializers` +- Wiring :ref:`async-injections-wiring` + +.. disqus:: diff --git a/docs/examples/index.rst b/docs/examples/index.rst index bbb2feb3..2898a5a0 100644 --- a/docs/examples/index.rst +++ b/docs/examples/index.rst @@ -19,5 +19,6 @@ Explore the examples to see the ``Dependency Injector`` in action. aiohttp sanic fastapi + fastapi-redis .. disqus:: diff --git a/docs/index.rst b/docs/index.rst index f45e2472..a539fe0e 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -78,6 +78,7 @@ Key features of the ``Dependency Injector``: - **Containers**. Provides declarative and dynamic containers. See :ref:`containers`. - **Wiring**. Injects dependencies into functions and methods. Helps integrating with other frameworks: Django, Flask, Aiohttp, Sanic, FastAPI, etc. See :ref:`wiring`. +- **Asynchronous**. Supports asynchronous injections. See :ref:`async-injections`. - **Typing**. Provides typing stubs, ``mypy``-friendly. See :ref:`provider-typing`. - **Performance**. Fast. Written in ``Cython``. - **Maturity**. Mature and production-ready. Well-tested, documented and supported. diff --git a/docs/introduction/di_in_python.rst b/docs/introduction/di_in_python.rst index 1a1daf07..bf8d7f0c 100644 --- a/docs/introduction/di_in_python.rst +++ b/docs/introduction/di_in_python.rst @@ -287,6 +287,7 @@ Choose one of the following as a next step: - :ref:`aiohttp-example` - :ref:`sanic-example` - :ref:`fastapi-example` + - :ref:`fastapi-redis-example` - Pass the tutorials: - :ref:`flask-tutorial` - :ref:`aiohttp-tutorial` diff --git a/docs/introduction/key_features.rst b/docs/introduction/key_features.rst index 23aa6822..ca290452 100644 --- a/docs/introduction/key_features.rst +++ b/docs/introduction/key_features.rst @@ -24,6 +24,7 @@ Key features of the ``Dependency Injector``: - **Containers**. Provides declarative and dynamic containers. See :ref:`containers`. - **Wiring**. Injects dependencies into functions and methods. Helps integrating with other frameworks: Django, Flask, Aiohttp, Sanic, FastAPI, etc. See :ref:`wiring`. +- **Asynchronous**. Supports asynchronous injections. See :ref:`async-injections`. - **Typing**. Provides typing stubs, ``mypy``-friendly. See :ref:`provider-typing`. - **Performance**. Fast. Written in ``Cython``. - **Maturity**. Mature and production-ready. Well-tested, documented and supported. diff --git a/docs/main/changelog.rst b/docs/main/changelog.rst index 44998734..fd5284a3 100644 --- a/docs/main/changelog.rst +++ b/docs/main/changelog.rst @@ -9,6 +9,10 @@ follows `Semantic versioning`_ Development version ------------------- +- Add support of async injections for providers. +- Add support of async injections for wiring. +- Add support of async initializers for ``Resource`` provider. +- Add ``FastAPI`` + ``Redis`` example. - Add ARM wheel builds. See issue `#342 `_ for details. - Fix a typo in `ext.flask` deprecation warning. diff --git a/docs/providers/async.rst b/docs/providers/async.rst new file mode 100644 index 00000000..312bb33c --- /dev/null +++ b/docs/providers/async.rst @@ -0,0 +1,108 @@ +.. _async-injections: + +Asynchronous injections +======================= + +.. meta:: + :keywords: Python,DI,Dependency injection,IoC,Inversion of Control,Providers,Async,Injections,Asynchronous,Await, + Asyncio + :description: Dependency Injector providers support asynchronous injections. This page + demonstrates how make asynchronous dependency injections in Python. + +Providers support asynchronous injections. + +.. literalinclude:: ../../examples/providers/async.py + :language: python + :emphasize-lines: 26-29 + :lines: 3- + +If provider has any awaitable injections it switches into async mode. In async mode provider always returns awaitable. +This causes a cascade effect: + +.. code-block:: bash + + provider1() <── Async mode enabled <──┐ + │ │ + ├──> provider2() │ + │ │ + ├──> provider3() <── Async mode enabled <──┤ + │ │ │ + │ └──> provider4() <── Async provider ───────┘ + │ + └──> provider5() + │ + └──> provider6() + +In async mode provider prepares injections asynchronously. + +If provider has multiple awaitable dependencies, it will run them concurrently. Provider will wait until all +dependencies are ready and inject them afterwards. + +.. code-block:: bash + + provider1() + │ + ├──> provider2() <── Async mode enabled + │ + ├──> provider3() <── Async mode enabled + │ + └──> provider4() <── Async mode enabled + +Here is what provider will do for the previous example: + +.. code-block:: python + + injections = await asyncio.gather( + provider2(), + provider3(), + provider4(), + ) + await provider1(*injections) + +Overriding behaviour +-------------------- + +In async mode provider always returns awaitable. It applies to the overriding too. If provider in async mode is +overridden by a provider that doesn't return awaitable result, the result will be wrapped into awaitable. + +.. literalinclude:: ../../examples/providers/async_overriding.py + :language: python + :emphasize-lines: 19-24 + :lines: 3- + +Async mode mechanics and API +---------------------------- + +By default provider's async mode is undefined. + +When provider async mode is undefined, provider will automatically select the mode during the next call. +If the result is awaitable, provider will enable async mode, if not - disable it. + +If provider async mode is enabled, provider always returns awaitable. If the result is not awaitable, +provider wraps it into awaitable explicitly. You can safely ``await`` provider in async mode. + +If provider async mode is disabled, provider behaves the regular way. It doesn't do async injections +preparation or non-awaitables to awaitables conversion. + +Once provider async mode is enabled or disabled, provider will stay in this state. No automatic switching +will be done. + +.. image:: images/async_mode.png + +You can also use following methods to change provider's async mode manually: + +- ``Provider.enable_async_mode()`` +- ``Provider.disable_async_mode()`` +- ``Provider.reset_async_mode()`` + +To check the state of provider's async mode use: + +- ``Provider.is_async_mode_enabled()`` +- ``Provider.is_async_mode_disabled()`` +- ``Provider.is_async_mode_undefined()`` + +See also: + +- Wiring :ref:`async-injections-wiring` +- Resource provider :ref:`resource-async-initializers` +- :ref:`fastapi-redis-example` diff --git a/docs/providers/images/async_mode.png b/docs/providers/images/async_mode.png new file mode 100644 index 0000000000000000000000000000000000000000..8c7382f19046aa09f857ad16e108a151e92ab515 GIT binary patch literal 12700 zcmeHuXH-+&wkU~25ky3R&;@n8ZYqm9K=H6?rz2;nbrK_z%P0372Mn*=h zrmCnegEjok6E)?+fVibSeYYX|^y*sAJlk&y*+laV1`l93Ss z6mpr2%wL#{Y{iO2xWX`pm|e!jA@(%IR$y}jMv-(OHr5E2q% zX=&Nm*qEN4espwHUS2*nHs}+n3zDJP|C{6i;IgVCntS!nZEbDA!NIPst}qy^x3{;YrNzb1CLqQkw$#JP2k!It>z5x|q6*#8+kEmz z0t&_gk$F`KEhBIGH{arRkl8Mo-M%4jN?y0&-}U;XeqZ!L*tv&B**ROKG<(}RxuWX& z@&^6Wf31e3I0YuXOKtZE$${kz_`RxhO#Mmle_Iw&+F|OZp42`U*E(+G;;(ICZyT%| zQqU;#STUn-(;+fNNyqT*Pw)I;{}&~;zR9MEO|G!OsOXx0_k?_1n3C)hN!Py(RdnT3 zQc|u3aV`SS31p+8qDU44xvdHSSG`nCe96cJIWHOrUL+p?Ag}nTX(?S<1W`io@}yBw zgprX6fz%Wq8^Ficr(T8JG9J$Jb{k8FO5VA9T|3ZL*oGS3__Vh7tVi=^vS0G`cfHEr z9WHgg34?)u<;s0*QBPkBSx@e5Ic&x(9k*V-163y+6^W$<1NY2}fK+;9?titM|Srb`*j!6umkOpMc1tLtKVwnlTQQF9Pe`N5eWPLA!@ z>{I3Gl6)w7Ll^zX?D$Xk#_<%h?76wUz^~duJOf#qunDm>+`11XMA)CpfvT_C=o8~X z!d|}f$91PaLk`r%RVSxqg_c%rL$!%LAmQin$7?5~v?<)acl(BMrQw6VC=rEz=Holq zDYtX`gNrRk@}Kufp@?Q>h)O$5d|;q zdgk$d6e|V!ixk$WjkK;!siefR&vJ1Wuvb3L@0QXM-py$Q@qNykwlv z0!3is^c8H?Kq^J}2V^z*$UnRsH<&4%62Rd6|7!pOc*E@Z^HI!D%5{EzK|yA@K)w@c zDwE0S41EO-Q5-~O)T6GB0%xQwK%#uazKCYH#l|NYUIDg|+7k ze5%Dv6(h+mKWRi#nHdSV*qv;BjikGwFqJK2)qE9x_iS;XqoczXz_e)T?_^9*(8-gpww$$kXPpA zCj%d}WES~tt?Lr|yTj7JY#}x8B)$1z&x`#8C63V@^Fus`mWpmL>2O-WM2{|r%;f%P zggOXHLwEIOqwkv4S$}sy5tvQZd}V63z>I!txqGgA3^r{`Yk`tf1c4rPn)#Z^*aC8+ zhZVffRixfZ)qnBgEi*K2yfsjs$iA}1%I=vf^IE?3+|FkfpC8qx###{N-&%cJ$l5yp z6Ow8m8D=3t=Si^<@}V;3R*_P3ss|`X#(Uv=es5d!WeaS>F#IVo?8*&7Xj?*}mghkn z2>NBPVBxz(YT+%l;yJB~ql~U(t=d9lbZi$?Ju9y0;hi+F!vuW$0q&;aCn z`IX))*sXatm6mXLTjB0mx_htZ&99H4TUNoM8w!Z;TSLuJ??P|)Q9Y-$W&TCVf^NYZ z7mlb7Ju73JuJTkxzTmn1980J;wu^eEfW6wIiKn>Uh&+BZK5vqwoz5Mj~%z8p{49F#~4%NGD8$Z$_+)ECj{s zKW{`VS_QG!8iP>w{C0iIRWU1E(&fXJ*s@bS1uT6JHMc|h{XWKjYQvb7_=(WiHapkr zeh+j%q5tw+*$69#T5fb2*m=ljM(^e9U^B1&4_z(4(m9`pfKcwuE2ZZ@ApBuJ1VZ2y zEd#|6{`873$A2|?l^7VJb0*Oyw?^jR3>y z?;H#nU>l5b0fY92oZ@ZXWM-+BrI(SOdGqYtsx*Sc>3Fbyma>9jHUbg`zjpe57! ztkUswE>i0%ZfBlyuc7+`_vC}=%xOJPqG4H}8f)Kbbp>*)^agPa!oIN|IJyowtWUAp zU+|@dWKYY4-w=M(Fch8JF3_`aDt~MLB;@qG?j$Ao{>UP|-kLGCBSXwB*)ZYKMl-U7 zL2vhM5=H}Kzic1iy!4tmPx5TYZ$P^aG*8{S;xO{0!ekVK?C7*)`(f*(Qxg-p@%u*OEHzDkHc^ zQbZ<{Hs7>O4ZCha=OqFJ zFKW~%Ov?1_q(RauDDvS=*c&-+(t}`EMcW6PTiU_(VhG=1;@hN*WQ$(`C+*+n20Ef{ zb<1j0u^rsAVl8aDBE^z0u&$@`M<>=5&O7cR9l$Xzswscu`V0%FEpd!8` z&vYIY%6(VHcOd?r!_;I?++oC2sB`{mFRUk*s#pBuj~!0$Fv=tSV9t|zjc9e9*u$6! z9-89AAnm&GUzBjGDkWA`%lYl2=AMXPs(Mr(L>fK2f$-|9_$uu78e<_XG^5eQaGxZt zm+il9jKyiK(y;T%6I4GG^HllrGB`dV3ZPR7DJqG;^sty@>AbqltAUBJR7RIRBS7;F z&SWLuoLu5QVE+*=)%9v8Xtos+>I@^MJh^@wC9j+8P>y++T2velddpmX3u3mrn zv}!JO*0H0(y?dag=iZr~A0tGxtB)#Rf&%jL(Zzb&7!Ur&1`$;OO(}z{6Tz7UNRI;K z7Zp&Cosc3#KYUy6yAmAG=NT{}ypd~y3EENy7VVT=pDfTmOPWpVGAbyRc ztKinAcCKs566rId9w{*w4sA8;_qro=P+@sWDmCl|ulvA`;(H)BoGX7{Q>S$l)%Zb%P&uLWn7Z*3?2^8;LmYzi2J(|4=_ z>#(~h>vm;hYS*V#u5%1>Kn7{Qt|dk#v^Ef`u+w$yIu=qmiS3Rahr)P9Q&pUy*;bWl+L(iEv@%SV=|+4?+b zl)e7u&B9H_a)9r>h*(*}i(B)y3w`2rHy*JtF)`8On3z9c8h2p=EprvO>2Ay}UyI+< zKsxeryx30c?LU1=RKg0;-T0b^{Gtq^y+%pl`fuR>hz~%^N}&I2vl%1WN|qT2CJJ)M zOW3rN%Jk$;kY~&O@C2@$exm@n^mfu6$A-SLJnAxXwJ?gQ>7*pXO# zEq>tvvjL#)?sNl5Sn|%PHF4Ak5_-}Tz;xw`o-%0mbs#PtBR;3~RWT9VdN3T~&54h_ zPHM?=J82<3KJ6G_za&XXk=Xn;U1*vbArSOg1vFTSh5HK01t!ZJMjqD5MS<;kIZn5O zYY$mAFJrP~;2%?K*dTG|60+_))`Ss-m*8*g+dOmAy@-9p&ddkgKnoirw2tok$SAck zl#;@;*~0A`sp`mXk^ypBve&hpTUT`caONgJvCED5c{ew10*&<4S8#g){>HNDPcM9I zH~GQFcPkPYB@t|Mi|$72QQnk*T(hwh^t4al;Ke*wvk(an$^bkz_xo>f>udRJ*4v@) z@eMP3D})irTQ39w5je(=){5A)oZ{_0Je?R2gGXRYvG5UzRxo!ue-1PVGGzXD!HqG8buV}_pz_oMlaEAR&IF8PV0JWp>O)l~4 znvEIl8wH7HZ*w0bmfFO}-N0yI{o|Sbyhff85Q{?DS%yEv?`W{ULOg4Hr1?H&lAX$) z?gj$h;wK{%a39Yd%2_(m?$|4fwB6WuXotxc-{JjA2f-zw}K(lre<=qt%6wESA? zW=o*-MC7J&B3Jn7u*zl~K9uwL1&y{pVi0j&@T}bAtcZdQLY@cxUv7%RX9G-`;i?#l zqbTrSjC41Kf%x+nWF7ziEwFtE1XqiH1=pio07%?JAz{26PX?TnnQ=mwEc1~R9na0N zB7_VO5W8R6+!vf_-usC(=H&nnxNtiZ!YD$YfN1}gK%Qrjf4dG*ypb$`J%6YHwvGaS z3y-f@V6<{I=G2}!WpsRL{Wn<3y75u$dgfcLM6y~b*UHyt4gtzU`=HN{1W42(GIY9= zleh)NThb%3#*XOXgPA^>r=ZCm9wwN)a#wTi4TEzyUNnlD&q(5Uh>yc|* zyapzZf>+8Jv`lj|$!d6PLhR@cc=4;7+}p1XfoE ze@|oa>YHp%0O*fx$#3+k-()alGFmGbF@eC2)suXbD!hA zv*Nv(egVQ*8!}fko)^N}%67sSv0;sU7OR{Jz79(ai&Hohp1G%VAywWbr<@nUxRr{g zEkc6D)@)xkMuT7kCOt}Ct2R015`dJJ^Dk0$A&gcx-%;^i9YZ7VK*e*90IRHX2-nW6#GSUHwzf7eLglB{V01K3U z5k}jPnCc65kun>aOKi^`00B$cncY^CSVJbudtr)gBV)NUVFbLFX9oq)2Rnl;u@3Q$e?cKAy)D3`zph}c_x1r!(C0Q{*U5I}KeEWoT^Ob;---Upat z-_nHBTtW<9gh$QhM3MWX`^Z*Nzzn*H*T53S#SneiVU7reCRGhZX(#omHlQoKh`3BOSj*(%HCo0q z@xAJpin2Giiy{PV6n!t<)_VtGwXIioXlp%=&Se~^1SOPof@^`Tt?q~>`RT4zOM6TJ z%V^9B-;DWw|4vtK=tmq6yRlIlUDLOXW#)mw+^{m7&Q#v1Oy2$I)3zXc{?!Q$mN1lQ>2LlxNy#a;be3{pr29 z%~IqmNf{>xU2dhnR57c(%6mMu=RSCnXg#f=A=aptO+KwG!A!1anCkt@qD4+(gP;H8 z&M{Wm;2DU8pe}P#<>zC*yF2DLyw*-|MM#S0(Ha_H340W~U96zVnUlTG zTl|L_NvZM6&Ix25TWy4|aV0t6-Xi()W0ejlcJI(WSlBCP6})K2NlclevLc@Rc^`4X zqFvmC#i)06YGI0{zkS8i^jZ^Qa!$0Q#5{=WlN`zhTA;z)v&n_KUhMc{z8I3#y|Ead zoArsCmqpMnly5BUv1&=Jh(F1UCIkRqSPr`^j5ei|NdDY}FM2p%iBIvTJEh_AGLS-t zt2%bthyRub$ZtZ2Px&1mi*4Kc@b-6j_j51}_+~@K+QpY#*!8#|th4G)mvSpEH`vdpEzX*k7>6bc_zZeZ;Hy|kZD5)0P$)**j}->JAk`)u;o z*WZBv5)Jk-n`wlEHwee&YKrwrwHVIu24Fas)6FUR@I5?#_xgN zkTja^20fiF`9&hF^deRE->WNWhFwfcOWSQ>w-mGde%xCn^!p$g@Rl|G)*NtrfNQmU zWmoB4v~dsA=fmzA%KubcSHZQH!K-M>L+B6z?||R=`OdL?=pQnfRPZ2@&!+tI&1*mD zS3CBP(YmsjPaGl^;$#E=Fp5w<7sifJ~NI52U$<&BUU`htqk+ z{bVK0ycpTG6bf=RxdBl`{{b_wgk^Yk&^A}3ke5Bf&K4j$sq&E^#^)eu>bP6*6K=@b zE3ii!H^ki1vUTt{x9QMmc-UyeuzbJii%+=w`q_`jrYVR__~zMo4UQgZ0WoidhFOe! z+Yl@_*I+9IMzR78lFP+~TgYCoXR|1%8&4}jefmUGE@R$e8Ek5bRe2{55B&gdHpQY6 z=gLD2EXEf#5(lr`%cF-;jUK1SV~8t=fNPEQ`o|k2p0P-s9hDTYT+i8zWjXlIPnU9f z!s*JB+UgTJVe&|Rt4u6v@r{z;RBvyp41eYRvbvlnO_lHWZm31;>v!h8Y(mg2pV}`6 z@wkpb@v5S!R!z`4+#DNl&ot=!#+iwnWCny!a7KOmXpkBr13PPU4BR10Z~Ys5*(wjH z#Ms|Wq=%SeEONegnb7m`ydKejGzW2pOGuYIzdy5YNhR&O>q2nl%}XmmYWNGdeTS?q z5V~v9(pEE}g7qSwZ1LZC)DX|)Gvu(BEQUD$k$zAy@$lPJD_wzkIEMFp=kr<_UY z#cc$#ojuC~id$-gtJ|usl@&wJE}LN=(iHT3Q3s{u`3JZdr}R{>2Cbr1*h{DH-ew79Ln#%|R2{D-c4V}-E zyWc7p>leiF?1sp?mo;0$R`oG&PABSY*8CRV@JoK9G4%s8;1i`{?{ z-dgRNy>g>xy{!yNPBqm*@Mh@tIXoA=Q%kj&uIDw9 zde4_Ou<0=Qfjk4DTi!LMEsAFD;=ABK4RKU~AI!1)>KyYH8$)~H~aLo9;q|fVc6FA;3YUPlO#6!{S{jRSxtiS9l zomc5k5*qn4jfVl#v}?6!y7yb24`Tj7u+ALYWYIL?+FgsETJioK0R`&H9~&aFp3N5z zuzm7$YuriA--Pfiz3`N2ZoTtDe572y^=5_JWSM^1w%kJIDxoYysEhmiRJVQSaKQMhmqLfy9IBy_4`N?H7wE|I8yFF_kYFwB_+%RFOq^46sek zg|TgsVN|0V{;ax%$XjM*T9nV<`-RbbL~buhu5Vaq;QKgbyG;CVS1)nthMpjIbN_Aq`pA>b%F zoOSE;ZyuvwIKOew`2Bxhk4cxdo<% zHMFUCFd7?iNw+yd-)!#wfy8B`ugl5*kY;u_wQPAS6Z}aFw0I4TWC=H#i~`(HH<%Nk z9(eee$M$eX00S42Xj#Qa@&v8Nf;+{*=BP^e;n$kE606gnP9a;NOP_MCRU?~@G`}ZM zpFg}~j9xWiD=l*{URezKLCF|?cfn<6{`Y)HMrYSKdcArgL#n57(&YOPujzK!&AF*D z?E^Fn)@;bi&##@N$PytwhoThf$}r%GimSU<-U+qA$7U#iqArXp-50V7;Ka(O#Md2h ze;AOho?8XYzu?kQ^$aqk6K+Y`>NXAjwEW|5*ojGX9#3Q=+n2aL$Y%SNJam!^Qy%8c zD%`@fx6bE$SI9n`d5Rz!JG7qF{mcWV-MZ|3x;C+GOK?s^BMDbD%ZlaSRW;6zB%H?@ zE|tX?DYhb)au;<%GNj-MKZ&$-k%EazbvyDudruf3GQPXk&eq4&wd$~4VM{Sc>Kz!i ze4|)idZACk28z~dbnUL%4Bh9LB5O{!5P2>*W4u&eG!fosqz>(zY)BXNT7P_6=M}Dy zL4AIPJnqD&m6@@p_CoN@IV8G7mbzH?_PvUu*I6_L>f94Zn!d@%16#{%?QzuvBn z={SZzKXdjb><^2x;R}&3Rs?4bCWE}JB|S%{q!;C-Frl+wkF{E>ce{SFoSlXS1=WnX zG}o(Cx6Dp+j(=O+U;Xqc@uNv&10t*izOd7yE-xKk+dU^})GB(8wxrR==KB;N5yFf@ z2<@1n*|Y4V89fD8y8i4j_;%Ht+qFZ-4hXRP0M&O!AzGl&&gl{l&a`b-)K&0}E4irK zZ{K_j>JdQ?1J(FW4Pe{R74vWA|DE0_=FO{s8)~UxY*#e(6l~*4YV4X3X$dGAgnhH( zT~1<_pLysO3#W?!Q@Ll+>RhBJlMt|fMDSQZ*+YS6!xBF-_8#ZI{q_C!N9Hs{*Kc5l z>q}@nn(ZIthm!s&m+fZ} z>XkrSBhFG@y;-z7*Sa}R|A>!-xR)BYOoI#Z#?!=WG^zJk{Fu4I`oR5CxkQ1mCvgDtjrI6D|7x7;)SAcv?L`d;j)t` z+NpFq_W898+$-;i49Bsy8-R5Uo`tvOYdtR{AK(^}v87zlOJXX8c!4w=?P4-kE37xh zV~~y|!c1Kp)G%(@`L8aMUI+p6#hkw775@0pQ2!$JU<{-lgwYdXZQV%%h3_9b6yopI zI7l#6M!^^d*0Z#Y*bY^emnQrmS{j&VF7}*1NVLSG1lp-r-FEBm7P(DiNtvwVZrbV? zo!BDI;Dju@{k;iEWj~%je^T}jIUSz{AMJG6t^e}PPs?^w44-pTrNN)J$87xa+Zp)z zrz=zr9=R#6J>0`D&6r$CE8DXaDSk97%GvlVeoy$DiFUN#vE&rwPXfy~fY?Py62xTN zDh8INl_{3Rl@UeFghI#lP36$$OcvXcoTjL^Zn9_J@6Aru$ve14eY&;)B#mypf9Z=S zwZ{zGiJGPK=twX#o?N7)yym^3Kt_s5<&v#@XlKl@qq7(+>)cv;>yzhsN_oN<7vb=7 z1uo_+V;%btPs*SzHMIQ;mfw?zIm(#Ru)Ro@<4s&9l%JO#;oe*%$()s| zJ$#?_R3^$F8x-ltm3{vEo?xYq%1BJk*_v;foODmjb!AudtJtf(UmBul*8$BgZUIZ4 zY7!1zg?Jh_Y)rZc+CPiM9;;tfux3#oLkmQhNZ}FY41}$P@U%_6c}Gkq<3Pk)v&`)A zW0r;T58Yf2Ki%VaIi;KiIXO%9{7pGIL$Q<4INtyA^Wpz6;OW6RNHEDaqr8O67C>vh}eCZe$OHABYGDiwKAa8$5U@^-xUep(LNMu#~Xy8%z!G4~YLkz}?f% Z*&*nEE` for +details on ``Closing`` marker. + +.. note:: + + Wiring does not not convert asynchronous injections to synchronous. + + It handles asynchronous injections only for ``async def`` functions. Asynchronous injections into + synchronous ``def`` function still work, but you need to take care of awaitables by your own. + +See also: + +- Provider :ref:`async-injections` +- Resource provider :ref:`resource-async-initializers` +- :ref:`fastapi-redis-example` Integration with other frameworks --------------------------------- @@ -211,5 +295,6 @@ Take a look at other application examples: - :ref:`aiohttp-example` - :ref:`sanic-example` - :ref:`fastapi-example` +- :ref:`fastapi-redis-example` .. disqus:: diff --git a/examples/miniapps/fastapi-redis/Dockerfile b/examples/miniapps/fastapi-redis/Dockerfile new file mode 100644 index 00000000..4adbf329 --- /dev/null +++ b/examples/miniapps/fastapi-redis/Dockerfile @@ -0,0 +1,10 @@ +FROM python:3.8-buster + +ENV PYTHONUNBUFFERED=1 + +WORKDIR /code +COPY . /code/ + +RUN pip install -r requirements.txt + +CMD ["uvicorn", "fastapiredis.application:app", "--host", "0.0.0.0"] diff --git a/examples/miniapps/fastapi-redis/README.rst b/examples/miniapps/fastapi-redis/README.rst new file mode 100644 index 00000000..4871fd2f --- /dev/null +++ b/examples/miniapps/fastapi-redis/README.rst @@ -0,0 +1,89 @@ +FastAPI + Redis + Dependency Injector Example +============================================= + +This is a `FastAPI `_ ++ `Redis `_ ++ `Dependency Injector `_ example application. + +Run +--- + +Build the Docker image: + +.. code-block:: bash + + docker-compose build + +Run the docker-compose environment: + +.. code-block:: bash + + docker-compose up + +The output should be something like: + +.. code-block:: + + redis_1 | 1:C 04 Jan 2021 02:42:14.115 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo + redis_1 | 1:C 04 Jan 2021 02:42:14.115 # Redis version=6.0.9, bits=64, commit=00000000, modified=0, pid=1, just started + redis_1 | 1:C 04 Jan 2021 02:42:14.115 # Configuration loaded + redis_1 | 1:M 04 Jan 2021 02:42:14.116 * Running mode=standalone, port=6379. + redis_1 | 1:M 04 Jan 2021 02:42:14.116 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128. + redis_1 | 1:M 04 Jan 2021 02:42:14.116 # Server initialized + redis_1 | 1:M 04 Jan 2021 02:42:14.117 * Loading RDB produced by version 6.0.9 + redis_1 | 1:M 04 Jan 2021 02:42:14.117 * RDB age 1 seconds + redis_1 | 1:M 04 Jan 2021 02:42:14.117 * RDB memory usage when created 0.77 Mb + redis_1 | 1:M 04 Jan 2021 02:42:14.117 * DB loaded from disk: 0.000 seconds + redis_1 | 1:M 04 Jan 2021 02:42:14.117 * Ready to accept connections + redis_1 | 1:signal-handler (1609728137) Received SIGTERM scheduling shutdown... + redis_1 | 1:M 04 Jan 2021 02:42:17.984 # User requested shutdown... + redis_1 | 1:M 04 Jan 2021 02:42:17.984 # Redis is now ready to exit, bye bye... + redis_1 | 1:C 04 Jan 2021 02:42:22.035 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo + redis_1 | 1:C 04 Jan 2021 02:42:22.035 # Redis version=6.0.9, bits=64, commit=00000000, modified=0, pid=1, just started + redis_1 | 1:C 04 Jan 2021 02:42:22.035 # Configuration loaded + redis_1 | 1:M 04 Jan 2021 02:42:22.037 * Running mode=standalone, port=6379. + redis_1 | 1:M 04 Jan 2021 02:42:22.037 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128. + redis_1 | 1:M 04 Jan 2021 02:42:22.037 # Server initialized + redis_1 | 1:M 04 Jan 2021 02:42:22.037 * Loading RDB produced by version 6.0.9 + redis_1 | 1:M 04 Jan 2021 02:42:22.037 * RDB age 9 seconds + redis_1 | 1:M 04 Jan 2021 02:42:22.037 * RDB memory usage when created 0.77 Mb + redis_1 | 1:M 04 Jan 2021 02:42:22.037 * DB loaded from disk: 0.000 seconds + redis_1 | 1:M 04 Jan 2021 02:42:22.037 * Ready to accept connections + example_1 | INFO: Started server process [1] + example_1 | INFO: Waiting for application startup. + example_1 | INFO: Application startup complete. + example_1 | INFO: Uvicorn running on http://0.0.0.0:8000 (Press CTRL+C to quit) + +Test +---- + +This application comes with the unit tests. + +To run the tests do: + +.. code-block:: bash + + docker-compose run --rm example py.test fastapiredis/tests.py --cov=fastapiredis + +The output should be something like: + +.. code-block:: + + platform linux -- Python 3.8.6, pytest-6.2.1, py-1.10.0, pluggy-0.13.1 + rootdir: /code + plugins: cov-2.10.1, asyncio-0.14.0 + collected 1 item + + fastapiredis/tests.py . [100%] + + ----------- coverage: platform linux, python 3.8.6-final-0 ----------- + Name Stmts Miss Cover + ------------------------------------------------- + fastapiredis/__init__.py 0 0 100% + fastapiredis/application.py 15 0 100% + fastapiredis/containers.py 6 0 100% + fastapiredis/redis.py 7 4 43% + fastapiredis/services.py 7 3 57% + fastapiredis/tests.py 18 0 100% + ------------------------------------------------- + TOTAL 53 7 87% diff --git a/examples/miniapps/fastapi-redis/docker-compose.yml b/examples/miniapps/fastapi-redis/docker-compose.yml new file mode 100644 index 00000000..0bc9390a --- /dev/null +++ b/examples/miniapps/fastapi-redis/docker-compose.yml @@ -0,0 +1,21 @@ +version: "3.7" + +services: + + example: + build: . + environment: + REDIS_HOST: "redis" + REDIS_PASSWORD: "password" + ports: + - "8000:8000" + volumes: + - "./:/code" + depends_on: + - "redis" + + redis: + image: redis + command: ["redis-server", "--requirepass", "password"] + ports: + - "6379:6379" diff --git a/examples/miniapps/fastapi-redis/fastapiredis/__init__.py b/examples/miniapps/fastapi-redis/fastapiredis/__init__.py new file mode 100644 index 00000000..1c744ca5 --- /dev/null +++ b/examples/miniapps/fastapi-redis/fastapiredis/__init__.py @@ -0,0 +1 @@ +"""Top-level package.""" diff --git a/examples/miniapps/fastapi-redis/fastapiredis/application.py b/examples/miniapps/fastapi-redis/fastapiredis/application.py new file mode 100644 index 00000000..706b472f --- /dev/null +++ b/examples/miniapps/fastapi-redis/fastapiredis/application.py @@ -0,0 +1,25 @@ +"""Application module.""" + +import sys + +from fastapi import FastAPI, Depends +from dependency_injector.wiring import inject, Provide + +from .containers import Container +from .services import Service + + +app = FastAPI() + + +@app.api_route('/') +@inject +async def index(service: Service = Depends(Provide[Container.service])): + value = await service.process() + return {'result': value} + + +container = Container() +container.config.redis_host.from_env('REDIS_HOST', 'localhost') +container.config.redis_password.from_env('REDIS_PASSWORD', 'password') +container.wire(modules=[sys.modules[__name__]]) diff --git a/examples/miniapps/fastapi-redis/fastapiredis/containers.py b/examples/miniapps/fastapi-redis/fastapiredis/containers.py new file mode 100644 index 00000000..14409bbf --- /dev/null +++ b/examples/miniapps/fastapi-redis/fastapiredis/containers.py @@ -0,0 +1,21 @@ +"""Containers module.""" + +from dependency_injector import containers, providers + +from . import redis, services + + +class Container(containers.DeclarativeContainer): + + config = providers.Configuration() + + redis_pool = providers.Resource( + redis.init_redis_pool, + host=config.redis_host, + password=config.redis_password, + ) + + service = providers.Factory( + services.Service, + redis=redis_pool, + ) diff --git a/examples/miniapps/fastapi-redis/fastapiredis/redis.py b/examples/miniapps/fastapi-redis/fastapiredis/redis.py new file mode 100644 index 00000000..60c672e3 --- /dev/null +++ b/examples/miniapps/fastapi-redis/fastapiredis/redis.py @@ -0,0 +1,12 @@ +"""Redis client module.""" + +from typing import AsyncIterator + +from aioredis import create_redis_pool, Redis + + +async def init_redis_pool(host: str, password: str) -> AsyncIterator[Redis]: + pool = await create_redis_pool(f'redis://{host}', password=password) + yield pool + pool.close() + await pool.wait_closed() diff --git a/examples/miniapps/fastapi-redis/fastapiredis/services.py b/examples/miniapps/fastapi-redis/fastapiredis/services.py new file mode 100644 index 00000000..7d426433 --- /dev/null +++ b/examples/miniapps/fastapi-redis/fastapiredis/services.py @@ -0,0 +1,12 @@ +"""Services module.""" + +from aioredis import Redis + + +class Service: + def __init__(self, redis: Redis) -> None: + self._redis = redis + + async def process(self) -> str: + await self._redis.set('my-key', 'value') + return await self._redis.get('my-key', encoding='utf-8') diff --git a/examples/miniapps/fastapi-redis/fastapiredis/tests.py b/examples/miniapps/fastapi-redis/fastapiredis/tests.py new file mode 100644 index 00000000..6ac376e5 --- /dev/null +++ b/examples/miniapps/fastapi-redis/fastapiredis/tests.py @@ -0,0 +1,28 @@ +"""Tests module.""" + +from unittest import mock + +import pytest +from httpx import AsyncClient + +from .application import app, container +from .services import Service + + +@pytest.fixture +def client(event_loop): + client = AsyncClient(app=app, base_url='http://test') + yield client + event_loop.run_until_complete(client.aclose()) + + +@pytest.mark.asyncio +async def test_index(client): + service_mock = mock.AsyncMock(spec=Service) + service_mock.process.return_value = 'Foo' + + with container.service.override(service_mock): + response = await client.get('/') + + assert response.status_code == 200 + assert response.json() == {'result': 'Foo'} diff --git a/examples/miniapps/fastapi-redis/requirements.txt b/examples/miniapps/fastapi-redis/requirements.txt new file mode 100644 index 00000000..c217324a --- /dev/null +++ b/examples/miniapps/fastapi-redis/requirements.txt @@ -0,0 +1,10 @@ +dependency-injector +fastapi +uvicorn +aioredis + +# For testing: +pytest +pytest-asyncio +pytest-cov +httpx diff --git a/examples/providers/async.py b/examples/providers/async.py new file mode 100644 index 00000000..297b3b2f --- /dev/null +++ b/examples/providers/async.py @@ -0,0 +1,37 @@ +"""Asynchronous injections example.""" + +import asyncio + +from dependency_injector import containers, providers + + +async def init_async_resource(): + await asyncio.sleep(0.1) + yield 'Initialized' + + +class Service: + def __init__(self, resource): + self.resource = resource + + +class Container(containers.DeclarativeContainer): + + resource = providers.Resource(init_async_resource) + + service = providers.Factory( + Service, + resource=resource, + ) + + +async def main(container: Container): + resource = await container.resource() + service = await container.service() + ... + + +if __name__ == '__main__': + container = Container() + + asyncio.run(main(container)) diff --git a/examples/providers/async_overriding.py b/examples/providers/async_overriding.py new file mode 100644 index 00000000..fc3ce320 --- /dev/null +++ b/examples/providers/async_overriding.py @@ -0,0 +1,32 @@ +"""Provider overriding in async mode example.""" + +import asyncio + +from dependency_injector import containers, providers + + +async def init_async_resource(): + return ... + + +def init_resource_mock(): + return ... + + +class Container(containers.DeclarativeContainer): + + resource = providers.Resource(init_async_resource) + + +async def main(container: Container): + resource1 = await container.resource() + + container.resource.override(providers.Callable(init_resource_mock)) + resource2 = await container.resource() + ... + + +if __name__ == '__main__': + container = Container() + + asyncio.run(main(container)) diff --git a/requirements-dev.txt b/requirements-dev.txt index 404c5095..096d0570 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -7,5 +7,8 @@ pydocstyle sphinx_autobuild pip mypy +pyyaml +httpx +fastapi -r requirements-ext.txt diff --git a/setup.cfg b/setup.cfg index da9fdf7b..603d689c 100644 --- a/setup.cfg +++ b/setup.cfg @@ -4,6 +4,8 @@ max_complexity = 10 exclude = types.py per-file-ignores = examples/demo/*: F841 + examples/providers/async.py: F841 + examples/providers/async_overriding.py: F841 examples/wiring/*: F841 [pydocstyle] diff --git a/src/dependency_injector/containers.c b/src/dependency_injector/containers.c index 4e04d48d..1cc7768a 100644 --- a/src/dependency_injector/containers.c +++ b/src/dependency_injector/containers.c @@ -815,6 +815,7 @@ static const char *__pyx_filename; static const char *__pyx_f[] = { "src/dependency_injector/containers.pyx", "src/dependency_injector/providers.pxd", + "stringsource", }; /*--- Type declarations ---*/ @@ -868,9 +869,10 @@ struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_2_genexpr struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_3_genexpr; struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_4_override; struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_5_copy; +struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py; struct __pyx_opt_args_19dependency_injector_9providers_deepcopy; -/* "providers.pxd":293 +/* "providers.pxd":299 * * * cpdef object deepcopy(object instance, dict memo=*) # <<<<<<<<<<<<<< @@ -882,7 +884,7 @@ struct __pyx_opt_args_19dependency_injector_9providers_deepcopy { PyObject *memo; }; -/* "providers.pxd":7 +/* "providers.pxd":14 * * # Base providers * cdef class Provider(object): # <<<<<<<<<<<<<< @@ -894,10 +896,11 @@ struct __pyx_obj_19dependency_injector_9providers_Provider { struct __pyx_vtabstruct_19dependency_injector_9providers_Provider *__pyx_vtab; PyObject *__pyx___overridden; struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx___last_overriding; + int __pyx___async_mode; }; -/* "providers.pxd":15 +/* "providers.pxd":23 * * * cdef class Object(Provider): # <<<<<<<<<<<<<< @@ -910,7 +913,7 @@ struct __pyx_obj_19dependency_injector_9providers_Object { }; -/* "providers.pxd":21 +/* "providers.pxd":29 * * * cdef class Delegate(Provider): # <<<<<<<<<<<<<< @@ -923,7 +926,7 @@ struct __pyx_obj_19dependency_injector_9providers_Delegate { }; -/* "providers.pxd":27 +/* "providers.pxd":35 * * * cdef class Dependency(Provider): # <<<<<<<<<<<<<< @@ -936,7 +939,7 @@ struct __pyx_obj_19dependency_injector_9providers_Dependency { }; -/* "providers.pxd":31 +/* "providers.pxd":39 * * * cdef class ExternalDependency(Dependency): # <<<<<<<<<<<<<< @@ -948,7 +951,7 @@ struct __pyx_obj_19dependency_injector_9providers_ExternalDependency { }; -/* "providers.pxd":35 +/* "providers.pxd":43 * * * cdef class DependenciesContainer(Object): # <<<<<<<<<<<<<< @@ -961,7 +964,7 @@ struct __pyx_obj_19dependency_injector_9providers_DependenciesContainer { }; -/* "providers.pxd":41 +/* "providers.pxd":49 * * * cdef class OverridingContext(object): # <<<<<<<<<<<<<< @@ -975,7 +978,7 @@ struct __pyx_obj_19dependency_injector_9providers_OverridingContext { }; -/* "providers.pxd":47 +/* "providers.pxd":55 * * # Callable providers * cdef class Callable(Provider): # <<<<<<<<<<<<<< @@ -992,7 +995,7 @@ struct __pyx_obj_19dependency_injector_9providers_Callable { }; -/* "providers.pxd":59 +/* "providers.pxd":67 * * * cdef class DelegatedCallable(Callable): # <<<<<<<<<<<<<< @@ -1004,7 +1007,7 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedCallable { }; -/* "providers.pxd":63 +/* "providers.pxd":71 * * * cdef class AbstractCallable(Callable): # <<<<<<<<<<<<<< @@ -1016,7 +1019,7 @@ struct __pyx_obj_19dependency_injector_9providers_AbstractCallable { }; -/* "providers.pxd":67 +/* "providers.pxd":75 * * * cdef class CallableDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1028,7 +1031,7 @@ struct __pyx_obj_19dependency_injector_9providers_CallableDelegate { }; -/* "providers.pxd":72 +/* "providers.pxd":80 * * # Coroutine providers * cdef class Coroutine(Callable): # <<<<<<<<<<<<<< @@ -1040,7 +1043,7 @@ struct __pyx_obj_19dependency_injector_9providers_Coroutine { }; -/* "providers.pxd":76 +/* "providers.pxd":84 * * * cdef class DelegatedCoroutine(Coroutine): # <<<<<<<<<<<<<< @@ -1052,7 +1055,7 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedCoroutine { }; -/* "providers.pxd":80 +/* "providers.pxd":88 * * * cdef class AbstractCoroutine(Coroutine): # <<<<<<<<<<<<<< @@ -1064,7 +1067,7 @@ struct __pyx_obj_19dependency_injector_9providers_AbstractCoroutine { }; -/* "providers.pxd":84 +/* "providers.pxd":92 * * * cdef class CoroutineDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1076,7 +1079,7 @@ struct __pyx_obj_19dependency_injector_9providers_CoroutineDelegate { }; -/* "providers.pxd":89 +/* "providers.pxd":97 * * # Configuration providers * cdef class ConfigurationOption(Provider): # <<<<<<<<<<<<<< @@ -1092,7 +1095,7 @@ struct __pyx_obj_19dependency_injector_9providers_ConfigurationOption { }; -/* "providers.pxd":96 +/* "providers.pxd":104 * * * cdef class TypedConfigurationOption(Callable): # <<<<<<<<<<<<<< @@ -1104,7 +1107,7 @@ struct __pyx_obj_19dependency_injector_9providers_TypedConfigurationOption { }; -/* "providers.pxd":100 +/* "providers.pxd":108 * * * cdef class Configuration(Object): # <<<<<<<<<<<<<< @@ -1119,7 +1122,7 @@ struct __pyx_obj_19dependency_injector_9providers_Configuration { }; -/* "providers.pxd":107 +/* "providers.pxd":115 * * # Factory providers * cdef class Factory(Provider): # <<<<<<<<<<<<<< @@ -1134,7 +1137,7 @@ struct __pyx_obj_19dependency_injector_9providers_Factory { }; -/* "providers.pxd":116 +/* "providers.pxd":124 * * * cdef class DelegatedFactory(Factory): # <<<<<<<<<<<<<< @@ -1146,7 +1149,7 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedFactory { }; -/* "providers.pxd":120 +/* "providers.pxd":128 * * * cdef class AbstractFactory(Factory): # <<<<<<<<<<<<<< @@ -1158,7 +1161,7 @@ struct __pyx_obj_19dependency_injector_9providers_AbstractFactory { }; -/* "providers.pxd":124 +/* "providers.pxd":132 * * * cdef class FactoryDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1170,7 +1173,7 @@ struct __pyx_obj_19dependency_injector_9providers_FactoryDelegate { }; -/* "providers.pxd":128 +/* "providers.pxd":136 * * * cdef class FactoryAggregate(Provider): # <<<<<<<<<<<<<< @@ -1183,33 +1186,33 @@ struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate { }; -/* "providers.pxd":135 +/* "providers.pxd":143 * * # Singleton providers * cdef class BaseSingleton(Provider): # <<<<<<<<<<<<<< * cdef Factory __instantiator - * + * cdef object __storage */ struct __pyx_obj_19dependency_injector_9providers_BaseSingleton { struct __pyx_obj_19dependency_injector_9providers_Provider __pyx_base; struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx___instantiator; -}; - - -/* "providers.pxd":139 - * - * - * cdef class Singleton(BaseSingleton): # <<<<<<<<<<<<<< - * cdef object __storage - * - */ -struct __pyx_obj_19dependency_injector_9providers_Singleton { - struct __pyx_obj_19dependency_injector_9providers_BaseSingleton __pyx_base; PyObject *__pyx___storage; }; -/* "providers.pxd":145 +/* "providers.pxd":148 + * + * + * cdef class Singleton(BaseSingleton): # <<<<<<<<<<<<<< + * + * cpdef object _provide(self, tuple args, dict kwargs) + */ +struct __pyx_obj_19dependency_injector_9providers_Singleton { + struct __pyx_obj_19dependency_injector_9providers_BaseSingleton __pyx_base; +}; + + +/* "providers.pxd":153 * * * cdef class DelegatedSingleton(Singleton): # <<<<<<<<<<<<<< @@ -1221,21 +1224,20 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedSingleton { }; -/* "providers.pxd":149 +/* "providers.pxd":157 * * * cdef class ThreadSafeSingleton(BaseSingleton): # <<<<<<<<<<<<<< - * cdef object __storage * cdef object __storage_lock + * */ struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton { struct __pyx_obj_19dependency_injector_9providers_BaseSingleton __pyx_base; - PyObject *__pyx___storage; PyObject *__pyx___storage_lock; }; -/* "providers.pxd":156 +/* "providers.pxd":163 * * * cdef class DelegatedThreadSafeSingleton(ThreadSafeSingleton): # <<<<<<<<<<<<<< @@ -1247,20 +1249,19 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadSafeSingleton { }; -/* "providers.pxd":160 +/* "providers.pxd":167 * * * cdef class ThreadLocalSingleton(BaseSingleton): # <<<<<<<<<<<<<< - * cdef object __storage * + * cpdef object _provide(self, tuple args, dict kwargs) */ struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton { struct __pyx_obj_19dependency_injector_9providers_BaseSingleton __pyx_base; - PyObject *__pyx___storage; }; -/* "providers.pxd":166 +/* "providers.pxd":172 * * * cdef class DelegatedThreadLocalSingleton(ThreadLocalSingleton): # <<<<<<<<<<<<<< @@ -1272,7 +1273,7 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadLocalSingleton }; -/* "providers.pxd":170 +/* "providers.pxd":176 * * * cdef class AbstractSingleton(BaseSingleton): # <<<<<<<<<<<<<< @@ -1284,7 +1285,7 @@ struct __pyx_obj_19dependency_injector_9providers_AbstractSingleton { }; -/* "providers.pxd":174 +/* "providers.pxd":180 * * * cdef class SingletonDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1296,7 +1297,7 @@ struct __pyx_obj_19dependency_injector_9providers_SingletonDelegate { }; -/* "providers.pxd":180 +/* "providers.pxd":186 * # Miscellaneous providers * * cdef class List(Provider): # <<<<<<<<<<<<<< @@ -1310,7 +1311,7 @@ struct __pyx_obj_19dependency_injector_9providers_List { }; -/* "providers.pxd":187 +/* "providers.pxd":193 * * * cdef class Dict(Provider): # <<<<<<<<<<<<<< @@ -1324,7 +1325,7 @@ struct __pyx_obj_19dependency_injector_9providers_Dict { }; -/* "providers.pxd":194 +/* "providers.pxd":200 * * * cdef class Resource(Provider): # <<<<<<<<<<<<<< @@ -1344,7 +1345,7 @@ struct __pyx_obj_19dependency_injector_9providers_Resource { }; -/* "providers.pxd":209 +/* "providers.pxd":215 * * * cdef class Container(Provider): # <<<<<<<<<<<<<< @@ -1359,7 +1360,7 @@ struct __pyx_obj_19dependency_injector_9providers_Container { }; -/* "providers.pxd":217 +/* "providers.pxd":223 * * * cdef class Selector(Provider): # <<<<<<<<<<<<<< @@ -1373,7 +1374,7 @@ struct __pyx_obj_19dependency_injector_9providers_Selector { }; -/* "providers.pxd":225 +/* "providers.pxd":231 * # Provided instance * * cdef class ProvidedInstance(Provider): # <<<<<<<<<<<<<< @@ -1386,7 +1387,7 @@ struct __pyx_obj_19dependency_injector_9providers_ProvidedInstance { }; -/* "providers.pxd":231 +/* "providers.pxd":237 * * * cdef class AttributeGetter(Provider): # <<<<<<<<<<<<<< @@ -1400,7 +1401,7 @@ struct __pyx_obj_19dependency_injector_9providers_AttributeGetter { }; -/* "providers.pxd":238 +/* "providers.pxd":244 * * * cdef class ItemGetter(Provider): # <<<<<<<<<<<<<< @@ -1414,7 +1415,7 @@ struct __pyx_obj_19dependency_injector_9providers_ItemGetter { }; -/* "providers.pxd":245 +/* "providers.pxd":251 * * * cdef class MethodCaller(Provider): # <<<<<<<<<<<<<< @@ -1431,7 +1432,7 @@ struct __pyx_obj_19dependency_injector_9providers_MethodCaller { }; -/* "providers.pxd":256 +/* "providers.pxd":262 * * # Injections * cdef class Injection(object): # <<<<<<<<<<<<<< @@ -1447,7 +1448,7 @@ struct __pyx_obj_19dependency_injector_9providers_Injection { }; -/* "providers.pxd":263 +/* "providers.pxd":269 * * * cdef class PositionalInjection(Injection): # <<<<<<<<<<<<<< @@ -1459,7 +1460,7 @@ struct __pyx_obj_19dependency_injector_9providers_PositionalInjection { }; -/* "providers.pxd":267 +/* "providers.pxd":273 * * * cdef class NamedInjection(Injection): # <<<<<<<<<<<<<< @@ -1472,7 +1473,7 @@ struct __pyx_obj_19dependency_injector_9providers_NamedInjection { }; -/* "dependency_injector/containers.pyx":235 +/* "dependency_injector/containers.pyx":257 * """Declarative inversion of control container meta class.""" * * def __new__(type mcs, str class_name, tuple bases, dict attributes): # <<<<<<<<<<<<<< @@ -1486,7 +1487,7 @@ struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct____new__ }; -/* "dependency_injector/containers.pyx":241 +/* "dependency_injector/containers.pyx":263 * cdef type cls * * containers = tuple((name, container) # <<<<<<<<<<<<<< @@ -1504,7 +1505,7 @@ struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_1_genexpr }; -/* "dependency_injector/containers.pyx":247 +/* "dependency_injector/containers.pyx":269 * attributes['containers'] = dict(containers) * * cls_providers = tuple((name, provider) # <<<<<<<<<<<<<< @@ -1522,7 +1523,7 @@ struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_2_genexpr }; -/* "dependency_injector/containers.pyx":251 +/* "dependency_injector/containers.pyx":273 * if isinstance(provider, Provider)) * * inherited_providers = tuple((name, provider) # <<<<<<<<<<<<<< @@ -1543,7 +1544,7 @@ struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_3_genexpr }; -/* "dependency_injector/containers.pyx":434 +/* "dependency_injector/containers.pyx":456 * * * def override(object container): # <<<<<<<<<<<<<< @@ -1556,7 +1557,7 @@ struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_4_overrid }; -/* "dependency_injector/containers.pyx":451 +/* "dependency_injector/containers.pyx":473 * * * def copy(object container): # <<<<<<<<<<<<<< @@ -1569,8 +1570,21 @@ struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_5_copy { }; +/* "cfunc.to_py":64 + * + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): # <<<<<<<<<<<<<< + * def wrap(object future): + * """wrap(future) -> 'void'""" + */ +struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py { + PyObject_HEAD + void (*__pyx_v_f)(PyObject *); +}; -/* "providers.pxd":7 + + +/* "providers.pxd":14 * * # Base providers * cdef class Provider(object): # <<<<<<<<<<<<<< @@ -1585,7 +1599,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Provider { static struct __pyx_vtabstruct_19dependency_injector_9providers_Provider *__pyx_vtabptr_19dependency_injector_9providers_Provider; -/* "providers.pxd":15 +/* "providers.pxd":23 * * * cdef class Object(Provider): # <<<<<<<<<<<<<< @@ -1599,7 +1613,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Object { static struct __pyx_vtabstruct_19dependency_injector_9providers_Object *__pyx_vtabptr_19dependency_injector_9providers_Object; -/* "providers.pxd":21 +/* "providers.pxd":29 * * * cdef class Delegate(Provider): # <<<<<<<<<<<<<< @@ -1613,7 +1627,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Delegate { static struct __pyx_vtabstruct_19dependency_injector_9providers_Delegate *__pyx_vtabptr_19dependency_injector_9providers_Delegate; -/* "providers.pxd":27 +/* "providers.pxd":35 * * * cdef class Dependency(Provider): # <<<<<<<<<<<<<< @@ -1627,7 +1641,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Dependency { static struct __pyx_vtabstruct_19dependency_injector_9providers_Dependency *__pyx_vtabptr_19dependency_injector_9providers_Dependency; -/* "providers.pxd":31 +/* "providers.pxd":39 * * * cdef class ExternalDependency(Dependency): # <<<<<<<<<<<<<< @@ -1641,7 +1655,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ExternalDependency { static struct __pyx_vtabstruct_19dependency_injector_9providers_ExternalDependency *__pyx_vtabptr_19dependency_injector_9providers_ExternalDependency; -/* "providers.pxd":35 +/* "providers.pxd":43 * * * cdef class DependenciesContainer(Object): # <<<<<<<<<<<<<< @@ -1656,7 +1670,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DependenciesContainer { static struct __pyx_vtabstruct_19dependency_injector_9providers_DependenciesContainer *__pyx_vtabptr_19dependency_injector_9providers_DependenciesContainer; -/* "providers.pxd":47 +/* "providers.pxd":55 * * # Callable providers * cdef class Callable(Provider): # <<<<<<<<<<<<<< @@ -1670,7 +1684,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Callable { static struct __pyx_vtabstruct_19dependency_injector_9providers_Callable *__pyx_vtabptr_19dependency_injector_9providers_Callable; -/* "providers.pxd":59 +/* "providers.pxd":67 * * * cdef class DelegatedCallable(Callable): # <<<<<<<<<<<<<< @@ -1684,7 +1698,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCallable { static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCallable *__pyx_vtabptr_19dependency_injector_9providers_DelegatedCallable; -/* "providers.pxd":63 +/* "providers.pxd":71 * * * cdef class AbstractCallable(Callable): # <<<<<<<<<<<<<< @@ -1698,7 +1712,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCallable { static struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCallable *__pyx_vtabptr_19dependency_injector_9providers_AbstractCallable; -/* "providers.pxd":67 +/* "providers.pxd":75 * * * cdef class CallableDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1712,7 +1726,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_CallableDelegate { static struct __pyx_vtabstruct_19dependency_injector_9providers_CallableDelegate *__pyx_vtabptr_19dependency_injector_9providers_CallableDelegate; -/* "providers.pxd":72 +/* "providers.pxd":80 * * # Coroutine providers * cdef class Coroutine(Callable): # <<<<<<<<<<<<<< @@ -1726,7 +1740,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Coroutine { static struct __pyx_vtabstruct_19dependency_injector_9providers_Coroutine *__pyx_vtabptr_19dependency_injector_9providers_Coroutine; -/* "providers.pxd":76 +/* "providers.pxd":84 * * * cdef class DelegatedCoroutine(Coroutine): # <<<<<<<<<<<<<< @@ -1740,7 +1754,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCoroutine { static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCoroutine *__pyx_vtabptr_19dependency_injector_9providers_DelegatedCoroutine; -/* "providers.pxd":80 +/* "providers.pxd":88 * * * cdef class AbstractCoroutine(Coroutine): # <<<<<<<<<<<<<< @@ -1754,7 +1768,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCoroutine { static struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCoroutine *__pyx_vtabptr_19dependency_injector_9providers_AbstractCoroutine; -/* "providers.pxd":84 +/* "providers.pxd":92 * * * cdef class CoroutineDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1768,7 +1782,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_CoroutineDelegate { static struct __pyx_vtabstruct_19dependency_injector_9providers_CoroutineDelegate *__pyx_vtabptr_19dependency_injector_9providers_CoroutineDelegate; -/* "providers.pxd":89 +/* "providers.pxd":97 * * # Configuration providers * cdef class ConfigurationOption(Provider): # <<<<<<<<<<<<<< @@ -1782,7 +1796,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ConfigurationOption { static struct __pyx_vtabstruct_19dependency_injector_9providers_ConfigurationOption *__pyx_vtabptr_19dependency_injector_9providers_ConfigurationOption; -/* "providers.pxd":96 +/* "providers.pxd":104 * * * cdef class TypedConfigurationOption(Callable): # <<<<<<<<<<<<<< @@ -1796,7 +1810,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_TypedConfigurationOptio static struct __pyx_vtabstruct_19dependency_injector_9providers_TypedConfigurationOption *__pyx_vtabptr_19dependency_injector_9providers_TypedConfigurationOption; -/* "providers.pxd":100 +/* "providers.pxd":108 * * * cdef class Configuration(Object): # <<<<<<<<<<<<<< @@ -1810,7 +1824,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Configuration { static struct __pyx_vtabstruct_19dependency_injector_9providers_Configuration *__pyx_vtabptr_19dependency_injector_9providers_Configuration; -/* "providers.pxd":107 +/* "providers.pxd":115 * * # Factory providers * cdef class Factory(Provider): # <<<<<<<<<<<<<< @@ -1824,7 +1838,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Factory { static struct __pyx_vtabstruct_19dependency_injector_9providers_Factory *__pyx_vtabptr_19dependency_injector_9providers_Factory; -/* "providers.pxd":116 +/* "providers.pxd":124 * * * cdef class DelegatedFactory(Factory): # <<<<<<<<<<<<<< @@ -1838,7 +1852,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedFactory { static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedFactory *__pyx_vtabptr_19dependency_injector_9providers_DelegatedFactory; -/* "providers.pxd":120 +/* "providers.pxd":128 * * * cdef class AbstractFactory(Factory): # <<<<<<<<<<<<<< @@ -1852,7 +1866,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractFactory { static struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractFactory *__pyx_vtabptr_19dependency_injector_9providers_AbstractFactory; -/* "providers.pxd":124 +/* "providers.pxd":132 * * * cdef class FactoryDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1866,7 +1880,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryDelegate { static struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryDelegate *__pyx_vtabptr_19dependency_injector_9providers_FactoryDelegate; -/* "providers.pxd":128 +/* "providers.pxd":136 * * * cdef class FactoryAggregate(Provider): # <<<<<<<<<<<<<< @@ -1881,12 +1895,12 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate { static struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate *__pyx_vtabptr_19dependency_injector_9providers_FactoryAggregate; -/* "providers.pxd":135 +/* "providers.pxd":143 * * # Singleton providers * cdef class BaseSingleton(Provider): # <<<<<<<<<<<<<< * cdef Factory __instantiator - * + * cdef object __storage */ struct __pyx_vtabstruct_19dependency_injector_9providers_BaseSingleton { @@ -1895,12 +1909,12 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_BaseSingleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_BaseSingleton *__pyx_vtabptr_19dependency_injector_9providers_BaseSingleton; -/* "providers.pxd":139 +/* "providers.pxd":148 * * * cdef class Singleton(BaseSingleton): # <<<<<<<<<<<<<< - * cdef object __storage * + * cpdef object _provide(self, tuple args, dict kwargs) */ struct __pyx_vtabstruct_19dependency_injector_9providers_Singleton { @@ -1909,7 +1923,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Singleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_Singleton *__pyx_vtabptr_19dependency_injector_9providers_Singleton; -/* "providers.pxd":145 +/* "providers.pxd":153 * * * cdef class DelegatedSingleton(Singleton): # <<<<<<<<<<<<<< @@ -1923,12 +1937,12 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedSingleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedSingleton *__pyx_vtabptr_19dependency_injector_9providers_DelegatedSingleton; -/* "providers.pxd":149 +/* "providers.pxd":157 * * * cdef class ThreadSafeSingleton(BaseSingleton): # <<<<<<<<<<<<<< - * cdef object __storage * cdef object __storage_lock + * */ struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadSafeSingleton { @@ -1937,7 +1951,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadSafeSingleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadSafeSingleton *__pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton; -/* "providers.pxd":156 +/* "providers.pxd":163 * * * cdef class DelegatedThreadSafeSingleton(ThreadSafeSingleton): # <<<<<<<<<<<<<< @@ -1951,12 +1965,12 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadSafeSing static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadSafeSingleton *__pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadSafeSingleton; -/* "providers.pxd":160 +/* "providers.pxd":167 * * * cdef class ThreadLocalSingleton(BaseSingleton): # <<<<<<<<<<<<<< - * cdef object __storage * + * cpdef object _provide(self, tuple args, dict kwargs) */ struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadLocalSingleton { @@ -1965,7 +1979,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadLocalSingleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton; -/* "providers.pxd":166 +/* "providers.pxd":172 * * * cdef class DelegatedThreadLocalSingleton(ThreadLocalSingleton): # <<<<<<<<<<<<<< @@ -1979,7 +1993,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadLocalSin static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadLocalSingleton *__pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadLocalSingleton; -/* "providers.pxd":170 +/* "providers.pxd":176 * * * cdef class AbstractSingleton(BaseSingleton): # <<<<<<<<<<<<<< @@ -1993,7 +2007,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractSingleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractSingleton *__pyx_vtabptr_19dependency_injector_9providers_AbstractSingleton; -/* "providers.pxd":174 +/* "providers.pxd":180 * * * cdef class SingletonDelegate(Delegate): # <<<<<<<<<<<<<< @@ -2007,7 +2021,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_SingletonDelegate { static struct __pyx_vtabstruct_19dependency_injector_9providers_SingletonDelegate *__pyx_vtabptr_19dependency_injector_9providers_SingletonDelegate; -/* "providers.pxd":180 +/* "providers.pxd":186 * # Miscellaneous providers * * cdef class List(Provider): # <<<<<<<<<<<<<< @@ -2021,7 +2035,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_List { static struct __pyx_vtabstruct_19dependency_injector_9providers_List *__pyx_vtabptr_19dependency_injector_9providers_List; -/* "providers.pxd":187 +/* "providers.pxd":193 * * * cdef class Dict(Provider): # <<<<<<<<<<<<<< @@ -2035,7 +2049,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Dict { static struct __pyx_vtabstruct_19dependency_injector_9providers_Dict *__pyx_vtabptr_19dependency_injector_9providers_Dict; -/* "providers.pxd":194 +/* "providers.pxd":200 * * * cdef class Resource(Provider): # <<<<<<<<<<<<<< @@ -2049,7 +2063,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Resource { static struct __pyx_vtabstruct_19dependency_injector_9providers_Resource *__pyx_vtabptr_19dependency_injector_9providers_Resource; -/* "providers.pxd":209 +/* "providers.pxd":215 * * * cdef class Container(Provider): # <<<<<<<<<<<<<< @@ -2063,7 +2077,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Container { static struct __pyx_vtabstruct_19dependency_injector_9providers_Container *__pyx_vtabptr_19dependency_injector_9providers_Container; -/* "providers.pxd":217 +/* "providers.pxd":223 * * * cdef class Selector(Provider): # <<<<<<<<<<<<<< @@ -2077,7 +2091,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Selector { static struct __pyx_vtabstruct_19dependency_injector_9providers_Selector *__pyx_vtabptr_19dependency_injector_9providers_Selector; -/* "providers.pxd":225 +/* "providers.pxd":231 * # Provided instance * * cdef class ProvidedInstance(Provider): # <<<<<<<<<<<<<< @@ -2091,7 +2105,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ProvidedInstance { static struct __pyx_vtabstruct_19dependency_injector_9providers_ProvidedInstance *__pyx_vtabptr_19dependency_injector_9providers_ProvidedInstance; -/* "providers.pxd":231 +/* "providers.pxd":237 * * * cdef class AttributeGetter(Provider): # <<<<<<<<<<<<<< @@ -2105,7 +2119,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_AttributeGetter { static struct __pyx_vtabstruct_19dependency_injector_9providers_AttributeGetter *__pyx_vtabptr_19dependency_injector_9providers_AttributeGetter; -/* "providers.pxd":238 +/* "providers.pxd":244 * * * cdef class ItemGetter(Provider): # <<<<<<<<<<<<<< @@ -2119,7 +2133,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ItemGetter { static struct __pyx_vtabstruct_19dependency_injector_9providers_ItemGetter *__pyx_vtabptr_19dependency_injector_9providers_ItemGetter; -/* "providers.pxd":245 +/* "providers.pxd":251 * * * cdef class MethodCaller(Provider): # <<<<<<<<<<<<<< @@ -2428,6 +2442,23 @@ static CYTHON_INLINE PyObject* __Pyx_PyObject_GetSlice( PyObject** py_start, PyObject** py_stop, PyObject** py_slice, int has_cstart, int has_cstop, int wraparound); +/* ListAppend.proto */ +#if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS +static CYTHON_INLINE int __Pyx_PyList_Append(PyObject* list, PyObject* x) { + PyListObject* L = (PyListObject*) list; + Py_ssize_t len = Py_SIZE(list); + if (likely(L->allocated > len) & likely(len > (L->allocated >> 1))) { + Py_INCREF(x); + PyList_SET_ITEM(list, len, x); + __Pyx_SET_SIZE(list, len + 1); + return 0; + } + return PyList_Append(list, x); +} +#else +#define __Pyx_PyList_Append(L,x) PyList_Append(L,x) +#endif + /* None.proto */ static CYTHON_INLINE void __Pyx_RaiseClosureNameError(const char *varname); @@ -2502,6 +2533,14 @@ static void __Pyx_WriteUnraisable(const char *name, int clineno, int lineno, const char *filename, int full_traceback, int nogil); +/* GetException.proto */ +#if CYTHON_FAST_THREAD_STATE +#define __Pyx_GetException(type, value, tb) __Pyx__GetException(__pyx_tstate, type, value, tb) +static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb); +#else +static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb); +#endif + /* py_dict_items.proto */ static CYTHON_INLINE PyObject* __Pyx_PyDict_Items(PyObject* d); @@ -2559,23 +2598,6 @@ static PyObject *__Pyx_PyDict_GetItem(PyObject *d, PyObject* key); #define __Pyx_PyObject_Dict_GetItem(obj, name) PyObject_GetItem(obj, name) #endif -/* ListAppend.proto */ -#if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS -static CYTHON_INLINE int __Pyx_PyList_Append(PyObject* list, PyObject* x) { - PyListObject* L = (PyListObject*) list; - Py_ssize_t len = Py_SIZE(list); - if (likely(L->allocated > len) & likely(len > (L->allocated >> 1))) { - Py_INCREF(x); - PyList_SET_ITEM(list, len, x); - __Pyx_SET_SIZE(list, len + 1); - return 0; - } - return PyList_Append(list, x); -} -#else -#define __Pyx_PyList_Append(L,x) PyList_Append(L,x) -#endif - /* ListExtend.proto */ static CYTHON_INLINE int __Pyx_PyList_Extend(PyObject* L, PyObject* v) { #if CYTHON_COMPILING_IN_CPYTHON @@ -2592,6 +2614,26 @@ static CYTHON_INLINE int __Pyx_PyList_Extend(PyObject* L, PyObject* v) { /* RaiseNoneIterError.proto */ static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void); +/* ListCompAppend.proto */ +#if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS +static CYTHON_INLINE int __Pyx_ListComp_Append(PyObject* list, PyObject* x) { + PyListObject* L = (PyListObject*) list; + Py_ssize_t len = Py_SIZE(list); + if (likely(L->allocated > len)) { + Py_INCREF(x); + PyList_SET_ITEM(list, len, x); + __Pyx_SET_SIZE(list, len + 1); + return 0; + } + return PyList_Append(list, x); +} +#else +#define __Pyx_ListComp_Append(L,x) PyList_Append(L,x) +#endif + +/* HasAttr.proto */ +static CYTHON_INLINE int __Pyx_HasAttr(PyObject *, PyObject *); + /* IncludeStringH.proto */ #include @@ -2619,6 +2661,15 @@ static void* __Pyx_GetVtable(PyObject *dict); /* Import.proto */ static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level); +/* PatchModuleWithCoroutine.proto */ +static PyObject* __Pyx_Coroutine_patch_module(PyObject* module, const char* py_code); + +/* PatchInspect.proto */ +static PyObject* __Pyx_patch_inspect(PyObject* module); + +/* PatchAsyncIO.proto */ +static PyObject* __Pyx_patch_asyncio(PyObject* module); + /* ImportFrom.proto */ static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name); @@ -2771,9 +2822,6 @@ static PyObject *__Pyx_Coroutine_Throw(PyObject *gen, PyObject *args); static int __Pyx_PyGen__FetchStopIterationValue(PyThreadState *tstate, PyObject **pvalue); static CYTHON_INLINE void __Pyx_Coroutine_ResetFrameBackpointer(__Pyx_ExcInfoStruct *exc_state); -/* PatchModuleWithCoroutine.proto */ -static PyObject* __Pyx_Coroutine_patch_module(PyObject* module, const char* py_code); - /* PatchGeneratorABC.proto */ static int __Pyx_patch_abc(void); @@ -2851,6 +2899,8 @@ static PyTypeObject *__pyx_ptype_19dependency_injector_9providers_PositionalInje static PyTypeObject *__pyx_ptype_19dependency_injector_9providers_NamedInjection = 0; static PyObject **__pyx_vp_19dependency_injector_9providers_CLASS_TYPES = 0; #define __pyx_v_19dependency_injector_9providers_CLASS_TYPES (*__pyx_vp_19dependency_injector_9providers_CLASS_TYPES) +static int *__pyx_vp_19dependency_injector_9providers___has_isawaitable = 0; +#define __pyx_v_19dependency_injector_9providers___has_isawaitable (*__pyx_vp_19dependency_injector_9providers___has_isawaitable) static PyObject *(*__pyx_f_19dependency_injector_9providers_deepcopy)(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_19dependency_injector_9providers_deepcopy *__pyx_optional_args); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_name(struct __pyx_obj_19dependency_injector_9providers_NamedInjection *); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_value(struct __pyx_obj_19dependency_injector_9providers_Injection *); /*proto*/ @@ -2858,9 +2908,16 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separate_prefixed_kwargs(PyObject *); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provide_positional_args(PyObject *, PyObject *, int); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provide_keyword_args(PyObject *, PyObject *, int); /*proto*/ -static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___inject_attributes(PyObject *, PyObject *, int); /*proto*/ +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___awaitable_args_kwargs_future(PyObject *, PyObject *); /*proto*/ +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_prepare_args_kwargs_callback(PyObject *); /*proto*/ +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provide_attributes(PyObject *, int); /*proto*/ +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___async_inject_attributes(PyObject *, PyObject *); /*proto*/ +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_inject_attributes_callback(PyObject *); /*proto*/ +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___inject_attributes(PyObject *, PyObject *); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___call(PyObject *, PyObject *, PyObject *, int, PyObject *, PyObject *, int); /*proto*/ +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_call_callback(PyObject *); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callable_call(struct __pyx_obj_19dependency_injector_9providers_Callable *, PyObject *, PyObject *); /*proto*/ +static CYTHON_INLINE int __pyx_f_19dependency_injector_9providers___isawaitable(PyObject *); /*proto*/ /* Module declarations from 'dependency_injector.containers' */ static PyTypeObject *__pyx_ptype_19dependency_injector_10containers___pyx_scope_struct____new__ = 0; @@ -2869,19 +2926,24 @@ static PyTypeObject *__pyx_ptype_19dependency_injector_10containers___pyx_scope_ static PyTypeObject *__pyx_ptype_19dependency_injector_10containers___pyx_scope_struct_3_genexpr = 0; static PyTypeObject *__pyx_ptype_19dependency_injector_10containers___pyx_scope_struct_4_override = 0; static PyTypeObject *__pyx_ptype_19dependency_injector_10containers___pyx_scope_struct_5_copy = 0; +static PyTypeObject *__pyx_ptype___pyx_scope_struct____Pyx_CFunc_void____object___to_py = 0; static int __pyx_f_19dependency_injector_10containers_is_container(PyObject *, int __pyx_skip_dispatch); /*proto*/ static PyObject *__pyx_f_19dependency_injector_10containers__check_provider_type(PyObject *, PyObject *, int __pyx_skip_dispatch); /*proto*/ +static int __pyx_f_19dependency_injector_10containers__isawaitable(PyObject *, int __pyx_skip_dispatch); /*proto*/ +static PyObject *__Pyx_CFunc_void____object___to_py(void (*)(PyObject *)); /*proto*/ #define __Pyx_MODULE_NAME "dependency_injector.containers" extern int __pyx_module_is_main_dependency_injector__containers; int __pyx_module_is_main_dependency_injector__containers = 0; /* Implementation of 'dependency_injector.containers' */ +static PyObject *__pyx_builtin_ImportError; static PyObject *__pyx_builtin_object; static PyObject *__pyx_builtin_NotImplementedError; static PyObject *__pyx_builtin_super; static PyObject *__pyx_builtin_id; static PyObject *__pyx_builtin_AttributeError; static PyObject *__pyx_builtin_range; +static PyObject *__pyx_builtin_zip; static const char __pyx_k__7[] = "__"; static const char __pyx_k_id[] = "id"; static const char __pyx_k_cls[] = "cls"; @@ -2891,6 +2953,7 @@ static const char __pyx_k_mcs[] = "mcs"; static const char __pyx_k_new[] = "__new__"; static const char __pyx_k_six[] = "six"; static const char __pyx_k_sys[] = "sys"; +static const char __pyx_k_zip[] = "zip"; static const char __pyx_k_args[] = "args"; static const char __pyx_k_copy[] = "copy"; static const char __pyx_k_init[] = "__init__"; @@ -2901,6 +2964,7 @@ static const char __pyx_k_self[] = "self"; static const char __pyx_k_send[] = "send"; static const char __pyx_k_test[] = "__test__"; static const char __pyx_k_wire[] = "wire"; +static const char __pyx_k_wrap[] = "wrap"; static const char __pyx_k_Error[] = "Error"; static const char __pyx_k_bases[] = "bases"; static const char __pyx_k_class[] = "__class__"; @@ -2912,21 +2976,28 @@ static const char __pyx_k_range[] = "range"; static const char __pyx_k_super[] = "super"; static const char __pyx_k_throw[] = "throw"; static const char __pyx_k_value[] = "value"; +static const char __pyx_k_Future[] = "Future"; static const char __pyx_k_copied[] = "copied"; static const char __pyx_k_errors[] = "errors"; static const char __pyx_k_extend[] = "extend"; static const char __pyx_k_format[] = "format"; +static const char __pyx_k_future[] = "future"; +static const char __pyx_k_gather[] = "gather"; static const char __pyx_k_import[] = "__import__"; static const char __pyx_k_init_2[] = "init"; static const char __pyx_k_kwargs[] = "kwargs"; static const char __pyx_k_module[] = "__module__"; static const char __pyx_k_name_2[] = "__name__"; static const char __pyx_k_object[] = "object"; +static const char __pyx_k_result[] = "result"; static const char __pyx_k_unwire[] = "unwire"; static const char __pyx_k_values[] = "values"; static const char __pyx_k_wiring[] = "wiring"; +static const char __pyx_k_asyncio[] = "asyncio"; static const char __pyx_k_delattr[] = "__delattr__"; +static const char __pyx_k_futures[] = "futures"; static const char __pyx_k_genexpr[] = "genexpr"; +static const char __pyx_k_inspect[] = "inspect"; static const char __pyx_k_modules[] = "modules"; static const char __pyx_k_prepare[] = "__prepare__"; static const char __pyx_k_setattr[] = "__setattr__"; @@ -2935,6 +3006,7 @@ static const char __pyx_k_override[] = "override"; static const char __pyx_k_packages[] = "packages"; static const char __pyx_k_provider[] = "provider"; static const char __pyx_k_qualname[] = "__qualname__"; +static const char __pyx_k_resource[] = "resource"; static const char __pyx_k_shutdown[] = "shutdown"; static const char __pyx_k_container[] = "container"; static const char __pyx_k_decorator[] = "_decorator"; @@ -2948,10 +3020,17 @@ static const char __pyx_k_itervalues[] = "itervalues"; static const char __pyx_k_overridden[] = "overridden"; static const char __pyx_k_overriding[] = "overriding"; static const char __pyx_k_pyx_vtable[] = "__pyx_vtable__"; +static const char __pyx_k_set_result[] = "set_result"; +static const char __pyx_k_ImportError[] = "ImportError"; +static const char __pyx_k_cfunc_to_py[] = "cfunc.to_py"; +static const char __pyx_k_isawaitable[] = "isawaitable"; static const char __pyx_k_IS_CONTAINER[] = "__IS_CONTAINER__"; +static const char __pyx_k_stringsource[] = "stringsource"; static const char __pyx_k_version_info[] = "version_info"; static const char __pyx_k_add_metaclass[] = "add_metaclass"; +static const char __pyx_k_asyncio_tasks[] = "asyncio.tasks"; static const char __pyx_k_cls_providers[] = "cls_providers"; +static const char __pyx_k_ensure_future[] = "ensure_future"; static const char __pyx_k_instance_type[] = "instance_type"; static const char __pyx_k_provider_name[] = "provider_name"; static const char __pyx_k_provider_type[] = "provider_type"; @@ -2965,7 +3044,9 @@ static const char __pyx_k_DynamicContainer[] = "DynamicContainer"; static const char __pyx_k_copied_container[] = "copied_container"; static const char __pyx_k_wired_to_modules[] = "wired_to_modules"; static const char __pyx_k_Containers_module[] = "Containers module."; +static const char __pyx_k_add_done_callback[] = "add_done_callback"; static const char __pyx_k_wired_to_packages[] = "wired_to_packages"; +static const char __pyx_k_asyncio_coroutines[] = "asyncio.coroutines"; static const char __pyx_k_cline_in_traceback[] = "cline_in_traceback"; static const char __pyx_k_container_provider[] = "container_provider"; static const char __pyx_k_declarative_parent[] = "declarative_parent"; @@ -2993,6 +3074,7 @@ static const char __pyx_k_DynamicContainer___deepcopy[] = "DynamicContainer.__de static const char __pyx_k_Container_0_is_not_overridden[] = "Container {0} is not overridden"; static const char __pyx_k_DeclarativeContainerMetaClass[] = "DeclarativeContainerMetaClass.__new__..genexpr"; static const char __pyx_k_DeclarativeContainer_override[] = "DeclarativeContainer.override"; +static const char __pyx_k_Pyx_CFunc_void____object___to[] = "__Pyx_CFunc_void____object___to_py..wrap"; static const char __pyx_k_0_can_contain_only_1_instances[] = "{0} can contain only {1} instances"; static const char __pyx_k_DynamicContainer_set_providers[] = "DynamicContainer.set_providers"; static const char __pyx_k_dependency_injector_containers[] = "dependency_injector.containers"; @@ -3049,14 +3131,22 @@ static PyObject *__pyx_n_s_DynamicContainer_unwire; static PyObject *__pyx_n_s_DynamicContainer_wire; static PyObject *__pyx_kp_s_Dynamic_inversion_of_control_con; static PyObject *__pyx_n_s_Error; +static PyObject *__pyx_n_s_Future; static PyObject *__pyx_n_s_IS_CONTAINER; +static PyObject *__pyx_n_s_ImportError; static PyObject *__pyx_n_s_NotImplementedError; +static PyObject *__pyx_n_s_Pyx_CFunc_void____object___to; static PyObject *__pyx_kp_s_Wiring_requires_Python_3_6_or_ab; static PyObject *__pyx_n_s__7; +static PyObject *__pyx_n_s_add_done_callback; static PyObject *__pyx_n_s_add_metaclass; static PyObject *__pyx_n_s_args; +static PyObject *__pyx_n_s_asyncio; +static PyObject *__pyx_n_s_asyncio_coroutines; +static PyObject *__pyx_n_s_asyncio_tasks; static PyObject *__pyx_n_s_attributes; static PyObject *__pyx_n_s_bases; +static PyObject *__pyx_n_s_cfunc_to_py; static PyObject *__pyx_n_s_class; static PyObject *__pyx_n_s_class_name; static PyObject *__pyx_n_s_clear; @@ -3077,9 +3167,13 @@ static PyObject *__pyx_n_s_deepcopy; static PyObject *__pyx_n_s_delattr; static PyObject *__pyx_n_s_dependency_injector_containers; static PyObject *__pyx_n_s_doc; +static PyObject *__pyx_n_s_ensure_future; static PyObject *__pyx_n_s_errors; static PyObject *__pyx_n_s_extend; static PyObject *__pyx_n_s_format; +static PyObject *__pyx_n_s_future; +static PyObject *__pyx_n_s_futures; +static PyObject *__pyx_n_s_gather; static PyObject *__pyx_n_s_genexpr; static PyObject *__pyx_n_s_get; static PyObject *__pyx_n_s_id; @@ -3089,7 +3183,9 @@ static PyObject *__pyx_n_s_inherited_providers; static PyObject *__pyx_n_s_init; static PyObject *__pyx_n_s_init_2; static PyObject *__pyx_n_s_init_resources; +static PyObject *__pyx_n_s_inspect; static PyObject *__pyx_n_s_instance_type; +static PyObject *__pyx_n_s_isawaitable; static PyObject *__pyx_n_s_items; static PyObject *__pyx_n_s_iteritems; static PyObject *__pyx_n_s_itervalues; @@ -3126,15 +3222,19 @@ static PyObject *__pyx_n_s_range; static PyObject *__pyx_n_s_reset_last_overriding; static PyObject *__pyx_n_s_reset_override; static PyObject *__pyx_n_s_resolve_provider_name; +static PyObject *__pyx_n_s_resource; +static PyObject *__pyx_n_s_result; static PyObject *__pyx_n_s_self; static PyObject *__pyx_n_s_send; static PyObject *__pyx_n_s_set_providers; +static PyObject *__pyx_n_s_set_result; static PyObject *__pyx_n_s_setattr; static PyObject *__pyx_n_s_shutdown; static PyObject *__pyx_n_s_shutdown_resources; static PyObject *__pyx_n_s_six; static PyObject *__pyx_n_s_source_provider; static PyObject *__pyx_kp_s_src_dependency_injector_containe; +static PyObject *__pyx_kp_s_stringsource; static PyObject *__pyx_n_s_super; static PyObject *__pyx_n_s_sys; static PyObject *__pyx_n_s_test; @@ -3147,6 +3247,8 @@ static PyObject *__pyx_n_s_wire; static PyObject *__pyx_n_s_wired_to_modules; static PyObject *__pyx_n_s_wired_to_packages; static PyObject *__pyx_n_s_wiring; +static PyObject *__pyx_n_s_wrap; +static PyObject *__pyx_n_s_zip; static PyObject *__pyx_pf_19dependency_injector_10containers_wire(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_args, CYTHON_UNUSED PyObject *__pyx_v_kwargs); /* proto */ static PyObject *__pyx_pf_19dependency_injector_10containers_2unwire(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_args, CYTHON_UNUSED PyObject *__pyx_v_kwargs); /* proto */ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer___init__(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_self); /* proto */ @@ -3179,12 +3281,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py static PyObject *__pyx_pf_19dependency_injector_10containers_6copy(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_container); /* proto */ static PyObject *__pyx_pf_19dependency_injector_10containers_8is_container(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_instance); /* proto */ static PyObject *__pyx_pf_19dependency_injector_10containers_10_check_provider_type(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_container, PyObject *__pyx_v_provider); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_10containers_12_isawaitable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_instance); /* proto */ +static PyObject *__pyx_pf_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_wrap(PyObject *__pyx_self, PyObject *__pyx_v_future); /* proto */ static PyObject *__pyx_tp_new_19dependency_injector_10containers___pyx_scope_struct____new__(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_19dependency_injector_10containers___pyx_scope_struct_1_genexpr(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_19dependency_injector_10containers___pyx_scope_struct_2_genexpr(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_19dependency_injector_10containers___pyx_scope_struct_3_genexpr(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_19dependency_injector_10containers___pyx_scope_struct_4_override(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_19dependency_injector_10containers___pyx_scope_struct_5_copy(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ +static PyObject *__pyx_tp_new___pyx_scope_struct____Pyx_CFunc_void____object___to_py(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static __Pyx_CachedCFunction __pyx_umethod_PyDict_Type_items = {0, &__pyx_n_s_items, 0, 0, 0}; static PyObject *__pyx_int_2; static PyObject *__pyx_int_3; @@ -3192,14 +3297,14 @@ static PyObject *__pyx_int_6; static PyObject *__pyx_int_neg_1; static PyObject *__pyx_tuple_; static PyObject *__pyx_slice__2; -static PyObject *__pyx_slice__8; static PyObject *__pyx_tuple__3; static PyObject *__pyx_tuple__5; -static PyObject *__pyx_tuple__9; -static PyObject *__pyx_tuple__10; +static PyObject *__pyx_tuple__8; +static PyObject *__pyx_slice__10; +static PyObject *__pyx_tuple__11; static PyObject *__pyx_tuple__12; static PyObject *__pyx_tuple__14; -static PyObject *__pyx_tuple__15; +static PyObject *__pyx_tuple__16; static PyObject *__pyx_tuple__17; static PyObject *__pyx_tuple__19; static PyObject *__pyx_tuple__21; @@ -3210,25 +3315,26 @@ static PyObject *__pyx_tuple__29; static PyObject *__pyx_tuple__31; static PyObject *__pyx_tuple__33; static PyObject *__pyx_tuple__35; -static PyObject *__pyx_tuple__36; +static PyObject *__pyx_tuple__37; static PyObject *__pyx_tuple__38; static PyObject *__pyx_tuple__40; static PyObject *__pyx_tuple__42; static PyObject *__pyx_tuple__44; static PyObject *__pyx_tuple__46; static PyObject *__pyx_tuple__48; -static PyObject *__pyx_tuple__49; +static PyObject *__pyx_tuple__50; static PyObject *__pyx_tuple__51; static PyObject *__pyx_tuple__53; static PyObject *__pyx_tuple__55; static PyObject *__pyx_tuple__57; static PyObject *__pyx_tuple__59; static PyObject *__pyx_tuple__61; +static PyObject *__pyx_tuple__63; static PyObject *__pyx_codeobj__4; static PyObject *__pyx_codeobj__6; -static PyObject *__pyx_codeobj__11; +static PyObject *__pyx_codeobj__9; static PyObject *__pyx_codeobj__13; -static PyObject *__pyx_codeobj__16; +static PyObject *__pyx_codeobj__15; static PyObject *__pyx_codeobj__18; static PyObject *__pyx_codeobj__20; static PyObject *__pyx_codeobj__22; @@ -3238,22 +3344,23 @@ static PyObject *__pyx_codeobj__28; static PyObject *__pyx_codeobj__30; static PyObject *__pyx_codeobj__32; static PyObject *__pyx_codeobj__34; -static PyObject *__pyx_codeobj__37; +static PyObject *__pyx_codeobj__36; static PyObject *__pyx_codeobj__39; static PyObject *__pyx_codeobj__41; static PyObject *__pyx_codeobj__43; static PyObject *__pyx_codeobj__45; static PyObject *__pyx_codeobj__47; -static PyObject *__pyx_codeobj__50; +static PyObject *__pyx_codeobj__49; static PyObject *__pyx_codeobj__52; static PyObject *__pyx_codeobj__54; static PyObject *__pyx_codeobj__56; static PyObject *__pyx_codeobj__58; static PyObject *__pyx_codeobj__60; static PyObject *__pyx_codeobj__62; +static PyObject *__pyx_codeobj__64; /* Late includes */ -/* "dependency_injector/containers.pyx":18 +/* "dependency_injector/containers.pyx":24 * from .wiring import wire, unwire * else: * def wire(*args, **kwargs): # <<<<<<<<<<<<<< @@ -3291,20 +3398,20 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_wire(CYTHON_UNUSED int __pyx_clineno = 0; __Pyx_RefNannySetupContext("wire", 0); - /* "dependency_injector/containers.pyx":19 + /* "dependency_injector/containers.pyx":25 * else: * def wire(*args, **kwargs): * raise NotImplementedError('Wiring requires Python 3.6 or above') # <<<<<<<<<<<<<< * * def unwire(*args, **kwargs): */ - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_tuple_, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 19, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_tuple_, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 25, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(0, 19, __pyx_L1_error) + __PYX_ERR(0, 25, __pyx_L1_error) - /* "dependency_injector/containers.pyx":18 + /* "dependency_injector/containers.pyx":24 * from .wiring import wire, unwire * else: * def wire(*args, **kwargs): # <<<<<<<<<<<<<< @@ -3322,7 +3429,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_wire(CYTHON_UNUSED return __pyx_r; } -/* "dependency_injector/containers.pyx":21 +/* "dependency_injector/containers.pyx":27 * raise NotImplementedError('Wiring requires Python 3.6 or above') * * def unwire(*args, **kwargs): # <<<<<<<<<<<<<< @@ -3360,20 +3467,20 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_2unwire(CYTHON_UNUS int __pyx_clineno = 0; __Pyx_RefNannySetupContext("unwire", 0); - /* "dependency_injector/containers.pyx":22 + /* "dependency_injector/containers.pyx":28 * * def unwire(*args, **kwargs): * raise NotImplementedError('Wiring requires Python 3.6 or above') # <<<<<<<<<<<<<< * * */ - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_tuple_, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 22, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_tuple_, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 28, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(0, 22, __pyx_L1_error) + __PYX_ERR(0, 28, __pyx_L1_error) - /* "dependency_injector/containers.pyx":21 + /* "dependency_injector/containers.pyx":27 * raise NotImplementedError('Wiring requires Python 3.6 or above') * * def unwire(*args, **kwargs): # <<<<<<<<<<<<<< @@ -3391,7 +3498,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_2unwire(CYTHON_UNUS return __pyx_r; } -/* "dependency_injector/containers.pyx":56 +/* "dependency_injector/containers.pyx":62 * __IS_CONTAINER__ = True * * def __init__(self): # <<<<<<<<<<<<<< @@ -3425,82 +3532,82 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/containers.pyx":61 + /* "dependency_injector/containers.pyx":67 * :rtype: None * """ * self.provider_type = Provider # <<<<<<<<<<<<<< * self.providers = {} * self.overridden = tuple() */ - if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_provider_type, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider)) < 0) __PYX_ERR(0, 61, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_provider_type, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider)) < 0) __PYX_ERR(0, 67, __pyx_L1_error) - /* "dependency_injector/containers.pyx":62 + /* "dependency_injector/containers.pyx":68 * """ * self.provider_type = Provider * self.providers = {} # <<<<<<<<<<<<<< * self.overridden = tuple() * self.declarative_parent = None */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 62, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 68, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_providers, __pyx_t_1) < 0) __PYX_ERR(0, 62, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_providers, __pyx_t_1) < 0) __PYX_ERR(0, 68, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":63 + /* "dependency_injector/containers.pyx":69 * self.provider_type = Provider * self.providers = {} * self.overridden = tuple() # <<<<<<<<<<<<<< * self.declarative_parent = None * self.wired_to_modules = [] */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 63, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 69, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_overridden, __pyx_t_1) < 0) __PYX_ERR(0, 63, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_overridden, __pyx_t_1) < 0) __PYX_ERR(0, 69, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":64 + /* "dependency_injector/containers.pyx":70 * self.providers = {} * self.overridden = tuple() * self.declarative_parent = None # <<<<<<<<<<<<<< * self.wired_to_modules = [] * self.wired_to_packages = [] */ - if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_declarative_parent, Py_None) < 0) __PYX_ERR(0, 64, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_declarative_parent, Py_None) < 0) __PYX_ERR(0, 70, __pyx_L1_error) - /* "dependency_injector/containers.pyx":65 + /* "dependency_injector/containers.pyx":71 * self.overridden = tuple() * self.declarative_parent = None * self.wired_to_modules = [] # <<<<<<<<<<<<<< * self.wired_to_packages = [] * super(DynamicContainer, self).__init__() */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 65, __pyx_L1_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 71, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_modules, __pyx_t_1) < 0) __PYX_ERR(0, 65, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_modules, __pyx_t_1) < 0) __PYX_ERR(0, 71, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":66 + /* "dependency_injector/containers.pyx":72 * self.declarative_parent = None * self.wired_to_modules = [] * self.wired_to_packages = [] # <<<<<<<<<<<<<< * super(DynamicContainer, self).__init__() * */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 66, __pyx_L1_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 72, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_packages, __pyx_t_1) < 0) __PYX_ERR(0, 66, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_packages, __pyx_t_1) < 0) __PYX_ERR(0, 72, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":67 + /* "dependency_injector/containers.pyx":73 * self.wired_to_modules = [] * self.wired_to_packages = [] * super(DynamicContainer, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_DynamicContainer); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 67, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_DynamicContainer); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 73, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 67, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 73, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); @@ -3508,10 +3615,10 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_GIVEREF(__pyx_v_self); PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_self); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 67, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 73, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 67, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 73, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -3526,12 +3633,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 67, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 73, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":56 + /* "dependency_injector/containers.pyx":62 * __IS_CONTAINER__ = True * * def __init__(self): # <<<<<<<<<<<<<< @@ -3554,7 +3661,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":69 +/* "dependency_injector/containers.pyx":75 * super(DynamicContainer, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -3598,11 +3705,11 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_memo)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__deepcopy__", 1, 2, 2, 1); __PYX_ERR(0, 69, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__deepcopy__", 1, 2, 2, 1); __PYX_ERR(0, 75, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__deepcopy__") < 0)) __PYX_ERR(0, 69, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__deepcopy__") < 0)) __PYX_ERR(0, 75, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -3615,7 +3722,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__deepcopy__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 69, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__deepcopy__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 75, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers.DynamicContainer.__deepcopy__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -3651,16 +3758,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/containers.pyx":71 + /* "dependency_injector/containers.pyx":77 * def __deepcopy__(self, memo): * """Create and return full copy of container.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 71, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 77, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 71, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 77, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -3675,13 +3782,13 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 71, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 77, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":72 + /* "dependency_injector/containers.pyx":78 * """Create and return full copy of container.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -3692,7 +3799,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/containers.pyx":73 + /* "dependency_injector/containers.pyx":79 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -3704,7 +3811,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/containers.pyx":72 + /* "dependency_injector/containers.pyx":78 * """Create and return full copy of container.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -3713,14 +3820,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ */ } - /* "dependency_injector/containers.pyx":75 + /* "dependency_injector/containers.pyx":81 * return copied * * copied = self.__class__() # <<<<<<<<<<<<<< * copied.provider_type = Provider * copied.overridden = deepcopy(self.overridden, memo) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 75, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 81, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -3734,67 +3841,67 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 75, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 81, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":76 + /* "dependency_injector/containers.pyx":82 * * copied = self.__class__() * copied.provider_type = Provider # <<<<<<<<<<<<<< * copied.overridden = deepcopy(self.overridden, memo) * copied.declarative_parent = self.declarative_parent */ - if (__Pyx_PyObject_SetAttrStr(__pyx_v_copied, __pyx_n_s_provider_type, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider)) < 0) __PYX_ERR(0, 76, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_copied, __pyx_n_s_provider_type, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider)) < 0) __PYX_ERR(0, 82, __pyx_L1_error) - /* "dependency_injector/containers.pyx":77 + /* "dependency_injector/containers.pyx":83 * copied = self.__class__() * copied.provider_type = Provider * copied.overridden = deepcopy(self.overridden, memo) # <<<<<<<<<<<<<< * copied.declarative_parent = self.declarative_parent * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_overridden); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 77, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_overridden); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 83, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(0, 77, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(0, 83, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 77, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 83, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (__Pyx_PyObject_SetAttrStr(__pyx_v_copied, __pyx_n_s_overridden, __pyx_t_2) < 0) __PYX_ERR(0, 77, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_copied, __pyx_n_s_overridden, __pyx_t_2) < 0) __PYX_ERR(0, 83, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":78 + /* "dependency_injector/containers.pyx":84 * copied.provider_type = Provider * copied.overridden = deepcopy(self.overridden, memo) * copied.declarative_parent = self.declarative_parent # <<<<<<<<<<<<<< * * for name, provider in deepcopy(self.providers, memo).items(): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_declarative_parent); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 78, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_declarative_parent); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 84, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (__Pyx_PyObject_SetAttrStr(__pyx_v_copied, __pyx_n_s_declarative_parent, __pyx_t_2) < 0) __PYX_ERR(0, 78, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_copied, __pyx_n_s_declarative_parent, __pyx_t_2) < 0) __PYX_ERR(0, 84, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":80 + /* "dependency_injector/containers.pyx":86 * copied.declarative_parent = self.declarative_parent * * for name, provider in deepcopy(self.providers, memo).items(): # <<<<<<<<<<<<<< * setattr(copied, name, provider) * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 86, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(0, 80, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(0, 86, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_3 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_3 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 86, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_items); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_items); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 86, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -3809,16 +3916,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 80, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 86, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; if (likely(PyList_CheckExact(__pyx_t_2)) || PyTuple_CheckExact(__pyx_t_2)) { __pyx_t_1 = __pyx_t_2; __Pyx_INCREF(__pyx_t_1); __pyx_t_8 = 0; __pyx_t_9 = NULL; } else { - __pyx_t_8 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_8 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 86, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_9 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_9 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 86, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; for (;;) { @@ -3826,17 +3933,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ if (likely(PyList_CheckExact(__pyx_t_1))) { if (__pyx_t_8 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_2 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_8); __Pyx_INCREF(__pyx_t_2); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_2 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_8); __Pyx_INCREF(__pyx_t_2); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 86, __pyx_L1_error) #else - __pyx_t_2 = PySequence_ITEM(__pyx_t_1, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(__pyx_t_1, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 86, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); #endif } else { if (__pyx_t_8 >= PyTuple_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_2 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_8); __Pyx_INCREF(__pyx_t_2); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_8); __Pyx_INCREF(__pyx_t_2); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 86, __pyx_L1_error) #else - __pyx_t_2 = PySequence_ITEM(__pyx_t_1, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(__pyx_t_1, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 86, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); #endif } @@ -3846,7 +3953,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 80, __pyx_L1_error) + else __PYX_ERR(0, 86, __pyx_L1_error) } break; } @@ -3858,7 +3965,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 80, __pyx_L1_error) + __PYX_ERR(0, 86, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -3871,15 +3978,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(__pyx_t_4); #else - __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 86, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 86, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } else { Py_ssize_t index = -1; - __pyx_t_10 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 80, __pyx_L1_error) + __pyx_t_10 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 86, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_11 = Py_TYPE(__pyx_t_10)->tp_iternext; @@ -3887,7 +3994,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_GOTREF(__pyx_t_3); index = 1; __pyx_t_4 = __pyx_t_11(__pyx_t_10); if (unlikely(!__pyx_t_4)) goto __pyx_L6_unpacking_failed; __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_11(__pyx_t_10), 2) < 0) __PYX_ERR(0, 80, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_11(__pyx_t_10), 2) < 0) __PYX_ERR(0, 86, __pyx_L1_error) __pyx_t_11 = NULL; __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; goto __pyx_L7_unpacking_done; @@ -3895,7 +4002,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; __pyx_t_11 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 80, __pyx_L1_error) + __PYX_ERR(0, 86, __pyx_L1_error) __pyx_L7_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_3); @@ -3903,16 +4010,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":81 + /* "dependency_injector/containers.pyx":87 * * for name, provider in deepcopy(self.providers, memo).items(): * setattr(copied, name, provider) # <<<<<<<<<<<<<< * * return copied */ - __pyx_t_12 = PyObject_SetAttr(__pyx_v_copied, __pyx_v_name, __pyx_v_provider); if (unlikely(__pyx_t_12 == ((int)-1))) __PYX_ERR(0, 81, __pyx_L1_error) + __pyx_t_12 = PyObject_SetAttr(__pyx_v_copied, __pyx_v_name, __pyx_v_provider); if (unlikely(__pyx_t_12 == ((int)-1))) __PYX_ERR(0, 87, __pyx_L1_error) - /* "dependency_injector/containers.pyx":80 + /* "dependency_injector/containers.pyx":86 * copied.declarative_parent = self.declarative_parent * * for name, provider in deepcopy(self.providers, memo).items(): # <<<<<<<<<<<<<< @@ -3922,7 +4029,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":83 + /* "dependency_injector/containers.pyx":89 * setattr(copied, name, provider) * * return copied # <<<<<<<<<<<<<< @@ -3934,7 +4041,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/containers.pyx":69 + /* "dependency_injector/containers.pyx":75 * super(DynamicContainer, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -3960,7 +4067,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":85 +/* "dependency_injector/containers.pyx":91 * return copied * * def __setattr__(self, str name, object value): # <<<<<<<<<<<<<< @@ -4007,17 +4114,17 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, 1); __PYX_ERR(0, 85, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, 1); __PYX_ERR(0, 91, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 2: if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, 2); __PYX_ERR(0, 85, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, 2); __PYX_ERR(0, 91, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__setattr__") < 0)) __PYX_ERR(0, 85, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__setattr__") < 0)) __PYX_ERR(0, 91, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; @@ -4032,13 +4139,13 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 85, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 91, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers.DynamicContainer.__setattr__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyString_Type), 1, "name", 1))) __PYX_ERR(0, 85, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyString_Type), 1, "name", 1))) __PYX_ERR(0, 91, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_10containers_16DynamicContainer_4__setattr__(__pyx_self, __pyx_v_self, __pyx_v_name, __pyx_v_value); /* function exit code */ @@ -4065,7 +4172,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__setattr__", 0); - /* "dependency_injector/containers.pyx":99 + /* "dependency_injector/containers.pyx":105 * :rtype: None * """ * if isinstance(value, Provider): # <<<<<<<<<<<<<< @@ -4076,30 +4183,30 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_t_2 = (__pyx_t_1 != 0); if (__pyx_t_2) { - /* "dependency_injector/containers.pyx":100 + /* "dependency_injector/containers.pyx":106 * """ * if isinstance(value, Provider): * _check_provider_type(self, value) # <<<<<<<<<<<<<< * self.providers[name] = value * super(DynamicContainer, self).__setattr__(name, value) */ - __pyx_t_3 = __pyx_f_19dependency_injector_10containers__check_provider_type(__pyx_v_self, __pyx_v_value, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 100, __pyx_L1_error) + __pyx_t_3 = __pyx_f_19dependency_injector_10containers__check_provider_type(__pyx_v_self, __pyx_v_value, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 106, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":101 + /* "dependency_injector/containers.pyx":107 * if isinstance(value, Provider): * _check_provider_type(self, value) * self.providers[name] = value # <<<<<<<<<<<<<< * super(DynamicContainer, self).__setattr__(name, value) * */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 101, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 107, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (unlikely(PyObject_SetItem(__pyx_t_3, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 101, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_t_3, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 107, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":99 + /* "dependency_injector/containers.pyx":105 * :rtype: None * """ * if isinstance(value, Provider): # <<<<<<<<<<<<<< @@ -4108,16 +4215,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ */ } - /* "dependency_injector/containers.pyx":102 + /* "dependency_injector/containers.pyx":108 * _check_provider_type(self, value) * self.providers[name] = value * super(DynamicContainer, self).__setattr__(name, value) # <<<<<<<<<<<<<< * * def __delattr__(self, str name): */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_DynamicContainer); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 102, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_DynamicContainer); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 108, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 102, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 108, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4); @@ -4125,10 +4232,10 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_GIVEREF(__pyx_v_self); PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_v_self); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_5, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 102, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_5, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 108, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_setattr); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 102, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_setattr); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 108, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; @@ -4146,7 +4253,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_name, __pyx_v_value}; - __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 102, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 108, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_3); } else @@ -4154,13 +4261,13 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_name, __pyx_v_value}; - __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 102, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 108, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_3); } else #endif { - __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 102, __pyx_L1_error) + __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 108, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -4171,14 +4278,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_INCREF(__pyx_v_value); __Pyx_GIVEREF(__pyx_v_value); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_v_value); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 102, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 108, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":85 + /* "dependency_injector/containers.pyx":91 * return copied * * def __setattr__(self, str name, object value): # <<<<<<<<<<<<<< @@ -4202,7 +4309,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":104 +/* "dependency_injector/containers.pyx":110 * super(DynamicContainer, self).__setattr__(name, value) * * def __delattr__(self, str name): # <<<<<<<<<<<<<< @@ -4246,11 +4353,11 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__delattr__", 1, 2, 2, 1); __PYX_ERR(0, 104, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__delattr__", 1, 2, 2, 1); __PYX_ERR(0, 110, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__delattr__") < 0)) __PYX_ERR(0, 104, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__delattr__") < 0)) __PYX_ERR(0, 110, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -4263,13 +4370,13 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__delattr__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 104, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__delattr__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 110, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers.DynamicContainer.__delattr__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyString_Type), 1, "name", 1))) __PYX_ERR(0, 104, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyString_Type), 1, "name", 1))) __PYX_ERR(0, 110, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_10containers_16DynamicContainer_6__delattr__(__pyx_self, __pyx_v_self, __pyx_v_name); /* function exit code */ @@ -4294,33 +4401,33 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__delattr__", 0); - /* "dependency_injector/containers.pyx":115 + /* "dependency_injector/containers.pyx":121 * :rtype: None * """ * if name in self.providers: # <<<<<<<<<<<<<< * del self.providers[name] * super(DynamicContainer, self).__delattr__(name) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 115, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 121, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = (__Pyx_PySequence_ContainsTF(__pyx_v_name, __pyx_t_1, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 115, __pyx_L1_error) + __pyx_t_2 = (__Pyx_PySequence_ContainsTF(__pyx_v_name, __pyx_t_1, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 121, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = (__pyx_t_2 != 0); if (__pyx_t_3) { - /* "dependency_injector/containers.pyx":116 + /* "dependency_injector/containers.pyx":122 * """ * if name in self.providers: * del self.providers[name] # <<<<<<<<<<<<<< * super(DynamicContainer, self).__delattr__(name) * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 116, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 122, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (unlikely(PyObject_DelItem(__pyx_t_1, __pyx_v_name) < 0)) __PYX_ERR(0, 116, __pyx_L1_error) + if (unlikely(PyObject_DelItem(__pyx_t_1, __pyx_v_name) < 0)) __PYX_ERR(0, 122, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":115 + /* "dependency_injector/containers.pyx":121 * :rtype: None * """ * if name in self.providers: # <<<<<<<<<<<<<< @@ -4329,16 +4436,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ */ } - /* "dependency_injector/containers.pyx":117 + /* "dependency_injector/containers.pyx":123 * if name in self.providers: * del self.providers[name] * super(DynamicContainer, self).__delattr__(name) # <<<<<<<<<<<<<< * * def set_providers(self, **providers): */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_DynamicContainer); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 117, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_DynamicContainer); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 123, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 117, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 123, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4); @@ -4346,10 +4453,10 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_GIVEREF(__pyx_v_self); PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_v_self); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_5, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 117, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_5, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 123, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_delattr); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 117, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_delattr); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 123, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; @@ -4364,12 +4471,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_v_name) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_name); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 117, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 123, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":104 + /* "dependency_injector/containers.pyx":110 * super(DynamicContainer, self).__setattr__(name, value) * * def __delattr__(self, str name): # <<<<<<<<<<<<<< @@ -4392,7 +4499,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":119 +/* "dependency_injector/containers.pyx":125 * super(DynamicContainer, self).__delattr__(name) * * def set_providers(self, **providers): # <<<<<<<<<<<<<< @@ -4434,7 +4541,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_providers, values, pos_args, "set_providers") < 0)) __PYX_ERR(0, 119, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_providers, values, pos_args, "set_providers") < 0)) __PYX_ERR(0, 125, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -4445,7 +4552,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("set_providers", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 119, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("set_providers", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 125, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_providers); __pyx_v_providers = 0; __Pyx_AddTraceback("dependency_injector.containers.DynamicContainer.set_providers", __pyx_clineno, __pyx_lineno, __pyx_filename); @@ -4479,16 +4586,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_providers", 0); - /* "dependency_injector/containers.pyx":128 + /* "dependency_injector/containers.pyx":134 * :rtype: None * """ * for name, provider in six.iteritems(providers): # <<<<<<<<<<<<<< * setattr(self, name, provider) * */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 128, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 128, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -4503,16 +4610,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, __pyx_v_providers) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_providers); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 128, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0; __pyx_t_5 = NULL; } else { - __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 128, __pyx_L1_error) + __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 128, __pyx_L1_error) + __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 134, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -4520,17 +4627,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 128, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 134, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 128, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 128, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 134, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 128, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -4540,7 +4647,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 128, __pyx_L1_error) + else __PYX_ERR(0, 134, __pyx_L1_error) } break; } @@ -4552,7 +4659,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 128, __pyx_L1_error) + __PYX_ERR(0, 134, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -4565,15 +4672,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 128, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 128, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 128, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -4581,7 +4688,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_GOTREF(__pyx_t_2); index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 128, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 134, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L6_unpacking_done; @@ -4589,7 +4696,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 128, __pyx_L1_error) + __PYX_ERR(0, 134, __pyx_L1_error) __pyx_L6_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_2); @@ -4597,16 +4704,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":129 + /* "dependency_injector/containers.pyx":135 * """ * for name, provider in six.iteritems(providers): * setattr(self, name, provider) # <<<<<<<<<<<<<< * * def override(self, object overriding): */ - __pyx_t_9 = PyObject_SetAttr(__pyx_v_self, __pyx_v_name, __pyx_v_provider); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 129, __pyx_L1_error) + __pyx_t_9 = PyObject_SetAttr(__pyx_v_self, __pyx_v_name, __pyx_v_provider); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 135, __pyx_L1_error) - /* "dependency_injector/containers.pyx":128 + /* "dependency_injector/containers.pyx":134 * :rtype: None * """ * for name, provider in six.iteritems(providers): # <<<<<<<<<<<<<< @@ -4616,7 +4723,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":119 + /* "dependency_injector/containers.pyx":125 * super(DynamicContainer, self).__delattr__(name) * * def set_providers(self, **providers): # <<<<<<<<<<<<<< @@ -4643,7 +4750,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":131 +/* "dependency_injector/containers.pyx":137 * setattr(self, name, provider) * * def override(self, object overriding): # <<<<<<<<<<<<<< @@ -4687,11 +4794,11 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_overriding)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("override", 1, 2, 2, 1); __PYX_ERR(0, 131, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("override", 1, 2, 2, 1); __PYX_ERR(0, 137, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "override") < 0)) __PYX_ERR(0, 131, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "override") < 0)) __PYX_ERR(0, 137, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -4704,7 +4811,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("override", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 131, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("override", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 137, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers.DynamicContainer.override", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -4741,7 +4848,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/containers.pyx":142 + /* "dependency_injector/containers.pyx":148 * :rtype: None * """ * if overriding is self: # <<<<<<<<<<<<<< @@ -4752,24 +4859,24 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/containers.pyx":143 + /* "dependency_injector/containers.pyx":149 * """ * if overriding is self: * raise Error('Container {0} could not be overridden ' # <<<<<<<<<<<<<< * 'with itself'.format(self)) * */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 143, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 149, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/containers.pyx":144 + /* "dependency_injector/containers.pyx":150 * if overriding is self: * raise Error('Container {0} could not be overridden ' * 'with itself'.format(self)) # <<<<<<<<<<<<<< * * self.overridden += (overriding,) */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Container_0_could_not_be_overrid, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 144, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Container_0_could_not_be_overrid, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 150, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -4783,7 +4890,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, __pyx_v_self) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_self); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 144, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 150, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -4799,14 +4906,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 143, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 149, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(0, 143, __pyx_L1_error) + __PYX_ERR(0, 149, __pyx_L1_error) - /* "dependency_injector/containers.pyx":142 + /* "dependency_injector/containers.pyx":148 * :rtype: None * """ * if overriding is self: # <<<<<<<<<<<<<< @@ -4815,40 +4922,40 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ */ } - /* "dependency_injector/containers.pyx":146 + /* "dependency_injector/containers.pyx":152 * 'with itself'.format(self)) * * self.overridden += (overriding,) # <<<<<<<<<<<<<< * * for name, provider in six.iteritems(overriding.providers): */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_overridden); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 146, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_overridden); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 152, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 146, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 152, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v_overriding); __Pyx_GIVEREF(__pyx_v_overriding); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_overriding); - __pyx_t_5 = PyNumber_InPlaceAdd(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 146, __pyx_L1_error) + __pyx_t_5 = PyNumber_InPlaceAdd(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 152, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_overridden, __pyx_t_5) < 0) __PYX_ERR(0, 146, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_overridden, __pyx_t_5) < 0) __PYX_ERR(0, 152, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/containers.pyx":148 + /* "dependency_injector/containers.pyx":154 * self.overridden += (overriding,) * * for name, provider in six.iteritems(overriding.providers): # <<<<<<<<<<<<<< * try: * getattr(self, name).override(provider) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_six); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 148, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_six); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_overriding, __pyx_n_s_providers); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_overriding, __pyx_n_s_providers); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { @@ -4863,16 +4970,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_t_5 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_6, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 148, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) { __pyx_t_3 = __pyx_t_5; __Pyx_INCREF(__pyx_t_3); __pyx_t_8 = 0; __pyx_t_9 = NULL; } else { - __pyx_t_8 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_8 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_9 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_9 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 154, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; for (;;) { @@ -4880,17 +4987,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_8 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_5 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_8); __Pyx_INCREF(__pyx_t_5); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_5 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_8); __Pyx_INCREF(__pyx_t_5); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 154, __pyx_L1_error) #else - __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); #endif } else { if (__pyx_t_8 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_8); __Pyx_INCREF(__pyx_t_5); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_8); __Pyx_INCREF(__pyx_t_5); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 154, __pyx_L1_error) #else - __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); #endif } @@ -4900,7 +5007,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 148, __pyx_L1_error) + else __PYX_ERR(0, 154, __pyx_L1_error) } break; } @@ -4912,7 +5019,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 148, __pyx_L1_error) + __PYX_ERR(0, 154, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -4925,15 +5032,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_INCREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_4 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 148, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_10 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -4941,7 +5048,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_GOTREF(__pyx_t_4); index = 1; __pyx_t_6 = __pyx_t_10(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L6_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_7), 2) < 0) __PYX_ERR(0, 148, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_7), 2) < 0) __PYX_ERR(0, 154, __pyx_L1_error) __pyx_t_10 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L7_unpacking_done; @@ -4949,7 +5056,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_10 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 148, __pyx_L1_error) + __PYX_ERR(0, 154, __pyx_L1_error) __pyx_L7_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_4); @@ -4957,7 +5064,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":149 + /* "dependency_injector/containers.pyx":155 * * for name, provider in six.iteritems(overriding.providers): * try: # <<<<<<<<<<<<<< @@ -4973,16 +5080,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_XGOTREF(__pyx_t_13); /*try:*/ { - /* "dependency_injector/containers.pyx":150 + /* "dependency_injector/containers.pyx":156 * for name, provider in six.iteritems(overriding.providers): * try: * getattr(self, name).override(provider) # <<<<<<<<<<<<<< * except AttributeError: * pass */ - __pyx_t_6 = __Pyx_GetAttr(__pyx_v_self, __pyx_v_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 150, __pyx_L8_error) + __pyx_t_6 = __Pyx_GetAttr(__pyx_v_self, __pyx_v_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 156, __pyx_L8_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 150, __pyx_L8_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 156, __pyx_L8_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -4997,12 +5104,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_5 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_v_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_provider); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 150, __pyx_L8_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 156, __pyx_L8_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/containers.pyx":149 + /* "dependency_injector/containers.pyx":155 * * for name, provider in six.iteritems(overriding.providers): * try: # <<<<<<<<<<<<<< @@ -5020,7 +5127,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/containers.pyx":151 + /* "dependency_injector/containers.pyx":157 * try: * getattr(self, name).override(provider) * except AttributeError: # <<<<<<<<<<<<<< @@ -5035,7 +5142,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ goto __pyx_L10_except_error; __pyx_L10_except_error:; - /* "dependency_injector/containers.pyx":149 + /* "dependency_injector/containers.pyx":155 * * for name, provider in six.iteritems(overriding.providers): * try: # <<<<<<<<<<<<<< @@ -5055,7 +5162,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_L15_try_end:; } - /* "dependency_injector/containers.pyx":148 + /* "dependency_injector/containers.pyx":154 * self.overridden += (overriding,) * * for name, provider in six.iteritems(overriding.providers): # <<<<<<<<<<<<<< @@ -5065,7 +5172,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":131 + /* "dependency_injector/containers.pyx":137 * setattr(self, name, provider) * * def override(self, object overriding): # <<<<<<<<<<<<<< @@ -5092,7 +5199,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":154 +/* "dependency_injector/containers.pyx":160 * pass * * def override_providers(self, **overriding_providers): # <<<<<<<<<<<<<< @@ -5134,7 +5241,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_overriding_providers, values, pos_args, "override_providers") < 0)) __PYX_ERR(0, 154, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_overriding_providers, values, pos_args, "override_providers") < 0)) __PYX_ERR(0, 160, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -5145,7 +5252,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("override_providers", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 154, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("override_providers", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 160, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_overriding_providers); __pyx_v_overriding_providers = 0; __Pyx_AddTraceback("dependency_injector.containers.DynamicContainer.override_providers", __pyx_clineno, __pyx_lineno, __pyx_filename); @@ -5179,16 +5286,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override_providers", 0); - /* "dependency_injector/containers.pyx":163 + /* "dependency_injector/containers.pyx":169 * :rtype: None * """ * for name, overriding_provider in six.iteritems(overriding_providers): # <<<<<<<<<<<<<< * container_provider = getattr(self, name) * container_provider.override(overriding_provider) */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 163, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 163, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -5203,16 +5310,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, __pyx_v_overriding_providers) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_overriding_providers); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 163, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0; __pyx_t_5 = NULL; } else { - __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 163, __pyx_L1_error) + __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 163, __pyx_L1_error) + __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 169, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -5220,17 +5327,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 163, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 169, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 163, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 163, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 169, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 163, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -5240,7 +5347,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 163, __pyx_L1_error) + else __PYX_ERR(0, 169, __pyx_L1_error) } break; } @@ -5252,7 +5359,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 163, __pyx_L1_error) + __PYX_ERR(0, 169, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -5265,15 +5372,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 163, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 163, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 163, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -5281,7 +5388,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_GOTREF(__pyx_t_2); index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 163, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 169, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L6_unpacking_done; @@ -5289,7 +5396,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 163, __pyx_L1_error) + __PYX_ERR(0, 169, __pyx_L1_error) __pyx_L6_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_2); @@ -5297,26 +5404,26 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_XDECREF_SET(__pyx_v_overriding_provider, __pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":164 + /* "dependency_injector/containers.pyx":170 * """ * for name, overriding_provider in six.iteritems(overriding_providers): * container_provider = getattr(self, name) # <<<<<<<<<<<<<< * container_provider.override(overriding_provider) * */ - __pyx_t_1 = __Pyx_GetAttr(__pyx_v_self, __pyx_v_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 164, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetAttr(__pyx_v_self, __pyx_v_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 170, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_XDECREF_SET(__pyx_v_container_provider, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":165 + /* "dependency_injector/containers.pyx":171 * for name, overriding_provider in six.iteritems(overriding_providers): * container_provider = getattr(self, name) * container_provider.override(overriding_provider) # <<<<<<<<<<<<<< * * def reset_last_overriding(self): */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_container_provider, __pyx_n_s_override); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 165, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_container_provider, __pyx_n_s_override); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 171, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -5330,12 +5437,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_2, __pyx_v_overriding_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_overriding_provider); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 165, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 171, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":163 + /* "dependency_injector/containers.pyx":169 * :rtype: None * """ * for name, overriding_provider in six.iteritems(overriding_providers): # <<<<<<<<<<<<<< @@ -5345,7 +5452,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":154 + /* "dependency_injector/containers.pyx":160 * pass * * def override_providers(self, **overriding_providers): # <<<<<<<<<<<<<< @@ -5373,7 +5480,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":167 +/* "dependency_injector/containers.pyx":173 * container_provider.override(overriding_provider) * * def reset_last_overriding(self): # <<<<<<<<<<<<<< @@ -5414,30 +5521,30 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_last_overriding", 0); - /* "dependency_injector/containers.pyx":172 + /* "dependency_injector/containers.pyx":178 * :rtype: None * """ * if not self.overridden: # <<<<<<<<<<<<<< * raise Error('Container {0} is not overridden'.format(self)) * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_overridden); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 172, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_overridden); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 178, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 172, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 178, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = ((!__pyx_t_2) != 0); if (unlikely(__pyx_t_3)) { - /* "dependency_injector/containers.pyx":173 + /* "dependency_injector/containers.pyx":179 * """ * if not self.overridden: * raise Error('Container {0} is not overridden'.format(self)) # <<<<<<<<<<<<<< * * self.overridden = self.overridden[:-1] */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 173, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 179, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Container_0_is_not_overridden, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 173, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Container_0_is_not_overridden, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 179, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -5451,7 +5558,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, __pyx_v_self) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_self); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 173, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 179, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -5467,14 +5574,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 173, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 179, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(0, 173, __pyx_L1_error) + __PYX_ERR(0, 179, __pyx_L1_error) - /* "dependency_injector/containers.pyx":172 + /* "dependency_injector/containers.pyx":178 * :rtype: None * """ * if not self.overridden: # <<<<<<<<<<<<<< @@ -5483,34 +5590,34 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ */ } - /* "dependency_injector/containers.pyx":175 + /* "dependency_injector/containers.pyx":181 * raise Error('Container {0} is not overridden'.format(self)) * * self.overridden = self.overridden[:-1] # <<<<<<<<<<<<<< * * for provider in six.itervalues(self.providers): */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_overridden); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 175, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_overridden); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 181, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_4 = __Pyx_PyObject_GetSlice(__pyx_t_1, 0, -1L, NULL, NULL, &__pyx_slice__2, 0, 1, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 175, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetSlice(__pyx_t_1, 0, -1L, NULL, NULL, &__pyx_slice__2, 0, 1, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 181, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_overridden, __pyx_t_4) < 0) __PYX_ERR(0, 175, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_overridden, __pyx_t_4) < 0) __PYX_ERR(0, 181, __pyx_L1_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":177 + /* "dependency_injector/containers.pyx":183 * self.overridden = self.overridden[:-1] * * for provider in six.itervalues(self.providers): # <<<<<<<<<<<<<< * provider.reset_last_overriding() * */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_six); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 177, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_six); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_itervalues); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 177, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_itervalues); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 177, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { @@ -5525,16 +5632,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_t_1) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_1); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 177, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (likely(PyList_CheckExact(__pyx_t_4)) || PyTuple_CheckExact(__pyx_t_4)) { __pyx_t_5 = __pyx_t_4; __Pyx_INCREF(__pyx_t_5); __pyx_t_8 = 0; __pyx_t_9 = NULL; } else { - __pyx_t_8 = -1; __pyx_t_5 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 177, __pyx_L1_error) + __pyx_t_8 = -1; __pyx_t_5 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_9 = Py_TYPE(__pyx_t_5)->tp_iternext; if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 177, __pyx_L1_error) + __pyx_t_9 = Py_TYPE(__pyx_t_5)->tp_iternext; if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 183, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; for (;;) { @@ -5542,17 +5649,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ if (likely(PyList_CheckExact(__pyx_t_5))) { if (__pyx_t_8 >= PyList_GET_SIZE(__pyx_t_5)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_4 = PyList_GET_ITEM(__pyx_t_5, __pyx_t_8); __Pyx_INCREF(__pyx_t_4); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 177, __pyx_L1_error) + __pyx_t_4 = PyList_GET_ITEM(__pyx_t_5, __pyx_t_8); __Pyx_INCREF(__pyx_t_4); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 183, __pyx_L1_error) #else - __pyx_t_4 = PySequence_ITEM(__pyx_t_5, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 177, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(__pyx_t_5, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif } else { if (__pyx_t_8 >= PyTuple_GET_SIZE(__pyx_t_5)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_5, __pyx_t_8); __Pyx_INCREF(__pyx_t_4); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 177, __pyx_L1_error) + __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_5, __pyx_t_8); __Pyx_INCREF(__pyx_t_4); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 183, __pyx_L1_error) #else - __pyx_t_4 = PySequence_ITEM(__pyx_t_5, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 177, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(__pyx_t_5, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif } @@ -5562,7 +5669,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 177, __pyx_L1_error) + else __PYX_ERR(0, 183, __pyx_L1_error) } break; } @@ -5571,14 +5678,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":178 + /* "dependency_injector/containers.pyx":184 * * for provider in six.itervalues(self.providers): * provider.reset_last_overriding() # <<<<<<<<<<<<<< * * def reset_override(self): */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 178, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 184, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -5592,12 +5699,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 178, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 184, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":177 + /* "dependency_injector/containers.pyx":183 * self.overridden = self.overridden[:-1] * * for provider in six.itervalues(self.providers): # <<<<<<<<<<<<<< @@ -5607,7 +5714,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/containers.pyx":167 + /* "dependency_injector/containers.pyx":173 * container_provider.override(overriding_provider) * * def reset_last_overriding(self): # <<<<<<<<<<<<<< @@ -5633,7 +5740,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":180 +/* "dependency_injector/containers.pyx":186 * provider.reset_last_overriding() * * def reset_override(self): # <<<<<<<<<<<<<< @@ -5671,31 +5778,31 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_override", 0); - /* "dependency_injector/containers.pyx":185 + /* "dependency_injector/containers.pyx":191 * :rtype: None * """ * self.overridden = tuple() # <<<<<<<<<<<<<< * * for provider in six.itervalues(self.providers): */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 185, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 191, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_overridden, __pyx_t_1) < 0) __PYX_ERR(0, 185, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self, __pyx_n_s_overridden, __pyx_t_1) < 0) __PYX_ERR(0, 191, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":187 + /* "dependency_injector/containers.pyx":193 * self.overridden = tuple() * * for provider in six.itervalues(self.providers): # <<<<<<<<<<<<<< * provider.reset_override() * */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 187, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 193, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_itervalues); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 187, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_itervalues); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 193, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 187, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 193, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { @@ -5710,16 +5817,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_t_2) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 187, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 193, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_5 = 0; __pyx_t_6 = NULL; } else { - __pyx_t_5 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 187, __pyx_L1_error) + __pyx_t_5 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 193, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_6 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 187, __pyx_L1_error) + __pyx_t_6 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 193, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -5727,17 +5834,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 187, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 193, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 187, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 193, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 187, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 193, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 187, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 193, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -5747,7 +5854,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 187, __pyx_L1_error) + else __PYX_ERR(0, 193, __pyx_L1_error) } break; } @@ -5756,14 +5863,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":188 + /* "dependency_injector/containers.pyx":194 * * for provider in six.itervalues(self.providers): * provider.reset_override() # <<<<<<<<<<<<<< * * def wire(self, modules=None, packages=None): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_reset_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 188, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_reset_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 194, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -5777,12 +5884,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 188, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 194, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":187 + /* "dependency_injector/containers.pyx":193 * self.overridden = tuple() * * for provider in six.itervalues(self.providers): # <<<<<<<<<<<<<< @@ -5792,7 +5899,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":180 + /* "dependency_injector/containers.pyx":186 * provider.reset_last_overriding() * * def reset_override(self): # <<<<<<<<<<<<<< @@ -5817,7 +5924,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":190 +/* "dependency_injector/containers.pyx":196 * provider.reset_override() * * def wire(self, modules=None, packages=None): # <<<<<<<<<<<<<< @@ -5876,7 +5983,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "wire") < 0)) __PYX_ERR(0, 190, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "wire") < 0)) __PYX_ERR(0, 196, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -5895,7 +6002,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("wire", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 190, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("wire", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 196, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers.DynamicContainer.wire", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -5920,78 +6027,78 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("wire", 0); - /* "dependency_injector/containers.pyx":195 + /* "dependency_injector/containers.pyx":201 * :rtype: None * """ * wire( # <<<<<<<<<<<<<< * container=self, * modules=modules, */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_wire); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 195, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_wire); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 201, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/containers.pyx":196 + /* "dependency_injector/containers.pyx":202 * """ * wire( * container=self, # <<<<<<<<<<<<<< * modules=modules, * packages=packages, */ - __pyx_t_2 = __Pyx_PyDict_NewPresized(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 196, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyDict_NewPresized(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 202, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_container, __pyx_v_self) < 0) __PYX_ERR(0, 196, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_container, __pyx_v_self) < 0) __PYX_ERR(0, 202, __pyx_L1_error) - /* "dependency_injector/containers.pyx":197 + /* "dependency_injector/containers.pyx":203 * wire( * container=self, * modules=modules, # <<<<<<<<<<<<<< * packages=packages, * ) */ - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_modules, __pyx_v_modules) < 0) __PYX_ERR(0, 196, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_modules, __pyx_v_modules) < 0) __PYX_ERR(0, 202, __pyx_L1_error) - /* "dependency_injector/containers.pyx":198 + /* "dependency_injector/containers.pyx":204 * container=self, * modules=modules, * packages=packages, # <<<<<<<<<<<<<< * ) * */ - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_packages, __pyx_v_packages) < 0) __PYX_ERR(0, 196, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_packages, __pyx_v_packages) < 0) __PYX_ERR(0, 202, __pyx_L1_error) - /* "dependency_injector/containers.pyx":195 + /* "dependency_injector/containers.pyx":201 * :rtype: None * """ * wire( # <<<<<<<<<<<<<< * container=self, * modules=modules, */ - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 195, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 201, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":201 + /* "dependency_injector/containers.pyx":207 * ) * * if modules: # <<<<<<<<<<<<<< * self.wired_to_modules.extend(modules) * */ - __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_modules); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 201, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_modules); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 207, __pyx_L1_error) if (__pyx_t_4) { - /* "dependency_injector/containers.pyx":202 + /* "dependency_injector/containers.pyx":208 * * if modules: * self.wired_to_modules.extend(modules) # <<<<<<<<<<<<<< * * if packages: */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_modules); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 202, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_modules); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 208, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_extend); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 202, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_extend); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 208, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -6006,12 +6113,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_3 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_2, __pyx_v_modules) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_modules); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 202, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 208, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":201 + /* "dependency_injector/containers.pyx":207 * ) * * if modules: # <<<<<<<<<<<<<< @@ -6020,26 +6127,26 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ */ } - /* "dependency_injector/containers.pyx":204 + /* "dependency_injector/containers.pyx":210 * self.wired_to_modules.extend(modules) * * if packages: # <<<<<<<<<<<<<< * self.wired_to_packages.extend(packages) * */ - __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_packages); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 204, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_packages); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 210, __pyx_L1_error) if (__pyx_t_4) { - /* "dependency_injector/containers.pyx":205 + /* "dependency_injector/containers.pyx":211 * * if packages: * self.wired_to_packages.extend(packages) # <<<<<<<<<<<<<< * * def unwire(self): */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_packages); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 205, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_packages); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 211, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_extend); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 205, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_extend); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 211, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = NULL; @@ -6054,12 +6161,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_3 = (__pyx_t_1) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_1, __pyx_v_packages) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_packages); __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 205, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 211, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":204 + /* "dependency_injector/containers.pyx":210 * self.wired_to_modules.extend(modules) * * if packages: # <<<<<<<<<<<<<< @@ -6068,7 +6175,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ */ } - /* "dependency_injector/containers.pyx":190 + /* "dependency_injector/containers.pyx":196 * provider.reset_override() * * def wire(self, modules=None, packages=None): # <<<<<<<<<<<<<< @@ -6091,7 +6198,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":207 +/* "dependency_injector/containers.pyx":213 * self.wired_to_packages.extend(packages) * * def unwire(self): # <<<<<<<<<<<<<< @@ -6125,65 +6232,65 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("unwire", 0); - /* "dependency_injector/containers.pyx":209 + /* "dependency_injector/containers.pyx":215 * def unwire(self): * """Unwire container providers from previously wired packages and modules.""" * unwire( # <<<<<<<<<<<<<< * modules=self.wired_to_modules, * packages=self.wired_to_packages, */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_unwire); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 209, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_unwire); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 215, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/containers.pyx":210 + /* "dependency_injector/containers.pyx":216 * """Unwire container providers from previously wired packages and modules.""" * unwire( * modules=self.wired_to_modules, # <<<<<<<<<<<<<< * packages=self.wired_to_packages, * ) */ - __pyx_t_2 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 210, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 216, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_modules); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 210, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_modules); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 216, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_modules, __pyx_t_3) < 0) __PYX_ERR(0, 210, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_modules, __pyx_t_3) < 0) __PYX_ERR(0, 216, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":211 + /* "dependency_injector/containers.pyx":217 * unwire( * modules=self.wired_to_modules, * packages=self.wired_to_packages, # <<<<<<<<<<<<<< * ) * */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_packages); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 211, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_packages); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 217, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_packages, __pyx_t_3) < 0) __PYX_ERR(0, 210, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_packages, __pyx_t_3) < 0) __PYX_ERR(0, 216, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":209 + /* "dependency_injector/containers.pyx":215 * def unwire(self): * """Unwire container providers from previously wired packages and modules.""" * unwire( # <<<<<<<<<<<<<< * modules=self.wired_to_modules, * packages=self.wired_to_packages, */ - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 209, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 215, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":214 + /* "dependency_injector/containers.pyx":220 * ) * * self.wired_to_modules.clear() # <<<<<<<<<<<<<< * self.wired_to_packages.clear() * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_modules); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 214, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_modules); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 220, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_clear); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 214, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_clear); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 220, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -6198,21 +6305,21 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_3 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 214, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 220, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":215 + /* "dependency_injector/containers.pyx":221 * * self.wired_to_modules.clear() * self.wired_to_packages.clear() # <<<<<<<<<<<<<< * * def init_resources(self): */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_packages); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 215, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_wired_to_packages); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 221, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_clear); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 215, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_clear); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 221, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = NULL; @@ -6227,12 +6334,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_3 = (__pyx_t_1) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_1) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 215, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 221, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":207 + /* "dependency_injector/containers.pyx":213 * self.wired_to_packages.extend(packages) * * def unwire(self): # <<<<<<<<<<<<<< @@ -6255,12 +6362,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ return __pyx_r; } -/* "dependency_injector/containers.pyx":217 +/* "dependency_injector/containers.pyx":223 * self.wired_to_packages.clear() * * def init_resources(self): # <<<<<<<<<<<<<< * """Initialize all container resources.""" - * for provider in self.providers.values(): + * futures = [] */ /* Python wrapper */ @@ -6279,7 +6386,9 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_ } static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_22init_resources(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_self) { + PyObject *__pyx_v_futures = NULL; PyObject *__pyx_v_provider = NULL; + PyObject *__pyx_v_resource = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -6290,215 +6399,27 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ int __pyx_t_6; int __pyx_t_7; PyObject *__pyx_t_8 = NULL; + int __pyx_t_9; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("init_resources", 0); - /* "dependency_injector/containers.pyx":219 + /* "dependency_injector/containers.pyx":225 * def init_resources(self): * """Initialize all container resources.""" - * for provider in self.providers.values(): # <<<<<<<<<<<<<< + * futures = [] # <<<<<<<<<<<<<< + * for provider in self.providers.values(): * if not isinstance(provider, Resource): - * continue */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 219, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_values); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 219, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { - __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); - if (likely(__pyx_t_2)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); - __Pyx_INCREF(__pyx_t_2); - __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_3, function); - } - } - __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); - __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 219, __pyx_L1_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 225, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { - __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0; - __pyx_t_5 = NULL; - } else { - __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 219, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 219, __pyx_L1_error) - } - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - for (;;) { - if (likely(!__pyx_t_5)) { - if (likely(PyList_CheckExact(__pyx_t_3))) { - if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_3)) break; - #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 219, __pyx_L1_error) - #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 219, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - #endif - } else { - if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_3)) break; - #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 219, __pyx_L1_error) - #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 219, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - #endif - } - } else { - __pyx_t_1 = __pyx_t_5(__pyx_t_3); - if (unlikely(!__pyx_t_1)) { - PyObject* exc_type = PyErr_Occurred(); - if (exc_type) { - if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 219, __pyx_L1_error) - } - break; - } - __Pyx_GOTREF(__pyx_t_1); - } - __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_1); - __pyx_t_1 = 0; - - /* "dependency_injector/containers.pyx":220 - * """Initialize all container resources.""" - * for provider in self.providers.values(): - * if not isinstance(provider, Resource): # <<<<<<<<<<<<<< - * continue - * provider.init() - */ - __pyx_t_6 = __Pyx_TypeCheck(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Resource); - __pyx_t_7 = ((!(__pyx_t_6 != 0)) != 0); - if (__pyx_t_7) { - - /* "dependency_injector/containers.pyx":221 - * for provider in self.providers.values(): - * if not isinstance(provider, Resource): - * continue # <<<<<<<<<<<<<< - * provider.init() - * - */ - goto __pyx_L3_continue; - - /* "dependency_injector/containers.pyx":220 - * """Initialize all container resources.""" - * for provider in self.providers.values(): - * if not isinstance(provider, Resource): # <<<<<<<<<<<<<< - * continue - * provider.init() - */ - } - - /* "dependency_injector/containers.pyx":222 - * if not isinstance(provider, Resource): - * continue - * provider.init() # <<<<<<<<<<<<<< - * - * def shutdown_resources(self): - */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_init_2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 222, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_2); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); - __Pyx_INCREF(__pyx_t_8); - __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_2, function); - } - } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_8) : __Pyx_PyObject_CallNoArg(__pyx_t_2); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 222, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - - /* "dependency_injector/containers.pyx":219 - * def init_resources(self): - * """Initialize all container resources.""" - * for provider in self.providers.values(): # <<<<<<<<<<<<<< - * if not isinstance(provider, Resource): - * continue - */ - __pyx_L3_continue:; - } - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - - /* "dependency_injector/containers.pyx":217 - * self.wired_to_packages.clear() - * - * def init_resources(self): # <<<<<<<<<<<<<< - * """Initialize all container resources.""" - * for provider in self.providers.values(): - */ - - /* function exit code */ - __pyx_r = Py_None; __Pyx_INCREF(Py_None); - goto __pyx_L0; - __pyx_L1_error:; - __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_2); - __Pyx_XDECREF(__pyx_t_3); - __Pyx_XDECREF(__pyx_t_8); - __Pyx_AddTraceback("dependency_injector.containers.DynamicContainer.init_resources", __pyx_clineno, __pyx_lineno, __pyx_filename); - __pyx_r = NULL; - __pyx_L0:; - __Pyx_XDECREF(__pyx_v_provider); - __Pyx_XGIVEREF(__pyx_r); - __Pyx_RefNannyFinishContext(); - return __pyx_r; -} - -/* "dependency_injector/containers.pyx":224 - * provider.init() - * - * def shutdown_resources(self): # <<<<<<<<<<<<<< - * """Shutdown all container resources.""" - * for provider in self.providers.values(): - */ - -/* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_25shutdown_resources(PyObject *__pyx_self, PyObject *__pyx_v_self); /*proto*/ -static char __pyx_doc_19dependency_injector_10containers_16DynamicContainer_24shutdown_resources[] = "Shutdown all container resources."; -static PyMethodDef __pyx_mdef_19dependency_injector_10containers_16DynamicContainer_25shutdown_resources = {"shutdown_resources", (PyCFunction)__pyx_pw_19dependency_injector_10containers_16DynamicContainer_25shutdown_resources, METH_O, __pyx_doc_19dependency_injector_10containers_16DynamicContainer_24shutdown_resources}; -static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_25shutdown_resources(PyObject *__pyx_self, PyObject *__pyx_v_self) { - PyObject *__pyx_r = 0; - __Pyx_RefNannyDeclarations - __Pyx_RefNannySetupContext("shutdown_resources (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_10containers_16DynamicContainer_24shutdown_resources(__pyx_self, ((PyObject *)__pyx_v_self)); - - /* function exit code */ - __Pyx_RefNannyFinishContext(); - return __pyx_r; -} - -static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_24shutdown_resources(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_self) { - PyObject *__pyx_v_provider = NULL; - PyObject *__pyx_r = NULL; - __Pyx_RefNannyDeclarations - PyObject *__pyx_t_1 = NULL; - PyObject *__pyx_t_2 = NULL; - PyObject *__pyx_t_3 = NULL; - Py_ssize_t __pyx_t_4; - PyObject *(*__pyx_t_5)(PyObject *); - int __pyx_t_6; - int __pyx_t_7; - PyObject *__pyx_t_8 = NULL; - int __pyx_lineno = 0; - const char *__pyx_filename = NULL; - int __pyx_clineno = 0; - __Pyx_RefNannySetupContext("shutdown_resources", 0); + __pyx_v_futures = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; /* "dependency_injector/containers.pyx":226 - * def shutdown_resources(self): - * """Shutdown all container resources.""" + * """Initialize all container resources.""" + * futures = [] * for provider in self.providers.values(): # <<<<<<<<<<<<<< * if not isinstance(provider, Resource): * continue @@ -6567,11 +6488,11 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __pyx_t_1 = 0; /* "dependency_injector/containers.pyx":227 - * """Shutdown all container resources.""" + * futures = [] * for provider in self.providers.values(): * if not isinstance(provider, Resource): # <<<<<<<<<<<<<< * continue - * provider.shutdown() + * */ __pyx_t_6 = __Pyx_TypeCheck(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Resource); __pyx_t_7 = ((!(__pyx_t_6 != 0)) != 0); @@ -6581,28 +6502,28 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ * for provider in self.providers.values(): * if not isinstance(provider, Resource): * continue # <<<<<<<<<<<<<< - * provider.shutdown() * + * resource = provider.init() */ goto __pyx_L3_continue; /* "dependency_injector/containers.pyx":227 - * """Shutdown all container resources.""" + * futures = [] * for provider in self.providers.values(): * if not isinstance(provider, Resource): # <<<<<<<<<<<<<< * continue - * provider.shutdown() + * */ } - /* "dependency_injector/containers.pyx":229 - * if not isinstance(provider, Resource): + /* "dependency_injector/containers.pyx":230 * continue - * provider.shutdown() # <<<<<<<<<<<<<< * + * resource = provider.init() # <<<<<<<<<<<<<< * + * if _isawaitable(resource): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_shutdown); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 229, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_init_2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 230, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -6616,14 +6537,43 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_8) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 229, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 230, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF_SET(__pyx_v_resource, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/containers.pyx":232 + * resource = provider.init() + * + * if _isawaitable(resource): # <<<<<<<<<<<<<< + * futures.append(resource) + * + */ + __pyx_t_7 = (__pyx_f_19dependency_injector_10containers__isawaitable(__pyx_v_resource, 0) != 0); + if (__pyx_t_7) { + + /* "dependency_injector/containers.pyx":233 + * + * if _isawaitable(resource): + * futures.append(resource) # <<<<<<<<<<<<<< + * + * if futures: + */ + __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_futures, __pyx_v_resource); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 233, __pyx_L1_error) + + /* "dependency_injector/containers.pyx":232 + * resource = provider.init() + * + * if _isawaitable(resource): # <<<<<<<<<<<<<< + * futures.append(resource) + * + */ + } /* "dependency_injector/containers.pyx":226 - * def shutdown_resources(self): - * """Shutdown all container resources.""" + * """Initialize all container resources.""" + * futures = [] * for provider in self.providers.values(): # <<<<<<<<<<<<<< * if not isinstance(provider, Resource): * continue @@ -6632,12 +6582,343 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":224 - * provider.init() + /* "dependency_injector/containers.pyx":235 + * futures.append(resource) + * + * if futures: # <<<<<<<<<<<<<< + * return asyncio.gather(*futures) + * + */ + __pyx_t_7 = (PyList_GET_SIZE(__pyx_v_futures) != 0); + if (__pyx_t_7) { + + /* "dependency_injector/containers.pyx":236 + * + * if futures: + * return asyncio.gather(*futures) # <<<<<<<<<<<<<< + * + * def shutdown_resources(self): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 236, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_gather); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 236, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = PySequence_Tuple(__pyx_v_futures); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 236, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 236, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; + goto __pyx_L0; + + /* "dependency_injector/containers.pyx":235 + * futures.append(resource) + * + * if futures: # <<<<<<<<<<<<<< + * return asyncio.gather(*futures) + * + */ + } + + /* "dependency_injector/containers.pyx":223 + * self.wired_to_packages.clear() + * + * def init_resources(self): # <<<<<<<<<<<<<< + * """Initialize all container resources.""" + * futures = [] + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_AddTraceback("dependency_injector.containers.DynamicContainer.init_resources", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_futures); + __Pyx_XDECREF(__pyx_v_provider); + __Pyx_XDECREF(__pyx_v_resource); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/containers.pyx":238 + * return asyncio.gather(*futures) * * def shutdown_resources(self): # <<<<<<<<<<<<<< * """Shutdown all container resources.""" + * futures = [] + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_25shutdown_resources(PyObject *__pyx_self, PyObject *__pyx_v_self); /*proto*/ +static char __pyx_doc_19dependency_injector_10containers_16DynamicContainer_24shutdown_resources[] = "Shutdown all container resources."; +static PyMethodDef __pyx_mdef_19dependency_injector_10containers_16DynamicContainer_25shutdown_resources = {"shutdown_resources", (PyCFunction)__pyx_pw_19dependency_injector_10containers_16DynamicContainer_25shutdown_resources, METH_O, __pyx_doc_19dependency_injector_10containers_16DynamicContainer_24shutdown_resources}; +static PyObject *__pyx_pw_19dependency_injector_10containers_16DynamicContainer_25shutdown_resources(PyObject *__pyx_self, PyObject *__pyx_v_self) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("shutdown_resources (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_10containers_16DynamicContainer_24shutdown_resources(__pyx_self, ((PyObject *)__pyx_v_self)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_24shutdown_resources(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_self) { + PyObject *__pyx_v_futures = NULL; + PyObject *__pyx_v_provider = NULL; + PyObject *__pyx_v_shutdown = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + Py_ssize_t __pyx_t_4; + PyObject *(*__pyx_t_5)(PyObject *); + int __pyx_t_6; + int __pyx_t_7; + PyObject *__pyx_t_8 = NULL; + int __pyx_t_9; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("shutdown_resources", 0); + + /* "dependency_injector/containers.pyx":240 + * def shutdown_resources(self): + * """Shutdown all container resources.""" + * futures = [] # <<<<<<<<<<<<<< * for provider in self.providers.values(): + * if not isinstance(provider, Resource): + */ + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 240, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_futures = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/containers.pyx":241 + * """Shutdown all container resources.""" + * futures = [] + * for provider in self.providers.values(): # <<<<<<<<<<<<<< + * if not isinstance(provider, Resource): + * continue + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 241, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_values); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 241, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 241, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { + __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0; + __pyx_t_5 = NULL; + } else { + __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 241, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 241, __pyx_L1_error) + } + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + for (;;) { + if (likely(!__pyx_t_5)) { + if (likely(PyList_CheckExact(__pyx_t_3))) { + if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_3)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 241, __pyx_L1_error) + #else + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 241, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + #endif + } else { + if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_3)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 241, __pyx_L1_error) + #else + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 241, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + #endif + } + } else { + __pyx_t_1 = __pyx_t_5(__pyx_t_3); + if (unlikely(!__pyx_t_1)) { + PyObject* exc_type = PyErr_Occurred(); + if (exc_type) { + if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); + else __PYX_ERR(0, 241, __pyx_L1_error) + } + break; + } + __Pyx_GOTREF(__pyx_t_1); + } + __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/containers.pyx":242 + * futures = [] + * for provider in self.providers.values(): + * if not isinstance(provider, Resource): # <<<<<<<<<<<<<< + * continue + * + */ + __pyx_t_6 = __Pyx_TypeCheck(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Resource); + __pyx_t_7 = ((!(__pyx_t_6 != 0)) != 0); + if (__pyx_t_7) { + + /* "dependency_injector/containers.pyx":243 + * for provider in self.providers.values(): + * if not isinstance(provider, Resource): + * continue # <<<<<<<<<<<<<< + * + * shutdown = provider.shutdown() + */ + goto __pyx_L3_continue; + + /* "dependency_injector/containers.pyx":242 + * futures = [] + * for provider in self.providers.values(): + * if not isinstance(provider, Resource): # <<<<<<<<<<<<<< + * continue + * + */ + } + + /* "dependency_injector/containers.pyx":245 + * continue + * + * shutdown = provider.shutdown() # <<<<<<<<<<<<<< + * + * if _isawaitable(shutdown): + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_shutdown); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 245, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_8 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_8)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_8); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_8) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 245, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF_SET(__pyx_v_shutdown, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/containers.pyx":247 + * shutdown = provider.shutdown() + * + * if _isawaitable(shutdown): # <<<<<<<<<<<<<< + * futures.append(shutdown) + * + */ + __pyx_t_7 = (__pyx_f_19dependency_injector_10containers__isawaitable(__pyx_v_shutdown, 0) != 0); + if (__pyx_t_7) { + + /* "dependency_injector/containers.pyx":248 + * + * if _isawaitable(shutdown): + * futures.append(shutdown) # <<<<<<<<<<<<<< + * + * if futures: + */ + __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_futures, __pyx_v_shutdown); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 248, __pyx_L1_error) + + /* "dependency_injector/containers.pyx":247 + * shutdown = provider.shutdown() + * + * if _isawaitable(shutdown): # <<<<<<<<<<<<<< + * futures.append(shutdown) + * + */ + } + + /* "dependency_injector/containers.pyx":241 + * """Shutdown all container resources.""" + * futures = [] + * for provider in self.providers.values(): # <<<<<<<<<<<<<< + * if not isinstance(provider, Resource): + * continue + */ + __pyx_L3_continue:; + } + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/containers.pyx":250 + * futures.append(shutdown) + * + * if futures: # <<<<<<<<<<<<<< + * return asyncio.gather(*futures) + * + */ + __pyx_t_7 = (PyList_GET_SIZE(__pyx_v_futures) != 0); + if (__pyx_t_7) { + + /* "dependency_injector/containers.pyx":251 + * + * if futures: + * return asyncio.gather(*futures) # <<<<<<<<<<<<<< + * + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 251, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_gather); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 251, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = PySequence_Tuple(__pyx_v_futures); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 251, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 251, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; + goto __pyx_L0; + + /* "dependency_injector/containers.pyx":250 + * futures.append(shutdown) + * + * if futures: # <<<<<<<<<<<<<< + * return asyncio.gather(*futures) + * + */ + } + + /* "dependency_injector/containers.pyx":238 + * return asyncio.gather(*futures) + * + * def shutdown_resources(self): # <<<<<<<<<<<<<< + * """Shutdown all container resources.""" + * futures = [] */ /* function exit code */ @@ -6651,13 +6932,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_16DynamicContainer_ __Pyx_AddTraceback("dependency_injector.containers.DynamicContainer.shutdown_resources", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; + __Pyx_XDECREF(__pyx_v_futures); __Pyx_XDECREF(__pyx_v_provider); + __Pyx_XDECREF(__pyx_v_shutdown); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "dependency_injector/containers.pyx":235 +/* "dependency_injector/containers.pyx":257 * """Declarative inversion of control container meta class.""" * * def __new__(type mcs, str class_name, tuple bases, dict attributes): # <<<<<<<<<<<<<< @@ -6707,23 +6990,23 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_29DeclarativeContai case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_class_name)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__new__", 1, 4, 4, 1); __PYX_ERR(0, 235, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__new__", 1, 4, 4, 1); __PYX_ERR(0, 257, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 2: if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_bases)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__new__", 1, 4, 4, 2); __PYX_ERR(0, 235, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__new__", 1, 4, 4, 2); __PYX_ERR(0, 257, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 3: if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_attributes)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__new__", 1, 4, 4, 3); __PYX_ERR(0, 235, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__new__", 1, 4, 4, 3); __PYX_ERR(0, 257, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__new__") < 0)) __PYX_ERR(0, 235, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__new__") < 0)) __PYX_ERR(0, 257, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { goto __pyx_L5_argtuple_error; @@ -6740,16 +7023,16 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_29DeclarativeContai } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__new__", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 235, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__new__", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 257, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers.DeclarativeContainerMetaClass.__new__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_mcs), (&PyType_Type), 1, "mcs", 1))) __PYX_ERR(0, 235, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_class_name), (&PyString_Type), 1, "class_name", 1))) __PYX_ERR(0, 235, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_bases), (&PyTuple_Type), 1, "bases", 1))) __PYX_ERR(0, 235, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_attributes), (&PyDict_Type), 1, "attributes", 1))) __PYX_ERR(0, 235, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_mcs), (&PyType_Type), 1, "mcs", 1))) __PYX_ERR(0, 257, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_class_name), (&PyString_Type), 1, "class_name", 1))) __PYX_ERR(0, 257, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_bases), (&PyTuple_Type), 1, "bases", 1))) __PYX_ERR(0, 257, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_attributes), (&PyDict_Type), 1, "attributes", 1))) __PYX_ERR(0, 257, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_10containers_29DeclarativeContainerMetaClass___new__(__pyx_self, __pyx_v_mcs, __pyx_v_class_name, __pyx_v_bases, __pyx_v_attributes); /* function exit code */ @@ -6762,7 +7045,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_29DeclarativeContai } static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___2generator(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "dependency_injector/containers.pyx":241 +/* "dependency_injector/containers.pyx":263 * cdef type cls * * containers = tuple((name, container) # <<<<<<<<<<<<<< @@ -6782,7 +7065,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_1_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 241, __pyx_L1_error) + __PYX_ERR(0, 263, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -6790,7 +7073,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___2generator, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_DeclarativeContainerMetaClass, __pyx_n_s_dependency_injector_containers); if (unlikely(!gen)) __PYX_ERR(0, 241, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___2generator, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_DeclarativeContainerMetaClass, __pyx_n_s_dependency_injector_containers); if (unlikely(!gen)) __PYX_ERR(0, 263, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -6832,21 +7115,21 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 241, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 263, __pyx_L1_error) - /* "dependency_injector/containers.pyx":242 + /* "dependency_injector/containers.pyx":264 * * containers = tuple((name, container) * for name, container in six.iteritems(attributes) # <<<<<<<<<<<<<< * if is_container(container)) * */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 242, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 242, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_attributes)) { __Pyx_RaiseClosureNameError("attributes"); __PYX_ERR(0, 242, __pyx_L1_error) } + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_attributes)) { __Pyx_RaiseClosureNameError("attributes"); __PYX_ERR(0, 264, __pyx_L1_error) } __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); @@ -6859,16 +7142,16 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, __pyx_cur_scope->__pyx_outer_scope->__pyx_v_attributes) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_cur_scope->__pyx_outer_scope->__pyx_v_attributes); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 242, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0; __pyx_t_5 = NULL; } else { - __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 242, __pyx_L1_error) + __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 242, __pyx_L1_error) + __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 264, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -6876,17 +7159,17 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 242, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 264, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 242, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 242, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 264, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 242, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -6896,7 +7179,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 242, __pyx_L1_error) + else __PYX_ERR(0, 264, __pyx_L1_error) } break; } @@ -6908,7 +7191,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 242, __pyx_L1_error) + __PYX_ERR(0, 264, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -6921,15 +7204,15 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 242, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 242, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 242, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -6937,7 +7220,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_GOTREF(__pyx_t_2); index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L6_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 242, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 264, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L7_unpacking_done; @@ -6945,7 +7228,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 242, __pyx_L1_error) + __PYX_ERR(0, 264, __pyx_L1_error) __pyx_L7_unpacking_done:; } __Pyx_XGOTREF(__pyx_cur_scope->__pyx_v_name); @@ -6957,7 +7240,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_GIVEREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":243 + /* "dependency_injector/containers.pyx":265 * containers = tuple((name, container) * for name, container in six.iteritems(attributes) * if is_container(container)) # <<<<<<<<<<<<<< @@ -6967,14 +7250,14 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __pyx_t_9 = (__pyx_f_19dependency_injector_10containers_is_container(__pyx_cur_scope->__pyx_v_container, 0) != 0); if (__pyx_t_9) { - /* "dependency_injector/containers.pyx":241 + /* "dependency_injector/containers.pyx":263 * cdef type cls * * containers = tuple((name, container) # <<<<<<<<<<<<<< * for name, container in six.iteritems(attributes) * if is_container(container)) */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 241, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 263, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_cur_scope->__pyx_v_name); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_v_name); @@ -7000,9 +7283,9 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_XGOTREF(__pyx_t_3); __pyx_t_4 = __pyx_cur_scope->__pyx_t_1; __pyx_t_5 = __pyx_cur_scope->__pyx_t_2; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 241, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 263, __pyx_L1_error) - /* "dependency_injector/containers.pyx":243 + /* "dependency_injector/containers.pyx":265 * containers = tuple((name, container) * for name, container in six.iteritems(attributes) * if is_container(container)) # <<<<<<<<<<<<<< @@ -7011,7 +7294,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai */ } - /* "dependency_injector/containers.pyx":242 + /* "dependency_injector/containers.pyx":264 * * containers = tuple((name, container) * for name, container in six.iteritems(attributes) # <<<<<<<<<<<<<< @@ -7022,7 +7305,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; CYTHON_MAYBE_UNUSED_VAR(__pyx_cur_scope); - /* "dependency_injector/containers.pyx":241 + /* "dependency_injector/containers.pyx":263 * cdef type cls * * containers = tuple((name, container) # <<<<<<<<<<<<<< @@ -7052,7 +7335,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai } static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___5generator1(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "dependency_injector/containers.pyx":247 +/* "dependency_injector/containers.pyx":269 * attributes['containers'] = dict(containers) * * cls_providers = tuple((name, provider) # <<<<<<<<<<<<<< @@ -7072,7 +7355,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_2_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 247, __pyx_L1_error) + __PYX_ERR(0, 269, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -7080,7 +7363,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___5generator1, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_DeclarativeContainerMetaClass, __pyx_n_s_dependency_injector_containers); if (unlikely(!gen)) __PYX_ERR(0, 247, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___5generator1, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_DeclarativeContainerMetaClass, __pyx_n_s_dependency_injector_containers); if (unlikely(!gen)) __PYX_ERR(0, 269, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -7123,21 +7406,21 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 247, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 269, __pyx_L1_error) - /* "dependency_injector/containers.pyx":248 + /* "dependency_injector/containers.pyx":270 * * cls_providers = tuple((name, provider) * for name, provider in six.iteritems(attributes) # <<<<<<<<<<<<<< * if isinstance(provider, Provider)) * */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 248, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_attributes)) { __Pyx_RaiseClosureNameError("attributes"); __PYX_ERR(0, 248, __pyx_L1_error) } + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_attributes)) { __Pyx_RaiseClosureNameError("attributes"); __PYX_ERR(0, 270, __pyx_L1_error) } __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); @@ -7150,16 +7433,16 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, __pyx_cur_scope->__pyx_outer_scope->__pyx_v_attributes) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_cur_scope->__pyx_outer_scope->__pyx_v_attributes); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 248, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0; __pyx_t_5 = NULL; } else { - __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 270, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -7167,17 +7450,17 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 270, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 270, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -7187,7 +7470,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 248, __pyx_L1_error) + else __PYX_ERR(0, 270, __pyx_L1_error) } break; } @@ -7199,7 +7482,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 248, __pyx_L1_error) + __PYX_ERR(0, 270, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -7212,15 +7495,15 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -7228,7 +7511,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_GOTREF(__pyx_t_2); index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L6_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 248, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 270, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L7_unpacking_done; @@ -7236,7 +7519,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 248, __pyx_L1_error) + __PYX_ERR(0, 270, __pyx_L1_error) __pyx_L7_unpacking_done:; } __Pyx_XGOTREF(__pyx_cur_scope->__pyx_v_name); @@ -7248,7 +7531,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_GIVEREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":249 + /* "dependency_injector/containers.pyx":271 * cls_providers = tuple((name, provider) * for name, provider in six.iteritems(attributes) * if isinstance(provider, Provider)) # <<<<<<<<<<<<<< @@ -7259,14 +7542,14 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __pyx_t_10 = (__pyx_t_9 != 0); if (__pyx_t_10) { - /* "dependency_injector/containers.pyx":247 + /* "dependency_injector/containers.pyx":269 * attributes['containers'] = dict(containers) * * cls_providers = tuple((name, provider) # <<<<<<<<<<<<<< * for name, provider in six.iteritems(attributes) * if isinstance(provider, Provider)) */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 247, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 269, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_cur_scope->__pyx_v_name); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_v_name); @@ -7292,9 +7575,9 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_XGOTREF(__pyx_t_3); __pyx_t_4 = __pyx_cur_scope->__pyx_t_1; __pyx_t_5 = __pyx_cur_scope->__pyx_t_2; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 247, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 269, __pyx_L1_error) - /* "dependency_injector/containers.pyx":249 + /* "dependency_injector/containers.pyx":271 * cls_providers = tuple((name, provider) * for name, provider in six.iteritems(attributes) * if isinstance(provider, Provider)) # <<<<<<<<<<<<<< @@ -7303,7 +7586,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai */ } - /* "dependency_injector/containers.pyx":248 + /* "dependency_injector/containers.pyx":270 * * cls_providers = tuple((name, provider) * for name, provider in six.iteritems(attributes) # <<<<<<<<<<<<<< @@ -7314,7 +7597,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; CYTHON_MAYBE_UNUSED_VAR(__pyx_cur_scope); - /* "dependency_injector/containers.pyx":247 + /* "dependency_injector/containers.pyx":269 * attributes['containers'] = dict(containers) * * cls_providers = tuple((name, provider) # <<<<<<<<<<<<<< @@ -7344,7 +7627,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai } static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___8generator2(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "dependency_injector/containers.pyx":251 +/* "dependency_injector/containers.pyx":273 * if isinstance(provider, Provider)) * * inherited_providers = tuple((name, provider) # <<<<<<<<<<<<<< @@ -7364,7 +7647,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_3_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 251, __pyx_L1_error) + __PYX_ERR(0, 273, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -7372,7 +7655,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___8generator2, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_DeclarativeContainerMetaClass, __pyx_n_s_dependency_injector_containers); if (unlikely(!gen)) __PYX_ERR(0, 251, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___8generator2, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_DeclarativeContainerMetaClass, __pyx_n_s_dependency_injector_containers); if (unlikely(!gen)) __PYX_ERR(0, 273, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -7418,27 +7701,27 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 251, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 273, __pyx_L1_error) - /* "dependency_injector/containers.pyx":252 + /* "dependency_injector/containers.pyx":274 * * inherited_providers = tuple((name, provider) * for base in bases if is_container( # <<<<<<<<<<<<<< * base) and base is not DynamicContainer * for name, provider in six.iteritems( */ - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_bases)) { __Pyx_RaiseClosureNameError("bases"); __PYX_ERR(0, 252, __pyx_L1_error) } + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_bases)) { __Pyx_RaiseClosureNameError("bases"); __PYX_ERR(0, 274, __pyx_L1_error) } if (unlikely(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_bases == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 252, __pyx_L1_error) + __PYX_ERR(0, 274, __pyx_L1_error) } __pyx_t_1 = __pyx_cur_scope->__pyx_outer_scope->__pyx_v_bases; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyTuple_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 252, __pyx_L1_error) + __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 274, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 252, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 274, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XGOTREF(__pyx_cur_scope->__pyx_v_base); @@ -7446,7 +7729,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_GIVEREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":253 + /* "dependency_injector/containers.pyx":275 * inherited_providers = tuple((name, provider) * for base in bases if is_container( * base) and base is not DynamicContainer # <<<<<<<<<<<<<< @@ -7459,7 +7742,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __pyx_t_4 = __pyx_t_5; goto __pyx_L7_bool_binop_done; } - __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_DynamicContainer); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 253, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_DynamicContainer); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 275, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_5 = (__pyx_cur_scope->__pyx_v_base != __pyx_t_3); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -7467,7 +7750,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __pyx_t_4 = __pyx_t_6; __pyx_L7_bool_binop_done:; - /* "dependency_injector/containers.pyx":252 + /* "dependency_injector/containers.pyx":274 * * inherited_providers = tuple((name, provider) * for base in bases if is_container( # <<<<<<<<<<<<<< @@ -7476,27 +7759,27 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai */ if (__pyx_t_4) { - /* "dependency_injector/containers.pyx":254 + /* "dependency_injector/containers.pyx":276 * for base in bases if is_container( * base) and base is not DynamicContainer * for name, provider in six.iteritems( # <<<<<<<<<<<<<< * base.cls_providers)) * */ - __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_six); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 254, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_six); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 254, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/containers.pyx":255 + /* "dependency_injector/containers.pyx":277 * base) and base is not DynamicContainer * for name, provider in six.iteritems( * base.cls_providers)) # <<<<<<<<<<<<<< * * attributes['cls_providers'] = dict(cls_providers) */ - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_cur_scope->__pyx_v_base, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 255, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_cur_scope->__pyx_v_base, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 277, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_8))) { @@ -7511,11 +7794,11 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __pyx_t_3 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 254, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/containers.pyx":254 + /* "dependency_injector/containers.pyx":276 * for base in bases if is_container( * base) and base is not DynamicContainer * for name, provider in six.iteritems( # <<<<<<<<<<<<<< @@ -7526,9 +7809,9 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __pyx_t_8 = __pyx_t_3; __Pyx_INCREF(__pyx_t_8); __pyx_t_10 = 0; __pyx_t_11 = NULL; } else { - __pyx_t_10 = -1; __pyx_t_8 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 254, __pyx_L1_error) + __pyx_t_10 = -1; __pyx_t_8 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_11 = Py_TYPE(__pyx_t_8)->tp_iternext; if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 254, __pyx_L1_error) + __pyx_t_11 = Py_TYPE(__pyx_t_8)->tp_iternext; if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 276, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; for (;;) { @@ -7536,17 +7819,17 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai if (likely(PyList_CheckExact(__pyx_t_8))) { if (__pyx_t_10 >= PyList_GET_SIZE(__pyx_t_8)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyList_GET_ITEM(__pyx_t_8, __pyx_t_10); __Pyx_INCREF(__pyx_t_3); __pyx_t_10++; if (unlikely(0 < 0)) __PYX_ERR(0, 254, __pyx_L1_error) + __pyx_t_3 = PyList_GET_ITEM(__pyx_t_8, __pyx_t_10); __Pyx_INCREF(__pyx_t_3); __pyx_t_10++; if (unlikely(0 < 0)) __PYX_ERR(0, 276, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_8, __pyx_t_10); __pyx_t_10++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 254, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_8, __pyx_t_10); __pyx_t_10++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif } else { if (__pyx_t_10 >= PyTuple_GET_SIZE(__pyx_t_8)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_8, __pyx_t_10); __Pyx_INCREF(__pyx_t_3); __pyx_t_10++; if (unlikely(0 < 0)) __PYX_ERR(0, 254, __pyx_L1_error) + __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_8, __pyx_t_10); __Pyx_INCREF(__pyx_t_3); __pyx_t_10++; if (unlikely(0 < 0)) __PYX_ERR(0, 276, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_8, __pyx_t_10); __pyx_t_10++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 254, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_8, __pyx_t_10); __pyx_t_10++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif } @@ -7556,7 +7839,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 254, __pyx_L1_error) + else __PYX_ERR(0, 276, __pyx_L1_error) } break; } @@ -7568,7 +7851,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 254, __pyx_L1_error) + __PYX_ERR(0, 276, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -7581,15 +7864,15 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(__pyx_t_9); #else - __pyx_t_7 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 254, __pyx_L1_error) + __pyx_t_7 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __pyx_t_9 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 254, __pyx_L1_error) + __pyx_t_9 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); #endif __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else { Py_ssize_t index = -1; - __pyx_t_12 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 254, __pyx_L1_error) + __pyx_t_12 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_13 = Py_TYPE(__pyx_t_12)->tp_iternext; @@ -7597,7 +7880,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_GOTREF(__pyx_t_7); index = 1; __pyx_t_9 = __pyx_t_13(__pyx_t_12); if (unlikely(!__pyx_t_9)) goto __pyx_L11_unpacking_failed; __Pyx_GOTREF(__pyx_t_9); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_13(__pyx_t_12), 2) < 0) __PYX_ERR(0, 254, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_13(__pyx_t_12), 2) < 0) __PYX_ERR(0, 276, __pyx_L1_error) __pyx_t_13 = NULL; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; goto __pyx_L12_unpacking_done; @@ -7605,7 +7888,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __pyx_t_13 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 254, __pyx_L1_error) + __PYX_ERR(0, 276, __pyx_L1_error) __pyx_L12_unpacking_done:; } __Pyx_XGOTREF(__pyx_cur_scope->__pyx_v_name); @@ -7617,14 +7900,14 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_GIVEREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/containers.pyx":251 + /* "dependency_injector/containers.pyx":273 * if isinstance(provider, Provider)) * * inherited_providers = tuple((name, provider) # <<<<<<<<<<<<<< * for base in bases if is_container( * base) and base is not DynamicContainer */ - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 251, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_cur_scope->__pyx_v_name); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_v_name); @@ -7657,9 +7940,9 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_XGOTREF(__pyx_t_8); __pyx_t_10 = __pyx_cur_scope->__pyx_t_3; __pyx_t_11 = __pyx_cur_scope->__pyx_t_4; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 251, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 273, __pyx_L1_error) - /* "dependency_injector/containers.pyx":254 + /* "dependency_injector/containers.pyx":276 * for base in bases if is_container( * base) and base is not DynamicContainer * for name, provider in six.iteritems( # <<<<<<<<<<<<<< @@ -7669,7 +7952,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai } __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/containers.pyx":252 + /* "dependency_injector/containers.pyx":274 * * inherited_providers = tuple((name, provider) * for base in bases if is_container( # <<<<<<<<<<<<<< @@ -7681,7 +7964,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; CYTHON_MAYBE_UNUSED_VAR(__pyx_cur_scope); - /* "dependency_injector/containers.pyx":251 + /* "dependency_injector/containers.pyx":273 * if isinstance(provider, Provider)) * * inherited_providers = tuple((name, provider) # <<<<<<<<<<<<<< @@ -7711,7 +7994,7 @@ static PyObject *__pyx_gb_19dependency_injector_10containers_29DeclarativeContai return __pyx_r; } -/* "dependency_injector/containers.pyx":235 +/* "dependency_injector/containers.pyx":257 * """Declarative inversion of control container meta class.""" * * def __new__(type mcs, str class_name, tuple bases, dict attributes): # <<<<<<<<<<<<<< @@ -7743,7 +8026,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct____new__ *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 235, __pyx_L1_error) + __PYX_ERR(0, 257, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -7754,126 +8037,126 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __Pyx_INCREF(__pyx_cur_scope->__pyx_v_attributes); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_v_attributes); - /* "dependency_injector/containers.pyx":241 + /* "dependency_injector/containers.pyx":263 * cdef type cls * * containers = tuple((name, container) # <<<<<<<<<<<<<< * for name, container in six.iteritems(attributes) * if is_container(container)) */ - __pyx_t_1 = __pyx_pf_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 241, __pyx_L1_error) + __pyx_t_1 = __pyx_pf_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 263, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PySequence_Tuple(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 241, __pyx_L1_error) + __pyx_t_2 = __Pyx_PySequence_Tuple(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 263, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_containers = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":245 + /* "dependency_injector/containers.pyx":267 * if is_container(container)) * * attributes['containers'] = dict(containers) # <<<<<<<<<<<<<< * * cls_providers = tuple((name, provider) */ - __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_v_containers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 245, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_v_containers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 267, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (unlikely(__pyx_cur_scope->__pyx_v_attributes == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 245, __pyx_L1_error) + __PYX_ERR(0, 267, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_cur_scope->__pyx_v_attributes, __pyx_n_s_containers, __pyx_t_2) < 0)) __PYX_ERR(0, 245, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_cur_scope->__pyx_v_attributes, __pyx_n_s_containers, __pyx_t_2) < 0)) __PYX_ERR(0, 267, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":247 + /* "dependency_injector/containers.pyx":269 * attributes['containers'] = dict(containers) * * cls_providers = tuple((name, provider) # <<<<<<<<<<<<<< * for name, provider in six.iteritems(attributes) * if isinstance(provider, Provider)) */ - __pyx_t_2 = __pyx_pf_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___3genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 247, __pyx_L1_error) + __pyx_t_2 = __pyx_pf_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___3genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 269, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PySequence_Tuple(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 247, __pyx_L1_error) + __pyx_t_1 = __Pyx_PySequence_Tuple(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 269, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_cls_providers = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":251 + /* "dependency_injector/containers.pyx":273 * if isinstance(provider, Provider)) * * inherited_providers = tuple((name, provider) # <<<<<<<<<<<<<< * for base in bases if is_container( * base) and base is not DynamicContainer */ - __pyx_t_1 = __pyx_pf_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___6genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 251, __pyx_L1_error) + __pyx_t_1 = __pyx_pf_19dependency_injector_10containers_29DeclarativeContainerMetaClass_7__new___6genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PySequence_Tuple(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 251, __pyx_L1_error) + __pyx_t_2 = __Pyx_PySequence_Tuple(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_inherited_providers = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":257 + /* "dependency_injector/containers.pyx":279 * base.cls_providers)) * * attributes['cls_providers'] = dict(cls_providers) # <<<<<<<<<<<<<< * attributes['inherited_providers'] = dict(inherited_providers) * attributes['providers'] = dict(cls_providers + inherited_providers) */ - __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_v_cls_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 257, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_v_cls_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 279, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (unlikely(__pyx_cur_scope->__pyx_v_attributes == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 257, __pyx_L1_error) + __PYX_ERR(0, 279, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_cur_scope->__pyx_v_attributes, __pyx_n_s_cls_providers, __pyx_t_2) < 0)) __PYX_ERR(0, 257, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_cur_scope->__pyx_v_attributes, __pyx_n_s_cls_providers, __pyx_t_2) < 0)) __PYX_ERR(0, 279, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":258 + /* "dependency_injector/containers.pyx":280 * * attributes['cls_providers'] = dict(cls_providers) * attributes['inherited_providers'] = dict(inherited_providers) # <<<<<<<<<<<<<< * attributes['providers'] = dict(cls_providers + inherited_providers) * */ - __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_v_inherited_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 258, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_v_inherited_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 280, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (unlikely(__pyx_cur_scope->__pyx_v_attributes == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 258, __pyx_L1_error) + __PYX_ERR(0, 280, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_cur_scope->__pyx_v_attributes, __pyx_n_s_inherited_providers, __pyx_t_2) < 0)) __PYX_ERR(0, 258, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_cur_scope->__pyx_v_attributes, __pyx_n_s_inherited_providers, __pyx_t_2) < 0)) __PYX_ERR(0, 280, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":259 + /* "dependency_injector/containers.pyx":281 * attributes['cls_providers'] = dict(cls_providers) * attributes['inherited_providers'] = dict(inherited_providers) * attributes['providers'] = dict(cls_providers + inherited_providers) # <<<<<<<<<<<<<< * * cls = type.__new__(mcs, class_name, bases, attributes) */ - __pyx_t_2 = PyNumber_Add(__pyx_v_cls_providers, __pyx_v_inherited_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 259, __pyx_L1_error) + __pyx_t_2 = PyNumber_Add(__pyx_v_cls_providers, __pyx_v_inherited_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 281, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 259, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 281, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (unlikely(__pyx_cur_scope->__pyx_v_attributes == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 259, __pyx_L1_error) + __PYX_ERR(0, 281, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_cur_scope->__pyx_v_attributes, __pyx_n_s_providers, __pyx_t_1) < 0)) __PYX_ERR(0, 259, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_cur_scope->__pyx_v_attributes, __pyx_n_s_providers, __pyx_t_1) < 0)) __PYX_ERR(0, 281, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":261 + /* "dependency_injector/containers.pyx":283 * attributes['providers'] = dict(cls_providers + inherited_providers) * * cls = type.__new__(mcs, class_name, bases, attributes) # <<<<<<<<<<<<<< * * for provider in six.itervalues(cls.providers): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)(&PyType_Type)), __pyx_n_s_new); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 261, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)(&PyType_Type)), __pyx_n_s_new); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 283, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; __pyx_t_4 = 0; @@ -7890,7 +8173,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[5] = {__pyx_t_3, ((PyObject *)__pyx_v_mcs), __pyx_v_class_name, __pyx_cur_scope->__pyx_v_bases, __pyx_cur_scope->__pyx_v_attributes}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_4, 4+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 261, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_4, 4+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 283, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -7898,13 +8181,13 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[5] = {__pyx_t_3, ((PyObject *)__pyx_v_mcs), __pyx_v_class_name, __pyx_cur_scope->__pyx_v_bases, __pyx_cur_scope->__pyx_v_attributes}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_4, 4+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 261, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_4, 4+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 283, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_5 = PyTuple_New(4+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 261, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(4+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 283, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (__pyx_t_3) { __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_3); __pyx_t_3 = NULL; @@ -7921,7 +8204,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __Pyx_INCREF(__pyx_cur_scope->__pyx_v_attributes); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_v_attributes); PyTuple_SET_ITEM(__pyx_t_5, 3+__pyx_t_4, __pyx_cur_scope->__pyx_v_attributes); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 261, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 283, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } @@ -7932,19 +8215,19 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __pyx_v_cls = ((PyTypeObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":263 + /* "dependency_injector/containers.pyx":285 * cls = type.__new__(mcs, class_name, bases, attributes) * * for provider in six.itervalues(cls.providers): # <<<<<<<<<<<<<< * _check_provider_type(cls, provider) * */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_six); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 263, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_six); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 285, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_itervalues); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 263, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_itervalues); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 285, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_cls), __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 263, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_cls), __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 285, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { @@ -7959,16 +8242,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_3, __pyx_t_1) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_1); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 263, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 285, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (likely(PyList_CheckExact(__pyx_t_2)) || PyTuple_CheckExact(__pyx_t_2)) { __pyx_t_5 = __pyx_t_2; __Pyx_INCREF(__pyx_t_5); __pyx_t_6 = 0; __pyx_t_7 = NULL; } else { - __pyx_t_6 = -1; __pyx_t_5 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 263, __pyx_L1_error) + __pyx_t_6 = -1; __pyx_t_5 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 285, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_7 = Py_TYPE(__pyx_t_5)->tp_iternext; if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 263, __pyx_L1_error) + __pyx_t_7 = Py_TYPE(__pyx_t_5)->tp_iternext; if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 285, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; for (;;) { @@ -7976,17 +8259,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai if (likely(PyList_CheckExact(__pyx_t_5))) { if (__pyx_t_6 >= PyList_GET_SIZE(__pyx_t_5)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_2 = PyList_GET_ITEM(__pyx_t_5, __pyx_t_6); __Pyx_INCREF(__pyx_t_2); __pyx_t_6++; if (unlikely(0 < 0)) __PYX_ERR(0, 263, __pyx_L1_error) + __pyx_t_2 = PyList_GET_ITEM(__pyx_t_5, __pyx_t_6); __Pyx_INCREF(__pyx_t_2); __pyx_t_6++; if (unlikely(0 < 0)) __PYX_ERR(0, 285, __pyx_L1_error) #else - __pyx_t_2 = PySequence_ITEM(__pyx_t_5, __pyx_t_6); __pyx_t_6++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 263, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(__pyx_t_5, __pyx_t_6); __pyx_t_6++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 285, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); #endif } else { if (__pyx_t_6 >= PyTuple_GET_SIZE(__pyx_t_5)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_2 = PyTuple_GET_ITEM(__pyx_t_5, __pyx_t_6); __Pyx_INCREF(__pyx_t_2); __pyx_t_6++; if (unlikely(0 < 0)) __PYX_ERR(0, 263, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_ITEM(__pyx_t_5, __pyx_t_6); __Pyx_INCREF(__pyx_t_2); __pyx_t_6++; if (unlikely(0 < 0)) __PYX_ERR(0, 285, __pyx_L1_error) #else - __pyx_t_2 = PySequence_ITEM(__pyx_t_5, __pyx_t_6); __pyx_t_6++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 263, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(__pyx_t_5, __pyx_t_6); __pyx_t_6++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 285, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); #endif } @@ -7996,7 +8279,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 263, __pyx_L1_error) + else __PYX_ERR(0, 285, __pyx_L1_error) } break; } @@ -8005,18 +8288,18 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":264 + /* "dependency_injector/containers.pyx":286 * * for provider in six.itervalues(cls.providers): * _check_provider_type(cls, provider) # <<<<<<<<<<<<<< * * return cls */ - __pyx_t_2 = __pyx_f_19dependency_injector_10containers__check_provider_type(((PyObject *)__pyx_v_cls), __pyx_v_provider, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 264, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_10containers__check_provider_type(((PyObject *)__pyx_v_cls), __pyx_v_provider, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 286, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":263 + /* "dependency_injector/containers.pyx":285 * cls = type.__new__(mcs, class_name, bases, attributes) * * for provider in six.itervalues(cls.providers): # <<<<<<<<<<<<<< @@ -8026,7 +8309,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/containers.pyx":266 + /* "dependency_injector/containers.pyx":288 * _check_provider_type(cls, provider) * * return cls # <<<<<<<<<<<<<< @@ -8038,7 +8321,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __pyx_r = ((PyObject *)__pyx_v_cls); goto __pyx_L0; - /* "dependency_injector/containers.pyx":235 + /* "dependency_injector/containers.pyx":257 * """Declarative inversion of control container meta class.""" * * def __new__(type mcs, str class_name, tuple bases, dict attributes): # <<<<<<<<<<<<<< @@ -8066,7 +8349,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai return __pyx_r; } -/* "dependency_injector/containers.pyx":268 +/* "dependency_injector/containers.pyx":290 * return cls * * def __setattr__(cls, str name, object value): # <<<<<<<<<<<<<< @@ -8113,17 +8396,17 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_29DeclarativeContai case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, 1); __PYX_ERR(0, 268, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, 1); __PYX_ERR(0, 290, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 2: if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, 2); __PYX_ERR(0, 268, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, 2); __PYX_ERR(0, 290, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__setattr__") < 0)) __PYX_ERR(0, 268, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__setattr__") < 0)) __PYX_ERR(0, 290, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; @@ -8138,13 +8421,13 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_29DeclarativeContai } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 268, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__setattr__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 290, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers.DeclarativeContainerMetaClass.__setattr__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyString_Type), 1, "name", 1))) __PYX_ERR(0, 268, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyString_Type), 1, "name", 1))) __PYX_ERR(0, 290, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_10containers_29DeclarativeContainerMetaClass_2__setattr__(__pyx_self, __pyx_v_cls, __pyx_v_name, __pyx_v_value); /* function exit code */ @@ -8171,7 +8454,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__setattr__", 0); - /* "dependency_injector/containers.pyx":282 + /* "dependency_injector/containers.pyx":304 * :rtype: None * """ * if isinstance(value, Provider): # <<<<<<<<<<<<<< @@ -8182,42 +8465,42 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __pyx_t_2 = (__pyx_t_1 != 0); if (__pyx_t_2) { - /* "dependency_injector/containers.pyx":283 + /* "dependency_injector/containers.pyx":305 * """ * if isinstance(value, Provider): * _check_provider_type(cls, value) # <<<<<<<<<<<<<< * cls.providers[name] = value * cls.cls_providers[name] = value */ - __pyx_t_3 = __pyx_f_19dependency_injector_10containers__check_provider_type(__pyx_v_cls, __pyx_v_value, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 283, __pyx_L1_error) + __pyx_t_3 = __pyx_f_19dependency_injector_10containers__check_provider_type(__pyx_v_cls, __pyx_v_value, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 305, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":284 + /* "dependency_injector/containers.pyx":306 * if isinstance(value, Provider): * _check_provider_type(cls, value) * cls.providers[name] = value # <<<<<<<<<<<<<< * cls.cls_providers[name] = value * super(DeclarativeContainerMetaClass, cls).__setattr__(name, value) */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 284, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 306, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (unlikely(PyObject_SetItem(__pyx_t_3, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 284, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_t_3, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 306, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":285 + /* "dependency_injector/containers.pyx":307 * _check_provider_type(cls, value) * cls.providers[name] = value * cls.cls_providers[name] = value # <<<<<<<<<<<<<< * super(DeclarativeContainerMetaClass, cls).__setattr__(name, value) * */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 285, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 307, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (unlikely(PyObject_SetItem(__pyx_t_3, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 285, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_t_3, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 307, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":282 + /* "dependency_injector/containers.pyx":304 * :rtype: None * """ * if isinstance(value, Provider): # <<<<<<<<<<<<<< @@ -8226,16 +8509,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai */ } - /* "dependency_injector/containers.pyx":286 + /* "dependency_injector/containers.pyx":308 * cls.providers[name] = value * cls.cls_providers[name] = value * super(DeclarativeContainerMetaClass, cls).__setattr__(name, value) # <<<<<<<<<<<<<< * * def __delattr__(cls, str name): */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_DeclarativeContainerMetaClass_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 286, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_DeclarativeContainerMetaClass_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 286, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4); @@ -8243,10 +8526,10 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __Pyx_GIVEREF(__pyx_v_cls); PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_v_cls); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_5, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 286, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_5, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_setattr); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 286, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_setattr); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; @@ -8264,7 +8547,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_name, __pyx_v_value}; - __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 286, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 308, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_3); } else @@ -8272,13 +8555,13 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_name, __pyx_v_value}; - __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 286, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 308, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_3); } else #endif { - __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 286, __pyx_L1_error) + __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -8289,14 +8572,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __Pyx_INCREF(__pyx_v_value); __Pyx_GIVEREF(__pyx_v_value); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_v_value); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 286, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":268 + /* "dependency_injector/containers.pyx":290 * return cls * * def __setattr__(cls, str name, object value): # <<<<<<<<<<<<<< @@ -8320,7 +8603,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai return __pyx_r; } -/* "dependency_injector/containers.pyx":288 +/* "dependency_injector/containers.pyx":310 * super(DeclarativeContainerMetaClass, cls).__setattr__(name, value) * * def __delattr__(cls, str name): # <<<<<<<<<<<<<< @@ -8364,11 +8647,11 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_29DeclarativeContai case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__delattr__", 1, 2, 2, 1); __PYX_ERR(0, 288, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__delattr__", 1, 2, 2, 1); __PYX_ERR(0, 310, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__delattr__") < 0)) __PYX_ERR(0, 288, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__delattr__") < 0)) __PYX_ERR(0, 310, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -8381,13 +8664,13 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_29DeclarativeContai } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__delattr__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 288, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__delattr__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 310, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers.DeclarativeContainerMetaClass.__delattr__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyString_Type), 1, "name", 1))) __PYX_ERR(0, 288, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyString_Type), 1, "name", 1))) __PYX_ERR(0, 310, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_10containers_29DeclarativeContainerMetaClass_4__delattr__(__pyx_self, __pyx_v_cls, __pyx_v_name); /* function exit code */ @@ -8413,16 +8696,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__delattr__", 0); - /* "dependency_injector/containers.pyx":299 + /* "dependency_injector/containers.pyx":321 * :rtype: None * """ * if name in cls.providers and name in cls.cls_providers: # <<<<<<<<<<<<<< * del cls.providers[name] * del cls.cls_providers[name] */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 299, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = (__Pyx_PySequence_ContainsTF(__pyx_v_name, __pyx_t_2, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 299, __pyx_L1_error) + __pyx_t_3 = (__Pyx_PySequence_ContainsTF(__pyx_v_name, __pyx_t_2, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 321, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_4 = (__pyx_t_3 != 0); if (__pyx_t_4) { @@ -8430,40 +8713,40 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __pyx_t_1 = __pyx_t_4; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 299, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = (__Pyx_PySequence_ContainsTF(__pyx_v_name, __pyx_t_2, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 299, __pyx_L1_error) + __pyx_t_4 = (__Pyx_PySequence_ContainsTF(__pyx_v_name, __pyx_t_2, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 321, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_3 = (__pyx_t_4 != 0); __pyx_t_1 = __pyx_t_3; __pyx_L4_bool_binop_done:; if (__pyx_t_1) { - /* "dependency_injector/containers.pyx":300 + /* "dependency_injector/containers.pyx":322 * """ * if name in cls.providers and name in cls.cls_providers: * del cls.providers[name] # <<<<<<<<<<<<<< * del cls.cls_providers[name] * super(DeclarativeContainerMetaClass, cls).__delattr__(name) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 300, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 322, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (unlikely(PyObject_DelItem(__pyx_t_2, __pyx_v_name) < 0)) __PYX_ERR(0, 300, __pyx_L1_error) + if (unlikely(PyObject_DelItem(__pyx_t_2, __pyx_v_name) < 0)) __PYX_ERR(0, 322, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":301 + /* "dependency_injector/containers.pyx":323 * if name in cls.providers and name in cls.cls_providers: * del cls.providers[name] * del cls.cls_providers[name] # <<<<<<<<<<<<<< * super(DeclarativeContainerMetaClass, cls).__delattr__(name) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 301, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (unlikely(PyObject_DelItem(__pyx_t_2, __pyx_v_name) < 0)) __PYX_ERR(0, 301, __pyx_L1_error) + if (unlikely(PyObject_DelItem(__pyx_t_2, __pyx_v_name) < 0)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":299 + /* "dependency_injector/containers.pyx":321 * :rtype: None * """ * if name in cls.providers and name in cls.cls_providers: # <<<<<<<<<<<<<< @@ -8472,16 +8755,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai */ } - /* "dependency_injector/containers.pyx":302 + /* "dependency_injector/containers.pyx":324 * del cls.providers[name] * del cls.cls_providers[name] * super(DeclarativeContainerMetaClass, cls).__delattr__(name) # <<<<<<<<<<<<<< * * */ - __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_DeclarativeContainerMetaClass_2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 302, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_DeclarativeContainerMetaClass_2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 324, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_6 = PyTuple_New(2); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 302, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 324, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); @@ -8489,10 +8772,10 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai __Pyx_GIVEREF(__pyx_v_cls); PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_v_cls); __pyx_t_5 = 0; - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_6, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 302, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_6, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 324, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_delattr); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 302, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_delattr); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 324, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -8507,12 +8790,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai } __pyx_t_2 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_5, __pyx_v_name) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_name); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 302, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 324, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":288 + /* "dependency_injector/containers.pyx":310 * super(DeclarativeContainerMetaClass, cls).__setattr__(name, value) * * def __delattr__(cls, str name): # <<<<<<<<<<<<<< @@ -8535,7 +8818,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_29DeclarativeContai return __pyx_r; } -/* "dependency_injector/containers.pyx":362 +/* "dependency_injector/containers.pyx":384 * """ * * def __new__(cls, **overriding_providers): # <<<<<<<<<<<<<< @@ -8577,7 +8860,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_20DeclarativeContai else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_overriding_providers, values, pos_args, "__new__") < 0)) __PYX_ERR(0, 362, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_overriding_providers, values, pos_args, "__new__") < 0)) __PYX_ERR(0, 384, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -8588,7 +8871,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_20DeclarativeContai } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__new__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 362, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__new__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 384, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_overriding_providers); __pyx_v_overriding_providers = 0; __Pyx_AddTraceback("dependency_injector.containers.DeclarativeContainer.__new__", __pyx_clineno, __pyx_lineno, __pyx_filename); @@ -8616,14 +8899,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__new__", 0); - /* "dependency_injector/containers.pyx":368 + /* "dependency_injector/containers.pyx":390 * :rtype: :py:class:`DynamicContainer` * """ * container = cls.instance_type() # <<<<<<<<<<<<<< * container.provider_type = cls.provider_type * container.declarative_parent = cls */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_instance_type); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 368, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_instance_type); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 390, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -8637,81 +8920,81 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 368, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 390, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_container = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":369 + /* "dependency_injector/containers.pyx":391 * """ * container = cls.instance_type() * container.provider_type = cls.provider_type # <<<<<<<<<<<<<< * container.declarative_parent = cls * container.set_providers(**deepcopy(cls.providers)) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_provider_type); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 369, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_provider_type); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 391, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (__Pyx_PyObject_SetAttrStr(__pyx_v_container, __pyx_n_s_provider_type, __pyx_t_1) < 0) __PYX_ERR(0, 369, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_container, __pyx_n_s_provider_type, __pyx_t_1) < 0) __PYX_ERR(0, 391, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":370 + /* "dependency_injector/containers.pyx":392 * container = cls.instance_type() * container.provider_type = cls.provider_type * container.declarative_parent = cls # <<<<<<<<<<<<<< * container.set_providers(**deepcopy(cls.providers)) * container.override_providers(**overriding_providers) */ - if (__Pyx_PyObject_SetAttrStr(__pyx_v_container, __pyx_n_s_declarative_parent, __pyx_v_cls) < 0) __PYX_ERR(0, 370, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_container, __pyx_n_s_declarative_parent, __pyx_v_cls) < 0) __PYX_ERR(0, 392, __pyx_L1_error) - /* "dependency_injector/containers.pyx":371 + /* "dependency_injector/containers.pyx":393 * container.provider_type = cls.provider_type * container.declarative_parent = cls * container.set_providers(**deepcopy(cls.providers)) # <<<<<<<<<<<<<< * container.override_providers(**overriding_providers) * return container */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_set_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 371, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_set_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 393, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 371, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 393, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 371, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 393, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (unlikely(__pyx_t_4 == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(0, 371, __pyx_L1_error) + __PYX_ERR(0, 393, __pyx_L1_error) } if (likely(PyDict_CheckExact(__pyx_t_4))) { - __pyx_t_2 = PyDict_Copy(__pyx_t_4); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 371, __pyx_L1_error) + __pyx_t_2 = PyDict_Copy(__pyx_t_4); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 393, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else { - __pyx_t_2 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 371, __pyx_L1_error) + __pyx_t_2 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 393, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 371, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 393, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":372 + /* "dependency_injector/containers.pyx":394 * container.declarative_parent = cls * container.set_providers(**deepcopy(cls.providers)) * container.override_providers(**overriding_providers) # <<<<<<<<<<<<<< * return container * */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_override_providers); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 372, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_override_providers); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 394, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_empty_tuple, __pyx_v_overriding_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 372, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_empty_tuple, __pyx_v_overriding_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 394, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":373 + /* "dependency_injector/containers.pyx":395 * container.set_providers(**deepcopy(cls.providers)) * container.override_providers(**overriding_providers) * return container # <<<<<<<<<<<<<< @@ -8723,7 +9006,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __pyx_r = __pyx_v_container; goto __pyx_L0; - /* "dependency_injector/containers.pyx":362 + /* "dependency_injector/containers.pyx":384 * """ * * def __new__(cls, **overriding_providers): # <<<<<<<<<<<<<< @@ -8746,7 +9029,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai return __pyx_r; } -/* "dependency_injector/containers.pyx":376 +/* "dependency_injector/containers.pyx":398 * * @classmethod * def override(cls, object overriding): # <<<<<<<<<<<<<< @@ -8790,11 +9073,11 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_20DeclarativeContai case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_overriding)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("override", 1, 2, 2, 1); __PYX_ERR(0, 376, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("override", 1, 2, 2, 1); __PYX_ERR(0, 398, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "override") < 0)) __PYX_ERR(0, 376, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "override") < 0)) __PYX_ERR(0, 398, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -8807,7 +9090,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_20DeclarativeContai } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("override", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 376, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("override", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 398, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers.DeclarativeContainer.override", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -8844,35 +9127,35 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/containers.pyx":387 + /* "dependency_injector/containers.pyx":409 * :rtype: None * """ * if issubclass(cls, overriding): # <<<<<<<<<<<<<< * raise Error('Container {0} could not be overridden ' * 'with itself or its subclasses'.format(cls)) */ - __pyx_t_1 = PyObject_IsSubclass(__pyx_v_cls, __pyx_v_overriding); if (unlikely(__pyx_t_1 == ((int)-1))) __PYX_ERR(0, 387, __pyx_L1_error) + __pyx_t_1 = PyObject_IsSubclass(__pyx_v_cls, __pyx_v_overriding); if (unlikely(__pyx_t_1 == ((int)-1))) __PYX_ERR(0, 409, __pyx_L1_error) __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/containers.pyx":388 + /* "dependency_injector/containers.pyx":410 * """ * if issubclass(cls, overriding): * raise Error('Container {0} could not be overridden ' # <<<<<<<<<<<<<< * 'with itself or its subclasses'.format(cls)) * */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 388, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 410, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/containers.pyx":389 + /* "dependency_injector/containers.pyx":411 * if issubclass(cls, overriding): * raise Error('Container {0} could not be overridden ' * 'with itself or its subclasses'.format(cls)) # <<<<<<<<<<<<<< * * cls.overridden += (overriding,) */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Container_0_could_not_be_overrid_2, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 389, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Container_0_could_not_be_overrid_2, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 411, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -8886,7 +9169,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, __pyx_v_cls) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_cls); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 389, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 411, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -8902,14 +9185,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 388, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 410, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(0, 388, __pyx_L1_error) + __PYX_ERR(0, 410, __pyx_L1_error) - /* "dependency_injector/containers.pyx":387 + /* "dependency_injector/containers.pyx":409 * :rtype: None * """ * if issubclass(cls, overriding): # <<<<<<<<<<<<<< @@ -8918,40 +9201,40 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai */ } - /* "dependency_injector/containers.pyx":391 + /* "dependency_injector/containers.pyx":413 * 'with itself or its subclasses'.format(cls)) * * cls.overridden += (overriding,) # <<<<<<<<<<<<<< * * for name, provider in six.iteritems(overriding.cls_providers): */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_overridden); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 391, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_overridden); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 391, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v_overriding); __Pyx_GIVEREF(__pyx_v_overriding); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_overriding); - __pyx_t_5 = PyNumber_InPlaceAdd(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 391, __pyx_L1_error) + __pyx_t_5 = PyNumber_InPlaceAdd(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (__Pyx_PyObject_SetAttrStr(__pyx_v_cls, __pyx_n_s_overridden, __pyx_t_5) < 0) __PYX_ERR(0, 391, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_cls, __pyx_n_s_overridden, __pyx_t_5) < 0) __PYX_ERR(0, 413, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/containers.pyx":393 + /* "dependency_injector/containers.pyx":415 * cls.overridden += (overriding,) * * for name, provider in six.iteritems(overriding.cls_providers): # <<<<<<<<<<<<<< * try: * getattr(cls, name).override(provider) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_six); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 393, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_six); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_overriding, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_overriding, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { @@ -8966,16 +9249,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __pyx_t_5 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_6, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 393, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) { __pyx_t_3 = __pyx_t_5; __Pyx_INCREF(__pyx_t_3); __pyx_t_8 = 0; __pyx_t_9 = NULL; } else { - __pyx_t_8 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_8 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_9 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_9 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 415, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; for (;;) { @@ -8983,17 +9266,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_8 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_5 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_8); __Pyx_INCREF(__pyx_t_5); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_5 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_8); __Pyx_INCREF(__pyx_t_5); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 415, __pyx_L1_error) #else - __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); #endif } else { if (__pyx_t_8 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_8); __Pyx_INCREF(__pyx_t_5); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_8); __Pyx_INCREF(__pyx_t_5); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 415, __pyx_L1_error) #else - __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); #endif } @@ -9003,7 +9286,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 393, __pyx_L1_error) + else __PYX_ERR(0, 415, __pyx_L1_error) } break; } @@ -9015,7 +9298,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 393, __pyx_L1_error) + __PYX_ERR(0, 415, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -9028,15 +9311,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_INCREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_4 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 393, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_10 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -9044,7 +9327,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_GOTREF(__pyx_t_4); index = 1; __pyx_t_6 = __pyx_t_10(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L6_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_7), 2) < 0) __PYX_ERR(0, 393, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_7), 2) < 0) __PYX_ERR(0, 415, __pyx_L1_error) __pyx_t_10 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L7_unpacking_done; @@ -9052,7 +9335,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_10 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 393, __pyx_L1_error) + __PYX_ERR(0, 415, __pyx_L1_error) __pyx_L7_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_4); @@ -9060,7 +9343,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":394 + /* "dependency_injector/containers.pyx":416 * * for name, provider in six.iteritems(overriding.cls_providers): * try: # <<<<<<<<<<<<<< @@ -9076,16 +9359,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_XGOTREF(__pyx_t_13); /*try:*/ { - /* "dependency_injector/containers.pyx":395 + /* "dependency_injector/containers.pyx":417 * for name, provider in six.iteritems(overriding.cls_providers): * try: * getattr(cls, name).override(provider) # <<<<<<<<<<<<<< * except AttributeError: * pass */ - __pyx_t_6 = __Pyx_GetAttr(__pyx_v_cls, __pyx_v_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 395, __pyx_L8_error) + __pyx_t_6 = __Pyx_GetAttr(__pyx_v_cls, __pyx_v_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 417, __pyx_L8_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 395, __pyx_L8_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 417, __pyx_L8_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -9100,12 +9383,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } __pyx_t_5 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_v_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_provider); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 395, __pyx_L8_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 417, __pyx_L8_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/containers.pyx":394 + /* "dependency_injector/containers.pyx":416 * * for name, provider in six.iteritems(overriding.cls_providers): * try: # <<<<<<<<<<<<<< @@ -9123,7 +9406,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/containers.pyx":396 + /* "dependency_injector/containers.pyx":418 * try: * getattr(cls, name).override(provider) * except AttributeError: # <<<<<<<<<<<<<< @@ -9138,7 +9421,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai goto __pyx_L10_except_error; __pyx_L10_except_error:; - /* "dependency_injector/containers.pyx":394 + /* "dependency_injector/containers.pyx":416 * * for name, provider in six.iteritems(overriding.cls_providers): * try: # <<<<<<<<<<<<<< @@ -9158,7 +9441,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __pyx_L15_try_end:; } - /* "dependency_injector/containers.pyx":393 + /* "dependency_injector/containers.pyx":415 * cls.overridden += (overriding,) * * for name, provider in six.iteritems(overriding.cls_providers): # <<<<<<<<<<<<<< @@ -9168,7 +9451,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":376 + /* "dependency_injector/containers.pyx":398 * * @classmethod * def override(cls, object overriding): # <<<<<<<<<<<<<< @@ -9195,7 +9478,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai return __pyx_r; } -/* "dependency_injector/containers.pyx":400 +/* "dependency_injector/containers.pyx":422 * * @classmethod * def reset_last_overriding(cls): # <<<<<<<<<<<<<< @@ -9236,30 +9519,30 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_last_overriding", 0); - /* "dependency_injector/containers.pyx":405 + /* "dependency_injector/containers.pyx":427 * :rtype: None * """ * if not cls.overridden: # <<<<<<<<<<<<<< * raise Error('Container {0} is not overridden'.format(cls)) * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_overridden); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 405, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_overridden); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 427, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 405, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 427, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = ((!__pyx_t_2) != 0); if (unlikely(__pyx_t_3)) { - /* "dependency_injector/containers.pyx":406 + /* "dependency_injector/containers.pyx":428 * """ * if not cls.overridden: * raise Error('Container {0} is not overridden'.format(cls)) # <<<<<<<<<<<<<< * * cls.overridden = cls.overridden[:-1] */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 406, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 428, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Container_0_is_not_overridden, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 406, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Container_0_is_not_overridden, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 428, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -9273,7 +9556,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, __pyx_v_cls) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_cls); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 406, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 428, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -9289,14 +9572,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 406, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 428, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(0, 406, __pyx_L1_error) + __PYX_ERR(0, 428, __pyx_L1_error) - /* "dependency_injector/containers.pyx":405 + /* "dependency_injector/containers.pyx":427 * :rtype: None * """ * if not cls.overridden: # <<<<<<<<<<<<<< @@ -9305,34 +9588,34 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai */ } - /* "dependency_injector/containers.pyx":408 + /* "dependency_injector/containers.pyx":430 * raise Error('Container {0} is not overridden'.format(cls)) * * cls.overridden = cls.overridden[:-1] # <<<<<<<<<<<<<< * * for provider in six.itervalues(cls.providers): */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_overridden); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 408, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_overridden); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 430, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_4 = __Pyx_PyObject_GetSlice(__pyx_t_1, 0, -1L, NULL, NULL, &__pyx_slice__2, 0, 1, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 408, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetSlice(__pyx_t_1, 0, -1L, NULL, NULL, &__pyx_slice__2, 0, 1, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 430, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (__Pyx_PyObject_SetAttrStr(__pyx_v_cls, __pyx_n_s_overridden, __pyx_t_4) < 0) __PYX_ERR(0, 408, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_cls, __pyx_n_s_overridden, __pyx_t_4) < 0) __PYX_ERR(0, 430, __pyx_L1_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":410 + /* "dependency_injector/containers.pyx":432 * cls.overridden = cls.overridden[:-1] * * for provider in six.itervalues(cls.providers): # <<<<<<<<<<<<<< * provider.reset_last_overriding() * */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_six); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 410, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_six); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 432, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_itervalues); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 410, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_itervalues); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 432, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 410, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 432, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { @@ -9347,16 +9630,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_t_1) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_1); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 410, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 432, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (likely(PyList_CheckExact(__pyx_t_4)) || PyTuple_CheckExact(__pyx_t_4)) { __pyx_t_5 = __pyx_t_4; __Pyx_INCREF(__pyx_t_5); __pyx_t_8 = 0; __pyx_t_9 = NULL; } else { - __pyx_t_8 = -1; __pyx_t_5 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 410, __pyx_L1_error) + __pyx_t_8 = -1; __pyx_t_5 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 432, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_9 = Py_TYPE(__pyx_t_5)->tp_iternext; if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 410, __pyx_L1_error) + __pyx_t_9 = Py_TYPE(__pyx_t_5)->tp_iternext; if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 432, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; for (;;) { @@ -9364,17 +9647,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai if (likely(PyList_CheckExact(__pyx_t_5))) { if (__pyx_t_8 >= PyList_GET_SIZE(__pyx_t_5)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_4 = PyList_GET_ITEM(__pyx_t_5, __pyx_t_8); __Pyx_INCREF(__pyx_t_4); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 410, __pyx_L1_error) + __pyx_t_4 = PyList_GET_ITEM(__pyx_t_5, __pyx_t_8); __Pyx_INCREF(__pyx_t_4); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 432, __pyx_L1_error) #else - __pyx_t_4 = PySequence_ITEM(__pyx_t_5, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 410, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(__pyx_t_5, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 432, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif } else { if (__pyx_t_8 >= PyTuple_GET_SIZE(__pyx_t_5)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_5, __pyx_t_8); __Pyx_INCREF(__pyx_t_4); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 410, __pyx_L1_error) + __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_5, __pyx_t_8); __Pyx_INCREF(__pyx_t_4); __pyx_t_8++; if (unlikely(0 < 0)) __PYX_ERR(0, 432, __pyx_L1_error) #else - __pyx_t_4 = PySequence_ITEM(__pyx_t_5, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 410, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(__pyx_t_5, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 432, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif } @@ -9384,7 +9667,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 410, __pyx_L1_error) + else __PYX_ERR(0, 432, __pyx_L1_error) } break; } @@ -9393,14 +9676,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":411 + /* "dependency_injector/containers.pyx":433 * * for provider in six.itervalues(cls.providers): * provider.reset_last_overriding() # <<<<<<<<<<<<<< * * @classmethod */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 411, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 433, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -9414,12 +9697,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 411, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 433, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":410 + /* "dependency_injector/containers.pyx":432 * cls.overridden = cls.overridden[:-1] * * for provider in six.itervalues(cls.providers): # <<<<<<<<<<<<<< @@ -9429,7 +9712,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/containers.pyx":400 + /* "dependency_injector/containers.pyx":422 * * @classmethod * def reset_last_overriding(cls): # <<<<<<<<<<<<<< @@ -9455,7 +9738,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai return __pyx_r; } -/* "dependency_injector/containers.pyx":414 +/* "dependency_injector/containers.pyx":436 * * @classmethod * def reset_override(cls): # <<<<<<<<<<<<<< @@ -9493,31 +9776,31 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_override", 0); - /* "dependency_injector/containers.pyx":419 + /* "dependency_injector/containers.pyx":441 * :rtype: None * """ * cls.overridden = tuple() # <<<<<<<<<<<<<< * * for provider in six.itervalues(cls.providers): */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 419, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 441, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (__Pyx_PyObject_SetAttrStr(__pyx_v_cls, __pyx_n_s_overridden, __pyx_t_1) < 0) __PYX_ERR(0, 419, __pyx_L1_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_cls, __pyx_n_s_overridden, __pyx_t_1) < 0) __PYX_ERR(0, 441, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":421 + /* "dependency_injector/containers.pyx":443 * cls.overridden = tuple() * * for provider in six.itervalues(cls.providers): # <<<<<<<<<<<<<< * provider.reset_override() * */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 421, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 443, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_itervalues); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 421, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_itervalues); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 443, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 421, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 443, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { @@ -9532,16 +9815,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_t_2) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 421, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 443, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_5 = 0; __pyx_t_6 = NULL; } else { - __pyx_t_5 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 421, __pyx_L1_error) + __pyx_t_5 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 443, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_6 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 421, __pyx_L1_error) + __pyx_t_6 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 443, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -9549,17 +9832,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 421, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 443, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 421, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 443, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 421, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 443, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 421, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 443, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -9569,7 +9852,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 421, __pyx_L1_error) + else __PYX_ERR(0, 443, __pyx_L1_error) } break; } @@ -9578,14 +9861,14 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":422 + /* "dependency_injector/containers.pyx":444 * * for provider in six.itervalues(cls.providers): * provider.reset_override() # <<<<<<<<<<<<<< * * @classmethod */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_reset_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 422, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_reset_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 444, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -9599,12 +9882,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 422, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 444, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":421 + /* "dependency_injector/containers.pyx":443 * cls.overridden = tuple() * * for provider in six.itervalues(cls.providers): # <<<<<<<<<<<<<< @@ -9614,7 +9897,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":414 + /* "dependency_injector/containers.pyx":436 * * @classmethod * def reset_override(cls): # <<<<<<<<<<<<<< @@ -9639,7 +9922,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai return __pyx_r; } -/* "dependency_injector/containers.pyx":425 +/* "dependency_injector/containers.pyx":447 * * @classmethod * def resolve_provider_name(cls, provider_to_resolve): # <<<<<<<<<<<<<< @@ -9683,11 +9966,11 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_20DeclarativeContai case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_provider_to_resolve)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("resolve_provider_name", 1, 2, 2, 1); __PYX_ERR(0, 425, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("resolve_provider_name", 1, 2, 2, 1); __PYX_ERR(0, 447, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "resolve_provider_name") < 0)) __PYX_ERR(0, 425, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "resolve_provider_name") < 0)) __PYX_ERR(0, 447, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -9700,7 +9983,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_20DeclarativeContai } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("resolve_provider_name", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 425, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("resolve_provider_name", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 447, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers.DeclarativeContainer.resolve_provider_name", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -9733,16 +10016,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai int __pyx_clineno = 0; __Pyx_RefNannySetupContext("resolve_provider_name", 0); - /* "dependency_injector/containers.pyx":427 + /* "dependency_injector/containers.pyx":449 * def resolve_provider_name(cls, provider_to_resolve): * """Try to resolve provider name by its instance.""" * for provider_name, container_provider in cls.providers.items(): # <<<<<<<<<<<<<< * if container_provider is provider_to_resolve: * return provider_name */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cls, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_items); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_items); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -9757,16 +10040,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 427, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0; __pyx_t_5 = NULL; } else { - __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_4 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_5 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 449, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -9774,17 +10057,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 449, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 449, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -9794,7 +10077,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 427, __pyx_L1_error) + else __PYX_ERR(0, 449, __pyx_L1_error) } break; } @@ -9806,7 +10089,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 427, __pyx_L1_error) + __PYX_ERR(0, 449, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -9819,15 +10102,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 427, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -9835,7 +10118,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_GOTREF(__pyx_t_2); index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 427, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 449, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L6_unpacking_done; @@ -9843,7 +10126,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 427, __pyx_L1_error) + __PYX_ERR(0, 449, __pyx_L1_error) __pyx_L6_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_provider_name, __pyx_t_2); @@ -9851,7 +10134,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_XDECREF_SET(__pyx_v_container_provider, __pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":428 + /* "dependency_injector/containers.pyx":450 * """Try to resolve provider name by its instance.""" * for provider_name, container_provider in cls.providers.items(): * if container_provider is provider_to_resolve: # <<<<<<<<<<<<<< @@ -9862,7 +10145,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __pyx_t_10 = (__pyx_t_9 != 0); if (__pyx_t_10) { - /* "dependency_injector/containers.pyx":429 + /* "dependency_injector/containers.pyx":451 * for provider_name, container_provider in cls.providers.items(): * if container_provider is provider_to_resolve: * return provider_name # <<<<<<<<<<<<<< @@ -9875,7 +10158,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/containers.pyx":428 + /* "dependency_injector/containers.pyx":450 * """Try to resolve provider name by its instance.""" * for provider_name, container_provider in cls.providers.items(): * if container_provider is provider_to_resolve: # <<<<<<<<<<<<<< @@ -9884,7 +10167,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai */ } - /* "dependency_injector/containers.pyx":427 + /* "dependency_injector/containers.pyx":449 * def resolve_provider_name(cls, provider_to_resolve): * """Try to resolve provider name by its instance.""" * for provider_name, container_provider in cls.providers.items(): # <<<<<<<<<<<<<< @@ -9894,7 +10177,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai } /*else*/ { - /* "dependency_injector/containers.pyx":431 + /* "dependency_injector/containers.pyx":453 * return provider_name * else: * return None # <<<<<<<<<<<<<< @@ -9907,7 +10190,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai goto __pyx_L0; } - /* "dependency_injector/containers.pyx":427 + /* "dependency_injector/containers.pyx":449 * def resolve_provider_name(cls, provider_to_resolve): * """Try to resolve provider name by its instance.""" * for provider_name, container_provider in cls.providers.items(): # <<<<<<<<<<<<<< @@ -9916,7 +10199,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai */ __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":425 + /* "dependency_injector/containers.pyx":447 * * @classmethod * def resolve_provider_name(cls, provider_to_resolve): # <<<<<<<<<<<<<< @@ -9941,7 +10224,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_20DeclarativeContai return __pyx_r; } -/* "dependency_injector/containers.pyx":434 +/* "dependency_injector/containers.pyx":456 * * * def override(object container): # <<<<<<<<<<<<<< @@ -9964,7 +10247,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_5override(PyObject return __pyx_r; } -/* "dependency_injector/containers.pyx":444 +/* "dependency_injector/containers.pyx":466 * :rtype: callable(:py:class:`DeclarativeContainer`) * """ * def _decorator(object overriding_container): # <<<<<<<<<<<<<< @@ -10002,15 +10285,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_8override__decorato __pyx_outer_scope = (struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_4_override *) __Pyx_CyFunction_GetClosure(__pyx_self); __pyx_cur_scope = __pyx_outer_scope; - /* "dependency_injector/containers.pyx":446 + /* "dependency_injector/containers.pyx":468 * def _decorator(object overriding_container): * """Overriding decorator.""" * container.override(overriding_container) # <<<<<<<<<<<<<< * return overriding_container * return _decorator */ - if (unlikely(!__pyx_cur_scope->__pyx_v_container)) { __Pyx_RaiseClosureNameError("container"); __PYX_ERR(0, 446, __pyx_L1_error) } - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_cur_scope->__pyx_v_container, __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 446, __pyx_L1_error) + if (unlikely(!__pyx_cur_scope->__pyx_v_container)) { __Pyx_RaiseClosureNameError("container"); __PYX_ERR(0, 468, __pyx_L1_error) } + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_cur_scope->__pyx_v_container, __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 468, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -10024,12 +10307,12 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_8override__decorato } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_overriding_container) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_overriding_container); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 446, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 468, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":447 + /* "dependency_injector/containers.pyx":469 * """Overriding decorator.""" * container.override(overriding_container) * return overriding_container # <<<<<<<<<<<<<< @@ -10041,7 +10324,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_8override__decorato __pyx_r = __pyx_v_overriding_container; goto __pyx_L0; - /* "dependency_injector/containers.pyx":444 + /* "dependency_injector/containers.pyx":466 * :rtype: callable(:py:class:`DeclarativeContainer`) * """ * def _decorator(object overriding_container): # <<<<<<<<<<<<<< @@ -10062,7 +10345,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_8override__decorato return __pyx_r; } -/* "dependency_injector/containers.pyx":434 +/* "dependency_injector/containers.pyx":456 * * * def override(object container): # <<<<<<<<<<<<<< @@ -10084,7 +10367,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4override(CYTHON_UN if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_4_override *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 434, __pyx_L1_error) + __PYX_ERR(0, 456, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -10092,19 +10375,19 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4override(CYTHON_UN __Pyx_INCREF(__pyx_cur_scope->__pyx_v_container); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_v_container); - /* "dependency_injector/containers.pyx":444 + /* "dependency_injector/containers.pyx":466 * :rtype: callable(:py:class:`DeclarativeContainer`) * """ * def _decorator(object overriding_container): # <<<<<<<<<<<<<< * """Overriding decorator.""" * container.override(overriding_container) */ - __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_8override_1_decorator, 0, __pyx_n_s_override_locals__decorator, ((PyObject*)__pyx_cur_scope), __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__4)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 444, __pyx_L1_error) + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_8override_1_decorator, 0, __pyx_n_s_override_locals__decorator, ((PyObject*)__pyx_cur_scope), __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__4)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 466, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v__decorator = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":448 + /* "dependency_injector/containers.pyx":470 * container.override(overriding_container) * return overriding_container * return _decorator # <<<<<<<<<<<<<< @@ -10116,7 +10399,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4override(CYTHON_UN __pyx_r = __pyx_v__decorator; goto __pyx_L0; - /* "dependency_injector/containers.pyx":434 + /* "dependency_injector/containers.pyx":456 * * * def override(object container): # <<<<<<<<<<<<<< @@ -10137,7 +10420,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4override(CYTHON_UN return __pyx_r; } -/* "dependency_injector/containers.pyx":451 +/* "dependency_injector/containers.pyx":473 * * * def copy(object container): # <<<<<<<<<<<<<< @@ -10160,7 +10443,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_7copy(PyObject *__p return __pyx_r; } -/* "dependency_injector/containers.pyx":464 +/* "dependency_injector/containers.pyx":486 * :rtype: callable(:py:class:`DeclarativeContainer`) * """ * def _decorator(copied_container): # <<<<<<<<<<<<<< @@ -10213,31 +10496,31 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __pyx_outer_scope = (struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_5_copy *) __Pyx_CyFunction_GetClosure(__pyx_self); __pyx_cur_scope = __pyx_outer_scope; - /* "dependency_injector/containers.pyx":465 + /* "dependency_injector/containers.pyx":487 * """ * def _decorator(copied_container): * cdef dict memo = dict() # <<<<<<<<<<<<<< * for name, provider in six.iteritems(copied_container.cls_providers): * try: */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 465, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 487, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_memo = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":466 + /* "dependency_injector/containers.pyx":488 * def _decorator(copied_container): * cdef dict memo = dict() * for name, provider in six.iteritems(copied_container.cls_providers): # <<<<<<<<<<<<<< * try: * source_provider = getattr(container, name) */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 466, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_six); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_copied_container, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_copied_container, __pyx_n_s_cls_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { @@ -10252,16 +10535,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_t_2) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 466, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_5 = 0; __pyx_t_6 = NULL; } else { - __pyx_t_5 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_5 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_6 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_6 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 488, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -10269,17 +10552,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 488, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 488, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -10289,7 +10572,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 466, __pyx_L1_error) + else __PYX_ERR(0, 488, __pyx_L1_error) } break; } @@ -10301,7 +10584,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 466, __pyx_L1_error) + __PYX_ERR(0, 488, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -10314,15 +10597,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(__pyx_t_4); #else - __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 466, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -10330,7 +10613,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __Pyx_GOTREF(__pyx_t_2); index = 1; __pyx_t_4 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_4)) goto __pyx_L5_unpacking_failed; __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 466, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 488, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L6_unpacking_done; @@ -10338,7 +10621,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 466, __pyx_L1_error) + __PYX_ERR(0, 488, __pyx_L1_error) __pyx_L6_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_2); @@ -10346,7 +10629,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":467 + /* "dependency_injector/containers.pyx":489 * cdef dict memo = dict() * for name, provider in six.iteritems(copied_container.cls_providers): * try: # <<<<<<<<<<<<<< @@ -10362,23 +10645,23 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { - /* "dependency_injector/containers.pyx":468 + /* "dependency_injector/containers.pyx":490 * for name, provider in six.iteritems(copied_container.cls_providers): * try: * source_provider = getattr(container, name) # <<<<<<<<<<<<<< * except AttributeError: * pass */ - if (unlikely(!__pyx_cur_scope->__pyx_v_container)) { __Pyx_RaiseClosureNameError("container"); __PYX_ERR(0, 468, __pyx_L7_error) } + if (unlikely(!__pyx_cur_scope->__pyx_v_container)) { __Pyx_RaiseClosureNameError("container"); __PYX_ERR(0, 490, __pyx_L7_error) } __pyx_t_1 = __pyx_cur_scope->__pyx_v_container; __Pyx_INCREF(__pyx_t_1); - __pyx_t_4 = __Pyx_GetAttr(__pyx_t_1, __pyx_v_name); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 468, __pyx_L7_error) + __pyx_t_4 = __Pyx_GetAttr(__pyx_t_1, __pyx_v_name); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 490, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF_SET(__pyx_v_source_provider, __pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":467 + /* "dependency_injector/containers.pyx":489 * cdef dict memo = dict() * for name, provider in six.iteritems(copied_container.cls_providers): * try: # <<<<<<<<<<<<<< @@ -10387,7 +10670,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py */ } - /* "dependency_injector/containers.pyx":472 + /* "dependency_injector/containers.pyx":494 * pass * else: * memo[id(source_provider)] = provider # <<<<<<<<<<<<<< @@ -10395,9 +10678,9 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py * providers_copy = deepcopy(container.providers, memo) */ /*else:*/ { - __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_v_source_provider); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 472, __pyx_L9_except_error) + __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_v_source_provider); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 494, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_4); - if (unlikely(PyDict_SetItem(__pyx_v_memo, __pyx_t_4, __pyx_v_provider) < 0)) __PYX_ERR(0, 472, __pyx_L9_except_error) + if (unlikely(PyDict_SetItem(__pyx_v_memo, __pyx_t_4, __pyx_v_provider) < 0)) __PYX_ERR(0, 494, __pyx_L9_except_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; @@ -10410,7 +10693,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/containers.pyx":469 + /* "dependency_injector/containers.pyx":491 * try: * source_provider = getattr(container, name) * except AttributeError: # <<<<<<<<<<<<<< @@ -10425,7 +10708,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py goto __pyx_L9_except_error; __pyx_L9_except_error:; - /* "dependency_injector/containers.pyx":467 + /* "dependency_injector/containers.pyx":489 * cdef dict memo = dict() * for name, provider in six.iteritems(copied_container.cls_providers): * try: # <<<<<<<<<<<<<< @@ -10445,7 +10728,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __pyx_L14_try_end:; } - /* "dependency_injector/containers.pyx":466 + /* "dependency_injector/containers.pyx":488 * def _decorator(copied_container): * cdef dict memo = dict() * for name, provider in six.iteritems(copied_container.cls_providers): # <<<<<<<<<<<<<< @@ -10455,34 +10738,34 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/containers.pyx":474 + /* "dependency_injector/containers.pyx":496 * memo[id(source_provider)] = provider * * providers_copy = deepcopy(container.providers, memo) # <<<<<<<<<<<<<< * for name, provider in six.iteritems(providers_copy): * setattr(copied_container, name, provider) */ - if (unlikely(!__pyx_cur_scope->__pyx_v_container)) { __Pyx_RaiseClosureNameError("container"); __PYX_ERR(0, 474, __pyx_L1_error) } - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_cur_scope->__pyx_v_container, __pyx_n_s_providers); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 474, __pyx_L1_error) + if (unlikely(!__pyx_cur_scope->__pyx_v_container)) { __Pyx_RaiseClosureNameError("container"); __PYX_ERR(0, 496, __pyx_L1_error) } + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_cur_scope->__pyx_v_container, __pyx_n_s_providers); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 496, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_13.__pyx_n = 1; __pyx_t_13.memo = __pyx_v_memo; - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 474, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 496, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_v_providers_copy = __pyx_t_4; __pyx_t_4 = 0; - /* "dependency_injector/containers.pyx":475 + /* "dependency_injector/containers.pyx":497 * * providers_copy = deepcopy(container.providers, memo) * for name, provider in six.iteritems(providers_copy): # <<<<<<<<<<<<<< * setattr(copied_container, name, provider) * */ - __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_six); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 475, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_six); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 475, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_iteritems); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -10497,16 +10780,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py } __pyx_t_4 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_3, __pyx_v_providers_copy) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_providers_copy); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 475, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; if (likely(PyList_CheckExact(__pyx_t_4)) || PyTuple_CheckExact(__pyx_t_4)) { __pyx_t_1 = __pyx_t_4; __Pyx_INCREF(__pyx_t_1); __pyx_t_5 = 0; __pyx_t_6 = NULL; } else { - __pyx_t_5 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 475, __pyx_L1_error) + __pyx_t_5 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_6 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 475, __pyx_L1_error) + __pyx_t_6 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 497, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; for (;;) { @@ -10514,17 +10797,17 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py if (likely(PyList_CheckExact(__pyx_t_1))) { if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_4 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_4); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 475, __pyx_L1_error) + __pyx_t_4 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_4); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 497, __pyx_L1_error) #else - __pyx_t_4 = PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 475, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif } else { if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_4); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 475, __pyx_L1_error) + __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_4); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 497, __pyx_L1_error) #else - __pyx_t_4 = PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 475, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif } @@ -10534,7 +10817,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 475, __pyx_L1_error) + else __PYX_ERR(0, 497, __pyx_L1_error) } break; } @@ -10546,7 +10829,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 475, __pyx_L1_error) + __PYX_ERR(0, 497, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -10559,15 +10842,15 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(__pyx_t_2); #else - __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 475, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_2 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 475, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); #endif __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 475, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -10575,7 +10858,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __Pyx_GOTREF(__pyx_t_3); index = 1; __pyx_t_2 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_2)) goto __pyx_L17_unpacking_failed; __Pyx_GOTREF(__pyx_t_2); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 475, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 497, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L18_unpacking_done; @@ -10583,7 +10866,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 475, __pyx_L1_error) + __PYX_ERR(0, 497, __pyx_L1_error) __pyx_L18_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_3); @@ -10591,16 +10874,16 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/containers.pyx":476 + /* "dependency_injector/containers.pyx":498 * providers_copy = deepcopy(container.providers, memo) * for name, provider in six.iteritems(providers_copy): * setattr(copied_container, name, provider) # <<<<<<<<<<<<<< * * return copied_container */ - __pyx_t_14 = PyObject_SetAttr(__pyx_v_copied_container, __pyx_v_name, __pyx_v_provider); if (unlikely(__pyx_t_14 == ((int)-1))) __PYX_ERR(0, 476, __pyx_L1_error) + __pyx_t_14 = PyObject_SetAttr(__pyx_v_copied_container, __pyx_v_name, __pyx_v_provider); if (unlikely(__pyx_t_14 == ((int)-1))) __PYX_ERR(0, 498, __pyx_L1_error) - /* "dependency_injector/containers.pyx":475 + /* "dependency_injector/containers.pyx":497 * * providers_copy = deepcopy(container.providers, memo) * for name, provider in six.iteritems(providers_copy): # <<<<<<<<<<<<<< @@ -10610,7 +10893,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":478 + /* "dependency_injector/containers.pyx":500 * setattr(copied_container, name, provider) * * return copied_container # <<<<<<<<<<<<<< @@ -10622,7 +10905,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py __pyx_r = __pyx_v_copied_container; goto __pyx_L0; - /* "dependency_injector/containers.pyx":464 + /* "dependency_injector/containers.pyx":486 * :rtype: callable(:py:class:`DeclarativeContainer`) * """ * def _decorator(copied_container): # <<<<<<<<<<<<<< @@ -10650,7 +10933,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_4copy__decorator(Py return __pyx_r; } -/* "dependency_injector/containers.pyx":451 +/* "dependency_injector/containers.pyx":473 * * * def copy(object container): # <<<<<<<<<<<<<< @@ -10672,7 +10955,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_6copy(CYTHON_UNUSED if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_19dependency_injector_10containers___pyx_scope_struct_5_copy *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 451, __pyx_L1_error) + __PYX_ERR(0, 473, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -10680,19 +10963,19 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_6copy(CYTHON_UNUSED __Pyx_INCREF(__pyx_cur_scope->__pyx_v_container); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_v_container); - /* "dependency_injector/containers.pyx":464 + /* "dependency_injector/containers.pyx":486 * :rtype: callable(:py:class:`DeclarativeContainer`) * """ * def _decorator(copied_container): # <<<<<<<<<<<<<< * cdef dict memo = dict() * for name, provider in six.iteritems(copied_container.cls_providers): */ - __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_4copy_1_decorator, 0, __pyx_n_s_copy_locals__decorator, ((PyObject*)__pyx_cur_scope), __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__6)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 464, __pyx_L1_error) + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_4copy_1_decorator, 0, __pyx_n_s_copy_locals__decorator, ((PyObject*)__pyx_cur_scope), __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__6)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 486, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v__decorator = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":479 + /* "dependency_injector/containers.pyx":501 * * return copied_container * return _decorator # <<<<<<<<<<<<<< @@ -10704,7 +10987,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_6copy(CYTHON_UNUSED __pyx_r = __pyx_v__decorator; goto __pyx_L0; - /* "dependency_injector/containers.pyx":451 + /* "dependency_injector/containers.pyx":473 * * * def copy(object container): # <<<<<<<<<<<<<< @@ -10725,7 +11008,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_6copy(CYTHON_UNUSED return __pyx_r; } -/* "dependency_injector/containers.pyx":482 +/* "dependency_injector/containers.pyx":504 * * * cpdef bint is_container(object instance): # <<<<<<<<<<<<<< @@ -10744,21 +11027,21 @@ static int __pyx_f_19dependency_injector_10containers_is_container(PyObject *__p int __pyx_clineno = 0; __Pyx_RefNannySetupContext("is_container", 0); - /* "dependency_injector/containers.pyx":490 + /* "dependency_injector/containers.pyx":512 * :rtype: bool * """ * return getattr(instance, '__IS_CONTAINER__', False) is True # <<<<<<<<<<<<<< * * */ - __pyx_t_1 = __Pyx_GetAttr3(__pyx_v_instance, __pyx_n_s_IS_CONTAINER, Py_False); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 490, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetAttr3(__pyx_v_instance, __pyx_n_s_IS_CONTAINER, Py_False); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 512, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = (__pyx_t_1 == Py_True); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; goto __pyx_L0; - /* "dependency_injector/containers.pyx":482 + /* "dependency_injector/containers.pyx":504 * * * cpdef bint is_container(object instance): # <<<<<<<<<<<<<< @@ -10799,7 +11082,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_8is_container(CYTHO int __pyx_clineno = 0; __Pyx_RefNannySetupContext("is_container", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_f_19dependency_injector_10containers_is_container(__pyx_v_instance, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 482, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_f_19dependency_injector_10containers_is_container(__pyx_v_instance, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 504, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -10816,7 +11099,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_8is_container(CYTHO return __pyx_r; } -/* "dependency_injector/containers.pyx":493 +/* "dependency_injector/containers.pyx":515 * * * cpdef object _check_provider_type(object container, object provider): # <<<<<<<<<<<<<< @@ -10843,37 +11126,40 @@ static PyObject *__pyx_f_19dependency_injector_10containers__check_provider_type int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_check_provider_type", 0); - /* "dependency_injector/containers.pyx":494 + /* "dependency_injector/containers.pyx":516 * * cpdef object _check_provider_type(object container, object provider): * if not isinstance(provider, container.provider_type): # <<<<<<<<<<<<<< * raise Error('{0} can contain only {1} ' * 'instances'.format(container, container.provider_type)) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_provider_type); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 494, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_provider_type); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 516, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyObject_IsInstance(__pyx_v_provider, __pyx_t_1); if (unlikely(__pyx_t_2 == ((int)-1))) __PYX_ERR(0, 494, __pyx_L1_error) + __pyx_t_2 = PyObject_IsInstance(__pyx_v_provider, __pyx_t_1); if (unlikely(__pyx_t_2 == ((int)-1))) __PYX_ERR(0, 516, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = ((!(__pyx_t_2 != 0)) != 0); if (unlikely(__pyx_t_3)) { - /* "dependency_injector/containers.pyx":495 + /* "dependency_injector/containers.pyx":517 * cpdef object _check_provider_type(object container, object provider): * if not isinstance(provider, container.provider_type): * raise Error('{0} can contain only {1} ' # <<<<<<<<<<<<<< * 'instances'.format(container, container.provider_type)) + * */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 495, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 517, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/containers.pyx":496 + /* "dependency_injector/containers.pyx":518 * if not isinstance(provider, container.provider_type): * raise Error('{0} can contain only {1} ' * 'instances'.format(container, container.provider_type)) # <<<<<<<<<<<<<< + * + * */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_contain_only_1_instances, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 496, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_contain_only_1_instances, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 518, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_provider_type); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 496, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_provider_type); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 518, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_9 = 0; @@ -10890,7 +11176,7 @@ static PyObject *__pyx_f_19dependency_injector_10containers__check_provider_type #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_v_container, __pyx_t_7}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 496, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 518, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; @@ -10899,14 +11185,14 @@ static PyObject *__pyx_f_19dependency_injector_10containers__check_provider_type #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_v_container, __pyx_t_7}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 496, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 518, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { - __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 496, __pyx_L1_error) + __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 518, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_8); __pyx_t_8 = NULL; @@ -10917,7 +11203,7 @@ static PyObject *__pyx_f_19dependency_injector_10containers__check_provider_type __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_9, __pyx_t_7); __pyx_t_7 = 0; - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 496, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 518, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } @@ -10935,14 +11221,14 @@ static PyObject *__pyx_f_19dependency_injector_10containers__check_provider_type __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 495, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 517, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(0, 495, __pyx_L1_error) + __PYX_ERR(0, 517, __pyx_L1_error) - /* "dependency_injector/containers.pyx":494 + /* "dependency_injector/containers.pyx":516 * * cpdef object _check_provider_type(object container, object provider): * if not isinstance(provider, container.provider_type): # <<<<<<<<<<<<<< @@ -10951,7 +11237,7 @@ static PyObject *__pyx_f_19dependency_injector_10containers__check_provider_type */ } - /* "dependency_injector/containers.pyx":493 + /* "dependency_injector/containers.pyx":515 * * * cpdef object _check_provider_type(object container, object provider): # <<<<<<<<<<<<<< @@ -11012,11 +11298,11 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_11_check_provider_t case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_provider)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_check_provider_type", 1, 2, 2, 1); __PYX_ERR(0, 493, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_check_provider_type", 1, 2, 2, 1); __PYX_ERR(0, 515, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_check_provider_type") < 0)) __PYX_ERR(0, 493, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_check_provider_type") < 0)) __PYX_ERR(0, 515, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -11029,7 +11315,7 @@ static PyObject *__pyx_pw_19dependency_injector_10containers_11_check_provider_t } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_check_provider_type", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 493, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_check_provider_type", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 515, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.containers._check_provider_type", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -11051,7 +11337,7 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_10_check_provider_t int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_check_provider_type", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_10containers__check_provider_type(__pyx_v_container, __pyx_v_provider, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 493, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_10containers__check_provider_type(__pyx_v_container, __pyx_v_provider, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 515, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -11068,7 +11354,206 @@ static PyObject *__pyx_pf_19dependency_injector_10containers_10_check_provider_t return __pyx_r; } -/* "providers.pxd":297 +/* "dependency_injector/containers.pyx":521 + * + * + * cpdef bint _isawaitable(object instance): # <<<<<<<<<<<<<< + * try: + * return inspect.isawaitable(instance) + */ + +static PyObject *__pyx_pw_19dependency_injector_10containers_13_isawaitable(PyObject *__pyx_self, PyObject *__pyx_v_instance); /*proto*/ +static int __pyx_f_19dependency_injector_10containers__isawaitable(PyObject *__pyx_v_instance, CYTHON_UNUSED int __pyx_skip_dispatch) { + int __pyx_r; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + int __pyx_t_8; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_isawaitable", 0); + + /* "dependency_injector/containers.pyx":522 + * + * cpdef bint _isawaitable(object instance): + * try: # <<<<<<<<<<<<<< + * return inspect.isawaitable(instance) + * except AttributeError: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); + __Pyx_XGOTREF(__pyx_t_1); + __Pyx_XGOTREF(__pyx_t_2); + __Pyx_XGOTREF(__pyx_t_3); + /*try:*/ { + + /* "dependency_injector/containers.pyx":523 + * cpdef bint _isawaitable(object instance): + * try: + * return inspect.isawaitable(instance) # <<<<<<<<<<<<<< + * except AttributeError: + * return False + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_inspect); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 523, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_isawaitable); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 523, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_6, function); + } + } + __pyx_t_4 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_5, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 523, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(0, 523, __pyx_L3_error) + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_r = __pyx_t_7; + goto __pyx_L7_try_return; + + /* "dependency_injector/containers.pyx":522 + * + * cpdef bint _isawaitable(object instance): + * try: # <<<<<<<<<<<<<< + * return inspect.isawaitable(instance) + * except AttributeError: + */ + } + __pyx_L3_error:; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + + /* "dependency_injector/containers.pyx":524 + * try: + * return inspect.isawaitable(instance) + * except AttributeError: # <<<<<<<<<<<<<< + * return False + */ + __pyx_t_8 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_AttributeError); + if (__pyx_t_8) { + __Pyx_AddTraceback("dependency_injector.containers._isawaitable", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_5) < 0) __PYX_ERR(0, 524, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_GOTREF(__pyx_t_6); + __Pyx_GOTREF(__pyx_t_5); + + /* "dependency_injector/containers.pyx":525 + * return inspect.isawaitable(instance) + * except AttributeError: + * return False # <<<<<<<<<<<<<< + */ + __pyx_r = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + goto __pyx_L6_except_return; + } + goto __pyx_L5_except_error; + __pyx_L5_except_error:; + + /* "dependency_injector/containers.pyx":522 + * + * cpdef bint _isawaitable(object instance): + * try: # <<<<<<<<<<<<<< + * return inspect.isawaitable(instance) + * except AttributeError: + */ + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L1_error; + __pyx_L7_try_return:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L0; + __pyx_L6_except_return:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L0; + } + + /* "dependency_injector/containers.pyx":521 + * + * + * cpdef bint _isawaitable(object instance): # <<<<<<<<<<<<<< + * try: + * return inspect.isawaitable(instance) + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_WriteUnraisable("dependency_injector.containers._isawaitable", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_r = 0; + __pyx_L0:; + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_10containers_13_isawaitable(PyObject *__pyx_self, PyObject *__pyx_v_instance); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_10containers_13_isawaitable(PyObject *__pyx_self, PyObject *__pyx_v_instance) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_isawaitable (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_10containers_12_isawaitable(__pyx_self, ((PyObject *)__pyx_v_instance)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_10containers_12_isawaitable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_instance) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_isawaitable", 0); + __Pyx_XDECREF(__pyx_r); + __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_f_19dependency_injector_10containers__isawaitable(__pyx_v_instance, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 521, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_AddTraceback("dependency_injector.containers._isawaitable", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "providers.pxd":303 * * # Inline helper functions * cdef inline object __get_name(NamedInjection self): # <<<<<<<<<<<<<< @@ -11081,7 +11566,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_na __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get_name", 0); - /* "providers.pxd":298 + /* "providers.pxd":304 * # Inline helper functions * cdef inline object __get_name(NamedInjection self): * return self.__name # <<<<<<<<<<<<<< @@ -11093,7 +11578,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_na __pyx_r = __pyx_v_self->__pyx___name; goto __pyx_L0; - /* "providers.pxd":297 + /* "providers.pxd":303 * * # Inline helper functions * cdef inline object __get_name(NamedInjection self): # <<<<<<<<<<<<<< @@ -11108,7 +11593,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_na return __pyx_r; } -/* "providers.pxd":301 +/* "providers.pxd":307 * * * cdef inline object __get_value(Injection self): # <<<<<<<<<<<<<< @@ -11128,7 +11613,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get_value", 0); - /* "providers.pxd":302 + /* "providers.pxd":308 * * cdef inline object __get_value(Injection self): * if self.__call == 0: # <<<<<<<<<<<<<< @@ -11138,7 +11623,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va __pyx_t_1 = ((__pyx_v_self->__pyx___call == 0) != 0); if (__pyx_t_1) { - /* "providers.pxd":303 + /* "providers.pxd":309 * cdef inline object __get_value(Injection self): * if self.__call == 0: * return self.__value # <<<<<<<<<<<<<< @@ -11150,7 +11635,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va __pyx_r = __pyx_v_self->__pyx___value; goto __pyx_L0; - /* "providers.pxd":302 + /* "providers.pxd":308 * * cdef inline object __get_value(Injection self): * if self.__call == 0: # <<<<<<<<<<<<<< @@ -11159,7 +11644,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va */ } - /* "providers.pxd":304 + /* "providers.pxd":310 * if self.__call == 0: * return self.__value * return self.__value() # <<<<<<<<<<<<<< @@ -11180,14 +11665,14 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 304, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 310, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "providers.pxd":301 + /* "providers.pxd":307 * * * cdef inline object __get_value(Injection self): # <<<<<<<<<<<<<< @@ -11208,7 +11693,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va return __pyx_r; } -/* "providers.pxd":307 +/* "providers.pxd":313 * * * cdef inline object __get_value_kwargs(Injection self, dict kwargs): # <<<<<<<<<<<<<< @@ -11226,7 +11711,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get_value_kwargs", 0); - /* "providers.pxd":308 + /* "providers.pxd":314 * * cdef inline object __get_value_kwargs(Injection self, dict kwargs): * if self.__call == 0: # <<<<<<<<<<<<<< @@ -11236,7 +11721,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va __pyx_t_1 = ((__pyx_v_self->__pyx___call == 0) != 0); if (__pyx_t_1) { - /* "providers.pxd":309 + /* "providers.pxd":315 * cdef inline object __get_value_kwargs(Injection self, dict kwargs): * if self.__call == 0: * return self.__value # <<<<<<<<<<<<<< @@ -11248,7 +11733,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va __pyx_r = __pyx_v_self->__pyx___value; goto __pyx_L0; - /* "providers.pxd":308 + /* "providers.pxd":314 * * cdef inline object __get_value_kwargs(Injection self, dict kwargs): * if self.__call == 0: # <<<<<<<<<<<<<< @@ -11257,7 +11742,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va */ } - /* "providers.pxd":310 + /* "providers.pxd":316 * if self.__call == 0: * return self.__value * return self.__value(**kwargs) # <<<<<<<<<<<<<< @@ -11267,15 +11752,15 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va __Pyx_XDECREF(__pyx_r); if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 310, __pyx_L1_error) + __PYX_ERR(1, 316, __pyx_L1_error) } - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_v_self->__pyx___value, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 310, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_v_self->__pyx___value, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 316, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "providers.pxd":307 + /* "providers.pxd":313 * * * cdef inline object __get_value_kwargs(Injection self, dict kwargs): # <<<<<<<<<<<<<< @@ -11294,7 +11779,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va return __pyx_r; } -/* "providers.pxd":313 +/* "providers.pxd":319 * * * cdef inline tuple __separate_prefixed_kwargs(dict kwargs): # <<<<<<<<<<<<<< @@ -11327,31 +11812,31 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__separate_prefixed_kwargs", 0); - /* "providers.pxd":314 + /* "providers.pxd":320 * * cdef inline tuple __separate_prefixed_kwargs(dict kwargs): * cdef dict plain_kwargs = {} # <<<<<<<<<<<<<< * cdef dict prefixed_kwargs = {} * */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 314, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 320, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_plain_kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "providers.pxd":315 + /* "providers.pxd":321 * cdef inline tuple __separate_prefixed_kwargs(dict kwargs): * cdef dict plain_kwargs = {} * cdef dict prefixed_kwargs = {} # <<<<<<<<<<<<<< * * for key, value in kwargs.items(): */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 315, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_prefixed_kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "providers.pxd":317 + /* "providers.pxd":323 * cdef dict prefixed_kwargs = {} * * for key, value in kwargs.items(): # <<<<<<<<<<<<<< @@ -11360,17 +11845,17 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa */ if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "items"); - __PYX_ERR(1, 317, __pyx_L1_error) + __PYX_ERR(1, 323, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_Items(__pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 317, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_Items(__pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; __pyx_t_4 = NULL; } else { - __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 317, __pyx_L1_error) + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 317, __pyx_L1_error) + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 323, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -11378,17 +11863,17 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 317, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 323, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 317, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 317, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 323, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 317, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -11398,7 +11883,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 317, __pyx_L1_error) + else __PYX_ERR(1, 323, __pyx_L1_error) } break; } @@ -11410,7 +11895,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(1, 317, __pyx_L1_error) + __PYX_ERR(1, 323, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -11423,15 +11908,15 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 317, __pyx_L1_error) + __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 317, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 317, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -11439,7 +11924,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __Pyx_GOTREF(__pyx_t_5); index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 317, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 323, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L6_unpacking_done; @@ -11447,7 +11932,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(1, 317, __pyx_L1_error) + __PYX_ERR(1, 323, __pyx_L1_error) __pyx_L6_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_key, __pyx_t_5); @@ -11455,27 +11940,27 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_6); __pyx_t_6 = 0; - /* "providers.pxd":318 + /* "providers.pxd":324 * * for key, value in kwargs.items(): * if '__' not in key: # <<<<<<<<<<<<<< * plain_kwargs[key] = value * continue */ - __pyx_t_9 = (__Pyx_PySequence_ContainsTF(__pyx_n_s__7, __pyx_v_key, Py_NE)); if (unlikely(__pyx_t_9 < 0)) __PYX_ERR(1, 318, __pyx_L1_error) + __pyx_t_9 = (__Pyx_PySequence_ContainsTF(__pyx_n_s__7, __pyx_v_key, Py_NE)); if (unlikely(__pyx_t_9 < 0)) __PYX_ERR(1, 324, __pyx_L1_error) __pyx_t_10 = (__pyx_t_9 != 0); if (__pyx_t_10) { - /* "providers.pxd":319 + /* "providers.pxd":325 * for key, value in kwargs.items(): * if '__' not in key: * plain_kwargs[key] = value # <<<<<<<<<<<<<< * continue * */ - if (unlikely(PyDict_SetItem(__pyx_v_plain_kwargs, __pyx_v_key, __pyx_v_value) < 0)) __PYX_ERR(1, 319, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_plain_kwargs, __pyx_v_key, __pyx_v_value) < 0)) __PYX_ERR(1, 325, __pyx_L1_error) - /* "providers.pxd":320 + /* "providers.pxd":326 * if '__' not in key: * plain_kwargs[key] = value * continue # <<<<<<<<<<<<<< @@ -11484,7 +11969,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa */ goto __pyx_L3_continue; - /* "providers.pxd":318 + /* "providers.pxd":324 * * for key, value in kwargs.items(): * if '__' not in key: # <<<<<<<<<<<<<< @@ -11493,14 +11978,14 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa */ } - /* "providers.pxd":322 + /* "providers.pxd":328 * continue * * index = key.index('__') # <<<<<<<<<<<<<< * prefix, name = key[:index], key[index+2:] * */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_key, __pyx_n_s_index); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 322, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_key, __pyx_n_s_index); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 328, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -11514,24 +11999,24 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa } __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_5, __pyx_n_s__7) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_n_s__7); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 322, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 328, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF_SET(__pyx_v_index, __pyx_t_1); __pyx_t_1 = 0; - /* "providers.pxd":323 + /* "providers.pxd":329 * * index = key.index('__') * prefix, name = key[:index], key[index+2:] # <<<<<<<<<<<<<< * * if prefix not in prefixed_kwargs: */ - __pyx_t_1 = __Pyx_PyObject_GetSlice(__pyx_v_key, 0, 0, NULL, &__pyx_v_index, NULL, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 323, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetSlice(__pyx_v_key, 0, 0, NULL, &__pyx_v_index, NULL, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 329, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_6 = __Pyx_PyInt_AddObjC(__pyx_v_index, __pyx_int_2, 2, 0, 0); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 323, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyInt_AddObjC(__pyx_v_index, __pyx_int_2, 2, 0, 0); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 329, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_5 = __Pyx_PyObject_GetSlice(__pyx_v_key, 0, 0, &__pyx_t_6, NULL, NULL, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 323, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetSlice(__pyx_v_key, 0, 0, &__pyx_t_6, NULL, NULL, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 329, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_1); @@ -11539,30 +12024,30 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_5); __pyx_t_5 = 0; - /* "providers.pxd":325 + /* "providers.pxd":331 * prefix, name = key[:index], key[index+2:] * * if prefix not in prefixed_kwargs: # <<<<<<<<<<<<<< * prefixed_kwargs[prefix] = {} * prefixed_kwargs[prefix][name] = value */ - __pyx_t_10 = (__Pyx_PyDict_ContainsTF(__pyx_v_prefix, __pyx_v_prefixed_kwargs, Py_NE)); if (unlikely(__pyx_t_10 < 0)) __PYX_ERR(1, 325, __pyx_L1_error) + __pyx_t_10 = (__Pyx_PyDict_ContainsTF(__pyx_v_prefix, __pyx_v_prefixed_kwargs, Py_NE)); if (unlikely(__pyx_t_10 < 0)) __PYX_ERR(1, 331, __pyx_L1_error) __pyx_t_9 = (__pyx_t_10 != 0); if (__pyx_t_9) { - /* "providers.pxd":326 + /* "providers.pxd":332 * * if prefix not in prefixed_kwargs: * prefixed_kwargs[prefix] = {} # <<<<<<<<<<<<<< * prefixed_kwargs[prefix][name] = value * */ - __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 326, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 332, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - if (unlikely(PyDict_SetItem(__pyx_v_prefixed_kwargs, __pyx_v_prefix, __pyx_t_5) < 0)) __PYX_ERR(1, 326, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_prefixed_kwargs, __pyx_v_prefix, __pyx_t_5) < 0)) __PYX_ERR(1, 332, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "providers.pxd":325 + /* "providers.pxd":331 * prefix, name = key[:index], key[index+2:] * * if prefix not in prefixed_kwargs: # <<<<<<<<<<<<<< @@ -11571,19 +12056,19 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa */ } - /* "providers.pxd":327 + /* "providers.pxd":333 * if prefix not in prefixed_kwargs: * prefixed_kwargs[prefix] = {} * prefixed_kwargs[prefix][name] = value # <<<<<<<<<<<<<< * * return plain_kwargs, prefixed_kwargs */ - __pyx_t_5 = __Pyx_PyDict_GetItem(__pyx_v_prefixed_kwargs, __pyx_v_prefix); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 327, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyDict_GetItem(__pyx_v_prefixed_kwargs, __pyx_v_prefix); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 333, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - if (unlikely(PyObject_SetItem(__pyx_t_5, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(1, 327, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_t_5, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(1, 333, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "providers.pxd":317 + /* "providers.pxd":323 * cdef dict prefixed_kwargs = {} * * for key, value in kwargs.items(): # <<<<<<<<<<<<<< @@ -11594,7 +12079,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "providers.pxd":329 + /* "providers.pxd":335 * prefixed_kwargs[prefix][name] = value * * return plain_kwargs, prefixed_kwargs # <<<<<<<<<<<<<< @@ -11602,7 +12087,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 329, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 335, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_plain_kwargs); __Pyx_GIVEREF(__pyx_v_plain_kwargs); @@ -11614,7 +12099,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __pyx_t_2 = 0; goto __pyx_L0; - /* "providers.pxd":313 + /* "providers.pxd":319 * * * cdef inline tuple __separate_prefixed_kwargs(dict kwargs): # <<<<<<<<<<<<<< @@ -11644,10 +12129,10 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa return __pyx_r; } -/* "providers.pxd":334 +/* "providers.pxd":340 * @cython.boundscheck(False) * @cython.wraparound(False) - * cdef inline tuple __provide_positional_args( # <<<<<<<<<<<<<< + * cdef inline object __provide_positional_args( # <<<<<<<<<<<<<< * tuple args, * tuple inj_args, */ @@ -11655,43 +12140,70 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provide_positional_args(PyObject *__pyx_v_args, PyObject *__pyx_v_inj_args, int __pyx_v_inj_args_len) { int __pyx_v_index; PyObject *__pyx_v_positional_args = 0; + PyObject *__pyx_v_awaitables = 0; struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *__pyx_v_injection = 0; + PyObject *__pyx_v_value = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations - int __pyx_t_1; - PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_1 = NULL; + int __pyx_t_2; int __pyx_t_3; int __pyx_t_4; int __pyx_t_5; int __pyx_t_6; + PyObject *__pyx_t_7 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__provide_positional_args", 0); - /* "providers.pxd":343 + /* "providers.pxd":346 + * ): + * cdef int index + * cdef list positional_args = [] # <<<<<<<<<<<<<< + * cdef list awaitables = [] + * cdef PositionalInjection injection + */ + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 346, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_positional_args = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":347 + * cdef int index + * cdef list positional_args = [] + * cdef list awaitables = [] # <<<<<<<<<<<<<< + * cdef PositionalInjection injection + * + */ + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 347, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_awaitables = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":350 * cdef PositionalInjection injection * * if inj_args_len == 0: # <<<<<<<<<<<<<< * return args * */ - __pyx_t_1 = ((__pyx_v_inj_args_len == 0) != 0); - if (__pyx_t_1) { + __pyx_t_2 = ((__pyx_v_inj_args_len == 0) != 0); + if (__pyx_t_2) { - /* "providers.pxd":344 + /* "providers.pxd":351 * * if inj_args_len == 0: * return args # <<<<<<<<<<<<<< * - * positional_args = list() + * for index in range(inj_args_len): */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_args); __pyx_r = __pyx_v_args; goto __pyx_L0; - /* "providers.pxd":343 + /* "providers.pxd":350 * cdef PositionalInjection injection * * if inj_args_len == 0: # <<<<<<<<<<<<<< @@ -11700,107 +12212,177 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ } - /* "providers.pxd":346 + /* "providers.pxd":353 * return args * - * positional_args = list() # <<<<<<<<<<<<<< - * for index in range(inj_args_len): - * injection = inj_args[index] - */ - __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 346, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_v_positional_args = ((PyObject*)__pyx_t_2); - __pyx_t_2 = 0; - - /* "providers.pxd":347 - * - * positional_args = list() * for index in range(inj_args_len): # <<<<<<<<<<<<<< * injection = inj_args[index] - * positional_args.append(__get_value(injection)) + * value = __get_value(injection) */ __pyx_t_3 = __pyx_v_inj_args_len; __pyx_t_4 = __pyx_t_3; for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) { __pyx_v_index = __pyx_t_5; - /* "providers.pxd":348 - * positional_args = list() + /* "providers.pxd":354 + * * for index in range(inj_args_len): * injection = inj_args[index] # <<<<<<<<<<<<<< - * positional_args.append(__get_value(injection)) - * positional_args.extend(args) + * value = __get_value(injection) + * positional_args.append(value) */ if (unlikely(__pyx_v_inj_args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 348, __pyx_L1_error) + __PYX_ERR(1, 354, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_ITEM(__pyx_v_inj_args, __pyx_v_index); - __Pyx_INCREF(__pyx_t_2); - __Pyx_XDECREF_SET(__pyx_v_injection, ((struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *)__pyx_t_2)); - __pyx_t_2 = 0; + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_v_inj_args, __pyx_v_index); + __Pyx_INCREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_injection, ((struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *)__pyx_t_1)); + __pyx_t_1 = 0; - /* "providers.pxd":349 + /* "providers.pxd":355 * for index in range(inj_args_len): * injection = inj_args[index] - * positional_args.append(__get_value(injection)) # <<<<<<<<<<<<<< - * positional_args.extend(args) + * value = __get_value(injection) # <<<<<<<<<<<<<< + * positional_args.append(value) * */ - __pyx_t_2 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_injection)); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 349, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_positional_args, __pyx_t_2); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 349, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_injection)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 355, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":356 + * injection = inj_args[index] + * value = __get_value(injection) + * positional_args.append(value) # <<<<<<<<<<<<<< + * + * if __isawaitable(value): + */ + __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_positional_args, __pyx_v_value); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 356, __pyx_L1_error) + + /* "providers.pxd":358 + * positional_args.append(value) + * + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((index, value)) + * + */ + __pyx_t_2 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_value) != 0); + if (__pyx_t_2) { + + /* "providers.pxd":359 + * + * if __isawaitable(value): + * awaitables.append((index, value)) # <<<<<<<<<<<<<< + * + * positional_args.extend(args) + */ + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_index); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_7 = PyTuple_New(2); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_1); + __Pyx_INCREF(__pyx_v_value); + __Pyx_GIVEREF(__pyx_v_value); + PyTuple_SET_ITEM(__pyx_t_7, 1, __pyx_v_value); + __pyx_t_1 = 0; + __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_awaitables, __pyx_t_7); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 359, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + + /* "providers.pxd":358 + * positional_args.append(value) + * + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((index, value)) + * + */ + } } - /* "providers.pxd":350 - * injection = inj_args[index] - * positional_args.append(__get_value(injection)) + /* "providers.pxd":361 + * awaitables.append((index, value)) + * * positional_args.extend(args) # <<<<<<<<<<<<<< * - * return tuple(positional_args) + * if awaitables: */ - __pyx_t_6 = __Pyx_PyList_Extend(__pyx_v_positional_args, __pyx_v_args); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 350, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyList_Extend(__pyx_v_positional_args, __pyx_v_args); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 361, __pyx_L1_error) - /* "providers.pxd":352 + /* "providers.pxd":363 * positional_args.extend(args) * - * return tuple(positional_args) # <<<<<<<<<<<<<< + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(positional_args, awaitables) + * + */ + __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_awaitables) != 0); + if (__pyx_t_2) { + + /* "providers.pxd":364 + * + * if awaitables: + * return __awaitable_args_kwargs_future(positional_args, awaitables) # <<<<<<<<<<<<<< + * + * return positional_args + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_7 = __pyx_f_19dependency_injector_9providers___awaitable_args_kwargs_future(__pyx_v_positional_args, __pyx_v_awaitables); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 364, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_r = __pyx_t_7; + __pyx_t_7 = 0; + goto __pyx_L0; + + /* "providers.pxd":363 + * positional_args.extend(args) + * + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(positional_args, awaitables) + * + */ + } + + /* "providers.pxd":366 + * return __awaitable_args_kwargs_future(positional_args, awaitables) + * + * return positional_args # <<<<<<<<<<<<<< * * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = PyList_AsTuple(__pyx_v_positional_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 352, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_r = ((PyObject*)__pyx_t_2); - __pyx_t_2 = 0; + __Pyx_INCREF(__pyx_v_positional_args); + __pyx_r = __pyx_v_positional_args; goto __pyx_L0; - /* "providers.pxd":334 + /* "providers.pxd":340 * @cython.boundscheck(False) * @cython.wraparound(False) - * cdef inline tuple __provide_positional_args( # <<<<<<<<<<<<<< + * cdef inline object __provide_positional_args( # <<<<<<<<<<<<<< * tuple args, * tuple inj_args, */ /* function exit code */ __pyx_L1_error:; - __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_7); __Pyx_AddTraceback("dependency_injector.providers.__provide_positional_args", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_positional_args); + __Pyx_XDECREF(__pyx_v_awaitables); __Pyx_XDECREF((PyObject *)__pyx_v_injection); + __Pyx_XDECREF(__pyx_v_value); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "providers.pxd":357 +/* "providers.pxd":371 * @cython.boundscheck(False) * @cython.wraparound(False) - * cdef inline dict __provide_keyword_args( # <<<<<<<<<<<<<< + * cdef inline object __provide_keyword_args( # <<<<<<<<<<<<<< * dict kwargs, * tuple inj_kwargs, */ @@ -11810,25 +12392,51 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid PyObject *__pyx_v_name = 0; PyObject *__pyx_v_value = 0; PyObject *__pyx_v_prefixed = 0; + PyObject *__pyx_v_awaitables = 0; struct __pyx_obj_19dependency_injector_9providers_NamedInjection *__pyx_v_kw_injection = 0; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations - Py_ssize_t __pyx_t_1; - int __pyx_t_2; + PyObject *__pyx_t_1 = NULL; + Py_ssize_t __pyx_t_2; int __pyx_t_3; int __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; - PyObject *__pyx_t_7 = NULL; + int __pyx_t_6; + int __pyx_t_7; PyObject *__pyx_t_8 = NULL; - int __pyx_t_9; + PyObject *__pyx_t_9 = NULL; + int __pyx_t_10; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__provide_keyword_args", 0); __Pyx_INCREF(__pyx_v_kwargs); - /* "providers.pxd":368 + /* "providers.pxd":379 + * cdef object name + * cdef object value + * cdef dict prefixed = {} # <<<<<<<<<<<<<< + * cdef list awaitables = [] + * cdef NamedInjection kw_injection + */ + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 379, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_prefixed = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":380 + * cdef object value + * cdef dict prefixed = {} + * cdef list awaitables = [] # <<<<<<<<<<<<<< + * cdef NamedInjection kw_injection + * + */ + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 380, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_awaitables = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":383 * cdef NamedInjection kw_injection * * if len(kwargs) == 0: # <<<<<<<<<<<<<< @@ -11837,70 +12445,116 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 368, __pyx_L1_error) + __PYX_ERR(1, 383, __pyx_L1_error) } - __pyx_t_1 = PyDict_Size(__pyx_v_kwargs); if (unlikely(__pyx_t_1 == ((Py_ssize_t)-1))) __PYX_ERR(1, 368, __pyx_L1_error) - __pyx_t_2 = ((__pyx_t_1 == 0) != 0); - if (__pyx_t_2) { + __pyx_t_2 = PyDict_Size(__pyx_v_kwargs); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 383, __pyx_L1_error) + __pyx_t_3 = ((__pyx_t_2 == 0) != 0); + if (__pyx_t_3) { - /* "providers.pxd":369 + /* "providers.pxd":384 * * if len(kwargs) == 0: * for index in range(inj_kwargs_len): # <<<<<<<<<<<<<< * kw_injection = inj_kwargs[index] * name = __get_name(kw_injection) */ - __pyx_t_3 = __pyx_v_inj_kwargs_len; - __pyx_t_4 = __pyx_t_3; - for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) { - __pyx_v_index = __pyx_t_5; + __pyx_t_4 = __pyx_v_inj_kwargs_len; + __pyx_t_5 = __pyx_t_4; + for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) { + __pyx_v_index = __pyx_t_6; - /* "providers.pxd":370 + /* "providers.pxd":385 * if len(kwargs) == 0: * for index in range(inj_kwargs_len): * kw_injection = inj_kwargs[index] # <<<<<<<<<<<<<< * name = __get_name(kw_injection) - * kwargs[name] = __get_value(kw_injection) + * value = __get_value(kw_injection) */ if (unlikely(__pyx_v_inj_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 370, __pyx_L1_error) + __PYX_ERR(1, 385, __pyx_L1_error) } - __pyx_t_6 = PyTuple_GET_ITEM(__pyx_v_inj_kwargs, __pyx_v_index); - __Pyx_INCREF(__pyx_t_6); - __Pyx_XDECREF_SET(__pyx_v_kw_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_6)); - __pyx_t_6 = 0; + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_v_inj_kwargs, __pyx_v_index); + __Pyx_INCREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_kw_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); + __pyx_t_1 = 0; - /* "providers.pxd":371 + /* "providers.pxd":386 * for index in range(inj_kwargs_len): * kw_injection = inj_kwargs[index] * name = __get_name(kw_injection) # <<<<<<<<<<<<<< - * kwargs[name] = __get_value(kw_injection) - * else: + * value = __get_value(kw_injection) + * kwargs[name] = value */ - __pyx_t_6 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_kw_injection); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 371, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_6); - __pyx_t_6 = 0; + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_kw_injection); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 386, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_1); + __pyx_t_1 = 0; - /* "providers.pxd":372 + /* "providers.pxd":387 * kw_injection = inj_kwargs[index] * name = __get_name(kw_injection) - * kwargs[name] = __get_value(kw_injection) # <<<<<<<<<<<<<< + * value = __get_value(kw_injection) # <<<<<<<<<<<<<< + * kwargs[name] = value + * if __isawaitable(value): + */ + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 387, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":388 + * name = __get_name(kw_injection) + * value = __get_value(kw_injection) + * kwargs[name] = value # <<<<<<<<<<<<<< + * if __isawaitable(value): + * awaitables.append((name, value)) + */ + if (unlikely(__pyx_v_kwargs == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(1, 388, __pyx_L1_error) + } + if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(1, 388, __pyx_L1_error) + + /* "providers.pxd":389 + * value = __get_value(kw_injection) + * kwargs[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * else: + */ + __pyx_t_3 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_value) != 0); + if (__pyx_t_3) { + + /* "providers.pxd":390 + * kwargs[name] = value + * if __isawaitable(value): + * awaitables.append((name, value)) # <<<<<<<<<<<<<< * else: * kwargs, prefixed = __separate_prefixed_kwargs(kwargs) */ - __pyx_t_6 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 372, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - if (unlikely(__pyx_v_kwargs == Py_None)) { - PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 372, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 390, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_v_name); + __Pyx_GIVEREF(__pyx_v_name); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_name); + __Pyx_INCREF(__pyx_v_value); + __Pyx_GIVEREF(__pyx_v_value); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_value); + __pyx_t_7 = __Pyx_PyList_Append(__pyx_v_awaitables, __pyx_t_1); if (unlikely(__pyx_t_7 == ((int)-1))) __PYX_ERR(1, 390, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":389 + * value = __get_value(kw_injection) + * kwargs[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * else: + */ } - if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_name, __pyx_t_6) < 0)) __PYX_ERR(1, 372, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } - /* "providers.pxd":368 + /* "providers.pxd":383 * cdef NamedInjection kw_injection * * if len(kwargs) == 0: # <<<<<<<<<<<<<< @@ -11910,59 +12564,59 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid goto __pyx_L3; } - /* "providers.pxd":374 - * kwargs[name] = __get_value(kw_injection) + /* "providers.pxd":392 + * awaitables.append((name, value)) * else: * kwargs, prefixed = __separate_prefixed_kwargs(kwargs) # <<<<<<<<<<<<<< * * */ /*else*/ { - __pyx_t_6 = __pyx_f_19dependency_injector_9providers___separate_prefixed_kwargs(__pyx_v_kwargs); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 374, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - if (likely(__pyx_t_6 != Py_None)) { - PyObject* sequence = __pyx_t_6; + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___separate_prefixed_kwargs(__pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 392, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (likely(__pyx_t_1 != Py_None)) { + PyObject* sequence = __pyx_t_1; Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(1, 374, __pyx_L1_error) + __PYX_ERR(1, 392, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_7 = PyTuple_GET_ITEM(sequence, 0); - __pyx_t_8 = PyTuple_GET_ITEM(sequence, 1); - __Pyx_INCREF(__pyx_t_7); + __pyx_t_8 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_9 = PyTuple_GET_ITEM(sequence, 1); __Pyx_INCREF(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); #else - __pyx_t_7 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 374, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_7); - __pyx_t_8 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 374, __pyx_L1_error) + __pyx_t_8 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 392, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); + __pyx_t_9 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 392, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); #endif - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { - __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(1, 374, __pyx_L1_error) + __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(1, 392, __pyx_L1_error) } - if (!(likely(PyDict_CheckExact(__pyx_t_7))||((__pyx_t_7) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_7)->tp_name), 0))) __PYX_ERR(1, 374, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_t_8))||((__pyx_t_8) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_8)->tp_name), 0))) __PYX_ERR(1, 374, __pyx_L1_error) - __Pyx_DECREF_SET(__pyx_v_kwargs, ((PyObject*)__pyx_t_7)); - __pyx_t_7 = 0; - __pyx_v_prefixed = ((PyObject*)__pyx_t_8); + if (!(likely(PyDict_CheckExact(__pyx_t_8))||((__pyx_t_8) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_8)->tp_name), 0))) __PYX_ERR(1, 392, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_t_9))||((__pyx_t_9) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_9)->tp_name), 0))) __PYX_ERR(1, 392, __pyx_L1_error) + __Pyx_DECREF_SET(__pyx_v_kwargs, ((PyObject*)__pyx_t_8)); __pyx_t_8 = 0; + __Pyx_DECREF_SET(__pyx_v_prefixed, ((PyObject*)__pyx_t_9)); + __pyx_t_9 = 0; - /* "providers.pxd":377 + /* "providers.pxd":395 * * * for index in range(inj_kwargs_len): # <<<<<<<<<<<<<< * kw_injection = inj_kwargs[index] * name = __get_name(kw_injection) */ - __pyx_t_3 = __pyx_v_inj_kwargs_len; - __pyx_t_4 = __pyx_t_3; - for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) { - __pyx_v_index = __pyx_t_5; + __pyx_t_4 = __pyx_v_inj_kwargs_len; + __pyx_t_5 = __pyx_t_4; + for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) { + __pyx_v_index = __pyx_t_6; - /* "providers.pxd":378 + /* "providers.pxd":396 * * for index in range(inj_kwargs_len): * kw_injection = inj_kwargs[index] # <<<<<<<<<<<<<< @@ -11971,26 +12625,26 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ if (unlikely(__pyx_v_inj_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 378, __pyx_L1_error) + __PYX_ERR(1, 396, __pyx_L1_error) } - __pyx_t_6 = PyTuple_GET_ITEM(__pyx_v_inj_kwargs, __pyx_v_index); - __Pyx_INCREF(__pyx_t_6); - __Pyx_XDECREF_SET(__pyx_v_kw_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_6)); - __pyx_t_6 = 0; + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_v_inj_kwargs, __pyx_v_index); + __Pyx_INCREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_kw_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); + __pyx_t_1 = 0; - /* "providers.pxd":379 + /* "providers.pxd":397 * for index in range(inj_kwargs_len): * kw_injection = inj_kwargs[index] * name = __get_name(kw_injection) # <<<<<<<<<<<<<< * * if name in kwargs: */ - __pyx_t_6 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_kw_injection); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 379, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_6); - __pyx_t_6 = 0; + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_kw_injection); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 397, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_1); + __pyx_t_1 = 0; - /* "providers.pxd":381 + /* "providers.pxd":399 * name = __get_name(kw_injection) * * if name in kwargs: # <<<<<<<<<<<<<< @@ -11999,22 +12653,22 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 381, __pyx_L1_error) + __PYX_ERR(1, 399, __pyx_L1_error) } - __pyx_t_2 = (__Pyx_PyDict_ContainsTF(__pyx_v_name, __pyx_v_kwargs, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 381, __pyx_L1_error) - __pyx_t_9 = (__pyx_t_2 != 0); - if (__pyx_t_9) { + __pyx_t_3 = (__Pyx_PyDict_ContainsTF(__pyx_v_name, __pyx_v_kwargs, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(1, 399, __pyx_L1_error) + __pyx_t_10 = (__pyx_t_3 != 0); + if (__pyx_t_10) { - /* "providers.pxd":382 + /* "providers.pxd":400 * * if name in kwargs: * continue # <<<<<<<<<<<<<< * * if name in prefixed: */ - goto __pyx_L6_continue; + goto __pyx_L7_continue; - /* "providers.pxd":381 + /* "providers.pxd":399 * name = __get_name(kw_injection) * * if name in kwargs: # <<<<<<<<<<<<<< @@ -12023,7 +12677,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ } - /* "providers.pxd":384 + /* "providers.pxd":402 * continue * * if name in prefixed: # <<<<<<<<<<<<<< @@ -12032,13 +12686,13 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ if (unlikely(__pyx_v_prefixed == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 384, __pyx_L1_error) + __PYX_ERR(1, 402, __pyx_L1_error) } - __pyx_t_9 = (__Pyx_PyDict_ContainsTF(__pyx_v_name, __pyx_v_prefixed, Py_EQ)); if (unlikely(__pyx_t_9 < 0)) __PYX_ERR(1, 384, __pyx_L1_error) - __pyx_t_2 = (__pyx_t_9 != 0); - if (__pyx_t_2) { + __pyx_t_10 = (__Pyx_PyDict_ContainsTF(__pyx_v_name, __pyx_v_prefixed, Py_EQ)); if (unlikely(__pyx_t_10 < 0)) __PYX_ERR(1, 402, __pyx_L1_error) + __pyx_t_3 = (__pyx_t_10 != 0); + if (__pyx_t_3) { - /* "providers.pxd":385 + /* "providers.pxd":403 * * if name in prefixed: * value = __get_value_kwargs(kw_injection, prefixed[name]) # <<<<<<<<<<<<<< @@ -12047,28 +12701,28 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ if (unlikely(__pyx_v_prefixed == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 385, __pyx_L1_error) + __PYX_ERR(1, 403, __pyx_L1_error) } - __pyx_t_6 = __Pyx_PyDict_GetItem(__pyx_v_prefixed, __pyx_v_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 385, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - if (!(likely(PyDict_CheckExact(__pyx_t_6))||((__pyx_t_6) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_6)->tp_name), 0))) __PYX_ERR(1, 385, __pyx_L1_error) - __pyx_t_8 = __pyx_f_19dependency_injector_9providers___get_value_kwargs(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection), ((PyObject*)__pyx_t_6)); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 385, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_8); - __pyx_t_8 = 0; + __pyx_t_1 = __Pyx_PyDict_GetItem(__pyx_v_prefixed, __pyx_v_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 403, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 403, __pyx_L1_error) + __pyx_t_9 = __pyx_f_19dependency_injector_9providers___get_value_kwargs(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection), ((PyObject*)__pyx_t_1)); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 403, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_9); + __pyx_t_9 = 0; - /* "providers.pxd":384 + /* "providers.pxd":402 * continue * * if name in prefixed: # <<<<<<<<<<<<<< * value = __get_value_kwargs(kw_injection, prefixed[name]) * else: */ - goto __pyx_L9; + goto __pyx_L10; } - /* "providers.pxd":387 + /* "providers.pxd":405 * value = __get_value_kwargs(kw_injection, prefixed[name]) * else: * value = __get_value(kw_injection) # <<<<<<<<<<<<<< @@ -12076,32 +12730,102 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid * kwargs[name] = value */ /*else*/ { - __pyx_t_8 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection)); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 387, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_8); - __pyx_t_8 = 0; + __pyx_t_9 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection)); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 405, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_9); + __pyx_t_9 = 0; } - __pyx_L9:; + __pyx_L10:; - /* "providers.pxd":389 + /* "providers.pxd":407 * value = __get_value(kw_injection) * * kwargs[name] = value # <<<<<<<<<<<<<< - * - * return kwargs + * if __isawaitable(value): + * awaitables.append((name, value)) */ if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 389, __pyx_L1_error) + __PYX_ERR(1, 407, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(1, 389, __pyx_L1_error) - __pyx_L6_continue:; + if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(1, 407, __pyx_L1_error) + + /* "providers.pxd":408 + * + * kwargs[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * + */ + __pyx_t_3 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_value) != 0); + if (__pyx_t_3) { + + /* "providers.pxd":409 + * kwargs[name] = value + * if __isawaitable(value): + * awaitables.append((name, value)) # <<<<<<<<<<<<<< + * + * if awaitables: + */ + __pyx_t_9 = PyTuple_New(2); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 409, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_INCREF(__pyx_v_name); + __Pyx_GIVEREF(__pyx_v_name); + PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_v_name); + __Pyx_INCREF(__pyx_v_value); + __Pyx_GIVEREF(__pyx_v_value); + PyTuple_SET_ITEM(__pyx_t_9, 1, __pyx_v_value); + __pyx_t_7 = __Pyx_PyList_Append(__pyx_v_awaitables, __pyx_t_9); if (unlikely(__pyx_t_7 == ((int)-1))) __PYX_ERR(1, 409, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + + /* "providers.pxd":408 + * + * kwargs[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * + */ + } + __pyx_L7_continue:; } } __pyx_L3:; - /* "providers.pxd":391 - * kwargs[name] = value + /* "providers.pxd":411 + * awaitables.append((name, value)) + * + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(kwargs, awaitables) + * + */ + __pyx_t_3 = (PyList_GET_SIZE(__pyx_v_awaitables) != 0); + if (__pyx_t_3) { + + /* "providers.pxd":412 + * + * if awaitables: + * return __awaitable_args_kwargs_future(kwargs, awaitables) # <<<<<<<<<<<<<< + * + * return kwargs + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_9 = __pyx_f_19dependency_injector_9providers___awaitable_args_kwargs_future(__pyx_v_kwargs, __pyx_v_awaitables); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 412, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __pyx_r = __pyx_t_9; + __pyx_t_9 = 0; + goto __pyx_L0; + + /* "providers.pxd":411 + * awaitables.append((name, value)) + * + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(kwargs, awaitables) + * + */ + } + + /* "providers.pxd":414 + * return __awaitable_args_kwargs_future(kwargs, awaitables) * * return kwargs # <<<<<<<<<<<<<< * @@ -12112,25 +12836,26 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid __pyx_r = __pyx_v_kwargs; goto __pyx_L0; - /* "providers.pxd":357 + /* "providers.pxd":371 * @cython.boundscheck(False) * @cython.wraparound(False) - * cdef inline dict __provide_keyword_args( # <<<<<<<<<<<<<< + * cdef inline object __provide_keyword_args( # <<<<<<<<<<<<<< * dict kwargs, * tuple inj_kwargs, */ /* function exit code */ __pyx_L1_error:; - __Pyx_XDECREF(__pyx_t_6); - __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__provide_keyword_args", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_name); __Pyx_XDECREF(__pyx_v_value); __Pyx_XDECREF(__pyx_v_prefixed); + __Pyx_XDECREF(__pyx_v_awaitables); __Pyx_XDECREF((PyObject *)__pyx_v_kw_injection); __Pyx_XDECREF(__pyx_v_kwargs); __Pyx_XGIVEREF(__pyx_r); @@ -12138,114 +12863,1537 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid return __pyx_r; } -/* "providers.pxd":396 - * @cython.boundscheck(False) - * @cython.wraparound(False) - * cdef inline object __inject_attributes( # <<<<<<<<<<<<<< - * object instance, - * tuple attributes, +/* "providers.pxd":417 + * + * + * cdef inline object __awaitable_args_kwargs_future(object args, list awaitables): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * */ -static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___inject_attributes(PyObject *__pyx_v_instance, PyObject *__pyx_v_attributes, int __pyx_v_attributes_len) { - struct __pyx_obj_19dependency_injector_9providers_NamedInjection *__pyx_v_attr_injection = 0; - int __pyx_v_index; +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___awaitable_args_kwargs_future(PyObject *__pyx_v_args, PyObject *__pyx_v_awaitables) { + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_args_future = NULL; + PyObject *__pyx_v_args_ready = NULL; + CYTHON_UNUSED PyObject *__pyx_v__ = NULL; + PyObject *__pyx_v_value = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations - int __pyx_t_1; - int __pyx_t_2; - int __pyx_t_3; + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; - PyObject *__pyx_t_5 = NULL; - int __pyx_t_6; + Py_ssize_t __pyx_t_5; + PyObject *__pyx_t_6 = NULL; + PyObject *__pyx_t_7 = NULL; + PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; + PyObject *(*__pyx_t_10)(PyObject *); int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; - __Pyx_RefNannySetupContext("__inject_attributes", 0); + __Pyx_RefNannySetupContext("__awaitable_args_kwargs_future", 0); - /* "providers.pxd":402 - * ): - * cdef NamedInjection attr_injection - * for index in range(attributes_len): # <<<<<<<<<<<<<< - * attr_injection = attributes[index] - * setattr(instance, + /* "providers.pxd":418 + * + * cdef inline object __awaitable_args_kwargs_future(object args, list awaitables): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * + * args_future = asyncio.Future() */ - __pyx_t_1 = __pyx_v_attributes_len; - __pyx_t_2 = __pyx_t_1; - for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) { - __pyx_v_index = __pyx_t_3; - - /* "providers.pxd":403 - * cdef NamedInjection attr_injection - * for index in range(attributes_len): - * attr_injection = attributes[index] # <<<<<<<<<<<<<< - * setattr(instance, - * __get_name(attr_injection), - */ - if (unlikely(__pyx_v_attributes == Py_None)) { - PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 403, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 418, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_Future); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 418, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); } - __pyx_t_4 = PyTuple_GET_ITEM(__pyx_v_attributes, __pyx_v_index); - __Pyx_INCREF(__pyx_t_4); - __Pyx_XDECREF_SET(__pyx_v_attr_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_4)); - __pyx_t_4 = 0; - - /* "providers.pxd":405 - * attr_injection = attributes[index] - * setattr(instance, - * __get_name(attr_injection), # <<<<<<<<<<<<<< - * __get_value(attr_injection)) - * - */ - __pyx_t_4 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_attr_injection); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 405, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - - /* "providers.pxd":406 - * setattr(instance, - * __get_name(attr_injection), - * __get_value(attr_injection)) # <<<<<<<<<<<<<< - * - * - */ - __pyx_t_5 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_attr_injection)); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 406, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); - - /* "providers.pxd":404 - * for index in range(attributes_len): - * attr_injection = attributes[index] - * setattr(instance, # <<<<<<<<<<<<<< - * __get_name(attr_injection), - * __get_value(attr_injection)) - */ - __pyx_t_6 = PyObject_SetAttr(__pyx_v_instance, __pyx_t_4, __pyx_t_5); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 404, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 418, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_future_result = __pyx_t_1; + __pyx_t_1 = 0; - /* "providers.pxd":396 - * @cython.boundscheck(False) - * @cython.wraparound(False) - * cdef inline object __inject_attributes( # <<<<<<<<<<<<<< - * object instance, - * tuple attributes, + /* "providers.pxd":420 + * future_result = asyncio.Future() + * + * args_future = asyncio.Future() # <<<<<<<<<<<<<< + * args_future.set_result((future_result, args, awaitables)) + * + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 420, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_Future); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 420, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 420, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_args_future = __pyx_t_1; + __pyx_t_1 = 0; + + /* "providers.pxd":421 + * + * args_future = asyncio.Future() + * args_future.set_result((future_result, args, awaitables)) # <<<<<<<<<<<<<< + * + * args_ready = asyncio.gather(args_future, *[value for _, value in awaitables]) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_args_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 421, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 421, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_future_result); + __Pyx_INCREF(__pyx_v_args); + __Pyx_GIVEREF(__pyx_v_args); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_args); + __Pyx_INCREF(__pyx_v_awaitables); + __Pyx_GIVEREF(__pyx_v_awaitables); + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_awaitables); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 421, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":423 + * args_future.set_result((future_result, args, awaitables)) + * + * args_ready = asyncio.gather(args_future, *[value for _, value in awaitables]) # <<<<<<<<<<<<<< + * args_ready.add_done_callback(__async_prepare_args_kwargs_callback) + * asyncio.ensure_future(args_ready) + */ + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_gather); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_v_args_future); + __Pyx_GIVEREF(__pyx_v_args_future); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_args_future); + __pyx_t_3 = PyList_New(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + if (unlikely(__pyx_v_awaitables == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); + __PYX_ERR(1, 423, __pyx_L1_error) + } + __pyx_t_4 = __pyx_v_awaitables; __Pyx_INCREF(__pyx_t_4); __pyx_t_5 = 0; + for (;;) { + if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_4)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_6 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_5); __Pyx_INCREF(__pyx_t_6); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(1, 423, __pyx_L1_error) + #else + __pyx_t_6 = PySequence_ITEM(__pyx_t_4, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + #endif + if ((likely(PyTuple_CheckExact(__pyx_t_6))) || (PyList_CheckExact(__pyx_t_6))) { + PyObject* sequence = __pyx_t_6; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 2)) { + if (size > 2) __Pyx_RaiseTooManyValuesError(2); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(1, 423, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_7 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_8 = PyTuple_GET_ITEM(sequence, 1); + } else { + __pyx_t_7 = PyList_GET_ITEM(sequence, 0); + __pyx_t_8 = PyList_GET_ITEM(sequence, 1); + } + __Pyx_INCREF(__pyx_t_7); + __Pyx_INCREF(__pyx_t_8); + #else + __pyx_t_7 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_8 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + #endif + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_9 = PyObject_GetIter(__pyx_t_6); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_10 = Py_TYPE(__pyx_t_9)->tp_iternext; + index = 0; __pyx_t_7 = __pyx_t_10(__pyx_t_9); if (unlikely(!__pyx_t_7)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_7); + index = 1; __pyx_t_8 = __pyx_t_10(__pyx_t_9); if (unlikely(!__pyx_t_8)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_8); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_9), 2) < 0) __PYX_ERR(1, 423, __pyx_L1_error) + __pyx_t_10 = NULL; + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + goto __pyx_L6_unpacking_done; + __pyx_L5_unpacking_failed:; + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + __pyx_t_10 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(1, 423, __pyx_L1_error) + __pyx_L6_unpacking_done:; + } + __Pyx_XDECREF_SET(__pyx_v__, __pyx_t_7); + __pyx_t_7 = 0; + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_8); + __pyx_t_8 = 0; + if (unlikely(__Pyx_ListComp_Append(__pyx_t_3, (PyObject*)__pyx_v_value))) __PYX_ERR(1, 423, __pyx_L1_error) + } + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = PySequence_Tuple(__pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = PyNumber_Add(__pyx_t_1, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_args_ready = __pyx_t_4; + __pyx_t_4 = 0; + + /* "providers.pxd":424 + * + * args_ready = asyncio.gather(args_future, *[value for _, value in awaitables]) + * args_ready.add_done_callback(__async_prepare_args_kwargs_callback) # <<<<<<<<<<<<<< + * asyncio.ensure_future(args_ready) + * + */ + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_args_ready, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 424, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_CFunc_void____object___to_py(__pyx_f_19dependency_injector_9providers___async_prepare_args_kwargs_callback); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 424, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_1 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_1 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_1)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_1); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_4 = (__pyx_t_1) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_1, __pyx_t_2) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2); + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 424, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + + /* "providers.pxd":425 + * args_ready = asyncio.gather(args_future, *[value for _, value in awaitables]) + * args_ready.add_done_callback(__async_prepare_args_kwargs_callback) + * asyncio.ensure_future(args_ready) # <<<<<<<<<<<<<< + * + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 425, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 425, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_4 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_args_ready) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_args_ready); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 425, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + + /* "providers.pxd":427 + * asyncio.ensure_future(args_ready) + * + * return future_result # <<<<<<<<<<<<<< + * + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "providers.pxd":417 + * + * + * cdef inline object __awaitable_args_kwargs_future(object args, list awaitables): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * */ /* function exit code */ - __pyx_r = Py_None; __Pyx_INCREF(Py_None); - goto __pyx_L0; __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); - __Pyx_XDECREF(__pyx_t_5); - __Pyx_AddTraceback("dependency_injector.providers.__inject_attributes", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); + __Pyx_AddTraceback("dependency_injector.providers.__awaitable_args_kwargs_future", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; - __Pyx_XDECREF((PyObject *)__pyx_v_attr_injection); + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_args_future); + __Pyx_XDECREF(__pyx_v_args_ready); + __Pyx_XDECREF(__pyx_v__); + __Pyx_XDECREF(__pyx_v_value); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "providers.pxd":409 +/* "providers.pxd":430 + * + * + * cdef inline void __async_prepare_args_kwargs_callback(object future): # <<<<<<<<<<<<<< + * (future_result, args, awaitables), *awaited = future.result() + * for value, (key, _) in zip(awaited, awaitables): + */ + +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_prepare_args_kwargs_callback(PyObject *__pyx_v_future) { + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_args = NULL; + PyObject *__pyx_v_awaitables = NULL; + PyObject *__pyx_v_awaited = NULL; + PyObject *__pyx_v_value = NULL; + PyObject *__pyx_v_key = NULL; + CYTHON_UNUSED PyObject *__pyx_v__ = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *(*__pyx_t_4)(PyObject *); + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + PyObject *__pyx_t_7 = NULL; + PyObject *__pyx_t_8 = NULL; + Py_ssize_t __pyx_t_9; + PyObject *(*__pyx_t_10)(PyObject *); + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__async_prepare_args_kwargs_callback", 0); + + /* "providers.pxd":431 + * + * cdef inline void __async_prepare_args_kwargs_callback(object future): + * (future_result, args, awaitables), *awaited = future.result() # <<<<<<<<<<<<<< + * for value, (key, _) in zip(awaited, awaitables): + * args[key] = value + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + { + Py_ssize_t index = -1; + PyObject** temps[2] = {&__pyx_t_2}; + __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_4 = Py_TYPE(__pyx_t_3)->tp_iternext; + for (index=0; index < 1; index++) { + PyObject* item = __pyx_t_4(__pyx_t_3); if (unlikely(!item)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(item); + *(temps[index]) = item; + } + goto __pyx_L4_unpacking_done; + __pyx_L3_unpacking_failed:; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_4 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(1, 431, __pyx_L1_error) + __pyx_L4_unpacking_done:; + } + __pyx_t_5 = PySequence_List(__pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if ((likely(PyTuple_CheckExact(__pyx_t_2))) || (PyList_CheckExact(__pyx_t_2))) { + PyObject* sequence = __pyx_t_2; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 3)) { + if (size > 3) __Pyx_RaiseTooManyValuesError(3); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(1, 431, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_3 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_6 = PyTuple_GET_ITEM(sequence, 1); + __pyx_t_7 = PyTuple_GET_ITEM(sequence, 2); + } else { + __pyx_t_3 = PyList_GET_ITEM(sequence, 0); + __pyx_t_6 = PyList_GET_ITEM(sequence, 1); + __pyx_t_7 = PyList_GET_ITEM(sequence, 2); + } + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(__pyx_t_7); + #else + __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_7 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + #endif + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_8 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_4 = Py_TYPE(__pyx_t_8)->tp_iternext; + index = 0; __pyx_t_3 = __pyx_t_4(__pyx_t_8); if (unlikely(!__pyx_t_3)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_3); + index = 1; __pyx_t_6 = __pyx_t_4(__pyx_t_8); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_6); + index = 2; __pyx_t_7 = __pyx_t_4(__pyx_t_8); if (unlikely(!__pyx_t_7)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_7); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_4(__pyx_t_8), 3) < 0) __PYX_ERR(1, 431, __pyx_L1_error) + __pyx_t_4 = NULL; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + goto __pyx_L6_unpacking_done; + __pyx_L5_unpacking_failed:; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_4 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(1, 431, __pyx_L1_error) + __pyx_L6_unpacking_done:; + } + __pyx_v_future_result = __pyx_t_3; + __pyx_t_3 = 0; + __pyx_v_args = __pyx_t_6; + __pyx_t_6 = 0; + __pyx_v_awaitables = __pyx_t_7; + __pyx_t_7 = 0; + __pyx_v_awaited = ((PyObject*)__pyx_t_5); + __pyx_t_5 = 0; + + /* "providers.pxd":432 + * cdef inline void __async_prepare_args_kwargs_callback(object future): + * (future_result, args, awaitables), *awaited = future.result() + * for value, (key, _) in zip(awaited, awaitables): # <<<<<<<<<<<<<< + * args[key] = value + * future_result.set_result(args) + */ + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_v_awaited); + __Pyx_GIVEREF(__pyx_v_awaited); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_awaited); + __Pyx_INCREF(__pyx_v_awaitables); + __Pyx_GIVEREF(__pyx_v_awaitables); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_awaitables); + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_zip, __pyx_t_1, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) { + __pyx_t_1 = __pyx_t_5; __Pyx_INCREF(__pyx_t_1); __pyx_t_9 = 0; + __pyx_t_10 = NULL; + } else { + __pyx_t_9 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_10 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 432, __pyx_L1_error) + } + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + for (;;) { + if (likely(!__pyx_t_10)) { + if (likely(PyList_CheckExact(__pyx_t_1))) { + if (__pyx_t_9 >= PyList_GET_SIZE(__pyx_t_1)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_5 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_9); __Pyx_INCREF(__pyx_t_5); __pyx_t_9++; if (unlikely(0 < 0)) __PYX_ERR(1, 432, __pyx_L1_error) + #else + __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_9); __pyx_t_9++; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + #endif + } else { + if (__pyx_t_9 >= PyTuple_GET_SIZE(__pyx_t_1)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_9); __Pyx_INCREF(__pyx_t_5); __pyx_t_9++; if (unlikely(0 < 0)) __PYX_ERR(1, 432, __pyx_L1_error) + #else + __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_9); __pyx_t_9++; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + #endif + } + } else { + __pyx_t_5 = __pyx_t_10(__pyx_t_1); + if (unlikely(!__pyx_t_5)) { + PyObject* exc_type = PyErr_Occurred(); + if (exc_type) { + if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); + else __PYX_ERR(1, 432, __pyx_L1_error) + } + break; + } + __Pyx_GOTREF(__pyx_t_5); + } + if ((likely(PyTuple_CheckExact(__pyx_t_5))) || (PyList_CheckExact(__pyx_t_5))) { + PyObject* sequence = __pyx_t_5; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 2)) { + if (size > 2) __Pyx_RaiseTooManyValuesError(2); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(1, 432, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_2 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_7 = PyTuple_GET_ITEM(sequence, 1); + } else { + __pyx_t_2 = PyList_GET_ITEM(sequence, 0); + __pyx_t_7 = PyList_GET_ITEM(sequence, 1); + } + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(__pyx_t_7); + #else + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_7 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + #endif + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_6 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_4 = Py_TYPE(__pyx_t_6)->tp_iternext; + index = 0; __pyx_t_2 = __pyx_t_4(__pyx_t_6); if (unlikely(!__pyx_t_2)) goto __pyx_L9_unpacking_failed; + __Pyx_GOTREF(__pyx_t_2); + index = 1; __pyx_t_7 = __pyx_t_4(__pyx_t_6); if (unlikely(!__pyx_t_7)) goto __pyx_L9_unpacking_failed; + __Pyx_GOTREF(__pyx_t_7); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_4(__pyx_t_6), 2) < 0) __PYX_ERR(1, 432, __pyx_L1_error) + __pyx_t_4 = NULL; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + goto __pyx_L10_unpacking_done; + __pyx_L9_unpacking_failed:; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_4 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(1, 432, __pyx_L1_error) + __pyx_L10_unpacking_done:; + } + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_2); + __pyx_t_2 = 0; + if ((likely(PyTuple_CheckExact(__pyx_t_7))) || (PyList_CheckExact(__pyx_t_7))) { + PyObject* sequence = __pyx_t_7; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 2)) { + if (size > 2) __Pyx_RaiseTooManyValuesError(2); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(1, 432, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_6 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_3 = PyTuple_GET_ITEM(sequence, 1); + } else { + __pyx_t_6 = PyList_GET_ITEM(sequence, 0); + __pyx_t_3 = PyList_GET_ITEM(sequence, 1); + } + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(__pyx_t_3); + #else + __pyx_t_6 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_3 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + #endif + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_8 = PyObject_GetIter(__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_4 = Py_TYPE(__pyx_t_8)->tp_iternext; + index = 0; __pyx_t_6 = __pyx_t_4(__pyx_t_8); if (unlikely(!__pyx_t_6)) goto __pyx_L11_unpacking_failed; + __Pyx_GOTREF(__pyx_t_6); + index = 1; __pyx_t_3 = __pyx_t_4(__pyx_t_8); if (unlikely(!__pyx_t_3)) goto __pyx_L11_unpacking_failed; + __Pyx_GOTREF(__pyx_t_3); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_4(__pyx_t_8), 2) < 0) __PYX_ERR(1, 432, __pyx_L1_error) + __pyx_t_4 = NULL; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + goto __pyx_L12_unpacking_done; + __pyx_L11_unpacking_failed:; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_4 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(1, 432, __pyx_L1_error) + __pyx_L12_unpacking_done:; + } + __Pyx_XDECREF_SET(__pyx_v_key, __pyx_t_6); + __pyx_t_6 = 0; + __Pyx_XDECREF_SET(__pyx_v__, __pyx_t_3); + __pyx_t_3 = 0; + + /* "providers.pxd":433 + * (future_result, args, awaitables), *awaited = future.result() + * for value, (key, _) in zip(awaited, awaitables): + * args[key] = value # <<<<<<<<<<<<<< + * future_result.set_result(args) + * + */ + if (unlikely(PyObject_SetItem(__pyx_v_args, __pyx_v_key, __pyx_v_value) < 0)) __PYX_ERR(1, 433, __pyx_L1_error) + + /* "providers.pxd":432 + * cdef inline void __async_prepare_args_kwargs_callback(object future): + * (future_result, args, awaitables), *awaited = future.result() + * for value, (key, _) in zip(awaited, awaitables): # <<<<<<<<<<<<<< + * args[key] = value + * future_result.set_result(args) + */ + } + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":434 + * for value, (key, _) in zip(awaited, awaitables): + * args[key] = value + * future_result.set_result(args) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 434, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_7 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_7)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_7); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_7, __pyx_v_args) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_args); + __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 434, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":430 + * + * + * cdef inline void __async_prepare_args_kwargs_callback(object future): # <<<<<<<<<<<<<< + * (future_result, args, awaitables), *awaited = future.result() + * for value, (key, _) in zip(awaited, awaitables): + */ + + /* function exit code */ + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_WriteUnraisable("dependency_injector.providers.__async_prepare_args_kwargs_callback", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_args); + __Pyx_XDECREF(__pyx_v_awaitables); + __Pyx_XDECREF(__pyx_v_awaited); + __Pyx_XDECREF(__pyx_v_value); + __Pyx_XDECREF(__pyx_v_key); + __Pyx_XDECREF(__pyx_v__); + __Pyx_RefNannyFinishContext(); +} + +/* "providers.pxd":439 + * @cython.boundscheck(False) + * @cython.wraparound(False) + * cdef inline object __provide_attributes(tuple attributes, int attributes_len): # <<<<<<<<<<<<<< + * cdef NamedInjection attr_injection + * cdef dict attribute_injections = {} + */ + +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provide_attributes(PyObject *__pyx_v_attributes, int __pyx_v_attributes_len) { + struct __pyx_obj_19dependency_injector_9providers_NamedInjection *__pyx_v_attr_injection = 0; + PyObject *__pyx_v_attribute_injections = 0; + PyObject *__pyx_v_awaitables = 0; + int __pyx_v_index; + PyObject *__pyx_v_name = NULL; + PyObject *__pyx_v_value = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_t_2; + int __pyx_t_3; + int __pyx_t_4; + int __pyx_t_5; + int __pyx_t_6; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__provide_attributes", 0); + + /* "providers.pxd":441 + * cdef inline object __provide_attributes(tuple attributes, int attributes_len): + * cdef NamedInjection attr_injection + * cdef dict attribute_injections = {} # <<<<<<<<<<<<<< + * cdef list awaitables = [] + * + */ + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 441, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_attribute_injections = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":442 + * cdef NamedInjection attr_injection + * cdef dict attribute_injections = {} + * cdef list awaitables = [] # <<<<<<<<<<<<<< + * + * for index in range(attributes_len): + */ + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 442, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_awaitables = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":444 + * cdef list awaitables = [] + * + * for index in range(attributes_len): # <<<<<<<<<<<<<< + * attr_injection = attributes[index] + * name = __get_name(attr_injection) + */ + __pyx_t_2 = __pyx_v_attributes_len; + __pyx_t_3 = __pyx_t_2; + for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { + __pyx_v_index = __pyx_t_4; + + /* "providers.pxd":445 + * + * for index in range(attributes_len): + * attr_injection = attributes[index] # <<<<<<<<<<<<<< + * name = __get_name(attr_injection) + * value = __get_value(attr_injection) + */ + if (unlikely(__pyx_v_attributes == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(1, 445, __pyx_L1_error) + } + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_v_attributes, __pyx_v_index); + __Pyx_INCREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_attr_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); + __pyx_t_1 = 0; + + /* "providers.pxd":446 + * for index in range(attributes_len): + * attr_injection = attributes[index] + * name = __get_name(attr_injection) # <<<<<<<<<<<<<< + * value = __get_value(attr_injection) + * attribute_injections[name] = value + */ + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_attr_injection); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 446, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":447 + * attr_injection = attributes[index] + * name = __get_name(attr_injection) + * value = __get_value(attr_injection) # <<<<<<<<<<<<<< + * attribute_injections[name] = value + * if __isawaitable(value): + */ + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_attr_injection)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 447, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":448 + * name = __get_name(attr_injection) + * value = __get_value(attr_injection) + * attribute_injections[name] = value # <<<<<<<<<<<<<< + * if __isawaitable(value): + * awaitables.append((name, value)) + */ + if (unlikely(PyDict_SetItem(__pyx_v_attribute_injections, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(1, 448, __pyx_L1_error) + + /* "providers.pxd":449 + * value = __get_value(attr_injection) + * attribute_injections[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * + */ + __pyx_t_5 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_value) != 0); + if (__pyx_t_5) { + + /* "providers.pxd":450 + * attribute_injections[name] = value + * if __isawaitable(value): + * awaitables.append((name, value)) # <<<<<<<<<<<<<< + * + * if awaitables: + */ + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 450, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_v_name); + __Pyx_GIVEREF(__pyx_v_name); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_name); + __Pyx_INCREF(__pyx_v_value); + __Pyx_GIVEREF(__pyx_v_value); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_value); + __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_awaitables, __pyx_t_1); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 450, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":449 + * value = __get_value(attr_injection) + * attribute_injections[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * + */ + } + } + + /* "providers.pxd":452 + * awaitables.append((name, value)) + * + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(attribute_injections, awaitables) + * + */ + __pyx_t_5 = (PyList_GET_SIZE(__pyx_v_awaitables) != 0); + if (__pyx_t_5) { + + /* "providers.pxd":453 + * + * if awaitables: + * return __awaitable_args_kwargs_future(attribute_injections, awaitables) # <<<<<<<<<<<<<< + * + * return attribute_injections + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___awaitable_args_kwargs_future(__pyx_v_attribute_injections, __pyx_v_awaitables); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 453, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* "providers.pxd":452 + * awaitables.append((name, value)) + * + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(attribute_injections, awaitables) + * + */ + } + + /* "providers.pxd":455 + * return __awaitable_args_kwargs_future(attribute_injections, awaitables) + * + * return attribute_injections # <<<<<<<<<<<<<< + * + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_attribute_injections); + __pyx_r = __pyx_v_attribute_injections; + goto __pyx_L0; + + /* "providers.pxd":439 + * @cython.boundscheck(False) + * @cython.wraparound(False) + * cdef inline object __provide_attributes(tuple attributes, int attributes_len): # <<<<<<<<<<<<<< + * cdef NamedInjection attr_injection + * cdef dict attribute_injections = {} + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_AddTraceback("dependency_injector.providers.__provide_attributes", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = 0; + __pyx_L0:; + __Pyx_XDECREF((PyObject *)__pyx_v_attr_injection); + __Pyx_XDECREF(__pyx_v_attribute_injections); + __Pyx_XDECREF(__pyx_v_awaitables); + __Pyx_XDECREF(__pyx_v_name); + __Pyx_XDECREF(__pyx_v_value); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "providers.pxd":458 + * + * + * cdef inline object __async_inject_attributes(future_instance, future_attributes): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * + */ + +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___async_inject_attributes(PyObject *__pyx_v_future_instance, PyObject *__pyx_v_future_attributes) { + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_future = NULL; + PyObject *__pyx_v_attributes_ready = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + int __pyx_t_4; + PyObject *__pyx_t_5 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__async_inject_attributes", 0); + + /* "providers.pxd":459 + * + * cdef inline object __async_inject_attributes(future_instance, future_attributes): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * + * future = asyncio.Future() + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 459, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_Future); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 459, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 459, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_future_result = __pyx_t_1; + __pyx_t_1 = 0; + + /* "providers.pxd":461 + * future_result = asyncio.Future() + * + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result(future_result) + * + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 461, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_Future); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 461, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 461, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_future = __pyx_t_1; + __pyx_t_1 = 0; + + /* "providers.pxd":462 + * + * future = asyncio.Future() + * future.set_result(future_result) # <<<<<<<<<<<<<< + * + * attributes_ready = asyncio.gather(future, future_instance, future_attributes) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 462, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_future_result) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_future_result); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 462, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":464 + * future.set_result(future_result) + * + * attributes_ready = asyncio.gather(future, future_instance, future_attributes) # <<<<<<<<<<<<<< + * attributes_ready.add_done_callback(__async_inject_attributes_callback) + * asyncio.ensure_future(attributes_ready) + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_gather); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + __pyx_t_4 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + __pyx_t_4 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_3)) { + PyObject *__pyx_temp[4] = {__pyx_t_2, __pyx_v_future, __pyx_v_future_instance, __pyx_v_future_attributes}; + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 464, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_GOTREF(__pyx_t_1); + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { + PyObject *__pyx_temp[4] = {__pyx_t_2, __pyx_v_future, __pyx_v_future_instance, __pyx_v_future_attributes}; + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 464, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_GOTREF(__pyx_t_1); + } else + #endif + { + __pyx_t_5 = PyTuple_New(3+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + if (__pyx_t_2) { + __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_2); __pyx_t_2 = NULL; + } + __Pyx_INCREF(__pyx_v_future); + __Pyx_GIVEREF(__pyx_v_future); + PyTuple_SET_ITEM(__pyx_t_5, 0+__pyx_t_4, __pyx_v_future); + __Pyx_INCREF(__pyx_v_future_instance); + __Pyx_GIVEREF(__pyx_v_future_instance); + PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_4, __pyx_v_future_instance); + __Pyx_INCREF(__pyx_v_future_attributes); + __Pyx_GIVEREF(__pyx_v_future_attributes); + PyTuple_SET_ITEM(__pyx_t_5, 2+__pyx_t_4, __pyx_v_future_attributes); + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + } + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_attributes_ready = __pyx_t_1; + __pyx_t_1 = 0; + + /* "providers.pxd":465 + * + * attributes_ready = asyncio.gather(future, future_instance, future_attributes) + * attributes_ready.add_done_callback(__async_inject_attributes_callback) # <<<<<<<<<<<<<< + * asyncio.ensure_future(attributes_ready) + * + */ + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_attributes_ready, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 465, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_5 = __Pyx_CFunc_void____object___to_py(__pyx_f_19dependency_injector_9providers___async_inject_attributes_callback); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 465, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_5); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 465, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":466 + * attributes_ready = asyncio.gather(future, future_instance, future_attributes) + * attributes_ready.add_done_callback(__async_inject_attributes_callback) + * asyncio.ensure_future(attributes_ready) # <<<<<<<<<<<<<< + * + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 466, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 466, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_3, __pyx_v_attributes_ready) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_attributes_ready); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 466, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":468 + * asyncio.ensure_future(attributes_ready) + * + * return future_result # <<<<<<<<<<<<<< + * + * cdef inline void __async_inject_attributes_callback(future): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "providers.pxd":458 + * + * + * cdef inline object __async_inject_attributes(future_instance, future_attributes): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_AddTraceback("dependency_injector.providers.__async_inject_attributes", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = 0; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_future); + __Pyx_XDECREF(__pyx_v_attributes_ready); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "providers.pxd":470 + * return future_result + * + * cdef inline void __async_inject_attributes_callback(future): # <<<<<<<<<<<<<< + * future_result, instance, attributes = future.result() + * __inject_attributes(instance, attributes) + */ + +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_inject_attributes_callback(PyObject *__pyx_v_future) { + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_instance = NULL; + PyObject *__pyx_v_attributes = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *(*__pyx_t_6)(PyObject *); + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__async_inject_attributes_callback", 0); + + /* "providers.pxd":471 + * + * cdef inline void __async_inject_attributes_callback(future): + * future_result, instance, attributes = future.result() # <<<<<<<<<<<<<< + * __inject_attributes(instance, attributes) + * future_result.set_result(instance) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + if ((likely(PyTuple_CheckExact(__pyx_t_1))) || (PyList_CheckExact(__pyx_t_1))) { + PyObject* sequence = __pyx_t_1; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 3)) { + if (size > 3) __Pyx_RaiseTooManyValuesError(3); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(1, 471, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_2 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_3 = PyTuple_GET_ITEM(sequence, 1); + __pyx_t_4 = PyTuple_GET_ITEM(sequence, 2); + } else { + __pyx_t_2 = PyList_GET_ITEM(sequence, 0); + __pyx_t_3 = PyList_GET_ITEM(sequence, 1); + __pyx_t_4 = PyList_GET_ITEM(sequence, 2); + } + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + #else + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + #endif + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_5 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_6 = Py_TYPE(__pyx_t_5)->tp_iternext; + index = 0; __pyx_t_2 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_2)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_2); + index = 1; __pyx_t_3 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_3)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_3); + index = 2; __pyx_t_4 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_4)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_4); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_6(__pyx_t_5), 3) < 0) __PYX_ERR(1, 471, __pyx_L1_error) + __pyx_t_6 = NULL; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + goto __pyx_L4_unpacking_done; + __pyx_L3_unpacking_failed:; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_6 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(1, 471, __pyx_L1_error) + __pyx_L4_unpacking_done:; + } + __pyx_v_future_result = __pyx_t_2; + __pyx_t_2 = 0; + __pyx_v_instance = __pyx_t_3; + __pyx_t_3 = 0; + __pyx_v_attributes = __pyx_t_4; + __pyx_t_4 = 0; + + /* "providers.pxd":472 + * cdef inline void __async_inject_attributes_callback(future): + * future_result, instance, attributes = future.result() + * __inject_attributes(instance, attributes) # <<<<<<<<<<<<<< + * future_result.set_result(instance) + * + */ + if (!(likely(PyDict_CheckExact(__pyx_v_attributes))||((__pyx_v_attributes) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_attributes)->tp_name), 0))) __PYX_ERR(1, 472, __pyx_L1_error) + __pyx_f_19dependency_injector_9providers___inject_attributes(__pyx_v_instance, ((PyObject*)__pyx_v_attributes)); + + /* "providers.pxd":473 + * future_result, instance, attributes = future.result() + * __inject_attributes(instance, attributes) + * future_result.set_result(instance) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 473, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_3, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 473, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":470 + * return future_result + * + * cdef inline void __async_inject_attributes_callback(future): # <<<<<<<<<<<<<< + * future_result, instance, attributes = future.result() + * __inject_attributes(instance, attributes) + */ + + /* function exit code */ + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_WriteUnraisable("dependency_injector.providers.__async_inject_attributes_callback", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_attributes); + __Pyx_RefNannyFinishContext(); +} + +/* "providers.pxd":476 + * + * + * cdef inline void __inject_attributes(object instance, dict attributes): # <<<<<<<<<<<<<< + * for name, value in attributes.items(): + * setattr(instance, name, value) + */ + +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___inject_attributes(PyObject *__pyx_v_instance, PyObject *__pyx_v_attributes) { + PyObject *__pyx_v_name = NULL; + PyObject *__pyx_v_value = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + Py_ssize_t __pyx_t_3; + PyObject *(*__pyx_t_4)(PyObject *); + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + PyObject *__pyx_t_7 = NULL; + PyObject *(*__pyx_t_8)(PyObject *); + int __pyx_t_9; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__inject_attributes", 0); + + /* "providers.pxd":477 + * + * cdef inline void __inject_attributes(object instance, dict attributes): + * for name, value in attributes.items(): # <<<<<<<<<<<<<< + * setattr(instance, name, value) + * + */ + if (unlikely(__pyx_v_attributes == Py_None)) { + PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "items"); + __PYX_ERR(1, 477, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_PyDict_Items(__pyx_v_attributes); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { + __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; + __pyx_t_4 = NULL; + } else { + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 477, __pyx_L1_error) + } + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + for (;;) { + if (likely(!__pyx_t_4)) { + if (likely(PyList_CheckExact(__pyx_t_2))) { + if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 477, __pyx_L1_error) + #else + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + #endif + } else { + if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 477, __pyx_L1_error) + #else + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + #endif + } + } else { + __pyx_t_1 = __pyx_t_4(__pyx_t_2); + if (unlikely(!__pyx_t_1)) { + PyObject* exc_type = PyErr_Occurred(); + if (exc_type) { + if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); + else __PYX_ERR(1, 477, __pyx_L1_error) + } + break; + } + __Pyx_GOTREF(__pyx_t_1); + } + if ((likely(PyTuple_CheckExact(__pyx_t_1))) || (PyList_CheckExact(__pyx_t_1))) { + PyObject* sequence = __pyx_t_1; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 2)) { + if (size > 2) __Pyx_RaiseTooManyValuesError(2); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(1, 477, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_5 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_6 = PyTuple_GET_ITEM(sequence, 1); + } else { + __pyx_t_5 = PyList_GET_ITEM(sequence, 0); + __pyx_t_6 = PyList_GET_ITEM(sequence, 1); + } + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + #else + __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + #endif + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; + index = 0; __pyx_t_5 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_5)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_5); + index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_6); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 477, __pyx_L1_error) + __pyx_t_8 = NULL; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + goto __pyx_L6_unpacking_done; + __pyx_L5_unpacking_failed:; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_8 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(1, 477, __pyx_L1_error) + __pyx_L6_unpacking_done:; + } + __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_5); + __pyx_t_5 = 0; + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_6); + __pyx_t_6 = 0; + + /* "providers.pxd":478 + * cdef inline void __inject_attributes(object instance, dict attributes): + * for name, value in attributes.items(): + * setattr(instance, name, value) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_9 = PyObject_SetAttr(__pyx_v_instance, __pyx_v_name, __pyx_v_value); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(1, 478, __pyx_L1_error) + + /* "providers.pxd":477 + * + * cdef inline void __inject_attributes(object instance, dict attributes): + * for name, value in attributes.items(): # <<<<<<<<<<<<<< + * setattr(instance, name, value) + * + */ + } + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + + /* "providers.pxd":476 + * + * + * cdef inline void __inject_attributes(object instance, dict attributes): # <<<<<<<<<<<<<< + * for name, value in attributes.items(): + * setattr(instance, name, value) + */ + + /* function exit code */ + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_7); + __Pyx_WriteUnraisable("dependency_injector.providers.__inject_attributes", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_name); + __Pyx_XDECREF(__pyx_v_value); + __Pyx_RefNannyFinishContext(); +} + +/* "providers.pxd":481 * * * cdef inline object __call( # <<<<<<<<<<<<<< @@ -12253,64 +14401,525 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___inject * tuple context_args, */ -static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___call(PyObject *__pyx_v_call, PyObject *__pyx_v_context_args, PyObject *__pyx_v_injection_args, int __pyx_v_injection_args_len, PyObject *__pyx_v_kwargs, PyObject *__pyx_v_injection_kwargs, int __pyx_v_injection_kwargs_len) { - PyObject *__pyx_v_positional_args = 0; - PyObject *__pyx_v_keyword_args = 0; +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___call(PyObject *__pyx_v_call, PyObject *__pyx_v_context_args, PyObject *__pyx_v_injection_args, int __pyx_v_injection_args_len, PyObject *__pyx_v_context_kwargs, PyObject *__pyx_v_injection_kwargs, int __pyx_v_injection_kwargs_len) { + PyObject *__pyx_v_args = NULL; + PyObject *__pyx_v_kwargs = NULL; + int __pyx_v_args_awaitable; + int __pyx_v_kwargs_awaitable; + PyObject *__pyx_v_future = NULL; + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_args_kwargs_ready = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; + int __pyx_t_2; + int __pyx_t_3; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__call", 0); - /* "providers.pxd":421 - * cdef dict keyword_args - * - * positional_args = __provide_positional_args( # <<<<<<<<<<<<<< + /* "providers.pxd":490 + * int injection_kwargs_len, + * ): + * args = __provide_positional_args( # <<<<<<<<<<<<<< * context_args, * injection_args, */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___provide_positional_args(__pyx_v_context_args, __pyx_v_injection_args, __pyx_v_injection_args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 421, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___provide_positional_args(__pyx_v_context_args, __pyx_v_injection_args, __pyx_v_injection_args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 490, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_v_positional_args = ((PyObject*)__pyx_t_1); + __pyx_v_args = __pyx_t_1; __pyx_t_1 = 0; - /* "providers.pxd":426 + /* "providers.pxd":495 * injection_args_len, * ) - * keyword_args = __provide_keyword_args( # <<<<<<<<<<<<<< - * kwargs, + * kwargs = __provide_keyword_args( # <<<<<<<<<<<<<< + * context_kwargs, * injection_kwargs, */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___provide_keyword_args(__pyx_v_kwargs, __pyx_v_injection_kwargs, __pyx_v_injection_kwargs_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 426, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___provide_keyword_args(__pyx_v_context_kwargs, __pyx_v_injection_kwargs, __pyx_v_injection_kwargs_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_v_keyword_args = ((PyObject*)__pyx_t_1); + __pyx_v_kwargs = __pyx_t_1; __pyx_t_1 = 0; - /* "providers.pxd":432 + /* "providers.pxd":501 * ) * - * return call(*positional_args, **keyword_args) # <<<<<<<<<<<<<< + * args_awaitable = __isawaitable(args) # <<<<<<<<<<<<<< + * kwargs_awaitable = __isawaitable(kwargs) + * + */ + __pyx_v_args_awaitable = __pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_args); + + /* "providers.pxd":502 + * + * args_awaitable = __isawaitable(args) + * kwargs_awaitable = __isawaitable(kwargs) # <<<<<<<<<<<<<< + * + * if args_awaitable or kwargs_awaitable: + */ + __pyx_v_kwargs_awaitable = __pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_kwargs); + + /* "providers.pxd":504 + * kwargs_awaitable = __isawaitable(kwargs) + * + * if args_awaitable or kwargs_awaitable: # <<<<<<<<<<<<<< + * if not args_awaitable: + * future = asyncio.Future() + */ + __pyx_t_3 = (__pyx_v_args_awaitable != 0); + if (!__pyx_t_3) { + } else { + __pyx_t_2 = __pyx_t_3; + goto __pyx_L4_bool_binop_done; + } + __pyx_t_3 = (__pyx_v_kwargs_awaitable != 0); + __pyx_t_2 = __pyx_t_3; + __pyx_L4_bool_binop_done:; + if (__pyx_t_2) { + + /* "providers.pxd":505 + * + * if args_awaitable or kwargs_awaitable: + * if not args_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(args) + */ + __pyx_t_2 = ((!(__pyx_v_args_awaitable != 0)) != 0); + if (__pyx_t_2) { + + /* "providers.pxd":506 + * if args_awaitable or kwargs_awaitable: + * if not args_awaitable: + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result(args) + * args = future + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 506, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_Future); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 506, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 506, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_future = __pyx_t_1; + __pyx_t_1 = 0; + + /* "providers.pxd":507 + * if not args_awaitable: + * future = asyncio.Future() + * future.set_result(args) # <<<<<<<<<<<<<< + * args = future + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 507, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_v_args) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_args); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 507, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":508 + * future = asyncio.Future() + * future.set_result(args) + * args = future # <<<<<<<<<<<<<< + * + * if not kwargs_awaitable: + */ + __Pyx_INCREF(__pyx_v_future); + __Pyx_DECREF_SET(__pyx_v_args, __pyx_v_future); + + /* "providers.pxd":505 + * + * if args_awaitable or kwargs_awaitable: + * if not args_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(args) + */ + } + + /* "providers.pxd":510 + * args = future + * + * if not kwargs_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(kwargs) + */ + __pyx_t_2 = ((!(__pyx_v_kwargs_awaitable != 0)) != 0); + if (__pyx_t_2) { + + /* "providers.pxd":511 + * + * if not kwargs_awaitable: + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result(kwargs) + * kwargs = future + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 511, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_Future); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 511, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 511, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF_SET(__pyx_v_future, __pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":512 + * if not kwargs_awaitable: + * future = asyncio.Future() + * future.set_result(kwargs) # <<<<<<<<<<<<<< + * kwargs = future + * + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 512, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_kwargs) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_kwargs); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 512, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":513 + * future = asyncio.Future() + * future.set_result(kwargs) + * kwargs = future # <<<<<<<<<<<<<< + * + * future_result = asyncio.Future() + */ + __Pyx_INCREF(__pyx_v_future); + __Pyx_DECREF_SET(__pyx_v_kwargs, __pyx_v_future); + + /* "providers.pxd":510 + * args = future + * + * if not kwargs_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(kwargs) + */ + } + + /* "providers.pxd":515 + * kwargs = future + * + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * + * future = asyncio.Future() + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 515, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_Future); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 515, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 515, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_future_result = __pyx_t_1; + __pyx_t_1 = 0; + + /* "providers.pxd":517 + * future_result = asyncio.Future() + * + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result((future_result, call)) + * + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 517, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_Future); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 517, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 517, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF_SET(__pyx_v_future, __pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":518 + * + * future = asyncio.Future() + * future.set_result((future_result, call)) # <<<<<<<<<<<<<< + * + * args_kwargs_ready = asyncio.gather(future, args, kwargs) + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 518, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 518, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_v_future_result); + __Pyx_INCREF(__pyx_v_call); + __Pyx_GIVEREF(__pyx_v_call); + PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_v_call); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 518, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":520 + * future.set_result((future_result, call)) + * + * args_kwargs_ready = asyncio.gather(future, args, kwargs) # <<<<<<<<<<<<<< + * args_kwargs_ready.add_done_callback(__async_call_callback) + * asyncio.ensure_future(args_kwargs_ready) + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 520, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_gather); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 520, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + __pyx_t_7 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + __pyx_t_7 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_5)) { + PyObject *__pyx_temp[4] = {__pyx_t_4, __pyx_v_future, __pyx_v_args, __pyx_v_kwargs}; + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 520, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_GOTREF(__pyx_t_1); + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { + PyObject *__pyx_temp[4] = {__pyx_t_4, __pyx_v_future, __pyx_v_args, __pyx_v_kwargs}; + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 520, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_GOTREF(__pyx_t_1); + } else + #endif + { + __pyx_t_6 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 520, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + if (__pyx_t_4) { + __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; + } + __Pyx_INCREF(__pyx_v_future); + __Pyx_GIVEREF(__pyx_v_future); + PyTuple_SET_ITEM(__pyx_t_6, 0+__pyx_t_7, __pyx_v_future); + __Pyx_INCREF(__pyx_v_args); + __Pyx_GIVEREF(__pyx_v_args); + PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_7, __pyx_v_args); + __Pyx_INCREF(__pyx_v_kwargs); + __Pyx_GIVEREF(__pyx_v_kwargs); + PyTuple_SET_ITEM(__pyx_t_6, 2+__pyx_t_7, __pyx_v_kwargs); + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 520, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_args_kwargs_ready = __pyx_t_1; + __pyx_t_1 = 0; + + /* "providers.pxd":521 + * + * args_kwargs_ready = asyncio.gather(future, args, kwargs) + * args_kwargs_ready.add_done_callback(__async_call_callback) # <<<<<<<<<<<<<< + * asyncio.ensure_future(args_kwargs_ready) + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_args_kwargs_ready, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 521, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = __Pyx_CFunc_void____object___to_py(__pyx_f_19dependency_injector_9providers___async_call_callback); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 521, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 521, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":522 + * args_kwargs_ready = asyncio.gather(future, args, kwargs) + * args_kwargs_ready.add_done_callback(__async_call_callback) + * asyncio.ensure_future(args_kwargs_ready) # <<<<<<<<<<<<<< + * + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 522, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 522, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_6, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_5, __pyx_v_args_kwargs_ready) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_args_kwargs_ready); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 522, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":524 + * asyncio.ensure_future(args_kwargs_ready) + * + * return future_result # <<<<<<<<<<<<<< + * + * return call(*args, **kwargs) + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "providers.pxd":504 + * kwargs_awaitable = __isawaitable(kwargs) + * + * if args_awaitable or kwargs_awaitable: # <<<<<<<<<<<<<< + * if not args_awaitable: + * future = asyncio.Future() + */ + } + + /* "providers.pxd":526 + * return future_result + * + * return call(*args, **kwargs) # <<<<<<<<<<<<<< * * */ __Pyx_XDECREF(__pyx_r); - if (unlikely(__pyx_v_positional_args == Py_None)) { - PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 432, __pyx_L1_error) - } - if (unlikely(__pyx_v_keyword_args == Py_None)) { - PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 432, __pyx_L1_error) - } - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_v_call, __pyx_v_positional_args, __pyx_v_keyword_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 432, __pyx_L1_error) + __pyx_t_1 = __Pyx_PySequence_Tuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 526, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_r = __pyx_t_1; - __pyx_t_1 = 0; + if (unlikely(__pyx_v_kwargs == Py_None)) { + PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); + __PYX_ERR(1, 526, __pyx_L1_error) + } + if (likely(PyDict_CheckExact(__pyx_v_kwargs))) { + __pyx_t_6 = PyDict_Copy(__pyx_v_kwargs); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 526, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + } else { + __pyx_t_6 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_v_kwargs, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 526, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + } + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_v_call, __pyx_t_1, __pyx_t_6); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 526, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_r = __pyx_t_5; + __pyx_t_5 = 0; goto __pyx_L0; - /* "providers.pxd":409 + /* "providers.pxd":481 * * * cdef inline object __call( # <<<<<<<<<<<<<< @@ -12321,17 +14930,264 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___call(P /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.__call", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; - __Pyx_XDECREF(__pyx_v_positional_args); - __Pyx_XDECREF(__pyx_v_keyword_args); + __Pyx_XDECREF(__pyx_v_args); + __Pyx_XDECREF(__pyx_v_kwargs); + __Pyx_XDECREF(__pyx_v_future); + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_args_kwargs_ready); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "providers.pxd":435 +/* "providers.pxd":529 + * + * + * cdef inline void __async_call_callback(object future): # <<<<<<<<<<<<<< + * (future_result, call), args, kwargs = future.result() + * result = call(*args, **kwargs) + */ + +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_call_callback(PyObject *__pyx_v_future) { + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_call = NULL; + PyObject *__pyx_v_args = NULL; + PyObject *__pyx_v_kwargs = NULL; + PyObject *__pyx_v_result = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *(*__pyx_t_6)(PyObject *); + PyObject *__pyx_t_7 = NULL; + PyObject *__pyx_t_8 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__async_call_callback", 0); + + /* "providers.pxd":530 + * + * cdef inline void __async_call_callback(object future): + * (future_result, call), args, kwargs = future.result() # <<<<<<<<<<<<<< + * result = call(*args, **kwargs) + * future_result.set_result(result) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + if ((likely(PyTuple_CheckExact(__pyx_t_1))) || (PyList_CheckExact(__pyx_t_1))) { + PyObject* sequence = __pyx_t_1; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 3)) { + if (size > 3) __Pyx_RaiseTooManyValuesError(3); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(1, 530, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_2 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_3 = PyTuple_GET_ITEM(sequence, 1); + __pyx_t_4 = PyTuple_GET_ITEM(sequence, 2); + } else { + __pyx_t_2 = PyList_GET_ITEM(sequence, 0); + __pyx_t_3 = PyList_GET_ITEM(sequence, 1); + __pyx_t_4 = PyList_GET_ITEM(sequence, 2); + } + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + #else + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + #endif + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_5 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_6 = Py_TYPE(__pyx_t_5)->tp_iternext; + index = 0; __pyx_t_2 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_2)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_2); + index = 1; __pyx_t_3 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_3)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_3); + index = 2; __pyx_t_4 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_4)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_4); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_6(__pyx_t_5), 3) < 0) __PYX_ERR(1, 530, __pyx_L1_error) + __pyx_t_6 = NULL; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + goto __pyx_L4_unpacking_done; + __pyx_L3_unpacking_failed:; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_6 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(1, 530, __pyx_L1_error) + __pyx_L4_unpacking_done:; + } + if ((likely(PyTuple_CheckExact(__pyx_t_2))) || (PyList_CheckExact(__pyx_t_2))) { + PyObject* sequence = __pyx_t_2; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 2)) { + if (size > 2) __Pyx_RaiseTooManyValuesError(2); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(1, 530, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_5 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_7 = PyTuple_GET_ITEM(sequence, 1); + } else { + __pyx_t_5 = PyList_GET_ITEM(sequence, 0); + __pyx_t_7 = PyList_GET_ITEM(sequence, 1); + } + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(__pyx_t_7); + #else + __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_7 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + #endif + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_8 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_6 = Py_TYPE(__pyx_t_8)->tp_iternext; + index = 0; __pyx_t_5 = __pyx_t_6(__pyx_t_8); if (unlikely(!__pyx_t_5)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_5); + index = 1; __pyx_t_7 = __pyx_t_6(__pyx_t_8); if (unlikely(!__pyx_t_7)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_7); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_6(__pyx_t_8), 2) < 0) __PYX_ERR(1, 530, __pyx_L1_error) + __pyx_t_6 = NULL; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + goto __pyx_L6_unpacking_done; + __pyx_L5_unpacking_failed:; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_6 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(1, 530, __pyx_L1_error) + __pyx_L6_unpacking_done:; + } + __pyx_v_future_result = __pyx_t_5; + __pyx_t_5 = 0; + __pyx_v_call = __pyx_t_7; + __pyx_t_7 = 0; + __pyx_v_args = __pyx_t_3; + __pyx_t_3 = 0; + __pyx_v_kwargs = __pyx_t_4; + __pyx_t_4 = 0; + + /* "providers.pxd":531 + * cdef inline void __async_call_callback(object future): + * (future_result, call), args, kwargs = future.result() + * result = call(*args, **kwargs) # <<<<<<<<<<<<<< + * future_result.set_result(result) + * + */ + __pyx_t_1 = __Pyx_PySequence_Tuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 531, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (unlikely(__pyx_v_kwargs == Py_None)) { + PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); + __PYX_ERR(1, 531, __pyx_L1_error) + } + if (likely(PyDict_CheckExact(__pyx_v_kwargs))) { + __pyx_t_4 = PyDict_Copy(__pyx_v_kwargs); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 531, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + } else { + __pyx_t_4 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_v_kwargs, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 531, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + } + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_v_call, __pyx_t_1, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 531, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_v_result = __pyx_t_3; + __pyx_t_3 = 0; + + /* "providers.pxd":532 + * (future_result, call), args, kwargs = future.result() + * result = call(*args, **kwargs) + * future_result.set_result(result) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 532, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_1 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_1 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_1)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_1); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_3 = (__pyx_t_1) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_1, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 532, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "providers.pxd":529 + * + * + * cdef inline void __async_call_callback(object future): # <<<<<<<<<<<<<< + * (future_result, call), args, kwargs = future.result() + * result = call(*args, **kwargs) + */ + + /* function exit code */ + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_WriteUnraisable("dependency_injector.providers.__async_call_callback", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_call); + __Pyx_XDECREF(__pyx_v_args); + __Pyx_XDECREF(__pyx_v_kwargs); + __Pyx_XDECREF(__pyx_v_result); + __Pyx_RefNannyFinishContext(); +} + +/* "providers.pxd":535 * * * cdef inline object __callable_call(Callable self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -12351,7 +15207,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__callable_call", 0); - /* "providers.pxd":436 + /* "providers.pxd":536 * * cdef inline object __callable_call(Callable self, tuple args, dict kwargs): * return __call( # <<<<<<<<<<<<<< @@ -12360,7 +15216,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab */ __Pyx_XDECREF(__pyx_r); - /* "providers.pxd":437 + /* "providers.pxd":537 * cdef inline object __callable_call(Callable self, tuple args, dict kwargs): * return __call( * self.__provides, # <<<<<<<<<<<<<< @@ -12370,7 +15226,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab __pyx_t_1 = __pyx_v_self->__pyx___provides; __Pyx_INCREF(__pyx_t_1); - /* "providers.pxd":439 + /* "providers.pxd":539 * self.__provides, * args, * self.__args, # <<<<<<<<<<<<<< @@ -12380,7 +15236,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab __pyx_t_2 = __pyx_v_self->__pyx___args; __Pyx_INCREF(__pyx_t_2); - /* "providers.pxd":442 + /* "providers.pxd":542 * self.__args_len, * kwargs, * self.__kwargs, # <<<<<<<<<<<<<< @@ -12390,14 +15246,14 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab __pyx_t_3 = __pyx_v_self->__pyx___kwargs; __Pyx_INCREF(__pyx_t_3); - /* "providers.pxd":436 + /* "providers.pxd":536 * * cdef inline object __callable_call(Callable self, tuple args, dict kwargs): * return __call( # <<<<<<<<<<<<<< * self.__provides, * args, */ - __pyx_t_4 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_1, __pyx_v_args, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_3), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 436, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_1, __pyx_v_args, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_3), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 536, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -12406,7 +15262,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab __pyx_t_4 = 0; goto __pyx_L0; - /* "providers.pxd":435 + /* "providers.pxd":535 * * * cdef inline object __callable_call(Callable self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -12428,7 +15284,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab return __pyx_r; } -/* "providers.pxd":447 +/* "providers.pxd":547 * * * cdef inline object __factory_call(Factory self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -12438,17 +15294,23 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___factory_call(struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs) { PyObject *__pyx_v_instance = 0; + PyObject *__pyx_v_attributes = NULL; + int __pyx_v_instance_awaitable; + int __pyx_v_attributes_awaitable; + PyObject *__pyx_v_future = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; int __pyx_t_3; + int __pyx_t_4; + PyObject *__pyx_t_5 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__factory_call", 0); - /* "providers.pxd":450 + /* "providers.pxd":550 * cdef object instance * * instance = __callable_call(self.__instantiator, args, kwargs) # <<<<<<<<<<<<<< @@ -12457,64 +15319,298 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___factor */ __pyx_t_1 = ((PyObject *)__pyx_v_self->__pyx___instantiator); __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers___callable_call(((struct __pyx_obj_19dependency_injector_9providers_Callable *)__pyx_t_1), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 450, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers___callable_call(((struct __pyx_obj_19dependency_injector_9providers_Callable *)__pyx_t_1), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 550, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_instance = __pyx_t_2; __pyx_t_2 = 0; - /* "providers.pxd":452 + /* "providers.pxd":552 * instance = __callable_call(self.__instantiator, args, kwargs) * * if self.__attributes_len > 0: # <<<<<<<<<<<<<< - * __inject_attributes(instance, - * self.__attributes, + * attributes = __provide_attributes(self.__attributes, self.__attributes_len) + * */ __pyx_t_3 = ((__pyx_v_self->__pyx___attributes_len > 0) != 0); if (__pyx_t_3) { - /* "providers.pxd":454 - * if self.__attributes_len > 0: - * __inject_attributes(instance, - * self.__attributes, # <<<<<<<<<<<<<< - * self.__attributes_len) + /* "providers.pxd":553 * + * if self.__attributes_len > 0: + * attributes = __provide_attributes(self.__attributes, self.__attributes_len) # <<<<<<<<<<<<<< + * + * instance_awaitable = __isawaitable(instance) */ __pyx_t_2 = __pyx_v_self->__pyx___attributes; __Pyx_INCREF(__pyx_t_2); - - /* "providers.pxd":453 - * - * if self.__attributes_len > 0: - * __inject_attributes(instance, # <<<<<<<<<<<<<< - * self.__attributes, - * self.__attributes_len) - */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___inject_attributes(__pyx_v_instance, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___attributes_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 453, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___provide_attributes(((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___attributes_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 553, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v_attributes = __pyx_t_1; + __pyx_t_1 = 0; - /* "providers.pxd":452 + /* "providers.pxd":555 + * attributes = __provide_attributes(self.__attributes, self.__attributes_len) + * + * instance_awaitable = __isawaitable(instance) # <<<<<<<<<<<<<< + * attributes_awaitable = __isawaitable(attributes) + * + */ + __pyx_v_instance_awaitable = __pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_instance); + + /* "providers.pxd":556 + * + * instance_awaitable = __isawaitable(instance) + * attributes_awaitable = __isawaitable(attributes) # <<<<<<<<<<<<<< + * + * if instance_awaitable or attributes_awaitable: + */ + __pyx_v_attributes_awaitable = __pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_attributes); + + /* "providers.pxd":558 + * attributes_awaitable = __isawaitable(attributes) + * + * if instance_awaitable or attributes_awaitable: # <<<<<<<<<<<<<< + * if not instance_awaitable: + * future = asyncio.Future() + */ + __pyx_t_4 = (__pyx_v_instance_awaitable != 0); + if (!__pyx_t_4) { + } else { + __pyx_t_3 = __pyx_t_4; + goto __pyx_L5_bool_binop_done; + } + __pyx_t_4 = (__pyx_v_attributes_awaitable != 0); + __pyx_t_3 = __pyx_t_4; + __pyx_L5_bool_binop_done:; + if (__pyx_t_3) { + + /* "providers.pxd":559 + * + * if instance_awaitable or attributes_awaitable: + * if not instance_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(instance) + */ + __pyx_t_3 = ((!(__pyx_v_instance_awaitable != 0)) != 0); + if (__pyx_t_3) { + + /* "providers.pxd":560 + * if instance_awaitable or attributes_awaitable: + * if not instance_awaitable: + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result(instance) + * instance = future + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 560, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_Future); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 560, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 560, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_future = __pyx_t_1; + __pyx_t_1 = 0; + + /* "providers.pxd":561 + * if not instance_awaitable: + * future = asyncio.Future() + * future.set_result(instance) # <<<<<<<<<<<<<< + * instance = future + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 561, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_2, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 561, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":562 + * future = asyncio.Future() + * future.set_result(instance) + * instance = future # <<<<<<<<<<<<<< + * + * if not attributes_awaitable: + */ + __Pyx_INCREF(__pyx_v_future); + __Pyx_DECREF_SET(__pyx_v_instance, __pyx_v_future); + + /* "providers.pxd":559 + * + * if instance_awaitable or attributes_awaitable: + * if not instance_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(instance) + */ + } + + /* "providers.pxd":564 + * instance = future + * + * if not attributes_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(attributes) + */ + __pyx_t_3 = ((!(__pyx_v_attributes_awaitable != 0)) != 0); + if (__pyx_t_3) { + + /* "providers.pxd":565 + * + * if not attributes_awaitable: + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result(attributes) + * attributes = future + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 565, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_Future); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 565, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 565, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF_SET(__pyx_v_future, __pyx_t_1); + __pyx_t_1 = 0; + + /* "providers.pxd":566 + * if not attributes_awaitable: + * future = asyncio.Future() + * future.set_result(attributes) # <<<<<<<<<<<<<< + * attributes = future + * + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 566, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_5, __pyx_v_attributes) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_attributes); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 566, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "providers.pxd":567 + * future = asyncio.Future() + * future.set_result(attributes) + * attributes = future # <<<<<<<<<<<<<< + * + * return __async_inject_attributes(instance, attributes) + */ + __Pyx_INCREF(__pyx_v_future); + __Pyx_DECREF_SET(__pyx_v_attributes, __pyx_v_future); + + /* "providers.pxd":564 + * instance = future + * + * if not attributes_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(attributes) + */ + } + + /* "providers.pxd":569 + * attributes = future + * + * return __async_inject_attributes(instance, attributes) # <<<<<<<<<<<<<< + * + * __inject_attributes(instance, attributes) + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___async_inject_attributes(__pyx_v_instance, __pyx_v_attributes); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 569, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* "providers.pxd":558 + * attributes_awaitable = __isawaitable(attributes) + * + * if instance_awaitable or attributes_awaitable: # <<<<<<<<<<<<<< + * if not instance_awaitable: + * future = asyncio.Future() + */ + } + + /* "providers.pxd":571 + * return __async_inject_attributes(instance, attributes) + * + * __inject_attributes(instance, attributes) # <<<<<<<<<<<<<< + * + * return instance + */ + if (!(likely(PyDict_CheckExact(__pyx_v_attributes))||((__pyx_v_attributes) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_attributes)->tp_name), 0))) __PYX_ERR(1, 571, __pyx_L1_error) + __pyx_f_19dependency_injector_9providers___inject_attributes(__pyx_v_instance, ((PyObject*)__pyx_v_attributes)); + + /* "providers.pxd":552 * instance = __callable_call(self.__instantiator, args, kwargs) * * if self.__attributes_len > 0: # <<<<<<<<<<<<<< - * __inject_attributes(instance, - * self.__attributes, + * attributes = __provide_attributes(self.__attributes, self.__attributes_len) + * */ } - /* "providers.pxd":457 - * self.__attributes_len) + /* "providers.pxd":573 + * __inject_attributes(instance, attributes) * * return instance # <<<<<<<<<<<<<< + * + * */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_instance); __pyx_r = __pyx_v_instance; goto __pyx_L0; - /* "providers.pxd":447 + /* "providers.pxd":547 * * * cdef inline object __factory_call(Factory self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -12526,10 +15622,314 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___factor __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_5); __Pyx_AddTraceback("dependency_injector.providers.__factory_call", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_attributes); + __Pyx_XDECREF(__pyx_v_future); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "providers.pxd":579 + * + * + * cdef inline bint __isawaitable(object instance): # <<<<<<<<<<<<<< + * global __has_isawaitable + * + */ + +static CYTHON_INLINE int __pyx_f_19dependency_injector_9providers___isawaitable(PyObject *__pyx_v_instance) { + int __pyx_r; + __Pyx_RefNannyDeclarations + int __pyx_t_1; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + int __pyx_t_5; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__isawaitable", 0); + + /* "providers.pxd":582 + * global __has_isawaitable + * + * if __has_isawaitable is True: # <<<<<<<<<<<<<< + * return inspect.isawaitable(instance) + * + */ + __pyx_t_1 = ((__pyx_v_19dependency_injector_9providers___has_isawaitable == 1) != 0); + if (__pyx_t_1) { + + /* "providers.pxd":583 + * + * if __has_isawaitable is True: + * return inspect.isawaitable(instance) # <<<<<<<<<<<<<< + * + * if hasattr(inspect, 'isawaitable'): + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_inspect); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 583, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_isawaitable); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 583, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_3, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 583, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 583, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; + goto __pyx_L0; + + /* "providers.pxd":582 + * global __has_isawaitable + * + * if __has_isawaitable is True: # <<<<<<<<<<<<<< + * return inspect.isawaitable(instance) + * + */ + } + + /* "providers.pxd":585 + * return inspect.isawaitable(instance) + * + * if hasattr(inspect, 'isawaitable'): # <<<<<<<<<<<<<< + * __has_isawaitable = True + * return inspect.isawaitable(instance) + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_inspect); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 585, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_1 = __Pyx_HasAttr(__pyx_t_2, __pyx_n_s_isawaitable); if (unlikely(__pyx_t_1 == ((int)-1))) __PYX_ERR(1, 585, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_5 = (__pyx_t_1 != 0); + if (__pyx_t_5) { + + /* "providers.pxd":586 + * + * if hasattr(inspect, 'isawaitable'): + * __has_isawaitable = True # <<<<<<<<<<<<<< + * return inspect.isawaitable(instance) + * + */ + __pyx_v_19dependency_injector_9providers___has_isawaitable = 1; + + /* "providers.pxd":587 + * if hasattr(inspect, 'isawaitable'): + * __has_isawaitable = True + * return inspect.isawaitable(instance) # <<<<<<<<<<<<<< + * + * return False + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_inspect); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 587, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_isawaitable); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 587, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 587, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 587, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_r = __pyx_t_5; + goto __pyx_L0; + + /* "providers.pxd":585 + * return inspect.isawaitable(instance) + * + * if hasattr(inspect, 'isawaitable'): # <<<<<<<<<<<<<< + * __has_isawaitable = True + * return inspect.isawaitable(instance) + */ + } + + /* "providers.pxd":589 + * return inspect.isawaitable(instance) + * + * return False # <<<<<<<<<<<<<< + */ + __pyx_r = 0; + goto __pyx_L0; + + /* "providers.pxd":579 + * + * + * cdef inline bint __isawaitable(object instance): # <<<<<<<<<<<<<< + * global __has_isawaitable + * + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_WriteUnraisable("dependency_injector.providers.__isawaitable", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_r = 0; + __pyx_L0:; + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "cfunc.to_py":65 + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): + * def wrap(object future): # <<<<<<<<<<<<<< + * """wrap(future) -> 'void'""" + * f(future) + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_1wrap(PyObject *__pyx_self, PyObject *__pyx_v_future); /*proto*/ +static char __pyx_doc_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_wrap[] = "wrap(future) -> 'void'"; +static PyMethodDef __pyx_mdef_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_1wrap = {"wrap", (PyCFunction)__pyx_pw_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_1wrap, METH_O, __pyx_doc_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_wrap}; +static PyObject *__pyx_pw_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_1wrap(PyObject *__pyx_self, PyObject *__pyx_v_future) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("wrap (wrapper)", 0); + __pyx_r = __pyx_pf_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_wrap(__pyx_self, ((PyObject *)__pyx_v_future)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_wrap(PyObject *__pyx_self, PyObject *__pyx_v_future) { + struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *__pyx_cur_scope; + struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *__pyx_outer_scope; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("wrap", 0); + __pyx_outer_scope = (struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *) __Pyx_CyFunction_GetClosure(__pyx_self); + __pyx_cur_scope = __pyx_outer_scope; + + /* "cfunc.to_py":67 + * def wrap(object future): + * """wrap(future) -> 'void'""" + * f(future) # <<<<<<<<<<<<<< + * return wrap + * + */ + __pyx_cur_scope->__pyx_v_f(__pyx_v_future); if (unlikely(PyErr_Occurred())) __PYX_ERR(2, 67, __pyx_L1_error) + + /* "cfunc.to_py":65 + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): + * def wrap(object future): # <<<<<<<<<<<<<< + * """wrap(future) -> 'void'""" + * f(future) + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_AddTraceback("cfunc.to_py.__Pyx_CFunc_void____object___to_py.wrap", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "cfunc.to_py":64 + * + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): # <<<<<<<<<<<<<< + * def wrap(object future): + * """wrap(future) -> 'void'""" + */ + +static PyObject *__Pyx_CFunc_void____object___to_py(void (*__pyx_v_f)(PyObject *)) { + struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *__pyx_cur_scope; + PyObject *__pyx_v_wrap = 0; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__Pyx_CFunc_void____object___to_py", 0); + __pyx_cur_scope = (struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *)__pyx_tp_new___pyx_scope_struct____Pyx_CFunc_void____object___to_py(__pyx_ptype___pyx_scope_struct____Pyx_CFunc_void____object___to_py, __pyx_empty_tuple, NULL); + if (unlikely(!__pyx_cur_scope)) { + __pyx_cur_scope = ((struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *)Py_None); + __Pyx_INCREF(Py_None); + __PYX_ERR(2, 64, __pyx_L1_error) + } else { + __Pyx_GOTREF(__pyx_cur_scope); + } + __pyx_cur_scope->__pyx_v_f = __pyx_v_f; + + /* "cfunc.to_py":65 + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): + * def wrap(object future): # <<<<<<<<<<<<<< + * """wrap(future) -> 'void'""" + * f(future) + */ + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_1wrap, 0, __pyx_n_s_Pyx_CFunc_void____object___to, ((PyObject*)__pyx_cur_scope), __pyx_n_s_cfunc_to_py, __pyx_d, ((PyObject *)__pyx_codeobj__9)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 65, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_wrap = __pyx_t_1; + __pyx_t_1 = 0; + + /* "cfunc.to_py":68 + * """wrap(future) -> 'void'""" + * f(future) + * return wrap # <<<<<<<<<<<<<< + * + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_wrap); + __pyx_r = __pyx_v_wrap; + goto __pyx_L0; + + /* "cfunc.to_py":64 + * + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): # <<<<<<<<<<<<<< + * def wrap(object future): + * """wrap(future) -> 'void'""" + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_AddTraceback("cfunc.to_py.__Pyx_CFunc_void____object___to_py", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = 0; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_wrap); + __Pyx_DECREF(((PyObject *)__pyx_cur_scope)); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; @@ -13249,9 +16649,103 @@ static PyTypeObject __pyx_type_19dependency_injector_10containers___pyx_scope_st #endif }; +static struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *__pyx_freelist___pyx_scope_struct____Pyx_CFunc_void____object___to_py[8]; +static int __pyx_freecount___pyx_scope_struct____Pyx_CFunc_void____object___to_py = 0; + +static PyObject *__pyx_tp_new___pyx_scope_struct____Pyx_CFunc_void____object___to_py(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) { + PyObject *o; + if (CYTHON_COMPILING_IN_CPYTHON && likely((__pyx_freecount___pyx_scope_struct____Pyx_CFunc_void____object___to_py > 0) & (t->tp_basicsize == sizeof(struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py)))) { + o = (PyObject*)__pyx_freelist___pyx_scope_struct____Pyx_CFunc_void____object___to_py[--__pyx_freecount___pyx_scope_struct____Pyx_CFunc_void____object___to_py]; + memset(o, 0, sizeof(struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py)); + (void) PyObject_INIT(o, t); + } else { + o = (*t->tp_alloc)(t, 0); + if (unlikely(!o)) return 0; + } + return o; +} + +static void __pyx_tp_dealloc___pyx_scope_struct____Pyx_CFunc_void____object___to_py(PyObject *o) { + if (CYTHON_COMPILING_IN_CPYTHON && ((__pyx_freecount___pyx_scope_struct____Pyx_CFunc_void____object___to_py < 8) & (Py_TYPE(o)->tp_basicsize == sizeof(struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py)))) { + __pyx_freelist___pyx_scope_struct____Pyx_CFunc_void____object___to_py[__pyx_freecount___pyx_scope_struct____Pyx_CFunc_void____object___to_py++] = ((struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *)o); + } else { + (*Py_TYPE(o)->tp_free)(o); + } +} + +static PyTypeObject __pyx_scope_struct____Pyx_CFunc_void____object___to_py = { + PyVarObject_HEAD_INIT(0, 0) + "dependency_injector.containers.__pyx_scope_struct____Pyx_CFunc_void____object___to_py", /*tp_name*/ + sizeof(struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py), /*tp_basicsize*/ + 0, /*tp_itemsize*/ + __pyx_tp_dealloc___pyx_scope_struct____Pyx_CFunc_void____object___to_py, /*tp_dealloc*/ + #if PY_VERSION_HEX < 0x030800b4 + 0, /*tp_print*/ + #endif + #if PY_VERSION_HEX >= 0x030800b4 + 0, /*tp_vectorcall_offset*/ + #endif + 0, /*tp_getattr*/ + 0, /*tp_setattr*/ + #if PY_MAJOR_VERSION < 3 + 0, /*tp_compare*/ + #endif + #if PY_MAJOR_VERSION >= 3 + 0, /*tp_as_async*/ + #endif + 0, /*tp_repr*/ + 0, /*tp_as_number*/ + 0, /*tp_as_sequence*/ + 0, /*tp_as_mapping*/ + 0, /*tp_hash*/ + 0, /*tp_call*/ + 0, /*tp_str*/ + 0, /*tp_getattro*/ + 0, /*tp_setattro*/ + 0, /*tp_as_buffer*/ + Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER, /*tp_flags*/ + 0, /*tp_doc*/ + 0, /*tp_traverse*/ + 0, /*tp_clear*/ + 0, /*tp_richcompare*/ + 0, /*tp_weaklistoffset*/ + 0, /*tp_iter*/ + 0, /*tp_iternext*/ + 0, /*tp_methods*/ + 0, /*tp_members*/ + 0, /*tp_getset*/ + 0, /*tp_base*/ + 0, /*tp_dict*/ + 0, /*tp_descr_get*/ + 0, /*tp_descr_set*/ + 0, /*tp_dictoffset*/ + 0, /*tp_init*/ + 0, /*tp_alloc*/ + __pyx_tp_new___pyx_scope_struct____Pyx_CFunc_void____object___to_py, /*tp_new*/ + 0, /*tp_free*/ + 0, /*tp_is_gc*/ + 0, /*tp_bases*/ + 0, /*tp_mro*/ + 0, /*tp_cache*/ + 0, /*tp_subclasses*/ + 0, /*tp_weaklist*/ + 0, /*tp_del*/ + 0, /*tp_version_tag*/ + #if PY_VERSION_HEX >= 0x030400a1 + 0, /*tp_finalize*/ + #endif + #if PY_VERSION_HEX >= 0x030800b1 + 0, /*tp_vectorcall*/ + #endif + #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000 + 0, /*tp_print*/ + #endif +}; + static PyMethodDef __pyx_methods[] = { {"is_container", (PyCFunction)__pyx_pw_19dependency_injector_10containers_9is_container, METH_O, __pyx_doc_19dependency_injector_10containers_8is_container}, {"_check_provider_type", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_10containers_11_check_provider_type, METH_VARARGS|METH_KEYWORDS, 0}, + {"_isawaitable", (PyCFunction)__pyx_pw_19dependency_injector_10containers_13_isawaitable, METH_O, 0}, {0, 0, 0, 0} }; @@ -13331,14 +16825,22 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_DynamicContainer_wire, __pyx_k_DynamicContainer_wire, sizeof(__pyx_k_DynamicContainer_wire), 0, 0, 1, 1}, {&__pyx_kp_s_Dynamic_inversion_of_control_con, __pyx_k_Dynamic_inversion_of_control_con, sizeof(__pyx_k_Dynamic_inversion_of_control_con), 0, 0, 1, 0}, {&__pyx_n_s_Error, __pyx_k_Error, sizeof(__pyx_k_Error), 0, 0, 1, 1}, + {&__pyx_n_s_Future, __pyx_k_Future, sizeof(__pyx_k_Future), 0, 0, 1, 1}, {&__pyx_n_s_IS_CONTAINER, __pyx_k_IS_CONTAINER, sizeof(__pyx_k_IS_CONTAINER), 0, 0, 1, 1}, + {&__pyx_n_s_ImportError, __pyx_k_ImportError, sizeof(__pyx_k_ImportError), 0, 0, 1, 1}, {&__pyx_n_s_NotImplementedError, __pyx_k_NotImplementedError, sizeof(__pyx_k_NotImplementedError), 0, 0, 1, 1}, + {&__pyx_n_s_Pyx_CFunc_void____object___to, __pyx_k_Pyx_CFunc_void____object___to, sizeof(__pyx_k_Pyx_CFunc_void____object___to), 0, 0, 1, 1}, {&__pyx_kp_s_Wiring_requires_Python_3_6_or_ab, __pyx_k_Wiring_requires_Python_3_6_or_ab, sizeof(__pyx_k_Wiring_requires_Python_3_6_or_ab), 0, 0, 1, 0}, {&__pyx_n_s__7, __pyx_k__7, sizeof(__pyx_k__7), 0, 0, 1, 1}, + {&__pyx_n_s_add_done_callback, __pyx_k_add_done_callback, sizeof(__pyx_k_add_done_callback), 0, 0, 1, 1}, {&__pyx_n_s_add_metaclass, __pyx_k_add_metaclass, sizeof(__pyx_k_add_metaclass), 0, 0, 1, 1}, {&__pyx_n_s_args, __pyx_k_args, sizeof(__pyx_k_args), 0, 0, 1, 1}, + {&__pyx_n_s_asyncio, __pyx_k_asyncio, sizeof(__pyx_k_asyncio), 0, 0, 1, 1}, + {&__pyx_n_s_asyncio_coroutines, __pyx_k_asyncio_coroutines, sizeof(__pyx_k_asyncio_coroutines), 0, 0, 1, 1}, + {&__pyx_n_s_asyncio_tasks, __pyx_k_asyncio_tasks, sizeof(__pyx_k_asyncio_tasks), 0, 0, 1, 1}, {&__pyx_n_s_attributes, __pyx_k_attributes, sizeof(__pyx_k_attributes), 0, 0, 1, 1}, {&__pyx_n_s_bases, __pyx_k_bases, sizeof(__pyx_k_bases), 0, 0, 1, 1}, + {&__pyx_n_s_cfunc_to_py, __pyx_k_cfunc_to_py, sizeof(__pyx_k_cfunc_to_py), 0, 0, 1, 1}, {&__pyx_n_s_class, __pyx_k_class, sizeof(__pyx_k_class), 0, 0, 1, 1}, {&__pyx_n_s_class_name, __pyx_k_class_name, sizeof(__pyx_k_class_name), 0, 0, 1, 1}, {&__pyx_n_s_clear, __pyx_k_clear, sizeof(__pyx_k_clear), 0, 0, 1, 1}, @@ -13359,9 +16861,13 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_delattr, __pyx_k_delattr, sizeof(__pyx_k_delattr), 0, 0, 1, 1}, {&__pyx_n_s_dependency_injector_containers, __pyx_k_dependency_injector_containers, sizeof(__pyx_k_dependency_injector_containers), 0, 0, 1, 1}, {&__pyx_n_s_doc, __pyx_k_doc, sizeof(__pyx_k_doc), 0, 0, 1, 1}, + {&__pyx_n_s_ensure_future, __pyx_k_ensure_future, sizeof(__pyx_k_ensure_future), 0, 0, 1, 1}, {&__pyx_n_s_errors, __pyx_k_errors, sizeof(__pyx_k_errors), 0, 0, 1, 1}, {&__pyx_n_s_extend, __pyx_k_extend, sizeof(__pyx_k_extend), 0, 0, 1, 1}, {&__pyx_n_s_format, __pyx_k_format, sizeof(__pyx_k_format), 0, 0, 1, 1}, + {&__pyx_n_s_future, __pyx_k_future, sizeof(__pyx_k_future), 0, 0, 1, 1}, + {&__pyx_n_s_futures, __pyx_k_futures, sizeof(__pyx_k_futures), 0, 0, 1, 1}, + {&__pyx_n_s_gather, __pyx_k_gather, sizeof(__pyx_k_gather), 0, 0, 1, 1}, {&__pyx_n_s_genexpr, __pyx_k_genexpr, sizeof(__pyx_k_genexpr), 0, 0, 1, 1}, {&__pyx_n_s_get, __pyx_k_get, sizeof(__pyx_k_get), 0, 0, 1, 1}, {&__pyx_n_s_id, __pyx_k_id, sizeof(__pyx_k_id), 0, 0, 1, 1}, @@ -13371,7 +16877,9 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_init, __pyx_k_init, sizeof(__pyx_k_init), 0, 0, 1, 1}, {&__pyx_n_s_init_2, __pyx_k_init_2, sizeof(__pyx_k_init_2), 0, 0, 1, 1}, {&__pyx_n_s_init_resources, __pyx_k_init_resources, sizeof(__pyx_k_init_resources), 0, 0, 1, 1}, + {&__pyx_n_s_inspect, __pyx_k_inspect, sizeof(__pyx_k_inspect), 0, 0, 1, 1}, {&__pyx_n_s_instance_type, __pyx_k_instance_type, sizeof(__pyx_k_instance_type), 0, 0, 1, 1}, + {&__pyx_n_s_isawaitable, __pyx_k_isawaitable, sizeof(__pyx_k_isawaitable), 0, 0, 1, 1}, {&__pyx_n_s_items, __pyx_k_items, sizeof(__pyx_k_items), 0, 0, 1, 1}, {&__pyx_n_s_iteritems, __pyx_k_iteritems, sizeof(__pyx_k_iteritems), 0, 0, 1, 1}, {&__pyx_n_s_itervalues, __pyx_k_itervalues, sizeof(__pyx_k_itervalues), 0, 0, 1, 1}, @@ -13408,15 +16916,19 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_reset_last_overriding, __pyx_k_reset_last_overriding, sizeof(__pyx_k_reset_last_overriding), 0, 0, 1, 1}, {&__pyx_n_s_reset_override, __pyx_k_reset_override, sizeof(__pyx_k_reset_override), 0, 0, 1, 1}, {&__pyx_n_s_resolve_provider_name, __pyx_k_resolve_provider_name, sizeof(__pyx_k_resolve_provider_name), 0, 0, 1, 1}, + {&__pyx_n_s_resource, __pyx_k_resource, sizeof(__pyx_k_resource), 0, 0, 1, 1}, + {&__pyx_n_s_result, __pyx_k_result, sizeof(__pyx_k_result), 0, 0, 1, 1}, {&__pyx_n_s_self, __pyx_k_self, sizeof(__pyx_k_self), 0, 0, 1, 1}, {&__pyx_n_s_send, __pyx_k_send, sizeof(__pyx_k_send), 0, 0, 1, 1}, {&__pyx_n_s_set_providers, __pyx_k_set_providers, sizeof(__pyx_k_set_providers), 0, 0, 1, 1}, + {&__pyx_n_s_set_result, __pyx_k_set_result, sizeof(__pyx_k_set_result), 0, 0, 1, 1}, {&__pyx_n_s_setattr, __pyx_k_setattr, sizeof(__pyx_k_setattr), 0, 0, 1, 1}, {&__pyx_n_s_shutdown, __pyx_k_shutdown, sizeof(__pyx_k_shutdown), 0, 0, 1, 1}, {&__pyx_n_s_shutdown_resources, __pyx_k_shutdown_resources, sizeof(__pyx_k_shutdown_resources), 0, 0, 1, 1}, {&__pyx_n_s_six, __pyx_k_six, sizeof(__pyx_k_six), 0, 0, 1, 1}, {&__pyx_n_s_source_provider, __pyx_k_source_provider, sizeof(__pyx_k_source_provider), 0, 0, 1, 1}, {&__pyx_kp_s_src_dependency_injector_containe, __pyx_k_src_dependency_injector_containe, sizeof(__pyx_k_src_dependency_injector_containe), 0, 0, 1, 0}, + {&__pyx_kp_s_stringsource, __pyx_k_stringsource, sizeof(__pyx_k_stringsource), 0, 0, 1, 0}, {&__pyx_n_s_super, __pyx_k_super, sizeof(__pyx_k_super), 0, 0, 1, 1}, {&__pyx_n_s_sys, __pyx_k_sys, sizeof(__pyx_k_sys), 0, 0, 1, 1}, {&__pyx_n_s_test, __pyx_k_test, sizeof(__pyx_k_test), 0, 0, 1, 1}, @@ -13429,15 +16941,19 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_wired_to_modules, __pyx_k_wired_to_modules, sizeof(__pyx_k_wired_to_modules), 0, 0, 1, 1}, {&__pyx_n_s_wired_to_packages, __pyx_k_wired_to_packages, sizeof(__pyx_k_wired_to_packages), 0, 0, 1, 1}, {&__pyx_n_s_wiring, __pyx_k_wiring, sizeof(__pyx_k_wiring), 0, 0, 1, 1}, + {&__pyx_n_s_wrap, __pyx_k_wrap, sizeof(__pyx_k_wrap), 0, 0, 1, 1}, + {&__pyx_n_s_zip, __pyx_k_zip, sizeof(__pyx_k_zip), 0, 0, 1, 1}, {0, 0, 0, 0, 0, 0, 0} }; static CYTHON_SMALL_CODE int __Pyx_InitCachedBuiltins(void) { - __pyx_builtin_object = __Pyx_GetBuiltinName(__pyx_n_s_object); if (!__pyx_builtin_object) __PYX_ERR(0, 25, __pyx_L1_error) - __pyx_builtin_NotImplementedError = __Pyx_GetBuiltinName(__pyx_n_s_NotImplementedError); if (!__pyx_builtin_NotImplementedError) __PYX_ERR(0, 19, __pyx_L1_error) - __pyx_builtin_super = __Pyx_GetBuiltinName(__pyx_n_s_super); if (!__pyx_builtin_super) __PYX_ERR(0, 67, __pyx_L1_error) - __pyx_builtin_id = __Pyx_GetBuiltinName(__pyx_n_s_id); if (!__pyx_builtin_id) __PYX_ERR(0, 71, __pyx_L1_error) - __pyx_builtin_AttributeError = __Pyx_GetBuiltinName(__pyx_n_s_AttributeError); if (!__pyx_builtin_AttributeError) __PYX_ERR(0, 151, __pyx_L1_error) - __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_range) __PYX_ERR(1, 347, __pyx_L1_error) + __pyx_builtin_ImportError = __Pyx_GetBuiltinName(__pyx_n_s_ImportError); if (!__pyx_builtin_ImportError) __PYX_ERR(0, 8, __pyx_L1_error) + __pyx_builtin_object = __Pyx_GetBuiltinName(__pyx_n_s_object); if (!__pyx_builtin_object) __PYX_ERR(0, 31, __pyx_L1_error) + __pyx_builtin_NotImplementedError = __Pyx_GetBuiltinName(__pyx_n_s_NotImplementedError); if (!__pyx_builtin_NotImplementedError) __PYX_ERR(0, 25, __pyx_L1_error) + __pyx_builtin_super = __Pyx_GetBuiltinName(__pyx_n_s_super); if (!__pyx_builtin_super) __PYX_ERR(0, 73, __pyx_L1_error) + __pyx_builtin_id = __Pyx_GetBuiltinName(__pyx_n_s_id); if (!__pyx_builtin_id) __PYX_ERR(0, 77, __pyx_L1_error) + __pyx_builtin_AttributeError = __Pyx_GetBuiltinName(__pyx_n_s_AttributeError); if (!__pyx_builtin_AttributeError) __PYX_ERR(0, 157, __pyx_L1_error) + __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_range) __PYX_ERR(1, 353, __pyx_L1_error) + __pyx_builtin_zip = __Pyx_GetBuiltinName(__pyx_n_s_zip); if (!__pyx_builtin_zip) __PYX_ERR(1, 432, __pyx_L1_error) return 0; __pyx_L1_error:; return -1; @@ -13447,390 +16963,402 @@ static CYTHON_SMALL_CODE int __Pyx_InitCachedConstants(void) { __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0); - /* "dependency_injector/containers.pyx":19 + /* "dependency_injector/containers.pyx":25 * else: * def wire(*args, **kwargs): * raise NotImplementedError('Wiring requires Python 3.6 or above') # <<<<<<<<<<<<<< * * def unwire(*args, **kwargs): */ - __pyx_tuple_ = PyTuple_Pack(1, __pyx_kp_s_Wiring_requires_Python_3_6_or_ab); if (unlikely(!__pyx_tuple_)) __PYX_ERR(0, 19, __pyx_L1_error) + __pyx_tuple_ = PyTuple_Pack(1, __pyx_kp_s_Wiring_requires_Python_3_6_or_ab); if (unlikely(!__pyx_tuple_)) __PYX_ERR(0, 25, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple_); __Pyx_GIVEREF(__pyx_tuple_); - /* "dependency_injector/containers.pyx":175 + /* "dependency_injector/containers.pyx":181 * raise Error('Container {0} is not overridden'.format(self)) * * self.overridden = self.overridden[:-1] # <<<<<<<<<<<<<< * * for provider in six.itervalues(self.providers): */ - __pyx_slice__2 = PySlice_New(Py_None, __pyx_int_neg_1, Py_None); if (unlikely(!__pyx_slice__2)) __PYX_ERR(0, 175, __pyx_L1_error) + __pyx_slice__2 = PySlice_New(Py_None, __pyx_int_neg_1, Py_None); if (unlikely(!__pyx_slice__2)) __PYX_ERR(0, 181, __pyx_L1_error) __Pyx_GOTREF(__pyx_slice__2); __Pyx_GIVEREF(__pyx_slice__2); - /* "dependency_injector/containers.pyx":444 + /* "dependency_injector/containers.pyx":466 * :rtype: callable(:py:class:`DeclarativeContainer`) * """ * def _decorator(object overriding_container): # <<<<<<<<<<<<<< * """Overriding decorator.""" * container.override(overriding_container) */ - __pyx_tuple__3 = PyTuple_Pack(1, __pyx_n_s_overriding_container); if (unlikely(!__pyx_tuple__3)) __PYX_ERR(0, 444, __pyx_L1_error) + __pyx_tuple__3 = PyTuple_Pack(1, __pyx_n_s_overriding_container); if (unlikely(!__pyx_tuple__3)) __PYX_ERR(0, 466, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__3); __Pyx_GIVEREF(__pyx_tuple__3); - __pyx_codeobj__4 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__3, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_decorator, 444, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__4)) __PYX_ERR(0, 444, __pyx_L1_error) + __pyx_codeobj__4 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__3, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_decorator, 466, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__4)) __PYX_ERR(0, 466, __pyx_L1_error) - /* "dependency_injector/containers.pyx":464 + /* "dependency_injector/containers.pyx":486 * :rtype: callable(:py:class:`DeclarativeContainer`) * """ * def _decorator(copied_container): # <<<<<<<<<<<<<< * cdef dict memo = dict() * for name, provider in six.iteritems(copied_container.cls_providers): */ - __pyx_tuple__5 = PyTuple_Pack(6, __pyx_n_s_copied_container, __pyx_n_s_memo, __pyx_n_s_name, __pyx_n_s_provider, __pyx_n_s_source_provider, __pyx_n_s_providers_copy); if (unlikely(!__pyx_tuple__5)) __PYX_ERR(0, 464, __pyx_L1_error) + __pyx_tuple__5 = PyTuple_Pack(6, __pyx_n_s_copied_container, __pyx_n_s_memo, __pyx_n_s_name, __pyx_n_s_provider, __pyx_n_s_source_provider, __pyx_n_s_providers_copy); if (unlikely(!__pyx_tuple__5)) __PYX_ERR(0, 486, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__5); __Pyx_GIVEREF(__pyx_tuple__5); - __pyx_codeobj__6 = (PyObject*)__Pyx_PyCode_New(1, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__5, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_decorator, 464, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__6)) __PYX_ERR(0, 464, __pyx_L1_error) + __pyx_codeobj__6 = (PyObject*)__Pyx_PyCode_New(1, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__5, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_decorator, 486, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__6)) __PYX_ERR(0, 486, __pyx_L1_error) - /* "dependency_injector/containers.pyx":15 + /* "cfunc.to_py":65 + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): + * def wrap(object future): # <<<<<<<<<<<<<< + * """wrap(future) -> 'void'""" + * f(future) + */ + __pyx_tuple__8 = PyTuple_Pack(1, __pyx_n_s_future); if (unlikely(!__pyx_tuple__8)) __PYX_ERR(2, 65, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__8); + __Pyx_GIVEREF(__pyx_tuple__8); + __pyx_codeobj__9 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__8, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_wrap, 65, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__9)) __PYX_ERR(2, 65, __pyx_L1_error) + + /* "dependency_injector/containers.pyx":21 * * * if sys.version_info[:2] >= (3, 6): # <<<<<<<<<<<<<< * from .wiring import wire, unwire * else: */ - __pyx_slice__8 = PySlice_New(Py_None, __pyx_int_2, Py_None); if (unlikely(!__pyx_slice__8)) __PYX_ERR(0, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_slice__8); - __Pyx_GIVEREF(__pyx_slice__8); - __pyx_tuple__9 = PyTuple_Pack(2, __pyx_int_3, __pyx_int_6); if (unlikely(!__pyx_tuple__9)) __PYX_ERR(0, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__9); - __Pyx_GIVEREF(__pyx_tuple__9); + __pyx_slice__10 = PySlice_New(Py_None, __pyx_int_2, Py_None); if (unlikely(!__pyx_slice__10)) __PYX_ERR(0, 21, __pyx_L1_error) + __Pyx_GOTREF(__pyx_slice__10); + __Pyx_GIVEREF(__pyx_slice__10); + __pyx_tuple__11 = PyTuple_Pack(2, __pyx_int_3, __pyx_int_6); if (unlikely(!__pyx_tuple__11)) __PYX_ERR(0, 21, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__11); + __Pyx_GIVEREF(__pyx_tuple__11); - /* "dependency_injector/containers.pyx":18 + /* "dependency_injector/containers.pyx":24 * from .wiring import wire, unwire * else: * def wire(*args, **kwargs): # <<<<<<<<<<<<<< * raise NotImplementedError('Wiring requires Python 3.6 or above') * */ - __pyx_tuple__10 = PyTuple_Pack(2, __pyx_n_s_args, __pyx_n_s_kwargs); if (unlikely(!__pyx_tuple__10)) __PYX_ERR(0, 18, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__10); - __Pyx_GIVEREF(__pyx_tuple__10); - __pyx_codeobj__11 = (PyObject*)__Pyx_PyCode_New(0, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARARGS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__10, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_wire, 18, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__11)) __PYX_ERR(0, 18, __pyx_L1_error) + __pyx_tuple__12 = PyTuple_Pack(2, __pyx_n_s_args, __pyx_n_s_kwargs); if (unlikely(!__pyx_tuple__12)) __PYX_ERR(0, 24, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__12); + __Pyx_GIVEREF(__pyx_tuple__12); + __pyx_codeobj__13 = (PyObject*)__Pyx_PyCode_New(0, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARARGS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__12, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_wire, 24, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__13)) __PYX_ERR(0, 24, __pyx_L1_error) - /* "dependency_injector/containers.pyx":21 + /* "dependency_injector/containers.pyx":27 * raise NotImplementedError('Wiring requires Python 3.6 or above') * * def unwire(*args, **kwargs): # <<<<<<<<<<<<<< * raise NotImplementedError('Wiring requires Python 3.6 or above') * */ - __pyx_tuple__12 = PyTuple_Pack(2, __pyx_n_s_args, __pyx_n_s_kwargs); if (unlikely(!__pyx_tuple__12)) __PYX_ERR(0, 21, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__12); - __Pyx_GIVEREF(__pyx_tuple__12); - __pyx_codeobj__13 = (PyObject*)__Pyx_PyCode_New(0, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARARGS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__12, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_unwire, 21, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__13)) __PYX_ERR(0, 21, __pyx_L1_error) + __pyx_tuple__14 = PyTuple_Pack(2, __pyx_n_s_args, __pyx_n_s_kwargs); if (unlikely(!__pyx_tuple__14)) __PYX_ERR(0, 27, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__14); + __Pyx_GIVEREF(__pyx_tuple__14); + __pyx_codeobj__15 = (PyObject*)__Pyx_PyCode_New(0, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARARGS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__14, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_unwire, 27, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__15)) __PYX_ERR(0, 27, __pyx_L1_error) - /* "dependency_injector/containers.pyx":25 + /* "dependency_injector/containers.pyx":31 * * * class DynamicContainer(object): # <<<<<<<<<<<<<< * """Dynamic inversion of control container. * */ - __pyx_tuple__14 = PyTuple_Pack(1, __pyx_builtin_object); if (unlikely(!__pyx_tuple__14)) __PYX_ERR(0, 25, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__14); - __Pyx_GIVEREF(__pyx_tuple__14); + __pyx_tuple__16 = PyTuple_Pack(1, __pyx_builtin_object); if (unlikely(!__pyx_tuple__16)) __PYX_ERR(0, 31, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__16); + __Pyx_GIVEREF(__pyx_tuple__16); - /* "dependency_injector/containers.pyx":56 + /* "dependency_injector/containers.pyx":62 * __IS_CONTAINER__ = True * * def __init__(self): # <<<<<<<<<<<<<< * """Initializer. * */ - __pyx_tuple__15 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__15)) __PYX_ERR(0, 56, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__15); - __Pyx_GIVEREF(__pyx_tuple__15); - __pyx_codeobj__16 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__15, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_init, 56, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__16)) __PYX_ERR(0, 56, __pyx_L1_error) + __pyx_tuple__17 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__17)) __PYX_ERR(0, 62, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__17); + __Pyx_GIVEREF(__pyx_tuple__17); + __pyx_codeobj__18 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__17, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_init, 62, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__18)) __PYX_ERR(0, 62, __pyx_L1_error) - /* "dependency_injector/containers.pyx":69 + /* "dependency_injector/containers.pyx":75 * super(DynamicContainer, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< * """Create and return full copy of container.""" * copied = memo.get(id(self)) */ - __pyx_tuple__17 = PyTuple_Pack(5, __pyx_n_s_self, __pyx_n_s_memo, __pyx_n_s_copied, __pyx_n_s_name, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__17)) __PYX_ERR(0, 69, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__17); - __Pyx_GIVEREF(__pyx_tuple__17); - __pyx_codeobj__18 = (PyObject*)__Pyx_PyCode_New(2, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__17, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_deepcopy, 69, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__18)) __PYX_ERR(0, 69, __pyx_L1_error) + __pyx_tuple__19 = PyTuple_Pack(5, __pyx_n_s_self, __pyx_n_s_memo, __pyx_n_s_copied, __pyx_n_s_name, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__19)) __PYX_ERR(0, 75, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__19); + __Pyx_GIVEREF(__pyx_tuple__19); + __pyx_codeobj__20 = (PyObject*)__Pyx_PyCode_New(2, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__19, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_deepcopy, 75, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__20)) __PYX_ERR(0, 75, __pyx_L1_error) - /* "dependency_injector/containers.pyx":85 + /* "dependency_injector/containers.pyx":91 * return copied * * def __setattr__(self, str name, object value): # <<<<<<<<<<<<<< * """Set instance attribute. * */ - __pyx_tuple__19 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_name, __pyx_n_s_value); if (unlikely(!__pyx_tuple__19)) __PYX_ERR(0, 85, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__19); - __Pyx_GIVEREF(__pyx_tuple__19); - __pyx_codeobj__20 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__19, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_setattr, 85, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__20)) __PYX_ERR(0, 85, __pyx_L1_error) + __pyx_tuple__21 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_name, __pyx_n_s_value); if (unlikely(!__pyx_tuple__21)) __PYX_ERR(0, 91, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__21); + __Pyx_GIVEREF(__pyx_tuple__21); + __pyx_codeobj__22 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__21, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_setattr, 91, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__22)) __PYX_ERR(0, 91, __pyx_L1_error) - /* "dependency_injector/containers.pyx":104 + /* "dependency_injector/containers.pyx":110 * super(DynamicContainer, self).__setattr__(name, value) * * def __delattr__(self, str name): # <<<<<<<<<<<<<< * """Delete instance attribute. * */ - __pyx_tuple__21 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_name); if (unlikely(!__pyx_tuple__21)) __PYX_ERR(0, 104, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__21); - __Pyx_GIVEREF(__pyx_tuple__21); - __pyx_codeobj__22 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__21, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_delattr, 104, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__22)) __PYX_ERR(0, 104, __pyx_L1_error) + __pyx_tuple__23 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_name); if (unlikely(!__pyx_tuple__23)) __PYX_ERR(0, 110, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__23); + __Pyx_GIVEREF(__pyx_tuple__23); + __pyx_codeobj__24 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__23, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_delattr, 110, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__24)) __PYX_ERR(0, 110, __pyx_L1_error) - /* "dependency_injector/containers.pyx":119 + /* "dependency_injector/containers.pyx":125 * super(DynamicContainer, self).__delattr__(name) * * def set_providers(self, **providers): # <<<<<<<<<<<<<< * """Set container providers. * */ - __pyx_tuple__23 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_providers, __pyx_n_s_name, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__23)) __PYX_ERR(0, 119, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__23); - __Pyx_GIVEREF(__pyx_tuple__23); - __pyx_codeobj__24 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__23, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_set_providers, 119, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__24)) __PYX_ERR(0, 119, __pyx_L1_error) + __pyx_tuple__25 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_providers, __pyx_n_s_name, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__25)) __PYX_ERR(0, 125, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__25); + __Pyx_GIVEREF(__pyx_tuple__25); + __pyx_codeobj__26 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__25, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_set_providers, 125, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__26)) __PYX_ERR(0, 125, __pyx_L1_error) - /* "dependency_injector/containers.pyx":131 + /* "dependency_injector/containers.pyx":137 * setattr(self, name, provider) * * def override(self, object overriding): # <<<<<<<<<<<<<< * """Override current container by overriding container. * */ - __pyx_tuple__25 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_overriding, __pyx_n_s_name, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__25)) __PYX_ERR(0, 131, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__25); - __Pyx_GIVEREF(__pyx_tuple__25); - __pyx_codeobj__26 = (PyObject*)__Pyx_PyCode_New(2, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__25, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_override, 131, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__26)) __PYX_ERR(0, 131, __pyx_L1_error) + __pyx_tuple__27 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_overriding, __pyx_n_s_name, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__27)) __PYX_ERR(0, 137, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__27); + __Pyx_GIVEREF(__pyx_tuple__27); + __pyx_codeobj__28 = (PyObject*)__Pyx_PyCode_New(2, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__27, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_override, 137, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__28)) __PYX_ERR(0, 137, __pyx_L1_error) - /* "dependency_injector/containers.pyx":154 + /* "dependency_injector/containers.pyx":160 * pass * * def override_providers(self, **overriding_providers): # <<<<<<<<<<<<<< * """Override container providers. * */ - __pyx_tuple__27 = PyTuple_Pack(5, __pyx_n_s_self, __pyx_n_s_overriding_providers, __pyx_n_s_name, __pyx_n_s_overriding_provider, __pyx_n_s_container_provider); if (unlikely(!__pyx_tuple__27)) __PYX_ERR(0, 154, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__27); - __Pyx_GIVEREF(__pyx_tuple__27); - __pyx_codeobj__28 = (PyObject*)__Pyx_PyCode_New(1, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__27, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_override_providers, 154, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__28)) __PYX_ERR(0, 154, __pyx_L1_error) + __pyx_tuple__29 = PyTuple_Pack(5, __pyx_n_s_self, __pyx_n_s_overriding_providers, __pyx_n_s_name, __pyx_n_s_overriding_provider, __pyx_n_s_container_provider); if (unlikely(!__pyx_tuple__29)) __PYX_ERR(0, 160, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__29); + __Pyx_GIVEREF(__pyx_tuple__29); + __pyx_codeobj__30 = (PyObject*)__Pyx_PyCode_New(1, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__29, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_override_providers, 160, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__30)) __PYX_ERR(0, 160, __pyx_L1_error) - /* "dependency_injector/containers.pyx":167 + /* "dependency_injector/containers.pyx":173 * container_provider.override(overriding_provider) * * def reset_last_overriding(self): # <<<<<<<<<<<<<< * """Reset last overriding provider for each container providers. * */ - __pyx_tuple__29 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__29)) __PYX_ERR(0, 167, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__29); - __Pyx_GIVEREF(__pyx_tuple__29); - __pyx_codeobj__30 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__29, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_reset_last_overriding, 167, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__30)) __PYX_ERR(0, 167, __pyx_L1_error) + __pyx_tuple__31 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__31)) __PYX_ERR(0, 173, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__31); + __Pyx_GIVEREF(__pyx_tuple__31); + __pyx_codeobj__32 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__31, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_reset_last_overriding, 173, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__32)) __PYX_ERR(0, 173, __pyx_L1_error) - /* "dependency_injector/containers.pyx":180 + /* "dependency_injector/containers.pyx":186 * provider.reset_last_overriding() * * def reset_override(self): # <<<<<<<<<<<<<< * """Reset all overridings for each container providers. * */ - __pyx_tuple__31 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__31)) __PYX_ERR(0, 180, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__31); - __Pyx_GIVEREF(__pyx_tuple__31); - __pyx_codeobj__32 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__31, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_reset_override, 180, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__32)) __PYX_ERR(0, 180, __pyx_L1_error) + __pyx_tuple__33 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__33)) __PYX_ERR(0, 186, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__33); + __Pyx_GIVEREF(__pyx_tuple__33); + __pyx_codeobj__34 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__33, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_reset_override, 186, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__34)) __PYX_ERR(0, 186, __pyx_L1_error) - /* "dependency_injector/containers.pyx":190 + /* "dependency_injector/containers.pyx":196 * provider.reset_override() * * def wire(self, modules=None, packages=None): # <<<<<<<<<<<<<< * """Wire container providers with provided packages and modules. * */ - __pyx_tuple__33 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_modules, __pyx_n_s_packages); if (unlikely(!__pyx_tuple__33)) __PYX_ERR(0, 190, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__33); - __Pyx_GIVEREF(__pyx_tuple__33); - __pyx_codeobj__34 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__33, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_wire, 190, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__34)) __PYX_ERR(0, 190, __pyx_L1_error) - __pyx_tuple__35 = PyTuple_Pack(2, ((PyObject *)Py_None), ((PyObject *)Py_None)); if (unlikely(!__pyx_tuple__35)) __PYX_ERR(0, 190, __pyx_L1_error) + __pyx_tuple__35 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_modules, __pyx_n_s_packages); if (unlikely(!__pyx_tuple__35)) __PYX_ERR(0, 196, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__35); __Pyx_GIVEREF(__pyx_tuple__35); + __pyx_codeobj__36 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__35, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_wire, 196, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__36)) __PYX_ERR(0, 196, __pyx_L1_error) + __pyx_tuple__37 = PyTuple_Pack(2, ((PyObject *)Py_None), ((PyObject *)Py_None)); if (unlikely(!__pyx_tuple__37)) __PYX_ERR(0, 196, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__37); + __Pyx_GIVEREF(__pyx_tuple__37); - /* "dependency_injector/containers.pyx":207 + /* "dependency_injector/containers.pyx":213 * self.wired_to_packages.extend(packages) * * def unwire(self): # <<<<<<<<<<<<<< * """Unwire container providers from previously wired packages and modules.""" * unwire( */ - __pyx_tuple__36 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__36)) __PYX_ERR(0, 207, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__36); - __Pyx_GIVEREF(__pyx_tuple__36); - __pyx_codeobj__37 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__36, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_unwire, 207, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__37)) __PYX_ERR(0, 207, __pyx_L1_error) + __pyx_tuple__38 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__38)) __PYX_ERR(0, 213, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__38); + __Pyx_GIVEREF(__pyx_tuple__38); + __pyx_codeobj__39 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__38, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_unwire, 213, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__39)) __PYX_ERR(0, 213, __pyx_L1_error) - /* "dependency_injector/containers.pyx":217 + /* "dependency_injector/containers.pyx":223 * self.wired_to_packages.clear() * * def init_resources(self): # <<<<<<<<<<<<<< * """Initialize all container resources.""" - * for provider in self.providers.values(): + * futures = [] */ - __pyx_tuple__38 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__38)) __PYX_ERR(0, 217, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__38); - __Pyx_GIVEREF(__pyx_tuple__38); - __pyx_codeobj__39 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__38, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_init_resources, 217, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__39)) __PYX_ERR(0, 217, __pyx_L1_error) + __pyx_tuple__40 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_futures, __pyx_n_s_provider, __pyx_n_s_resource); if (unlikely(!__pyx_tuple__40)) __PYX_ERR(0, 223, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__40); + __Pyx_GIVEREF(__pyx_tuple__40); + __pyx_codeobj__41 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__40, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_init_resources, 223, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__41)) __PYX_ERR(0, 223, __pyx_L1_error) - /* "dependency_injector/containers.pyx":224 - * provider.init() + /* "dependency_injector/containers.pyx":238 + * return asyncio.gather(*futures) * * def shutdown_resources(self): # <<<<<<<<<<<<<< * """Shutdown all container resources.""" - * for provider in self.providers.values(): + * futures = [] */ - __pyx_tuple__40 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__40)) __PYX_ERR(0, 224, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__40); - __Pyx_GIVEREF(__pyx_tuple__40); - __pyx_codeobj__41 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__40, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_shutdown_resources, 224, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__41)) __PYX_ERR(0, 224, __pyx_L1_error) + __pyx_tuple__42 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_futures, __pyx_n_s_provider, __pyx_n_s_shutdown); if (unlikely(!__pyx_tuple__42)) __PYX_ERR(0, 238, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__42); + __Pyx_GIVEREF(__pyx_tuple__42); + __pyx_codeobj__43 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__42, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_shutdown_resources, 238, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__43)) __PYX_ERR(0, 238, __pyx_L1_error) - /* "dependency_injector/containers.pyx":235 + /* "dependency_injector/containers.pyx":257 * """Declarative inversion of control container meta class.""" * * def __new__(type mcs, str class_name, tuple bases, dict attributes): # <<<<<<<<<<<<<< * """Declarative container class factory.""" * cdef tuple cls_providers */ - __pyx_tuple__42 = PyTuple_Pack(13, __pyx_n_s_mcs, __pyx_n_s_class_name, __pyx_n_s_bases, __pyx_n_s_attributes, __pyx_n_s_cls_providers, __pyx_n_s_inherited_providers, __pyx_n_s_cls, __pyx_n_s_containers, __pyx_n_s_provider, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr); if (unlikely(!__pyx_tuple__42)) __PYX_ERR(0, 235, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__42); - __Pyx_GIVEREF(__pyx_tuple__42); - __pyx_codeobj__43 = (PyObject*)__Pyx_PyCode_New(4, 0, 13, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__42, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_new, 235, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__43)) __PYX_ERR(0, 235, __pyx_L1_error) + __pyx_tuple__44 = PyTuple_Pack(13, __pyx_n_s_mcs, __pyx_n_s_class_name, __pyx_n_s_bases, __pyx_n_s_attributes, __pyx_n_s_cls_providers, __pyx_n_s_inherited_providers, __pyx_n_s_cls, __pyx_n_s_containers, __pyx_n_s_provider, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr); if (unlikely(!__pyx_tuple__44)) __PYX_ERR(0, 257, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__44); + __Pyx_GIVEREF(__pyx_tuple__44); + __pyx_codeobj__45 = (PyObject*)__Pyx_PyCode_New(4, 0, 13, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__44, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_new, 257, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__45)) __PYX_ERR(0, 257, __pyx_L1_error) - /* "dependency_injector/containers.pyx":268 + /* "dependency_injector/containers.pyx":290 * return cls * * def __setattr__(cls, str name, object value): # <<<<<<<<<<<<<< * """Set class attribute. * */ - __pyx_tuple__44 = PyTuple_Pack(3, __pyx_n_s_cls, __pyx_n_s_name, __pyx_n_s_value); if (unlikely(!__pyx_tuple__44)) __PYX_ERR(0, 268, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__44); - __Pyx_GIVEREF(__pyx_tuple__44); - __pyx_codeobj__45 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__44, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_setattr, 268, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__45)) __PYX_ERR(0, 268, __pyx_L1_error) + __pyx_tuple__46 = PyTuple_Pack(3, __pyx_n_s_cls, __pyx_n_s_name, __pyx_n_s_value); if (unlikely(!__pyx_tuple__46)) __PYX_ERR(0, 290, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__46); + __Pyx_GIVEREF(__pyx_tuple__46); + __pyx_codeobj__47 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__46, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_setattr, 290, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__47)) __PYX_ERR(0, 290, __pyx_L1_error) - /* "dependency_injector/containers.pyx":288 + /* "dependency_injector/containers.pyx":310 * super(DeclarativeContainerMetaClass, cls).__setattr__(name, value) * * def __delattr__(cls, str name): # <<<<<<<<<<<<<< * """Delete class attribute. * */ - __pyx_tuple__46 = PyTuple_Pack(2, __pyx_n_s_cls, __pyx_n_s_name); if (unlikely(!__pyx_tuple__46)) __PYX_ERR(0, 288, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__46); - __Pyx_GIVEREF(__pyx_tuple__46); - __pyx_codeobj__47 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__46, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_delattr, 288, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__47)) __PYX_ERR(0, 288, __pyx_L1_error) + __pyx_tuple__48 = PyTuple_Pack(2, __pyx_n_s_cls, __pyx_n_s_name); if (unlikely(!__pyx_tuple__48)) __PYX_ERR(0, 310, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__48); + __Pyx_GIVEREF(__pyx_tuple__48); + __pyx_codeobj__49 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__48, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_delattr, 310, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__49)) __PYX_ERR(0, 310, __pyx_L1_error) - /* "dependency_injector/containers.pyx":306 + /* "dependency_injector/containers.pyx":328 * * @six.add_metaclass(DeclarativeContainerMetaClass) * class DeclarativeContainer(object): # <<<<<<<<<<<<<< * """Declarative inversion of control container. * */ - __pyx_tuple__48 = PyTuple_Pack(1, __pyx_builtin_object); if (unlikely(!__pyx_tuple__48)) __PYX_ERR(0, 306, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__48); - __Pyx_GIVEREF(__pyx_tuple__48); + __pyx_tuple__50 = PyTuple_Pack(1, __pyx_builtin_object); if (unlikely(!__pyx_tuple__50)) __PYX_ERR(0, 328, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__50); + __Pyx_GIVEREF(__pyx_tuple__50); - /* "dependency_injector/containers.pyx":362 + /* "dependency_injector/containers.pyx":384 * """ * * def __new__(cls, **overriding_providers): # <<<<<<<<<<<<<< * """Constructor. * */ - __pyx_tuple__49 = PyTuple_Pack(3, __pyx_n_s_cls, __pyx_n_s_overriding_providers, __pyx_n_s_container); if (unlikely(!__pyx_tuple__49)) __PYX_ERR(0, 362, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__49); - __Pyx_GIVEREF(__pyx_tuple__49); - __pyx_codeobj__50 = (PyObject*)__Pyx_PyCode_New(1, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__49, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_new, 362, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__50)) __PYX_ERR(0, 362, __pyx_L1_error) + __pyx_tuple__51 = PyTuple_Pack(3, __pyx_n_s_cls, __pyx_n_s_overriding_providers, __pyx_n_s_container); if (unlikely(!__pyx_tuple__51)) __PYX_ERR(0, 384, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__51); + __Pyx_GIVEREF(__pyx_tuple__51); + __pyx_codeobj__52 = (PyObject*)__Pyx_PyCode_New(1, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__51, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_new, 384, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__52)) __PYX_ERR(0, 384, __pyx_L1_error) - /* "dependency_injector/containers.pyx":376 + /* "dependency_injector/containers.pyx":398 * * @classmethod * def override(cls, object overriding): # <<<<<<<<<<<<<< * """Override current container by overriding container. * */ - __pyx_tuple__51 = PyTuple_Pack(4, __pyx_n_s_cls, __pyx_n_s_overriding, __pyx_n_s_name, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__51)) __PYX_ERR(0, 376, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__51); - __Pyx_GIVEREF(__pyx_tuple__51); - __pyx_codeobj__52 = (PyObject*)__Pyx_PyCode_New(2, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__51, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_override, 376, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__52)) __PYX_ERR(0, 376, __pyx_L1_error) + __pyx_tuple__53 = PyTuple_Pack(4, __pyx_n_s_cls, __pyx_n_s_overriding, __pyx_n_s_name, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__53)) __PYX_ERR(0, 398, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__53); + __Pyx_GIVEREF(__pyx_tuple__53); + __pyx_codeobj__54 = (PyObject*)__Pyx_PyCode_New(2, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__53, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_override, 398, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__54)) __PYX_ERR(0, 398, __pyx_L1_error) - /* "dependency_injector/containers.pyx":400 + /* "dependency_injector/containers.pyx":422 * * @classmethod * def reset_last_overriding(cls): # <<<<<<<<<<<<<< * """Reset last overriding provider for each container providers. * */ - __pyx_tuple__53 = PyTuple_Pack(2, __pyx_n_s_cls, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__53)) __PYX_ERR(0, 400, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__53); - __Pyx_GIVEREF(__pyx_tuple__53); - __pyx_codeobj__54 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__53, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_reset_last_overriding, 400, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__54)) __PYX_ERR(0, 400, __pyx_L1_error) + __pyx_tuple__55 = PyTuple_Pack(2, __pyx_n_s_cls, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__55)) __PYX_ERR(0, 422, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__55); + __Pyx_GIVEREF(__pyx_tuple__55); + __pyx_codeobj__56 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__55, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_reset_last_overriding, 422, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__56)) __PYX_ERR(0, 422, __pyx_L1_error) - /* "dependency_injector/containers.pyx":414 + /* "dependency_injector/containers.pyx":436 * * @classmethod * def reset_override(cls): # <<<<<<<<<<<<<< * """Reset all overridings for each container providers. * */ - __pyx_tuple__55 = PyTuple_Pack(2, __pyx_n_s_cls, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__55)) __PYX_ERR(0, 414, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__55); - __Pyx_GIVEREF(__pyx_tuple__55); - __pyx_codeobj__56 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__55, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_reset_override, 414, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__56)) __PYX_ERR(0, 414, __pyx_L1_error) + __pyx_tuple__57 = PyTuple_Pack(2, __pyx_n_s_cls, __pyx_n_s_provider); if (unlikely(!__pyx_tuple__57)) __PYX_ERR(0, 436, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__57); + __Pyx_GIVEREF(__pyx_tuple__57); + __pyx_codeobj__58 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__57, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_reset_override, 436, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__58)) __PYX_ERR(0, 436, __pyx_L1_error) - /* "dependency_injector/containers.pyx":425 + /* "dependency_injector/containers.pyx":447 * * @classmethod * def resolve_provider_name(cls, provider_to_resolve): # <<<<<<<<<<<<<< * """Try to resolve provider name by its instance.""" * for provider_name, container_provider in cls.providers.items(): */ - __pyx_tuple__57 = PyTuple_Pack(4, __pyx_n_s_cls, __pyx_n_s_provider_to_resolve, __pyx_n_s_provider_name, __pyx_n_s_container_provider); if (unlikely(!__pyx_tuple__57)) __PYX_ERR(0, 425, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__57); - __Pyx_GIVEREF(__pyx_tuple__57); - __pyx_codeobj__58 = (PyObject*)__Pyx_PyCode_New(2, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__57, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_resolve_provider_name, 425, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__58)) __PYX_ERR(0, 425, __pyx_L1_error) + __pyx_tuple__59 = PyTuple_Pack(4, __pyx_n_s_cls, __pyx_n_s_provider_to_resolve, __pyx_n_s_provider_name, __pyx_n_s_container_provider); if (unlikely(!__pyx_tuple__59)) __PYX_ERR(0, 447, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__59); + __Pyx_GIVEREF(__pyx_tuple__59); + __pyx_codeobj__60 = (PyObject*)__Pyx_PyCode_New(2, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__59, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_resolve_provider_name, 447, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__60)) __PYX_ERR(0, 447, __pyx_L1_error) - /* "dependency_injector/containers.pyx":434 + /* "dependency_injector/containers.pyx":456 * * * def override(object container): # <<<<<<<<<<<<<< * """:py:class:`DeclarativeContainer` overriding decorator. * */ - __pyx_tuple__59 = PyTuple_Pack(3, __pyx_n_s_container, __pyx_n_s_decorator, __pyx_n_s_decorator); if (unlikely(!__pyx_tuple__59)) __PYX_ERR(0, 434, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__59); - __Pyx_GIVEREF(__pyx_tuple__59); - __pyx_codeobj__60 = (PyObject*)__Pyx_PyCode_New(1, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__59, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_override, 434, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__60)) __PYX_ERR(0, 434, __pyx_L1_error) + __pyx_tuple__61 = PyTuple_Pack(3, __pyx_n_s_container, __pyx_n_s_decorator, __pyx_n_s_decorator); if (unlikely(!__pyx_tuple__61)) __PYX_ERR(0, 456, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__61); + __Pyx_GIVEREF(__pyx_tuple__61); + __pyx_codeobj__62 = (PyObject*)__Pyx_PyCode_New(1, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__61, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_override, 456, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__62)) __PYX_ERR(0, 456, __pyx_L1_error) - /* "dependency_injector/containers.pyx":451 + /* "dependency_injector/containers.pyx":473 * * * def copy(object container): # <<<<<<<<<<<<<< * """:py:class:`DeclarativeContainer` copying decorator. * */ - __pyx_tuple__61 = PyTuple_Pack(3, __pyx_n_s_container, __pyx_n_s_decorator, __pyx_n_s_decorator); if (unlikely(!__pyx_tuple__61)) __PYX_ERR(0, 451, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__61); - __Pyx_GIVEREF(__pyx_tuple__61); - __pyx_codeobj__62 = (PyObject*)__Pyx_PyCode_New(1, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__61, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_copy, 451, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__62)) __PYX_ERR(0, 451, __pyx_L1_error) + __pyx_tuple__63 = PyTuple_Pack(3, __pyx_n_s_container, __pyx_n_s_decorator, __pyx_n_s_decorator); if (unlikely(!__pyx_tuple__63)) __PYX_ERR(0, 473, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__63); + __Pyx_GIVEREF(__pyx_tuple__63); + __pyx_codeobj__64 = (PyObject*)__Pyx_PyCode_New(1, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__63, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_containe, __pyx_n_s_copy, 473, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__64)) __PYX_ERR(0, 473, __pyx_L1_error) __Pyx_RefNannyFinishContext(); return 0; __pyx_L1_error:; @@ -13883,6 +17411,7 @@ static int __Pyx_modinit_function_export_code(void) { /*--- Function export code ---*/ if (__Pyx_ExportFunction("is_container", (void (*)(void))__pyx_f_19dependency_injector_10containers_is_container, "int (PyObject *, int __pyx_skip_dispatch)") < 0) __PYX_ERR(0, 1, __pyx_L1_error) if (__Pyx_ExportFunction("_check_provider_type", (void (*)(void))__pyx_f_19dependency_injector_10containers__check_provider_type, "PyObject *(PyObject *, PyObject *, int __pyx_skip_dispatch)") < 0) __PYX_ERR(0, 1, __pyx_L1_error) + if (__Pyx_ExportFunction("_isawaitable", (void (*)(void))__pyx_f_19dependency_injector_10containers__isawaitable, "int (PyObject *, int __pyx_skip_dispatch)") < 0) __PYX_ERR(0, 1, __pyx_L1_error) __Pyx_RefNannyFinishContext(); return 0; __pyx_L1_error:; @@ -13897,7 +17426,7 @@ static int __Pyx_modinit_type_init_code(void) { int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__Pyx_modinit_type_init_code", 0); /*--- Type init code ---*/ - if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct____new__) < 0) __PYX_ERR(0, 235, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct____new__) < 0) __PYX_ERR(0, 257, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_10containers___pyx_scope_struct____new__.tp_print = 0; #endif @@ -13905,7 +17434,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_19dependency_injector_10containers___pyx_scope_struct____new__.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_19dependency_injector_10containers___pyx_scope_struct____new__ = &__pyx_type_19dependency_injector_10containers___pyx_scope_struct____new__; - if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct_1_genexpr) < 0) __PYX_ERR(0, 241, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct_1_genexpr) < 0) __PYX_ERR(0, 263, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_10containers___pyx_scope_struct_1_genexpr.tp_print = 0; #endif @@ -13913,7 +17442,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_19dependency_injector_10containers___pyx_scope_struct_1_genexpr.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_19dependency_injector_10containers___pyx_scope_struct_1_genexpr = &__pyx_type_19dependency_injector_10containers___pyx_scope_struct_1_genexpr; - if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct_2_genexpr) < 0) __PYX_ERR(0, 247, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct_2_genexpr) < 0) __PYX_ERR(0, 269, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_10containers___pyx_scope_struct_2_genexpr.tp_print = 0; #endif @@ -13921,7 +17450,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_19dependency_injector_10containers___pyx_scope_struct_2_genexpr.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_19dependency_injector_10containers___pyx_scope_struct_2_genexpr = &__pyx_type_19dependency_injector_10containers___pyx_scope_struct_2_genexpr; - if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct_3_genexpr) < 0) __PYX_ERR(0, 251, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct_3_genexpr) < 0) __PYX_ERR(0, 273, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_10containers___pyx_scope_struct_3_genexpr.tp_print = 0; #endif @@ -13929,7 +17458,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_19dependency_injector_10containers___pyx_scope_struct_3_genexpr.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_19dependency_injector_10containers___pyx_scope_struct_3_genexpr = &__pyx_type_19dependency_injector_10containers___pyx_scope_struct_3_genexpr; - if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct_4_override) < 0) __PYX_ERR(0, 434, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct_4_override) < 0) __PYX_ERR(0, 456, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_10containers___pyx_scope_struct_4_override.tp_print = 0; #endif @@ -13937,7 +17466,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_19dependency_injector_10containers___pyx_scope_struct_4_override.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_19dependency_injector_10containers___pyx_scope_struct_4_override = &__pyx_type_19dependency_injector_10containers___pyx_scope_struct_4_override; - if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct_5_copy) < 0) __PYX_ERR(0, 451, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_10containers___pyx_scope_struct_5_copy) < 0) __PYX_ERR(0, 473, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_10containers___pyx_scope_struct_5_copy.tp_print = 0; #endif @@ -13945,6 +17474,14 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_19dependency_injector_10containers___pyx_scope_struct_5_copy.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_19dependency_injector_10containers___pyx_scope_struct_5_copy = &__pyx_type_19dependency_injector_10containers___pyx_scope_struct_5_copy; + if (PyType_Ready(&__pyx_scope_struct____Pyx_CFunc_void____object___to_py) < 0) __PYX_ERR(2, 64, __pyx_L1_error) + #if PY_VERSION_HEX < 0x030800B1 + __pyx_scope_struct____Pyx_CFunc_void____object___to_py.tp_print = 0; + #endif + if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_scope_struct____Pyx_CFunc_void____object___to_py.tp_dictoffset && __pyx_scope_struct____Pyx_CFunc_void____object___to_py.tp_getattro == PyObject_GenericGetAttr)) { + __pyx_scope_struct____Pyx_CFunc_void____object___to_py.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; + } + __pyx_ptype___pyx_scope_struct____Pyx_CFunc_void____object___to_py = &__pyx_scope_struct____Pyx_CFunc_void____object___to_py; __Pyx_RefNannyFinishContext(); return 0; __pyx_L1_error:; @@ -13960,136 +17497,136 @@ static int __Pyx_modinit_type_import_code(void) { int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__Pyx_modinit_type_import_code", 0); /*--- Type import code ---*/ - __pyx_t_1 = PyImport_ImportModule("dependency_injector.providers"); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 7, __pyx_L1_error) + __pyx_t_1 = PyImport_ImportModule("dependency_injector.providers"); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_ptype_19dependency_injector_9providers_Provider = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Provider", sizeof(struct __pyx_obj_19dependency_injector_9providers_Provider), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Provider) __PYX_ERR(1, 7, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Provider = (struct __pyx_vtabstruct_19dependency_injector_9providers_Provider*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Provider->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Provider)) __PYX_ERR(1, 7, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Provider) __PYX_ERR(1, 14, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Provider = (struct __pyx_vtabstruct_19dependency_injector_9providers_Provider*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Provider->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Provider)) __PYX_ERR(1, 14, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Object = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Object", sizeof(struct __pyx_obj_19dependency_injector_9providers_Object), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Object) __PYX_ERR(1, 15, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Object = (struct __pyx_vtabstruct_19dependency_injector_9providers_Object*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Object->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Object)) __PYX_ERR(1, 15, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Object) __PYX_ERR(1, 23, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Object = (struct __pyx_vtabstruct_19dependency_injector_9providers_Object*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Object->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Object)) __PYX_ERR(1, 23, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Delegate = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Delegate", sizeof(struct __pyx_obj_19dependency_injector_9providers_Delegate), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Delegate) __PYX_ERR(1, 21, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Delegate = (struct __pyx_vtabstruct_19dependency_injector_9providers_Delegate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Delegate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Delegate)) __PYX_ERR(1, 21, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Delegate) __PYX_ERR(1, 29, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Delegate = (struct __pyx_vtabstruct_19dependency_injector_9providers_Delegate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Delegate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Delegate)) __PYX_ERR(1, 29, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Dependency = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Dependency", sizeof(struct __pyx_obj_19dependency_injector_9providers_Dependency), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Dependency) __PYX_ERR(1, 27, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Dependency = (struct __pyx_vtabstruct_19dependency_injector_9providers_Dependency*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Dependency->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Dependency)) __PYX_ERR(1, 27, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Dependency) __PYX_ERR(1, 35, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Dependency = (struct __pyx_vtabstruct_19dependency_injector_9providers_Dependency*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Dependency->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Dependency)) __PYX_ERR(1, 35, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ExternalDependency = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "ExternalDependency", sizeof(struct __pyx_obj_19dependency_injector_9providers_ExternalDependency), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_ExternalDependency) __PYX_ERR(1, 31, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_ExternalDependency = (struct __pyx_vtabstruct_19dependency_injector_9providers_ExternalDependency*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ExternalDependency->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ExternalDependency)) __PYX_ERR(1, 31, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_ExternalDependency) __PYX_ERR(1, 39, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_ExternalDependency = (struct __pyx_vtabstruct_19dependency_injector_9providers_ExternalDependency*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ExternalDependency->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ExternalDependency)) __PYX_ERR(1, 39, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DependenciesContainer = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "DependenciesContainer", sizeof(struct __pyx_obj_19dependency_injector_9providers_DependenciesContainer), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_DependenciesContainer) __PYX_ERR(1, 35, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_DependenciesContainer = (struct __pyx_vtabstruct_19dependency_injector_9providers_DependenciesContainer*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DependenciesContainer->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DependenciesContainer)) __PYX_ERR(1, 35, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_DependenciesContainer) __PYX_ERR(1, 43, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_DependenciesContainer = (struct __pyx_vtabstruct_19dependency_injector_9providers_DependenciesContainer*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DependenciesContainer->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DependenciesContainer)) __PYX_ERR(1, 43, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_OverridingContext = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "OverridingContext", sizeof(struct __pyx_obj_19dependency_injector_9providers_OverridingContext), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_OverridingContext) __PYX_ERR(1, 41, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_OverridingContext) __PYX_ERR(1, 49, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Callable = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Callable", sizeof(struct __pyx_obj_19dependency_injector_9providers_Callable), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Callable) __PYX_ERR(1, 47, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Callable = (struct __pyx_vtabstruct_19dependency_injector_9providers_Callable*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Callable->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Callable)) __PYX_ERR(1, 47, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Callable) __PYX_ERR(1, 55, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Callable = (struct __pyx_vtabstruct_19dependency_injector_9providers_Callable*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Callable->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Callable)) __PYX_ERR(1, 55, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedCallable = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "DelegatedCallable", sizeof(struct __pyx_obj_19dependency_injector_9providers_DelegatedCallable), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_DelegatedCallable) __PYX_ERR(1, 59, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_DelegatedCallable = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCallable*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedCallable->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedCallable)) __PYX_ERR(1, 59, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_DelegatedCallable) __PYX_ERR(1, 67, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_DelegatedCallable = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCallable*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedCallable->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedCallable)) __PYX_ERR(1, 67, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_AbstractCallable = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "AbstractCallable", sizeof(struct __pyx_obj_19dependency_injector_9providers_AbstractCallable), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_AbstractCallable) __PYX_ERR(1, 63, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_AbstractCallable = (struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCallable*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_AbstractCallable->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_AbstractCallable)) __PYX_ERR(1, 63, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_AbstractCallable) __PYX_ERR(1, 71, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_AbstractCallable = (struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCallable*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_AbstractCallable->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_AbstractCallable)) __PYX_ERR(1, 71, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_CallableDelegate = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "CallableDelegate", sizeof(struct __pyx_obj_19dependency_injector_9providers_CallableDelegate), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_CallableDelegate) __PYX_ERR(1, 67, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_CallableDelegate = (struct __pyx_vtabstruct_19dependency_injector_9providers_CallableDelegate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_CallableDelegate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_CallableDelegate)) __PYX_ERR(1, 67, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_CallableDelegate) __PYX_ERR(1, 75, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_CallableDelegate = (struct __pyx_vtabstruct_19dependency_injector_9providers_CallableDelegate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_CallableDelegate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_CallableDelegate)) __PYX_ERR(1, 75, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Coroutine = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Coroutine", sizeof(struct __pyx_obj_19dependency_injector_9providers_Coroutine), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Coroutine) __PYX_ERR(1, 72, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Coroutine = (struct __pyx_vtabstruct_19dependency_injector_9providers_Coroutine*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Coroutine->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Coroutine)) __PYX_ERR(1, 72, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Coroutine) __PYX_ERR(1, 80, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Coroutine = (struct __pyx_vtabstruct_19dependency_injector_9providers_Coroutine*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Coroutine->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Coroutine)) __PYX_ERR(1, 80, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedCoroutine = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "DelegatedCoroutine", sizeof(struct __pyx_obj_19dependency_injector_9providers_DelegatedCoroutine), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_DelegatedCoroutine) __PYX_ERR(1, 76, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_DelegatedCoroutine = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCoroutine*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedCoroutine->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedCoroutine)) __PYX_ERR(1, 76, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_DelegatedCoroutine) __PYX_ERR(1, 84, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_DelegatedCoroutine = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCoroutine*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedCoroutine->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedCoroutine)) __PYX_ERR(1, 84, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_AbstractCoroutine = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "AbstractCoroutine", sizeof(struct __pyx_obj_19dependency_injector_9providers_AbstractCoroutine), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_AbstractCoroutine) __PYX_ERR(1, 80, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_AbstractCoroutine = (struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCoroutine*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_AbstractCoroutine->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_AbstractCoroutine)) __PYX_ERR(1, 80, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_AbstractCoroutine) __PYX_ERR(1, 88, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_AbstractCoroutine = (struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCoroutine*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_AbstractCoroutine->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_AbstractCoroutine)) __PYX_ERR(1, 88, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_CoroutineDelegate = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "CoroutineDelegate", sizeof(struct __pyx_obj_19dependency_injector_9providers_CoroutineDelegate), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_CoroutineDelegate) __PYX_ERR(1, 84, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_CoroutineDelegate = (struct __pyx_vtabstruct_19dependency_injector_9providers_CoroutineDelegate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_CoroutineDelegate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_CoroutineDelegate)) __PYX_ERR(1, 84, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_CoroutineDelegate) __PYX_ERR(1, 92, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_CoroutineDelegate = (struct __pyx_vtabstruct_19dependency_injector_9providers_CoroutineDelegate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_CoroutineDelegate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_CoroutineDelegate)) __PYX_ERR(1, 92, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ConfigurationOption = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "ConfigurationOption", sizeof(struct __pyx_obj_19dependency_injector_9providers_ConfigurationOption), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_ConfigurationOption) __PYX_ERR(1, 89, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_ConfigurationOption = (struct __pyx_vtabstruct_19dependency_injector_9providers_ConfigurationOption*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ConfigurationOption->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ConfigurationOption)) __PYX_ERR(1, 89, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_ConfigurationOption) __PYX_ERR(1, 97, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_ConfigurationOption = (struct __pyx_vtabstruct_19dependency_injector_9providers_ConfigurationOption*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ConfigurationOption->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ConfigurationOption)) __PYX_ERR(1, 97, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "TypedConfigurationOption", sizeof(struct __pyx_obj_19dependency_injector_9providers_TypedConfigurationOption), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption) __PYX_ERR(1, 96, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_TypedConfigurationOption = (struct __pyx_vtabstruct_19dependency_injector_9providers_TypedConfigurationOption*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_TypedConfigurationOption)) __PYX_ERR(1, 96, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption) __PYX_ERR(1, 104, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_TypedConfigurationOption = (struct __pyx_vtabstruct_19dependency_injector_9providers_TypedConfigurationOption*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_TypedConfigurationOption)) __PYX_ERR(1, 104, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Configuration = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Configuration", sizeof(struct __pyx_obj_19dependency_injector_9providers_Configuration), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Configuration) __PYX_ERR(1, 100, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Configuration = (struct __pyx_vtabstruct_19dependency_injector_9providers_Configuration*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Configuration->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Configuration)) __PYX_ERR(1, 100, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Configuration) __PYX_ERR(1, 108, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Configuration = (struct __pyx_vtabstruct_19dependency_injector_9providers_Configuration*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Configuration->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Configuration)) __PYX_ERR(1, 108, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Factory = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Factory", sizeof(struct __pyx_obj_19dependency_injector_9providers_Factory), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Factory) __PYX_ERR(1, 107, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Factory = (struct __pyx_vtabstruct_19dependency_injector_9providers_Factory*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Factory->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Factory)) __PYX_ERR(1, 107, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Factory) __PYX_ERR(1, 115, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Factory = (struct __pyx_vtabstruct_19dependency_injector_9providers_Factory*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Factory->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Factory)) __PYX_ERR(1, 115, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedFactory = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "DelegatedFactory", sizeof(struct __pyx_obj_19dependency_injector_9providers_DelegatedFactory), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_DelegatedFactory) __PYX_ERR(1, 116, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_DelegatedFactory = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedFactory*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedFactory->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedFactory)) __PYX_ERR(1, 116, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_DelegatedFactory) __PYX_ERR(1, 124, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_DelegatedFactory = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedFactory*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedFactory->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedFactory)) __PYX_ERR(1, 124, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_AbstractFactory = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "AbstractFactory", sizeof(struct __pyx_obj_19dependency_injector_9providers_AbstractFactory), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_AbstractFactory) __PYX_ERR(1, 120, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_AbstractFactory = (struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractFactory*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_AbstractFactory->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_AbstractFactory)) __PYX_ERR(1, 120, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_AbstractFactory) __PYX_ERR(1, 128, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_AbstractFactory = (struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractFactory*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_AbstractFactory->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_AbstractFactory)) __PYX_ERR(1, 128, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_FactoryDelegate = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "FactoryDelegate", sizeof(struct __pyx_obj_19dependency_injector_9providers_FactoryDelegate), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_FactoryDelegate) __PYX_ERR(1, 124, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_FactoryDelegate = (struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryDelegate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_FactoryDelegate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_FactoryDelegate)) __PYX_ERR(1, 124, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_FactoryDelegate) __PYX_ERR(1, 132, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_FactoryDelegate = (struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryDelegate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_FactoryDelegate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_FactoryDelegate)) __PYX_ERR(1, 132, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_FactoryAggregate = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "FactoryAggregate", sizeof(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_FactoryAggregate) __PYX_ERR(1, 128, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_FactoryAggregate = (struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_FactoryAggregate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_FactoryAggregate)) __PYX_ERR(1, 128, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_FactoryAggregate) __PYX_ERR(1, 136, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_FactoryAggregate = (struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_FactoryAggregate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_FactoryAggregate)) __PYX_ERR(1, 136, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_BaseSingleton = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "BaseSingleton", sizeof(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_BaseSingleton) __PYX_ERR(1, 135, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_BaseSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_BaseSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_BaseSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_BaseSingleton)) __PYX_ERR(1, 135, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_BaseSingleton) __PYX_ERR(1, 143, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_BaseSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_BaseSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_BaseSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_BaseSingleton)) __PYX_ERR(1, 143, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Singleton = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Singleton", sizeof(struct __pyx_obj_19dependency_injector_9providers_Singleton), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Singleton) __PYX_ERR(1, 139, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Singleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_Singleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Singleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Singleton)) __PYX_ERR(1, 139, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Singleton) __PYX_ERR(1, 148, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Singleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_Singleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Singleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Singleton)) __PYX_ERR(1, 148, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedSingleton = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "DelegatedSingleton", sizeof(struct __pyx_obj_19dependency_injector_9providers_DelegatedSingleton), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_DelegatedSingleton) __PYX_ERR(1, 145, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_DelegatedSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedSingleton)) __PYX_ERR(1, 145, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_DelegatedSingleton) __PYX_ERR(1, 153, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_DelegatedSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedSingleton)) __PYX_ERR(1, 153, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "ThreadSafeSingleton", sizeof(struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton) __PYX_ERR(1, 149, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadSafeSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton)) __PYX_ERR(1, 149, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton) __PYX_ERR(1, 157, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadSafeSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton)) __PYX_ERR(1, 157, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedThreadSafeSingleton = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "DelegatedThreadSafeSingleton", sizeof(struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadSafeSingleton), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_DelegatedThreadSafeSingleton) __PYX_ERR(1, 156, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadSafeSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadSafeSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedThreadSafeSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadSafeSingleton)) __PYX_ERR(1, 156, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_DelegatedThreadSafeSingleton) __PYX_ERR(1, 163, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadSafeSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadSafeSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedThreadSafeSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadSafeSingleton)) __PYX_ERR(1, 163, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ThreadLocalSingleton = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "ThreadLocalSingleton", sizeof(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_ThreadLocalSingleton) __PYX_ERR(1, 160, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadLocalSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ThreadLocalSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton)) __PYX_ERR(1, 160, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_ThreadLocalSingleton) __PYX_ERR(1, 167, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadLocalSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ThreadLocalSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton)) __PYX_ERR(1, 167, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedThreadLocalSingleton = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "DelegatedThreadLocalSingleton", sizeof(struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadLocalSingleton), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_DelegatedThreadLocalSingleton) __PYX_ERR(1, 166, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadLocalSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadLocalSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedThreadLocalSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadLocalSingleton)) __PYX_ERR(1, 166, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_DelegatedThreadLocalSingleton) __PYX_ERR(1, 172, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadLocalSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadLocalSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_DelegatedThreadLocalSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadLocalSingleton)) __PYX_ERR(1, 172, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_AbstractSingleton = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "AbstractSingleton", sizeof(struct __pyx_obj_19dependency_injector_9providers_AbstractSingleton), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_AbstractSingleton) __PYX_ERR(1, 170, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_AbstractSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_AbstractSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_AbstractSingleton)) __PYX_ERR(1, 170, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_AbstractSingleton) __PYX_ERR(1, 176, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_AbstractSingleton = (struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractSingleton*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_AbstractSingleton->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_AbstractSingleton)) __PYX_ERR(1, 176, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_SingletonDelegate = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "SingletonDelegate", sizeof(struct __pyx_obj_19dependency_injector_9providers_SingletonDelegate), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_SingletonDelegate) __PYX_ERR(1, 174, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_SingletonDelegate = (struct __pyx_vtabstruct_19dependency_injector_9providers_SingletonDelegate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_SingletonDelegate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_SingletonDelegate)) __PYX_ERR(1, 174, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_SingletonDelegate) __PYX_ERR(1, 180, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_SingletonDelegate = (struct __pyx_vtabstruct_19dependency_injector_9providers_SingletonDelegate*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_SingletonDelegate->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_SingletonDelegate)) __PYX_ERR(1, 180, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_List = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "List", sizeof(struct __pyx_obj_19dependency_injector_9providers_List), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_List) __PYX_ERR(1, 180, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_List = (struct __pyx_vtabstruct_19dependency_injector_9providers_List*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_List->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_List)) __PYX_ERR(1, 180, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_List) __PYX_ERR(1, 186, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_List = (struct __pyx_vtabstruct_19dependency_injector_9providers_List*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_List->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_List)) __PYX_ERR(1, 186, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Dict = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Dict", sizeof(struct __pyx_obj_19dependency_injector_9providers_Dict), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Dict) __PYX_ERR(1, 187, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Dict = (struct __pyx_vtabstruct_19dependency_injector_9providers_Dict*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Dict->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Dict)) __PYX_ERR(1, 187, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Dict) __PYX_ERR(1, 193, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Dict = (struct __pyx_vtabstruct_19dependency_injector_9providers_Dict*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Dict->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Dict)) __PYX_ERR(1, 193, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Resource = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Resource", sizeof(struct __pyx_obj_19dependency_injector_9providers_Resource), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Resource) __PYX_ERR(1, 194, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Resource = (struct __pyx_vtabstruct_19dependency_injector_9providers_Resource*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Resource->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Resource)) __PYX_ERR(1, 194, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Resource) __PYX_ERR(1, 200, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Resource = (struct __pyx_vtabstruct_19dependency_injector_9providers_Resource*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Resource->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Resource)) __PYX_ERR(1, 200, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Container = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Container", sizeof(struct __pyx_obj_19dependency_injector_9providers_Container), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Container) __PYX_ERR(1, 209, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Container = (struct __pyx_vtabstruct_19dependency_injector_9providers_Container*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Container->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Container)) __PYX_ERR(1, 209, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Container) __PYX_ERR(1, 215, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Container = (struct __pyx_vtabstruct_19dependency_injector_9providers_Container*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Container->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Container)) __PYX_ERR(1, 215, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Selector = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Selector", sizeof(struct __pyx_obj_19dependency_injector_9providers_Selector), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Selector) __PYX_ERR(1, 217, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_Selector = (struct __pyx_vtabstruct_19dependency_injector_9providers_Selector*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Selector->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Selector)) __PYX_ERR(1, 217, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Selector) __PYX_ERR(1, 223, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_Selector = (struct __pyx_vtabstruct_19dependency_injector_9providers_Selector*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_Selector->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_Selector)) __PYX_ERR(1, 223, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ProvidedInstance = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "ProvidedInstance", sizeof(struct __pyx_obj_19dependency_injector_9providers_ProvidedInstance), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_ProvidedInstance) __PYX_ERR(1, 225, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_ProvidedInstance = (struct __pyx_vtabstruct_19dependency_injector_9providers_ProvidedInstance*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ProvidedInstance->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ProvidedInstance)) __PYX_ERR(1, 225, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_ProvidedInstance) __PYX_ERR(1, 231, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_ProvidedInstance = (struct __pyx_vtabstruct_19dependency_injector_9providers_ProvidedInstance*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ProvidedInstance->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ProvidedInstance)) __PYX_ERR(1, 231, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_AttributeGetter = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "AttributeGetter", sizeof(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_AttributeGetter) __PYX_ERR(1, 231, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_AttributeGetter = (struct __pyx_vtabstruct_19dependency_injector_9providers_AttributeGetter*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_AttributeGetter->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_AttributeGetter)) __PYX_ERR(1, 231, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_AttributeGetter) __PYX_ERR(1, 237, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_AttributeGetter = (struct __pyx_vtabstruct_19dependency_injector_9providers_AttributeGetter*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_AttributeGetter->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_AttributeGetter)) __PYX_ERR(1, 237, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ItemGetter = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "ItemGetter", sizeof(struct __pyx_obj_19dependency_injector_9providers_ItemGetter), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_ItemGetter) __PYX_ERR(1, 238, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_ItemGetter = (struct __pyx_vtabstruct_19dependency_injector_9providers_ItemGetter*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ItemGetter->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ItemGetter)) __PYX_ERR(1, 238, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_ItemGetter) __PYX_ERR(1, 244, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_ItemGetter = (struct __pyx_vtabstruct_19dependency_injector_9providers_ItemGetter*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_ItemGetter->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_ItemGetter)) __PYX_ERR(1, 244, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_MethodCaller = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "MethodCaller", sizeof(struct __pyx_obj_19dependency_injector_9providers_MethodCaller), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_MethodCaller) __PYX_ERR(1, 245, __pyx_L1_error) - __pyx_vtabptr_19dependency_injector_9providers_MethodCaller = (struct __pyx_vtabstruct_19dependency_injector_9providers_MethodCaller*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_MethodCaller->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_MethodCaller)) __PYX_ERR(1, 245, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_MethodCaller) __PYX_ERR(1, 251, __pyx_L1_error) + __pyx_vtabptr_19dependency_injector_9providers_MethodCaller = (struct __pyx_vtabstruct_19dependency_injector_9providers_MethodCaller*)__Pyx_GetVtable(__pyx_ptype_19dependency_injector_9providers_MethodCaller->tp_dict); if (unlikely(!__pyx_vtabptr_19dependency_injector_9providers_MethodCaller)) __PYX_ERR(1, 251, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Injection = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "Injection", sizeof(struct __pyx_obj_19dependency_injector_9providers_Injection), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_Injection) __PYX_ERR(1, 256, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_Injection) __PYX_ERR(1, 262, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_PositionalInjection = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "PositionalInjection", sizeof(struct __pyx_obj_19dependency_injector_9providers_PositionalInjection), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_PositionalInjection) __PYX_ERR(1, 263, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_PositionalInjection) __PYX_ERR(1, 269, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_NamedInjection = __Pyx_ImportType(__pyx_t_1, "dependency_injector.providers", "NamedInjection", sizeof(struct __pyx_obj_19dependency_injector_9providers_NamedInjection), __Pyx_ImportType_CheckSize_Warn); - if (!__pyx_ptype_19dependency_injector_9providers_NamedInjection) __PYX_ERR(1, 267, __pyx_L1_error) + if (!__pyx_ptype_19dependency_injector_9providers_NamedInjection) __PYX_ERR(1, 273, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_RefNannyFinishContext(); return 0; @@ -14110,6 +17647,7 @@ static int __Pyx_modinit_variable_import_code(void) { __pyx_t_1 = PyImport_ImportModule("dependency_injector.providers"); if (!__pyx_t_1) __PYX_ERR(0, 1, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (__Pyx_ImportVoidPtr(__pyx_t_1, "CLASS_TYPES", (void **)&__pyx_vp_19dependency_injector_9providers_CLASS_TYPES, "PyObject *") < 0) __PYX_ERR(0, 1, __pyx_L1_error) + if (__Pyx_ImportVoidPtr(__pyx_t_1, "__has_isawaitable", (void **)&__pyx_vp_19dependency_injector_9providers___has_isawaitable, "int") < 0) __PYX_ERR(0, 1, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_RefNannyFinishContext(); return 0; @@ -14235,12 +17773,16 @@ static CYTHON_SMALL_CODE int __pyx_pymod_exec_containers(PyObject *__pyx_pyinit_ { PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; - int __pyx_t_3; + PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; - PyObject *__pyx_t_5 = NULL; + int __pyx_t_5; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; - PyObject *__pyx_t_8 = NULL; + int __pyx_t_8; + PyObject *__pyx_t_9 = NULL; + PyObject *__pyx_t_10 = NULL; + PyObject *__pyx_t_11 = NULL; + PyObject *__pyx_t_12 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -14351,108 +17893,214 @@ if (!__Pyx_RefNanny) { /* "dependency_injector/containers.pyx":3 * """Containers module.""" * + * import inspect # <<<<<<<<<<<<<< + * import sys + * + */ + __pyx_t_1 = __Pyx_patch_inspect(__Pyx_Import(__pyx_n_s_inspect, 0, -1)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 3, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_inspect, __pyx_t_1) < 0) __PYX_ERR(0, 3, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/containers.pyx":4 + * + * import inspect * import sys # <<<<<<<<<<<<<< * + * try: + */ + __pyx_t_1 = __Pyx_Import(__pyx_n_s_sys, 0, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 4, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_sys, __pyx_t_1) < 0) __PYX_ERR(0, 4, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/containers.pyx":6 + * import sys + * + * try: # <<<<<<<<<<<<<< + * import asyncio + * except ImportError: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_2, &__pyx_t_3, &__pyx_t_4); + __Pyx_XGOTREF(__pyx_t_2); + __Pyx_XGOTREF(__pyx_t_3); + __Pyx_XGOTREF(__pyx_t_4); + /*try:*/ { + + /* "dependency_injector/containers.pyx":7 + * + * try: + * import asyncio # <<<<<<<<<<<<<< + * except ImportError: + * asyncio = None + */ + __pyx_t_1 = __Pyx_patch_asyncio(__Pyx_Import(__pyx_n_s_asyncio, 0, -1)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 7, __pyx_L2_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_asyncio, __pyx_t_1) < 0) __PYX_ERR(0, 7, __pyx_L2_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/containers.pyx":6 + * import sys + * + * try: # <<<<<<<<<<<<<< + * import asyncio + * except ImportError: + */ + } + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + goto __pyx_L7_try_end; + __pyx_L2_error:; + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/containers.pyx":8 + * try: + * import asyncio + * except ImportError: # <<<<<<<<<<<<<< + * asyncio = None + * + */ + __pyx_t_5 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_ImportError); + if (__pyx_t_5) { + __Pyx_AddTraceback("dependency_injector.containers", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(0, 8, __pyx_L4_except_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_GOTREF(__pyx_t_6); + __Pyx_GOTREF(__pyx_t_7); + + /* "dependency_injector/containers.pyx":9 + * import asyncio + * except ImportError: + * asyncio = None # <<<<<<<<<<<<<< + * * import six */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_sys, 0, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 3, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_sys, __pyx_t_1) < 0) __PYX_ERR(0, 3, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + if (PyDict_SetItem(__pyx_d, __pyx_n_s_asyncio, Py_None) < 0) __PYX_ERR(0, 9, __pyx_L4_except_error) + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; + goto __pyx_L3_exception_handled; + } + goto __pyx_L4_except_error; + __pyx_L4_except_error:; - /* "dependency_injector/containers.pyx":5 + /* "dependency_injector/containers.pyx":6 * import sys * + * try: # <<<<<<<<<<<<<< + * import asyncio + * except ImportError: + */ + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_XGIVEREF(__pyx_t_4); + __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4); + goto __pyx_L1_error; + __pyx_L3_exception_handled:; + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_XGIVEREF(__pyx_t_4); + __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4); + __pyx_L7_try_end:; + } + + /* "dependency_injector/containers.pyx":11 + * asyncio = None + * * import six # <<<<<<<<<<<<<< * * from .errors import Error */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_six, 0, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 5, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_six, __pyx_t_1) < 0) __PYX_ERR(0, 5, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_7 = __Pyx_Import(__pyx_n_s_six, 0, -1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 11, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_six, __pyx_t_7) < 0) __PYX_ERR(0, 11, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/containers.pyx":7 + /* "dependency_injector/containers.pyx":13 * import six * * from .errors import Error # <<<<<<<<<<<<<< * from .providers cimport ( * Provider, */ - __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 7, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_7 = PyList_New(1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); __Pyx_INCREF(__pyx_n_s_Error); __Pyx_GIVEREF(__pyx_n_s_Error); - PyList_SET_ITEM(__pyx_t_1, 0, __pyx_n_s_Error); - __pyx_t_2 = __Pyx_Import(__pyx_n_s_errors, __pyx_t_1, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 7, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 7, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_Error, __pyx_t_1) < 0) __PYX_ERR(0, 7, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + PyList_SET_ITEM(__pyx_t_7, 0, __pyx_n_s_Error); + __pyx_t_6 = __Pyx_Import(__pyx_n_s_errors, __pyx_t_7, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_7 = __Pyx_ImportFrom(__pyx_t_6, __pyx_n_s_Error); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_Error, __pyx_t_7) < 0) __PYX_ERR(0, 13, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":15 + /* "dependency_injector/containers.pyx":21 * * * if sys.version_info[:2] >= (3, 6): # <<<<<<<<<<<<<< * from .wiring import wire, unwire * else: */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_sys); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_version_info); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_t_1, 0, 2, NULL, NULL, &__pyx_slice__8, 0, 1, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyObject_RichCompare(__pyx_t_2, __pyx_tuple__9, Py_GE); __Pyx_XGOTREF(__pyx_t_1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 15, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 15, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (__pyx_t_3) { + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_sys); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 21, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_version_info); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 21, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_6 = __Pyx_PyObject_GetSlice(__pyx_t_7, 0, 2, NULL, NULL, &__pyx_slice__10, 0, 1, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 21, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_7 = PyObject_RichCompare(__pyx_t_6, __pyx_tuple__11, Py_GE); __Pyx_XGOTREF(__pyx_t_7); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 21, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_7); if (unlikely(__pyx_t_8 < 0)) __PYX_ERR(0, 21, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + if (__pyx_t_8) { - /* "dependency_injector/containers.pyx":16 + /* "dependency_injector/containers.pyx":22 * * if sys.version_info[:2] >= (3, 6): * from .wiring import wire, unwire # <<<<<<<<<<<<<< * else: * def wire(*args, **kwargs): */ - __pyx_t_1 = PyList_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 16, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_7 = PyList_New(2); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 22, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); __Pyx_INCREF(__pyx_n_s_wire); __Pyx_GIVEREF(__pyx_n_s_wire); - PyList_SET_ITEM(__pyx_t_1, 0, __pyx_n_s_wire); + PyList_SET_ITEM(__pyx_t_7, 0, __pyx_n_s_wire); __Pyx_INCREF(__pyx_n_s_unwire); __Pyx_GIVEREF(__pyx_n_s_unwire); - PyList_SET_ITEM(__pyx_t_1, 1, __pyx_n_s_unwire); - __pyx_t_2 = __Pyx_Import(__pyx_n_s_wiring, __pyx_t_1, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 16, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_2, __pyx_n_s_wire); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 16, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_wire, __pyx_t_1) < 0) __PYX_ERR(0, 16, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_2, __pyx_n_s_unwire); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 16, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_unwire, __pyx_t_1) < 0) __PYX_ERR(0, 16, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + PyList_SET_ITEM(__pyx_t_7, 1, __pyx_n_s_unwire); + __pyx_t_6 = __Pyx_Import(__pyx_n_s_wiring, __pyx_t_7, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 22, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_7 = __Pyx_ImportFrom(__pyx_t_6, __pyx_n_s_wire); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 22, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_wire, __pyx_t_7) < 0) __PYX_ERR(0, 22, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_7 = __Pyx_ImportFrom(__pyx_t_6, __pyx_n_s_unwire); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 22, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_unwire, __pyx_t_7) < 0) __PYX_ERR(0, 22, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":15 + /* "dependency_injector/containers.pyx":21 * * * if sys.version_info[:2] >= (3, 6): # <<<<<<<<<<<<<< * from .wiring import wire, unwire * else: */ - goto __pyx_L2; + goto __pyx_L10; } - /* "dependency_injector/containers.pyx":18 + /* "dependency_injector/containers.pyx":24 * from .wiring import wire, unwire * else: * def wire(*args, **kwargs): # <<<<<<<<<<<<<< @@ -14460,592 +18108,592 @@ if (!__Pyx_RefNanny) { * */ /*else*/ { - __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_10containers_1wire, NULL, __pyx_n_s_dependency_injector_containers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 18, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_wire, __pyx_t_2) < 0) __PYX_ERR(0, 18, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_6 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_10containers_1wire, NULL, __pyx_n_s_dependency_injector_containers); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 24, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_wire, __pyx_t_6) < 0) __PYX_ERR(0, 24, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":21 + /* "dependency_injector/containers.pyx":27 * raise NotImplementedError('Wiring requires Python 3.6 or above') * * def unwire(*args, **kwargs): # <<<<<<<<<<<<<< * raise NotImplementedError('Wiring requires Python 3.6 or above') * */ - __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_10containers_3unwire, NULL, __pyx_n_s_dependency_injector_containers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 21, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_unwire, __pyx_t_2) < 0) __PYX_ERR(0, 21, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_6 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_10containers_3unwire, NULL, __pyx_n_s_dependency_injector_containers); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 27, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_unwire, __pyx_t_6) < 0) __PYX_ERR(0, 27, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } - __pyx_L2:; + __pyx_L10:; - /* "dependency_injector/containers.pyx":25 + /* "dependency_injector/containers.pyx":31 * * * class DynamicContainer(object): # <<<<<<<<<<<<<< * """Dynamic inversion of control container. * */ - __pyx_t_2 = __Pyx_CalculateMetaclass(NULL, __pyx_tuple__14); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 25, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_Py3MetaclassPrepare(__pyx_t_2, __pyx_tuple__14, __pyx_n_s_DynamicContainer, __pyx_n_s_DynamicContainer, (PyObject *) NULL, __pyx_n_s_dependency_injector_containers, __pyx_kp_s_Dynamic_inversion_of_control_con); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 25, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_6 = __Pyx_CalculateMetaclass(NULL, __pyx_tuple__16); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 31, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_7 = __Pyx_Py3MetaclassPrepare(__pyx_t_6, __pyx_tuple__16, __pyx_n_s_DynamicContainer, __pyx_n_s_DynamicContainer, (PyObject *) NULL, __pyx_n_s_dependency_injector_containers, __pyx_kp_s_Dynamic_inversion_of_control_con); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 31, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); - /* "dependency_injector/containers.pyx":54 + /* "dependency_injector/containers.pyx":60 * """ * * __IS_CONTAINER__ = True # <<<<<<<<<<<<<< * * def __init__(self): */ - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_IS_CONTAINER, Py_True) < 0) __PYX_ERR(0, 54, __pyx_L1_error) + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_IS_CONTAINER, Py_True) < 0) __PYX_ERR(0, 60, __pyx_L1_error) - /* "dependency_injector/containers.pyx":56 + /* "dependency_injector/containers.pyx":62 * __IS_CONTAINER__ = True * * def __init__(self): # <<<<<<<<<<<<<< * """Initializer. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_1__init__, 0, __pyx_n_s_DynamicContainer___init, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__16)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 56, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_init, __pyx_t_4) < 0) __PYX_ERR(0, 56, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_1__init__, 0, __pyx_n_s_DynamicContainer___init, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__18)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 62, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_init, __pyx_t_1) < 0) __PYX_ERR(0, 62, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":69 + /* "dependency_injector/containers.pyx":75 * super(DynamicContainer, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< * """Create and return full copy of container.""" * copied = memo.get(id(self)) */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_3__deepcopy__, 0, __pyx_n_s_DynamicContainer___deepcopy, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__18)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 69, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_deepcopy, __pyx_t_4) < 0) __PYX_ERR(0, 69, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_3__deepcopy__, 0, __pyx_n_s_DynamicContainer___deepcopy, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__20)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 75, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_deepcopy, __pyx_t_1) < 0) __PYX_ERR(0, 75, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":85 + /* "dependency_injector/containers.pyx":91 * return copied * * def __setattr__(self, str name, object value): # <<<<<<<<<<<<<< * """Set instance attribute. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_5__setattr__, 0, __pyx_n_s_DynamicContainer___setattr, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__20)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 85, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_setattr, __pyx_t_4) < 0) __PYX_ERR(0, 85, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_5__setattr__, 0, __pyx_n_s_DynamicContainer___setattr, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__22)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 91, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_setattr, __pyx_t_1) < 0) __PYX_ERR(0, 91, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":104 + /* "dependency_injector/containers.pyx":110 * super(DynamicContainer, self).__setattr__(name, value) * * def __delattr__(self, str name): # <<<<<<<<<<<<<< * """Delete instance attribute. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_7__delattr__, 0, __pyx_n_s_DynamicContainer___delattr, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__22)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 104, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_delattr, __pyx_t_4) < 0) __PYX_ERR(0, 104, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_7__delattr__, 0, __pyx_n_s_DynamicContainer___delattr, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__24)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 110, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_delattr, __pyx_t_1) < 0) __PYX_ERR(0, 110, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":119 + /* "dependency_injector/containers.pyx":125 * super(DynamicContainer, self).__delattr__(name) * * def set_providers(self, **providers): # <<<<<<<<<<<<<< * """Set container providers. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_9set_providers, 0, __pyx_n_s_DynamicContainer_set_providers, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__24)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 119, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_set_providers, __pyx_t_4) < 0) __PYX_ERR(0, 119, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_9set_providers, 0, __pyx_n_s_DynamicContainer_set_providers, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__26)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 125, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_set_providers, __pyx_t_1) < 0) __PYX_ERR(0, 125, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":131 + /* "dependency_injector/containers.pyx":137 * setattr(self, name, provider) * * def override(self, object overriding): # <<<<<<<<<<<<<< * """Override current container by overriding container. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_11override, 0, __pyx_n_s_DynamicContainer_override, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__26)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 131, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_override, __pyx_t_4) < 0) __PYX_ERR(0, 131, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_11override, 0, __pyx_n_s_DynamicContainer_override, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__28)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 137, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_override, __pyx_t_1) < 0) __PYX_ERR(0, 137, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":154 + /* "dependency_injector/containers.pyx":160 * pass * * def override_providers(self, **overriding_providers): # <<<<<<<<<<<<<< * """Override container providers. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_13override_providers, 0, __pyx_n_s_DynamicContainer_override_provid, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__28)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 154, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_override_providers, __pyx_t_4) < 0) __PYX_ERR(0, 154, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_13override_providers, 0, __pyx_n_s_DynamicContainer_override_provid, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 160, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_override_providers, __pyx_t_1) < 0) __PYX_ERR(0, 160, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":167 + /* "dependency_injector/containers.pyx":173 * container_provider.override(overriding_provider) * * def reset_last_overriding(self): # <<<<<<<<<<<<<< * """Reset last overriding provider for each container providers. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_15reset_last_overriding, 0, __pyx_n_s_DynamicContainer_reset_last_over, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 167, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_reset_last_overriding, __pyx_t_4) < 0) __PYX_ERR(0, 167, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_15reset_last_overriding, 0, __pyx_n_s_DynamicContainer_reset_last_over, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__32)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 173, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_reset_last_overriding, __pyx_t_1) < 0) __PYX_ERR(0, 173, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":180 + /* "dependency_injector/containers.pyx":186 * provider.reset_last_overriding() * * def reset_override(self): # <<<<<<<<<<<<<< * """Reset all overridings for each container providers. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_17reset_override, 0, __pyx_n_s_DynamicContainer_reset_override, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__32)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 180, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_reset_override, __pyx_t_4) < 0) __PYX_ERR(0, 180, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_17reset_override, 0, __pyx_n_s_DynamicContainer_reset_override, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__34)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 186, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_reset_override, __pyx_t_1) < 0) __PYX_ERR(0, 186, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":190 + /* "dependency_injector/containers.pyx":196 * provider.reset_override() * * def wire(self, modules=None, packages=None): # <<<<<<<<<<<<<< * """Wire container providers with provided packages and modules. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_19wire, 0, __pyx_n_s_DynamicContainer_wire, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__34)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 190, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_tuple__35); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_wire, __pyx_t_4) < 0) __PYX_ERR(0, 190, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_19wire, 0, __pyx_n_s_DynamicContainer_wire, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__36)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 196, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_1, __pyx_tuple__37); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_wire, __pyx_t_1) < 0) __PYX_ERR(0, 196, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":207 + /* "dependency_injector/containers.pyx":213 * self.wired_to_packages.extend(packages) * * def unwire(self): # <<<<<<<<<<<<<< * """Unwire container providers from previously wired packages and modules.""" * unwire( */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_21unwire, 0, __pyx_n_s_DynamicContainer_unwire, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__37)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 207, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_unwire, __pyx_t_4) < 0) __PYX_ERR(0, 207, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_21unwire, 0, __pyx_n_s_DynamicContainer_unwire, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__39)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 213, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_unwire, __pyx_t_1) < 0) __PYX_ERR(0, 213, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":217 + /* "dependency_injector/containers.pyx":223 * self.wired_to_packages.clear() * * def init_resources(self): # <<<<<<<<<<<<<< * """Initialize all container resources.""" - * for provider in self.providers.values(): + * futures = [] */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_23init_resources, 0, __pyx_n_s_DynamicContainer_init_resources, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__39)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 217, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_init_resources, __pyx_t_4) < 0) __PYX_ERR(0, 217, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_23init_resources, 0, __pyx_n_s_DynamicContainer_init_resources, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__41)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 223, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_init_resources, __pyx_t_1) < 0) __PYX_ERR(0, 223, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":224 - * provider.init() + /* "dependency_injector/containers.pyx":238 + * return asyncio.gather(*futures) * * def shutdown_resources(self): # <<<<<<<<<<<<<< * """Shutdown all container resources.""" - * for provider in self.providers.values(): + * futures = [] */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_25shutdown_resources, 0, __pyx_n_s_DynamicContainer_shutdown_resour, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__41)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 224, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_shutdown_resources, __pyx_t_4) < 0) __PYX_ERR(0, 224, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_16DynamicContainer_25shutdown_resources, 0, __pyx_n_s_DynamicContainer_shutdown_resour, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__43)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 238, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_shutdown_resources, __pyx_t_1) < 0) __PYX_ERR(0, 238, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":25 + /* "dependency_injector/containers.pyx":31 * * * class DynamicContainer(object): # <<<<<<<<<<<<<< * """Dynamic inversion of control container. * */ - __pyx_t_4 = __Pyx_Py3ClassCreate(__pyx_t_2, __pyx_n_s_DynamicContainer, __pyx_tuple__14, __pyx_t_1, NULL, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 25, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_DynamicContainer, __pyx_t_4) < 0) __PYX_ERR(0, 25, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_Py3ClassCreate(__pyx_t_6, __pyx_n_s_DynamicContainer, __pyx_tuple__16, __pyx_t_7, NULL, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 31, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_DynamicContainer, __pyx_t_1) < 0) __PYX_ERR(0, 31, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":232 + /* "dependency_injector/containers.pyx":254 * * * class DeclarativeContainerMetaClass(type): # <<<<<<<<<<<<<< * """Declarative inversion of control container meta class.""" * */ - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 232, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __pyx_t_6 = PyTuple_New(1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 254, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(((PyObject *)(&PyType_Type))); __Pyx_GIVEREF(((PyObject *)(&PyType_Type))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)(&PyType_Type))); - __pyx_t_1 = __Pyx_CalculateMetaclass(NULL, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 232, __pyx_L1_error) + PyTuple_SET_ITEM(__pyx_t_6, 0, ((PyObject *)(&PyType_Type))); + __pyx_t_7 = __Pyx_CalculateMetaclass(NULL, __pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 254, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_1 = __Pyx_Py3MetaclassPrepare(__pyx_t_7, __pyx_t_6, __pyx_n_s_DeclarativeContainerMetaClass_2, __pyx_n_s_DeclarativeContainerMetaClass_2, (PyObject *) NULL, __pyx_n_s_dependency_injector_containers, __pyx_kp_s_Declarative_inversion_of_control); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 254, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_4 = __Pyx_Py3MetaclassPrepare(__pyx_t_1, __pyx_t_2, __pyx_n_s_DeclarativeContainerMetaClass_2, __pyx_n_s_DeclarativeContainerMetaClass_2, (PyObject *) NULL, __pyx_n_s_dependency_injector_containers, __pyx_kp_s_Declarative_inversion_of_control); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 232, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/containers.pyx":235 + /* "dependency_injector/containers.pyx":257 * """Declarative inversion of control container meta class.""" * * def __new__(type mcs, str class_name, tuple bases, dict attributes): # <<<<<<<<<<<<<< * """Declarative container class factory.""" * cdef tuple cls_providers */ - __pyx_t_5 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_29DeclarativeContainerMetaClass_1__new__, __Pyx_CYFUNCTION_STATICMETHOD, __pyx_n_s_DeclarativeContainerMetaClass_3, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__43)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 235, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); - if (__Pyx_SetNameInClass(__pyx_t_4, __pyx_n_s_new, __pyx_t_5) < 0) __PYX_ERR(0, 235, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_9 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_29DeclarativeContainerMetaClass_1__new__, __Pyx_CYFUNCTION_STATICMETHOD, __pyx_n_s_DeclarativeContainerMetaClass_3, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__45)); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 257, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_new, __pyx_t_9) < 0) __PYX_ERR(0, 257, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/containers.pyx":268 + /* "dependency_injector/containers.pyx":290 * return cls * * def __setattr__(cls, str name, object value): # <<<<<<<<<<<<<< * """Set class attribute. * */ - __pyx_t_5 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_29DeclarativeContainerMetaClass_3__setattr__, 0, __pyx_n_s_DeclarativeContainerMetaClass_4, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__45)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 268, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); - if (__Pyx_SetNameInClass(__pyx_t_4, __pyx_n_s_setattr, __pyx_t_5) < 0) __PYX_ERR(0, 268, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_9 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_29DeclarativeContainerMetaClass_3__setattr__, 0, __pyx_n_s_DeclarativeContainerMetaClass_4, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__47)); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 290, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_setattr, __pyx_t_9) < 0) __PYX_ERR(0, 290, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/containers.pyx":288 + /* "dependency_injector/containers.pyx":310 * super(DeclarativeContainerMetaClass, cls).__setattr__(name, value) * * def __delattr__(cls, str name): # <<<<<<<<<<<<<< * """Delete class attribute. * */ - __pyx_t_5 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_29DeclarativeContainerMetaClass_5__delattr__, 0, __pyx_n_s_DeclarativeContainerMetaClass_5, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__47)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 288, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); - if (__Pyx_SetNameInClass(__pyx_t_4, __pyx_n_s_delattr, __pyx_t_5) < 0) __PYX_ERR(0, 288, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_9 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_29DeclarativeContainerMetaClass_5__delattr__, 0, __pyx_n_s_DeclarativeContainerMetaClass_5, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__49)); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 310, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_delattr, __pyx_t_9) < 0) __PYX_ERR(0, 310, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/containers.pyx":232 + /* "dependency_injector/containers.pyx":254 * * * class DeclarativeContainerMetaClass(type): # <<<<<<<<<<<<<< * """Declarative inversion of control container meta class.""" * */ - __pyx_t_5 = __Pyx_Py3ClassCreate(__pyx_t_1, __pyx_n_s_DeclarativeContainerMetaClass_2, __pyx_t_2, __pyx_t_4, NULL, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 232, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_DeclarativeContainerMetaClass_2, __pyx_t_5) < 0) __PYX_ERR(0, 232, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_9 = __Pyx_Py3ClassCreate(__pyx_t_7, __pyx_n_s_DeclarativeContainerMetaClass_2, __pyx_t_6, __pyx_t_1, NULL, 0, 1); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 254, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_DeclarativeContainerMetaClass_2, __pyx_t_9) < 0) __PYX_ERR(0, 254, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":306 + /* "dependency_injector/containers.pyx":328 * * @six.add_metaclass(DeclarativeContainerMetaClass) * class DeclarativeContainer(object): # <<<<<<<<<<<<<< * """Declarative inversion of control container. * */ - __pyx_t_2 = __Pyx_CalculateMetaclass(NULL, __pyx_tuple__48); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 306, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_Py3MetaclassPrepare(__pyx_t_2, __pyx_tuple__48, __pyx_n_s_DeclarativeContainer, __pyx_n_s_DeclarativeContainer, (PyObject *) NULL, __pyx_n_s_dependency_injector_containers, __pyx_kp_s_Declarative_inversion_of_control_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 306, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_6 = __Pyx_CalculateMetaclass(NULL, __pyx_tuple__50); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 328, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_7 = __Pyx_Py3MetaclassPrepare(__pyx_t_6, __pyx_tuple__50, __pyx_n_s_DeclarativeContainer, __pyx_n_s_DeclarativeContainer, (PyObject *) NULL, __pyx_n_s_dependency_injector_containers, __pyx_kp_s_Declarative_inversion_of_control_2); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 328, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); - /* "dependency_injector/containers.pyx":317 + /* "dependency_injector/containers.pyx":339 * """ * * __IS_CONTAINER__ = True # <<<<<<<<<<<<<< * * provider_type = Provider */ - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_IS_CONTAINER, Py_True) < 0) __PYX_ERR(0, 317, __pyx_L1_error) + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_IS_CONTAINER, Py_True) < 0) __PYX_ERR(0, 339, __pyx_L1_error) - /* "dependency_injector/containers.pyx":319 + /* "dependency_injector/containers.pyx":341 * __IS_CONTAINER__ = True * * provider_type = Provider # <<<<<<<<<<<<<< * """Type of providers that could be placed in container. * */ - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_provider_type, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider)) < 0) __PYX_ERR(0, 319, __pyx_L1_error) + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_provider_type, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider)) < 0) __PYX_ERR(0, 341, __pyx_L1_error) - /* "dependency_injector/containers.pyx":325 + /* "dependency_injector/containers.pyx":347 * """ * * instance_type = DynamicContainer # <<<<<<<<<<<<<< * """Type of container that is returned on instantiating declarative * container. */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_DynamicContainer); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 325, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_instance_type, __pyx_t_4) < 0) __PYX_ERR(0, 325, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_DynamicContainer); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 347, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_instance_type, __pyx_t_1) < 0) __PYX_ERR(0, 347, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":332 + /* "dependency_injector/containers.pyx":354 * """ * * containers = dict() # <<<<<<<<<<<<<< * """Read-only dictionary of all nested containers. * */ - __pyx_t_4 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 332, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_containers, __pyx_t_4) < 0) __PYX_ERR(0, 332, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 354, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_containers, __pyx_t_1) < 0) __PYX_ERR(0, 354, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":338 + /* "dependency_injector/containers.pyx":360 * """ * * providers = dict() # <<<<<<<<<<<<<< * """Read-only dictionary of all providers. * */ - __pyx_t_4 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 338, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_providers, __pyx_t_4) < 0) __PYX_ERR(0, 338, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 360, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_providers, __pyx_t_1) < 0) __PYX_ERR(0, 360, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":344 + /* "dependency_injector/containers.pyx":366 * """ * * cls_providers = dict() # <<<<<<<<<<<<<< * """Read-only dictionary of current container providers. * */ - __pyx_t_4 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 344, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_cls_providers, __pyx_t_4) < 0) __PYX_ERR(0, 344, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 366, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_cls_providers, __pyx_t_1) < 0) __PYX_ERR(0, 366, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":350 + /* "dependency_injector/containers.pyx":372 * """ * * inherited_providers = dict() # <<<<<<<<<<<<<< * """Read-only dictionary of inherited providers. * */ - __pyx_t_4 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 350, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_inherited_providers, __pyx_t_4) < 0) __PYX_ERR(0, 350, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 372, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_inherited_providers, __pyx_t_1) < 0) __PYX_ERR(0, 372, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":356 + /* "dependency_injector/containers.pyx":378 * """ * * overridden = tuple() # <<<<<<<<<<<<<< * """Tuple of overriding containers. * */ - __pyx_t_4 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 356, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_overridden, __pyx_t_4) < 0) __PYX_ERR(0, 356, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 378, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_overridden, __pyx_t_1) < 0) __PYX_ERR(0, 378, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":362 + /* "dependency_injector/containers.pyx":384 * """ * * def __new__(cls, **overriding_providers): # <<<<<<<<<<<<<< * """Constructor. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_20DeclarativeContainer_1__new__, __Pyx_CYFUNCTION_STATICMETHOD, __pyx_n_s_DeclarativeContainer___new, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__50)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 362, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_new, __pyx_t_4) < 0) __PYX_ERR(0, 362, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_20DeclarativeContainer_1__new__, __Pyx_CYFUNCTION_STATICMETHOD, __pyx_n_s_DeclarativeContainer___new, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__52)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 384, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_new, __pyx_t_1) < 0) __PYX_ERR(0, 384, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":376 + /* "dependency_injector/containers.pyx":398 * * @classmethod * def override(cls, object overriding): # <<<<<<<<<<<<<< * """Override current container by overriding container. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_20DeclarativeContainer_3override, __Pyx_CYFUNCTION_CLASSMETHOD, __pyx_n_s_DeclarativeContainer_override, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__52)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 376, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_20DeclarativeContainer_3override, __Pyx_CYFUNCTION_CLASSMETHOD, __pyx_n_s_DeclarativeContainer_override, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__54)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 398, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/containers.pyx":375 + /* "dependency_injector/containers.pyx":397 * return container * * @classmethod # <<<<<<<<<<<<<< * def override(cls, object overriding): * """Override current container by overriding container. */ - __pyx_t_5 = __Pyx_Method_ClassMethod(__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 375, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_override, __pyx_t_5) < 0) __PYX_ERR(0, 376, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_9 = __Pyx_Method_ClassMethod(__pyx_t_1); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 397, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_override, __pyx_t_9) < 0) __PYX_ERR(0, 398, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/containers.pyx":400 + /* "dependency_injector/containers.pyx":422 * * @classmethod * def reset_last_overriding(cls): # <<<<<<<<<<<<<< * """Reset last overriding provider for each container providers. * */ - __pyx_t_5 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_20DeclarativeContainer_5reset_last_overriding, __Pyx_CYFUNCTION_CLASSMETHOD, __pyx_n_s_DeclarativeContainer_reset_last, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__54)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 400, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); + __pyx_t_9 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_20DeclarativeContainer_5reset_last_overriding, __Pyx_CYFUNCTION_CLASSMETHOD, __pyx_n_s_DeclarativeContainer_reset_last, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__56)); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 422, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); - /* "dependency_injector/containers.pyx":399 + /* "dependency_injector/containers.pyx":421 * pass * * @classmethod # <<<<<<<<<<<<<< * def reset_last_overriding(cls): * """Reset last overriding provider for each container providers. */ - __pyx_t_4 = __Pyx_Method_ClassMethod(__pyx_t_5); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 399, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_reset_last_overriding, __pyx_t_4) < 0) __PYX_ERR(0, 400, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_Method_ClassMethod(__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 421, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_reset_last_overriding, __pyx_t_1) < 0) __PYX_ERR(0, 422, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":414 + /* "dependency_injector/containers.pyx":436 * * @classmethod * def reset_override(cls): # <<<<<<<<<<<<<< * """Reset all overridings for each container providers. * */ - __pyx_t_4 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_20DeclarativeContainer_7reset_override, __Pyx_CYFUNCTION_CLASSMETHOD, __pyx_n_s_DeclarativeContainer_reset_overr, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__56)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 414, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_20DeclarativeContainer_7reset_override, __Pyx_CYFUNCTION_CLASSMETHOD, __pyx_n_s_DeclarativeContainer_reset_overr, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__58)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 436, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/containers.pyx":413 + /* "dependency_injector/containers.pyx":435 * provider.reset_last_overriding() * * @classmethod # <<<<<<<<<<<<<< * def reset_override(cls): * """Reset all overridings for each container providers. */ - __pyx_t_5 = __Pyx_Method_ClassMethod(__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 413, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_reset_override, __pyx_t_5) < 0) __PYX_ERR(0, 414, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_9 = __Pyx_Method_ClassMethod(__pyx_t_1); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 435, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_reset_override, __pyx_t_9) < 0) __PYX_ERR(0, 436, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/containers.pyx":425 + /* "dependency_injector/containers.pyx":447 * * @classmethod * def resolve_provider_name(cls, provider_to_resolve): # <<<<<<<<<<<<<< * """Try to resolve provider name by its instance.""" * for provider_name, container_provider in cls.providers.items(): */ - __pyx_t_5 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_20DeclarativeContainer_9resolve_provider_name, __Pyx_CYFUNCTION_CLASSMETHOD, __pyx_n_s_DeclarativeContainer_resolve_pro, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__58)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 425, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); + __pyx_t_9 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_10containers_20DeclarativeContainer_9resolve_provider_name, __Pyx_CYFUNCTION_CLASSMETHOD, __pyx_n_s_DeclarativeContainer_resolve_pro, NULL, __pyx_n_s_dependency_injector_containers, __pyx_d, ((PyObject *)__pyx_codeobj__60)); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 447, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); - /* "dependency_injector/containers.pyx":424 + /* "dependency_injector/containers.pyx":446 * provider.reset_override() * * @classmethod # <<<<<<<<<<<<<< * def resolve_provider_name(cls, provider_to_resolve): * """Try to resolve provider name by its instance.""" */ - __pyx_t_4 = __Pyx_Method_ClassMethod(__pyx_t_5); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 424, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_resolve_provider_name, __pyx_t_4) < 0) __PYX_ERR(0, 425, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_Method_ClassMethod(__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 446, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + if (__Pyx_SetNameInClass(__pyx_t_7, __pyx_n_s_resolve_provider_name, __pyx_t_1) < 0) __PYX_ERR(0, 447, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/containers.pyx":305 + /* "dependency_injector/containers.pyx":327 * * * @six.add_metaclass(DeclarativeContainerMetaClass) # <<<<<<<<<<<<<< * class DeclarativeContainer(object): * """Declarative inversion of control container. */ - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_six); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 305, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_add_metaclass); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 305, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_DeclarativeContainerMetaClass_2); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 305, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __Pyx_GetModuleGlobalName(__pyx_t_10, __pyx_n_s_six); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 327, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_10); + __pyx_t_11 = __Pyx_PyObject_GetAttrStr(__pyx_t_10, __pyx_n_s_add_metaclass); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 327, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_11); + __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; + __Pyx_GetModuleGlobalName(__pyx_t_10, __pyx_n_s_DeclarativeContainerMetaClass_2); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 327, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_10); + __pyx_t_12 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_11))) { + __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_11); + if (likely(__pyx_t_12)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_11); + __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_11, function); } } - __pyx_t_5 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 305, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_9 = (__pyx_t_12) ? __Pyx_PyObject_Call2Args(__pyx_t_11, __pyx_t_12, __pyx_t_10) : __Pyx_PyObject_CallOneArg(__pyx_t_11, __pyx_t_10); + __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; + __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; + if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 327, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; - /* "dependency_injector/containers.pyx":306 + /* "dependency_injector/containers.pyx":328 * * @six.add_metaclass(DeclarativeContainerMetaClass) * class DeclarativeContainer(object): # <<<<<<<<<<<<<< * """Declarative inversion of control container. * */ - __pyx_t_7 = __Pyx_Py3ClassCreate(__pyx_t_2, __pyx_n_s_DeclarativeContainer, __pyx_tuple__48, __pyx_t_1, NULL, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 306, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_7); - __pyx_t_6 = NULL; - if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { - __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5); - if (likely(__pyx_t_6)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); - __Pyx_INCREF(__pyx_t_6); + __pyx_t_11 = __Pyx_Py3ClassCreate(__pyx_t_6, __pyx_n_s_DeclarativeContainer, __pyx_tuple__50, __pyx_t_7, NULL, 0, 1); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 328, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_11); + __pyx_t_10 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_9))) { + __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_9); + if (likely(__pyx_t_10)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9); + __Pyx_INCREF(__pyx_t_10); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_5, function); + __Pyx_DECREF_SET(__pyx_t_9, function); } } - __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_7); - __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 305, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (PyDict_SetItem(__pyx_d, __pyx_n_s_DeclarativeContainer, __pyx_t_4) < 0) __PYX_ERR(0, 306, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = (__pyx_t_10) ? __Pyx_PyObject_Call2Args(__pyx_t_9, __pyx_t_10, __pyx_t_11) : __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_t_11); + __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; + __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 327, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + if (PyDict_SetItem(__pyx_d, __pyx_n_s_DeclarativeContainer, __pyx_t_1) < 0) __PYX_ERR(0, 328, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":434 + /* "dependency_injector/containers.pyx":456 * * * def override(object container): # <<<<<<<<<<<<<< * """:py:class:`DeclarativeContainer` overriding decorator. * */ - __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_10containers_5override, NULL, __pyx_n_s_dependency_injector_containers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 434, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_override, __pyx_t_2) < 0) __PYX_ERR(0, 434, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_6 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_10containers_5override, NULL, __pyx_n_s_dependency_injector_containers); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 456, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_override, __pyx_t_6) < 0) __PYX_ERR(0, 456, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/containers.pyx":451 + /* "dependency_injector/containers.pyx":473 * * * def copy(object container): # <<<<<<<<<<<<<< * """:py:class:`DeclarativeContainer` copying decorator. * */ - __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_10containers_7copy, NULL, __pyx_n_s_dependency_injector_containers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 451, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_copy, __pyx_t_2) < 0) __PYX_ERR(0, 451, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_6 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_10containers_7copy, NULL, __pyx_n_s_dependency_injector_containers); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 473, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_copy, __pyx_t_6) < 0) __PYX_ERR(0, 473, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; /* "dependency_injector/containers.pyx":1 * """Containers module.""" # <<<<<<<<<<<<<< * - * import sys + * import inspect */ - __pyx_t_2 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_2) < 0) __PYX_ERR(0, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_6 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_6) < 0) __PYX_ERR(0, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "providers.pxd":447 - * - * - * cdef inline object __factory_call(Factory self, tuple args, dict kwargs): # <<<<<<<<<<<<<< - * cdef object instance + /* "cfunc.to_py":64 * + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): # <<<<<<<<<<<<<< + * def wrap(object future): + * """wrap(future) -> 'void'""" */ /*--- Wrapped vars code ---*/ @@ -15053,12 +18701,12 @@ if (!__Pyx_RefNanny) { goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_2); - __Pyx_XDECREF(__pyx_t_4); - __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); - __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); + __Pyx_XDECREF(__pyx_t_10); + __Pyx_XDECREF(__pyx_t_11); + __Pyx_XDECREF(__pyx_t_12); if (__pyx_m) { if (__pyx_d) { __Pyx_AddTraceback("init dependency_injector.containers", __pyx_clineno, __pyx_lineno, __pyx_filename); @@ -16827,6 +20475,80 @@ static void __Pyx_WriteUnraisable(const char *name, CYTHON_UNUSED int clineno, #endif } +/* GetException */ +#if CYTHON_FAST_THREAD_STATE +static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) +#else +static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb) +#endif +{ + PyObject *local_type, *local_value, *local_tb; +#if CYTHON_FAST_THREAD_STATE + PyObject *tmp_type, *tmp_value, *tmp_tb; + local_type = tstate->curexc_type; + local_value = tstate->curexc_value; + local_tb = tstate->curexc_traceback; + tstate->curexc_type = 0; + tstate->curexc_value = 0; + tstate->curexc_traceback = 0; +#else + PyErr_Fetch(&local_type, &local_value, &local_tb); +#endif + PyErr_NormalizeException(&local_type, &local_value, &local_tb); +#if CYTHON_FAST_THREAD_STATE + if (unlikely(tstate->curexc_type)) +#else + if (unlikely(PyErr_Occurred())) +#endif + goto bad; + #if PY_MAJOR_VERSION >= 3 + if (local_tb) { + if (unlikely(PyException_SetTraceback(local_value, local_tb) < 0)) + goto bad; + } + #endif + Py_XINCREF(local_tb); + Py_XINCREF(local_type); + Py_XINCREF(local_value); + *type = local_type; + *value = local_value; + *tb = local_tb; +#if CYTHON_FAST_THREAD_STATE + #if CYTHON_USE_EXC_INFO_STACK + { + _PyErr_StackItem *exc_info = tstate->exc_info; + tmp_type = exc_info->exc_type; + tmp_value = exc_info->exc_value; + tmp_tb = exc_info->exc_traceback; + exc_info->exc_type = local_type; + exc_info->exc_value = local_value; + exc_info->exc_traceback = local_tb; + } + #else + tmp_type = tstate->exc_type; + tmp_value = tstate->exc_value; + tmp_tb = tstate->exc_traceback; + tstate->exc_type = local_type; + tstate->exc_value = local_value; + tstate->exc_traceback = local_tb; + #endif + Py_XDECREF(tmp_type); + Py_XDECREF(tmp_value); + Py_XDECREF(tmp_tb); +#else + PyErr_SetExcInfo(local_type, local_value, local_tb); +#endif + return 0; +bad: + *type = 0; + *value = 0; + *tb = 0; + Py_XDECREF(local_type); + Py_XDECREF(local_value); + Py_XDECREF(local_tb); + return -1; +} + /* UnpackUnboundCMethod */ static int __Pyx_TryUnpackUnboundCMethod(__Pyx_CachedCFunction* target) { PyObject *method; @@ -17027,6 +20749,24 @@ static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); } +/* HasAttr */ +static CYTHON_INLINE int __Pyx_HasAttr(PyObject *o, PyObject *n) { + PyObject *r; + if (unlikely(!__Pyx_PyBaseString_Check(n))) { + PyErr_SetString(PyExc_TypeError, + "hasattr(): attribute name must be string"); + return -1; + } + r = __Pyx_GetAttr(o, n); + if (unlikely(!r)) { + PyErr_Clear(); + return 0; + } else { + Py_DECREF(r); + return 1; + } +} + /* PyObject_GenericGetAttrNoDict */ #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000 static PyObject *__Pyx_RaiseGenericGetAttributeError(PyTypeObject *tp, PyObject *attr_name) { @@ -17213,6 +20953,154 @@ bad: return module; } +/* PatchModuleWithCoroutine */ +static PyObject* __Pyx_Coroutine_patch_module(PyObject* module, const char* py_code) { +#if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED) + int result; + PyObject *globals, *result_obj; + globals = PyDict_New(); if (unlikely(!globals)) goto ignore; + result = PyDict_SetItemString(globals, "_cython_coroutine_type", + #ifdef __Pyx_Coroutine_USED + (PyObject*)__pyx_CoroutineType); + #else + Py_None); + #endif + if (unlikely(result < 0)) goto ignore; + result = PyDict_SetItemString(globals, "_cython_generator_type", + #ifdef __Pyx_Generator_USED + (PyObject*)__pyx_GeneratorType); + #else + Py_None); + #endif + if (unlikely(result < 0)) goto ignore; + if (unlikely(PyDict_SetItemString(globals, "_module", module) < 0)) goto ignore; + if (unlikely(PyDict_SetItemString(globals, "__builtins__", __pyx_b) < 0)) goto ignore; + result_obj = PyRun_String(py_code, Py_file_input, globals, globals); + if (unlikely(!result_obj)) goto ignore; + Py_DECREF(result_obj); + Py_DECREF(globals); + return module; +ignore: + Py_XDECREF(globals); + PyErr_WriteUnraisable(module); + if (unlikely(PyErr_WarnEx(PyExc_RuntimeWarning, "Cython module failed to patch module with custom type", 1) < 0)) { + Py_DECREF(module); + module = NULL; + } +#else + py_code++; +#endif + return module; +} + +/* PatchInspect */ +static PyObject* __Pyx_patch_inspect(PyObject* module) { +#if defined(__Pyx_Generator_USED) && (!defined(CYTHON_PATCH_INSPECT) || CYTHON_PATCH_INSPECT) + static int inspect_patched = 0; + if (unlikely((!inspect_patched) && module)) { + module = __Pyx_Coroutine_patch_module( + module, "" +"old_types = getattr(_module.isgenerator, '_cython_generator_types', None)\n" +"if old_types is None or not isinstance(old_types, set):\n" +" old_types = set()\n" +" def cy_wrap(orig_func, type=type, cython_generator_types=old_types):\n" +" def cy_isgenerator(obj): return type(obj) in cython_generator_types or orig_func(obj)\n" +" cy_isgenerator._cython_generator_types = cython_generator_types\n" +" return cy_isgenerator\n" +" _module.isgenerator = cy_wrap(_module.isgenerator)\n" +"old_types.add(_cython_generator_type)\n" + ); + inspect_patched = 1; + } +#else + if ((0)) return __Pyx_Coroutine_patch_module(module, NULL); +#endif + return module; +} + +/* PatchAsyncIO */ +static PyObject* __Pyx_patch_asyncio(PyObject* module) { +#if PY_VERSION_HEX < 0x030500B2 &&\ + (defined(__Pyx_Coroutine_USED) || defined(__Pyx_Generator_USED)) &&\ + (!defined(CYTHON_PATCH_ASYNCIO) || CYTHON_PATCH_ASYNCIO) + PyObject *patch_module = NULL; + static int asyncio_patched = 0; + if (unlikely((!asyncio_patched) && module)) { + PyObject *package; + package = __Pyx_Import(__pyx_n_s_asyncio_coroutines, NULL, 0); + if (package) { + patch_module = __Pyx_Coroutine_patch_module( + PyObject_GetAttrString(package, "coroutines"), "" +"try:\n" +" coro_types = _module._COROUTINE_TYPES\n" +"except AttributeError: pass\n" +"else:\n" +" if _cython_coroutine_type is not None and _cython_coroutine_type not in coro_types:\n" +" coro_types = tuple(coro_types) + (_cython_coroutine_type,)\n" +" if _cython_generator_type is not None and _cython_generator_type not in coro_types:\n" +" coro_types = tuple(coro_types) + (_cython_generator_type,)\n" +"_module._COROUTINE_TYPES = coro_types\n" + ); + } else { + PyErr_Clear(); + package = __Pyx_Import(__pyx_n_s_asyncio_tasks, NULL, 0); + if (unlikely(!package)) goto asyncio_done; + patch_module = __Pyx_Coroutine_patch_module( + PyObject_GetAttrString(package, "tasks"), "" +"if hasattr(_module, 'iscoroutine'):\n" +" old_types = getattr(_module.iscoroutine, '_cython_coroutine_types', None)\n" +" if old_types is None or not isinstance(old_types, set):\n" +" old_types = set()\n" +" def cy_wrap(orig_func, type=type, cython_coroutine_types=old_types):\n" +" def cy_iscoroutine(obj): return type(obj) in cython_coroutine_types or orig_func(obj)\n" +" cy_iscoroutine._cython_coroutine_types = cython_coroutine_types\n" +" return cy_iscoroutine\n" +" _module.iscoroutine = cy_wrap(_module.iscoroutine)\n" +" if _cython_coroutine_type is not None:\n" +" old_types.add(_cython_coroutine_type)\n" +" if _cython_generator_type is not None:\n" +" old_types.add(_cython_generator_type)\n" + ); + } + Py_DECREF(package); + if (unlikely(!patch_module)) goto ignore; +asyncio_done: + PyErr_Clear(); + asyncio_patched = 1; +#ifdef __Pyx_Generator_USED + { + PyObject *inspect_module; + if (patch_module) { + inspect_module = PyObject_GetAttr(patch_module, __pyx_n_s_inspect); + Py_DECREF(patch_module); + } else { + inspect_module = __Pyx_Import(__pyx_n_s_inspect, NULL, 0); + } + if (unlikely(!inspect_module)) goto ignore; + inspect_module = __Pyx_patch_inspect(inspect_module); + if (unlikely(!inspect_module)) { + Py_DECREF(module); + module = NULL; + } + Py_XDECREF(inspect_module); + } +#else + if ((0)) return __Pyx_patch_inspect(module); +#endif + } + return module; +ignore: + PyErr_WriteUnraisable(module); + if (unlikely(PyErr_WarnEx(PyExc_RuntimeWarning, "Cython module failed to patch asyncio package with custom generator type", 1) < 0)) { + Py_DECREF(module); + module = NULL; + } +#else + if ((0)) return __Pyx_patch_inspect(__Pyx_Coroutine_patch_module(module, NULL)); +#endif + return module; +} + /* ImportFrom */ static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name) { PyObject* value = __Pyx_PyObject_GetAttrStr(module, name); @@ -19029,46 +22917,6 @@ static __pyx_CoroutineObject *__Pyx__Coroutine_NewInit( return gen; } -/* PatchModuleWithCoroutine */ -static PyObject* __Pyx_Coroutine_patch_module(PyObject* module, const char* py_code) { -#if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED) - int result; - PyObject *globals, *result_obj; - globals = PyDict_New(); if (unlikely(!globals)) goto ignore; - result = PyDict_SetItemString(globals, "_cython_coroutine_type", - #ifdef __Pyx_Coroutine_USED - (PyObject*)__pyx_CoroutineType); - #else - Py_None); - #endif - if (unlikely(result < 0)) goto ignore; - result = PyDict_SetItemString(globals, "_cython_generator_type", - #ifdef __Pyx_Generator_USED - (PyObject*)__pyx_GeneratorType); - #else - Py_None); - #endif - if (unlikely(result < 0)) goto ignore; - if (unlikely(PyDict_SetItemString(globals, "_module", module) < 0)) goto ignore; - if (unlikely(PyDict_SetItemString(globals, "__builtins__", __pyx_b) < 0)) goto ignore; - result_obj = PyRun_String(py_code, Py_file_input, globals, globals); - if (unlikely(!result_obj)) goto ignore; - Py_DECREF(result_obj); - Py_DECREF(globals); - return module; -ignore: - Py_XDECREF(globals); - PyErr_WriteUnraisable(module); - if (unlikely(PyErr_WarnEx(PyExc_RuntimeWarning, "Cython module failed to patch module with custom type", 1) < 0)) { - Py_DECREF(module); - module = NULL; - } -#else - py_code++; -#endif - return module; -} - /* PatchGeneratorABC */ #ifndef CYTHON_REGISTER_ABCS #define CYTHON_REGISTER_ABCS 1 diff --git a/src/dependency_injector/containers.pxd b/src/dependency_injector/containers.pxd index 4c818153..604d74ce 100644 --- a/src/dependency_injector/containers.pxd +++ b/src/dependency_injector/containers.pxd @@ -11,3 +11,6 @@ cpdef bint is_container(object instance) cpdef object _check_provider_type(object container, object provider) + + +cpdef bint _isawaitable(object instance) diff --git a/src/dependency_injector/containers.pyi b/src/dependency_injector/containers.pyi index 6ad24244..7ebba297 100644 --- a/src/dependency_injector/containers.pyi +++ b/src/dependency_injector/containers.pyi @@ -1,5 +1,17 @@ from types import ModuleType -from typing import Type, Dict, Tuple, Optional, Any, Union, ClassVar, Callable as _Callable, Iterable, TypeVar +from typing import ( + Type, + Dict, + Tuple, + Optional, + Any, + Union, + ClassVar, + Callable as _Callable, + Iterable, + TypeVar, + Awaitable, +) from .providers import Provider @@ -25,8 +37,8 @@ class Container: def resolve_provider_name(self, provider_to_resolve: Provider) -> Optional[str]: ... def wire(self, modules: Optional[Iterable[ModuleType]] = None, packages: Optional[Iterable[ModuleType]] = None) -> None: ... def unwire(self) -> None: ... - def init_resources(self) -> None: ... - def shutdown_resources(self) -> None: ... + def init_resources(self) -> Optional[Awaitable]: ... + def shutdown_resources(self) -> Optional[Awaitable]: ... class DynamicContainer(Container): ... diff --git a/src/dependency_injector/containers.pyx b/src/dependency_injector/containers.pyx index f3e90b8e..f91fa180 100644 --- a/src/dependency_injector/containers.pyx +++ b/src/dependency_injector/containers.pyx @@ -1,7 +1,13 @@ """Containers module.""" +import inspect import sys +try: + import asyncio +except ImportError: + asyncio = None + import six from .errors import Error @@ -216,17 +222,33 @@ class DynamicContainer(object): def init_resources(self): """Initialize all container resources.""" + futures = [] for provider in self.providers.values(): if not isinstance(provider, Resource): continue - provider.init() + + resource = provider.init() + + if _isawaitable(resource): + futures.append(resource) + + if futures: + return asyncio.gather(*futures) def shutdown_resources(self): """Shutdown all container resources.""" + futures = [] for provider in self.providers.values(): if not isinstance(provider, Resource): continue - provider.shutdown() + + shutdown = provider.shutdown() + + if _isawaitable(shutdown): + futures.append(shutdown) + + if futures: + return asyncio.gather(*futures) class DeclarativeContainerMetaClass(type): @@ -494,3 +516,10 @@ cpdef object _check_provider_type(object container, object provider): if not isinstance(provider, container.provider_type): raise Error('{0} can contain only {1} ' 'instances'.format(container, container.provider_type)) + + +cpdef bint _isawaitable(object instance): + try: + return inspect.isawaitable(instance) + except AttributeError: + return False diff --git a/src/dependency_injector/providers.c b/src/dependency_injector/providers.c index 6de5b139..2e79e892 100644 --- a/src/dependency_injector/providers.c +++ b/src/dependency_injector/providers.c @@ -867,9 +867,10 @@ struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct___get_self_ struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct_1_genexpr; struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct_2___str__; struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct_3_genexpr; +struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py; struct __pyx_opt_args_19dependency_injector_9providers_deepcopy; -/* "dependency_injector/providers.pxd":293 +/* "dependency_injector/providers.pxd":299 * * * cpdef object deepcopy(object instance, dict memo=*) # <<<<<<<<<<<<<< @@ -881,7 +882,7 @@ struct __pyx_opt_args_19dependency_injector_9providers_deepcopy { PyObject *memo; }; -/* "dependency_injector/providers.pxd":7 +/* "dependency_injector/providers.pxd":14 * * # Base providers * cdef class Provider(object): # <<<<<<<<<<<<<< @@ -893,10 +894,11 @@ struct __pyx_obj_19dependency_injector_9providers_Provider { struct __pyx_vtabstruct_19dependency_injector_9providers_Provider *__pyx_vtab; PyObject *__pyx___overridden; struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx___last_overriding; + int __pyx___async_mode; }; -/* "dependency_injector/providers.pxd":15 +/* "dependency_injector/providers.pxd":23 * * * cdef class Object(Provider): # <<<<<<<<<<<<<< @@ -909,7 +911,7 @@ struct __pyx_obj_19dependency_injector_9providers_Object { }; -/* "dependency_injector/providers.pxd":21 +/* "dependency_injector/providers.pxd":29 * * * cdef class Delegate(Provider): # <<<<<<<<<<<<<< @@ -922,7 +924,7 @@ struct __pyx_obj_19dependency_injector_9providers_Delegate { }; -/* "dependency_injector/providers.pxd":27 +/* "dependency_injector/providers.pxd":35 * * * cdef class Dependency(Provider): # <<<<<<<<<<<<<< @@ -935,7 +937,7 @@ struct __pyx_obj_19dependency_injector_9providers_Dependency { }; -/* "dependency_injector/providers.pxd":31 +/* "dependency_injector/providers.pxd":39 * * * cdef class ExternalDependency(Dependency): # <<<<<<<<<<<<<< @@ -947,7 +949,7 @@ struct __pyx_obj_19dependency_injector_9providers_ExternalDependency { }; -/* "dependency_injector/providers.pxd":35 +/* "dependency_injector/providers.pxd":43 * * * cdef class DependenciesContainer(Object): # <<<<<<<<<<<<<< @@ -960,7 +962,7 @@ struct __pyx_obj_19dependency_injector_9providers_DependenciesContainer { }; -/* "dependency_injector/providers.pxd":41 +/* "dependency_injector/providers.pxd":49 * * * cdef class OverridingContext(object): # <<<<<<<<<<<<<< @@ -974,7 +976,7 @@ struct __pyx_obj_19dependency_injector_9providers_OverridingContext { }; -/* "dependency_injector/providers.pxd":47 +/* "dependency_injector/providers.pxd":55 * * # Callable providers * cdef class Callable(Provider): # <<<<<<<<<<<<<< @@ -991,7 +993,7 @@ struct __pyx_obj_19dependency_injector_9providers_Callable { }; -/* "dependency_injector/providers.pxd":59 +/* "dependency_injector/providers.pxd":67 * * * cdef class DelegatedCallable(Callable): # <<<<<<<<<<<<<< @@ -1003,7 +1005,7 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedCallable { }; -/* "dependency_injector/providers.pxd":63 +/* "dependency_injector/providers.pxd":71 * * * cdef class AbstractCallable(Callable): # <<<<<<<<<<<<<< @@ -1015,7 +1017,7 @@ struct __pyx_obj_19dependency_injector_9providers_AbstractCallable { }; -/* "dependency_injector/providers.pxd":67 +/* "dependency_injector/providers.pxd":75 * * * cdef class CallableDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1027,7 +1029,7 @@ struct __pyx_obj_19dependency_injector_9providers_CallableDelegate { }; -/* "dependency_injector/providers.pxd":72 +/* "dependency_injector/providers.pxd":80 * * # Coroutine providers * cdef class Coroutine(Callable): # <<<<<<<<<<<<<< @@ -1039,7 +1041,7 @@ struct __pyx_obj_19dependency_injector_9providers_Coroutine { }; -/* "dependency_injector/providers.pxd":76 +/* "dependency_injector/providers.pxd":84 * * * cdef class DelegatedCoroutine(Coroutine): # <<<<<<<<<<<<<< @@ -1051,7 +1053,7 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedCoroutine { }; -/* "dependency_injector/providers.pxd":80 +/* "dependency_injector/providers.pxd":88 * * * cdef class AbstractCoroutine(Coroutine): # <<<<<<<<<<<<<< @@ -1063,7 +1065,7 @@ struct __pyx_obj_19dependency_injector_9providers_AbstractCoroutine { }; -/* "dependency_injector/providers.pxd":84 +/* "dependency_injector/providers.pxd":92 * * * cdef class CoroutineDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1075,7 +1077,7 @@ struct __pyx_obj_19dependency_injector_9providers_CoroutineDelegate { }; -/* "dependency_injector/providers.pxd":89 +/* "dependency_injector/providers.pxd":97 * * # Configuration providers * cdef class ConfigurationOption(Provider): # <<<<<<<<<<<<<< @@ -1091,7 +1093,7 @@ struct __pyx_obj_19dependency_injector_9providers_ConfigurationOption { }; -/* "dependency_injector/providers.pxd":96 +/* "dependency_injector/providers.pxd":104 * * * cdef class TypedConfigurationOption(Callable): # <<<<<<<<<<<<<< @@ -1103,7 +1105,7 @@ struct __pyx_obj_19dependency_injector_9providers_TypedConfigurationOption { }; -/* "dependency_injector/providers.pxd":100 +/* "dependency_injector/providers.pxd":108 * * * cdef class Configuration(Object): # <<<<<<<<<<<<<< @@ -1118,7 +1120,7 @@ struct __pyx_obj_19dependency_injector_9providers_Configuration { }; -/* "dependency_injector/providers.pxd":107 +/* "dependency_injector/providers.pxd":115 * * # Factory providers * cdef class Factory(Provider): # <<<<<<<<<<<<<< @@ -1133,7 +1135,7 @@ struct __pyx_obj_19dependency_injector_9providers_Factory { }; -/* "dependency_injector/providers.pxd":116 +/* "dependency_injector/providers.pxd":124 * * * cdef class DelegatedFactory(Factory): # <<<<<<<<<<<<<< @@ -1145,7 +1147,7 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedFactory { }; -/* "dependency_injector/providers.pxd":120 +/* "dependency_injector/providers.pxd":128 * * * cdef class AbstractFactory(Factory): # <<<<<<<<<<<<<< @@ -1157,7 +1159,7 @@ struct __pyx_obj_19dependency_injector_9providers_AbstractFactory { }; -/* "dependency_injector/providers.pxd":124 +/* "dependency_injector/providers.pxd":132 * * * cdef class FactoryDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1169,7 +1171,7 @@ struct __pyx_obj_19dependency_injector_9providers_FactoryDelegate { }; -/* "dependency_injector/providers.pxd":128 +/* "dependency_injector/providers.pxd":136 * * * cdef class FactoryAggregate(Provider): # <<<<<<<<<<<<<< @@ -1182,33 +1184,33 @@ struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate { }; -/* "dependency_injector/providers.pxd":135 +/* "dependency_injector/providers.pxd":143 * * # Singleton providers * cdef class BaseSingleton(Provider): # <<<<<<<<<<<<<< * cdef Factory __instantiator - * + * cdef object __storage */ struct __pyx_obj_19dependency_injector_9providers_BaseSingleton { struct __pyx_obj_19dependency_injector_9providers_Provider __pyx_base; struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx___instantiator; -}; - - -/* "dependency_injector/providers.pxd":139 - * - * - * cdef class Singleton(BaseSingleton): # <<<<<<<<<<<<<< - * cdef object __storage - * - */ -struct __pyx_obj_19dependency_injector_9providers_Singleton { - struct __pyx_obj_19dependency_injector_9providers_BaseSingleton __pyx_base; PyObject *__pyx___storage; }; -/* "dependency_injector/providers.pxd":145 +/* "dependency_injector/providers.pxd":148 + * + * + * cdef class Singleton(BaseSingleton): # <<<<<<<<<<<<<< + * + * cpdef object _provide(self, tuple args, dict kwargs) + */ +struct __pyx_obj_19dependency_injector_9providers_Singleton { + struct __pyx_obj_19dependency_injector_9providers_BaseSingleton __pyx_base; +}; + + +/* "dependency_injector/providers.pxd":153 * * * cdef class DelegatedSingleton(Singleton): # <<<<<<<<<<<<<< @@ -1220,21 +1222,20 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedSingleton { }; -/* "dependency_injector/providers.pxd":149 +/* "dependency_injector/providers.pxd":157 * * * cdef class ThreadSafeSingleton(BaseSingleton): # <<<<<<<<<<<<<< - * cdef object __storage * cdef object __storage_lock + * */ struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton { struct __pyx_obj_19dependency_injector_9providers_BaseSingleton __pyx_base; - PyObject *__pyx___storage; PyObject *__pyx___storage_lock; }; -/* "dependency_injector/providers.pxd":156 +/* "dependency_injector/providers.pxd":163 * * * cdef class DelegatedThreadSafeSingleton(ThreadSafeSingleton): # <<<<<<<<<<<<<< @@ -1246,20 +1247,19 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadSafeSingleton { }; -/* "dependency_injector/providers.pxd":160 +/* "dependency_injector/providers.pxd":167 * * * cdef class ThreadLocalSingleton(BaseSingleton): # <<<<<<<<<<<<<< - * cdef object __storage * + * cpdef object _provide(self, tuple args, dict kwargs) */ struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton { struct __pyx_obj_19dependency_injector_9providers_BaseSingleton __pyx_base; - PyObject *__pyx___storage; }; -/* "dependency_injector/providers.pxd":166 +/* "dependency_injector/providers.pxd":172 * * * cdef class DelegatedThreadLocalSingleton(ThreadLocalSingleton): # <<<<<<<<<<<<<< @@ -1271,7 +1271,7 @@ struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadLocalSingleton }; -/* "dependency_injector/providers.pxd":170 +/* "dependency_injector/providers.pxd":176 * * * cdef class AbstractSingleton(BaseSingleton): # <<<<<<<<<<<<<< @@ -1283,7 +1283,7 @@ struct __pyx_obj_19dependency_injector_9providers_AbstractSingleton { }; -/* "dependency_injector/providers.pxd":174 +/* "dependency_injector/providers.pxd":180 * * * cdef class SingletonDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1295,7 +1295,7 @@ struct __pyx_obj_19dependency_injector_9providers_SingletonDelegate { }; -/* "dependency_injector/providers.pxd":180 +/* "dependency_injector/providers.pxd":186 * # Miscellaneous providers * * cdef class List(Provider): # <<<<<<<<<<<<<< @@ -1309,7 +1309,7 @@ struct __pyx_obj_19dependency_injector_9providers_List { }; -/* "dependency_injector/providers.pxd":187 +/* "dependency_injector/providers.pxd":193 * * * cdef class Dict(Provider): # <<<<<<<<<<<<<< @@ -1323,7 +1323,7 @@ struct __pyx_obj_19dependency_injector_9providers_Dict { }; -/* "dependency_injector/providers.pxd":194 +/* "dependency_injector/providers.pxd":200 * * * cdef class Resource(Provider): # <<<<<<<<<<<<<< @@ -1343,7 +1343,7 @@ struct __pyx_obj_19dependency_injector_9providers_Resource { }; -/* "dependency_injector/providers.pxd":209 +/* "dependency_injector/providers.pxd":215 * * * cdef class Container(Provider): # <<<<<<<<<<<<<< @@ -1358,7 +1358,7 @@ struct __pyx_obj_19dependency_injector_9providers_Container { }; -/* "dependency_injector/providers.pxd":217 +/* "dependency_injector/providers.pxd":223 * * * cdef class Selector(Provider): # <<<<<<<<<<<<<< @@ -1372,7 +1372,7 @@ struct __pyx_obj_19dependency_injector_9providers_Selector { }; -/* "dependency_injector/providers.pxd":225 +/* "dependency_injector/providers.pxd":231 * # Provided instance * * cdef class ProvidedInstance(Provider): # <<<<<<<<<<<<<< @@ -1385,7 +1385,7 @@ struct __pyx_obj_19dependency_injector_9providers_ProvidedInstance { }; -/* "dependency_injector/providers.pxd":231 +/* "dependency_injector/providers.pxd":237 * * * cdef class AttributeGetter(Provider): # <<<<<<<<<<<<<< @@ -1399,7 +1399,7 @@ struct __pyx_obj_19dependency_injector_9providers_AttributeGetter { }; -/* "dependency_injector/providers.pxd":238 +/* "dependency_injector/providers.pxd":244 * * * cdef class ItemGetter(Provider): # <<<<<<<<<<<<<< @@ -1413,7 +1413,7 @@ struct __pyx_obj_19dependency_injector_9providers_ItemGetter { }; -/* "dependency_injector/providers.pxd":245 +/* "dependency_injector/providers.pxd":251 * * * cdef class MethodCaller(Provider): # <<<<<<<<<<<<<< @@ -1430,7 +1430,7 @@ struct __pyx_obj_19dependency_injector_9providers_MethodCaller { }; -/* "dependency_injector/providers.pxd":256 +/* "dependency_injector/providers.pxd":262 * * # Injections * cdef class Injection(object): # <<<<<<<<<<<<<< @@ -1446,7 +1446,7 @@ struct __pyx_obj_19dependency_injector_9providers_Injection { }; -/* "dependency_injector/providers.pxd":263 +/* "dependency_injector/providers.pxd":269 * * * cdef class PositionalInjection(Injection): # <<<<<<<<<<<<<< @@ -1458,7 +1458,7 @@ struct __pyx_obj_19dependency_injector_9providers_PositionalInjection { }; -/* "dependency_injector/providers.pxd":267 +/* "dependency_injector/providers.pxd":273 * * * cdef class NamedInjection(Injection): # <<<<<<<<<<<<<< @@ -1471,7 +1471,7 @@ struct __pyx_obj_19dependency_injector_9providers_NamedInjection { }; -/* "dependency_injector/providers.pyx":1139 +/* "dependency_injector/providers.pyx":1239 * return value * * def _get_self_name(self): # <<<<<<<<<<<<<< @@ -1484,7 +1484,7 @@ struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct___get_self_ }; -/* "dependency_injector/providers.pyx":1141 +/* "dependency_injector/providers.pyx":1241 * def _get_self_name(self): * return '.'.join( * segment() if is_provider(segment) else segment for segment in self.__name # <<<<<<<<<<<<<< @@ -1500,7 +1500,7 @@ struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct_1_genexpr { }; -/* "dependency_injector/providers.pyx":2892 +/* "dependency_injector/providers.pyx":3148 * return self.__providers[name] * * def __str__(self): # <<<<<<<<<<<<<< @@ -1513,7 +1513,7 @@ struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct_2___str__ { }; -/* "dependency_injector/providers.pyx":2902 +/* "dependency_injector/providers.pyx":3158 * selector=self.__selector, * providers=', '.join(( * '{0}={1}'.format(name, provider) # <<<<<<<<<<<<<< @@ -1531,8 +1531,21 @@ struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct_3_genexpr { }; +/* "cfunc.to_py":64 + * + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): # <<<<<<<<<<<<<< + * def wrap(object future): + * """wrap(future) -> 'void'""" + */ +struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py { + PyObject_HEAD + void (*__pyx_v_f)(PyObject *); +}; -/* "dependency_injector/providers.pyx":91 + + +/* "dependency_injector/providers.pyx":97 * * * cdef class Provider(object): # <<<<<<<<<<<<<< @@ -1547,7 +1560,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Provider { static struct __pyx_vtabstruct_19dependency_injector_9providers_Provider *__pyx_vtabptr_19dependency_injector_9providers_Provider; -/* "dependency_injector/providers.pyx":297 +/* "dependency_injector/providers.pyx":364 * * * cdef class Object(Provider): # <<<<<<<<<<<<<< @@ -1561,7 +1574,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Object { static struct __pyx_vtabstruct_19dependency_injector_9providers_Object *__pyx_vtabptr_19dependency_injector_9providers_Object; -/* "dependency_injector/providers.pyx":356 +/* "dependency_injector/providers.pyx":423 * * * cdef class Delegate(Provider): # <<<<<<<<<<<<<< @@ -1575,7 +1588,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Delegate { static struct __pyx_vtabstruct_19dependency_injector_9providers_Delegate *__pyx_vtabptr_19dependency_injector_9providers_Delegate; -/* "dependency_injector/providers.pyx":420 +/* "dependency_injector/providers.pyx":487 * * * cdef class Dependency(Provider): # <<<<<<<<<<<<<< @@ -1589,7 +1602,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Dependency { static struct __pyx_vtabstruct_19dependency_injector_9providers_Dependency *__pyx_vtabptr_19dependency_injector_9providers_Dependency; -/* "dependency_injector/providers.pyx":518 +/* "dependency_injector/providers.pyx":618 * * * cdef class ExternalDependency(Dependency): # <<<<<<<<<<<<<< @@ -1603,7 +1616,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ExternalDependency { static struct __pyx_vtabstruct_19dependency_injector_9providers_ExternalDependency *__pyx_vtabptr_19dependency_injector_9providers_ExternalDependency; -/* "dependency_injector/providers.pyx":546 +/* "dependency_injector/providers.pyx":646 * * * cdef class DependenciesContainer(Object): # <<<<<<<<<<<<<< @@ -1618,7 +1631,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DependenciesContainer { static struct __pyx_vtabstruct_19dependency_injector_9providers_DependenciesContainer *__pyx_vtabptr_19dependency_injector_9providers_DependenciesContainer; -/* "dependency_injector/providers.pyx":715 +/* "dependency_injector/providers.pyx":815 * * * cdef class Callable(Provider): # <<<<<<<<<<<<<< @@ -1632,7 +1645,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Callable { static struct __pyx_vtabstruct_19dependency_injector_9providers_Callable *__pyx_vtabptr_19dependency_injector_9providers_Callable; -/* "dependency_injector/providers.pyx":881 +/* "dependency_injector/providers.pyx":981 * * * cdef class DelegatedCallable(Callable): # <<<<<<<<<<<<<< @@ -1646,7 +1659,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCallable { static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCallable *__pyx_vtabptr_19dependency_injector_9providers_DelegatedCallable; -/* "dependency_injector/providers.pyx":890 +/* "dependency_injector/providers.pyx":990 * * * cdef class AbstractCallable(Callable): # <<<<<<<<<<<<<< @@ -1660,7 +1673,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCallable { static struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCallable *__pyx_vtabptr_19dependency_injector_9providers_AbstractCallable; -/* "dependency_injector/providers.pyx":931 +/* "dependency_injector/providers.pyx":1031 * * * cdef class CallableDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1674,7 +1687,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_CallableDelegate { static struct __pyx_vtabstruct_19dependency_injector_9providers_CallableDelegate *__pyx_vtabptr_19dependency_injector_9providers_CallableDelegate; -/* "dependency_injector/providers.pyx":953 +/* "dependency_injector/providers.pyx":1053 * * * cdef class Coroutine(Callable): # <<<<<<<<<<<<<< @@ -1688,7 +1701,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Coroutine { static struct __pyx_vtabstruct_19dependency_injector_9providers_Coroutine *__pyx_vtabptr_19dependency_injector_9providers_Coroutine; -/* "dependency_injector/providers.pyx":997 +/* "dependency_injector/providers.pyx":1097 * * * cdef class DelegatedCoroutine(Coroutine): # <<<<<<<<<<<<<< @@ -1702,7 +1715,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCoroutine { static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedCoroutine *__pyx_vtabptr_19dependency_injector_9providers_DelegatedCoroutine; -/* "dependency_injector/providers.pyx":1006 +/* "dependency_injector/providers.pyx":1106 * * * cdef class AbstractCoroutine(Coroutine): # <<<<<<<<<<<<<< @@ -1716,7 +1729,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCoroutine { static struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractCoroutine *__pyx_vtabptr_19dependency_injector_9providers_AbstractCoroutine; -/* "dependency_injector/providers.pyx":1047 +/* "dependency_injector/providers.pyx":1147 * * * cdef class CoroutineDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1730,7 +1743,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_CoroutineDelegate { static struct __pyx_vtabstruct_19dependency_injector_9providers_CoroutineDelegate *__pyx_vtabptr_19dependency_injector_9providers_CoroutineDelegate; -/* "dependency_injector/providers.pyx":1069 +/* "dependency_injector/providers.pyx":1169 * * * cdef class ConfigurationOption(Provider): # <<<<<<<<<<<<<< @@ -1744,7 +1757,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ConfigurationOption { static struct __pyx_vtabstruct_19dependency_injector_9providers_ConfigurationOption *__pyx_vtabptr_19dependency_injector_9providers_ConfigurationOption; -/* "dependency_injector/providers.pyx":1274 +/* "dependency_injector/providers.pyx":1374 * * * cdef class TypedConfigurationOption(Callable): # <<<<<<<<<<<<<< @@ -1758,7 +1771,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_TypedConfigurationOptio static struct __pyx_vtabstruct_19dependency_injector_9providers_TypedConfigurationOption *__pyx_vtabptr_19dependency_injector_9providers_TypedConfigurationOption; -/* "dependency_injector/providers.pyx":1281 +/* "dependency_injector/providers.pyx":1381 * * * cdef class Configuration(Object): # <<<<<<<<<<<<<< @@ -1772,7 +1785,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Configuration { static struct __pyx_vtabstruct_19dependency_injector_9providers_Configuration *__pyx_vtabptr_19dependency_injector_9providers_Configuration; -/* "dependency_injector/providers.pyx":1537 +/* "dependency_injector/providers.pyx":1637 * * * cdef class Factory(Provider): # <<<<<<<<<<<<<< @@ -1786,7 +1799,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Factory { static struct __pyx_vtabstruct_19dependency_injector_9providers_Factory *__pyx_vtabptr_19dependency_injector_9providers_Factory; -/* "dependency_injector/providers.pyx":1754 +/* "dependency_injector/providers.pyx":1854 * * * cdef class DelegatedFactory(Factory): # <<<<<<<<<<<<<< @@ -1800,7 +1813,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedFactory { static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedFactory *__pyx_vtabptr_19dependency_injector_9providers_DelegatedFactory; -/* "dependency_injector/providers.pyx":1776 +/* "dependency_injector/providers.pyx":1876 * * * cdef class AbstractFactory(Factory): # <<<<<<<<<<<<<< @@ -1814,7 +1827,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractFactory { static struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractFactory *__pyx_vtabptr_19dependency_injector_9providers_AbstractFactory; -/* "dependency_injector/providers.pyx":1817 +/* "dependency_injector/providers.pyx":1917 * * * cdef class FactoryDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1828,7 +1841,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryDelegate { static struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryDelegate *__pyx_vtabptr_19dependency_injector_9providers_FactoryDelegate; -/* "dependency_injector/providers.pyx":1839 +/* "dependency_injector/providers.pyx":1939 * * * cdef class FactoryAggregate(Provider): # <<<<<<<<<<<<<< @@ -1843,7 +1856,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate { static struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate *__pyx_vtabptr_19dependency_injector_9providers_FactoryAggregate; -/* "dependency_injector/providers.pyx":1926 +/* "dependency_injector/providers.pyx":2032 * * * cdef class BaseSingleton(Provider): # <<<<<<<<<<<<<< @@ -1857,7 +1870,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_BaseSingleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_BaseSingleton *__pyx_vtabptr_19dependency_injector_9providers_BaseSingleton; -/* "dependency_injector/providers.pyx":2079 +/* "dependency_injector/providers.pyx":2195 * * * cdef class Singleton(BaseSingleton): # <<<<<<<<<<<<<< @@ -1871,7 +1884,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Singleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_Singleton *__pyx_vtabptr_19dependency_injector_9providers_Singleton; -/* "dependency_injector/providers.pyx":2135 +/* "dependency_injector/providers.pyx":2262 * * * cdef class DelegatedSingleton(Singleton): # <<<<<<<<<<<<<< @@ -1885,7 +1898,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedSingleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedSingleton *__pyx_vtabptr_19dependency_injector_9providers_DelegatedSingleton; -/* "dependency_injector/providers.pyx":2157 +/* "dependency_injector/providers.pyx":2284 * * * cdef class ThreadSafeSingleton(BaseSingleton): # <<<<<<<<<<<<<< @@ -1899,7 +1912,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadSafeSingleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadSafeSingleton *__pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton; -/* "dependency_injector/providers.pyx":2196 +/* "dependency_injector/providers.pyx":2335 * * * cdef class DelegatedThreadSafeSingleton(ThreadSafeSingleton): # <<<<<<<<<<<<<< @@ -1913,7 +1926,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadSafeSing static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadSafeSingleton *__pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadSafeSingleton; -/* "dependency_injector/providers.pyx":2218 +/* "dependency_injector/providers.pyx":2357 * * * cdef class ThreadLocalSingleton(BaseSingleton): # <<<<<<<<<<<<<< @@ -1927,7 +1940,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadLocalSingleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton; -/* "dependency_injector/providers.pyx":2266 +/* "dependency_injector/providers.pyx":2425 * * * cdef class DelegatedThreadLocalSingleton(ThreadLocalSingleton): # <<<<<<<<<<<<<< @@ -1941,7 +1954,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadLocalSin static struct __pyx_vtabstruct_19dependency_injector_9providers_DelegatedThreadLocalSingleton *__pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadLocalSingleton; -/* "dependency_injector/providers.pyx":2288 +/* "dependency_injector/providers.pyx":2447 * * * cdef class AbstractSingleton(BaseSingleton): # <<<<<<<<<<<<<< @@ -1955,7 +1968,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractSingleton { static struct __pyx_vtabstruct_19dependency_injector_9providers_AbstractSingleton *__pyx_vtabptr_19dependency_injector_9providers_AbstractSingleton; -/* "dependency_injector/providers.pyx":2333 +/* "dependency_injector/providers.pyx":2492 * * * cdef class SingletonDelegate(Delegate): # <<<<<<<<<<<<<< @@ -1969,7 +1982,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_SingletonDelegate { static struct __pyx_vtabstruct_19dependency_injector_9providers_SingletonDelegate *__pyx_vtabptr_19dependency_injector_9providers_SingletonDelegate; -/* "dependency_injector/providers.pyx":2355 +/* "dependency_injector/providers.pyx":2514 * * * cdef class List(Provider): # <<<<<<<<<<<<<< @@ -1983,7 +1996,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_List { static struct __pyx_vtabstruct_19dependency_injector_9providers_List *__pyx_vtabptr_19dependency_injector_9providers_List; -/* "dependency_injector/providers.pyx":2457 +/* "dependency_injector/providers.pyx":2616 * * * cdef class Dict(Provider): # <<<<<<<<<<<<<< @@ -1997,7 +2010,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Dict { static struct __pyx_vtabstruct_19dependency_injector_9providers_Dict *__pyx_vtabptr_19dependency_injector_9providers_Dict; -/* "dependency_injector/providers.pyx":2569 +/* "dependency_injector/providers.pyx":2728 * * * cdef class Resource(Provider): # <<<<<<<<<<<<<< @@ -2011,7 +2024,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Resource { static struct __pyx_vtabstruct_19dependency_injector_9providers_Resource *__pyx_vtabptr_19dependency_injector_9providers_Resource; -/* "dependency_injector/providers.pyx":2774 +/* "dependency_injector/providers.pyx":3030 * * * cdef class Container(Provider): # <<<<<<<<<<<<<< @@ -2025,7 +2038,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Container { static struct __pyx_vtabstruct_19dependency_injector_9providers_Container *__pyx_vtabptr_19dependency_injector_9providers_Container; -/* "dependency_injector/providers.pyx":2829 +/* "dependency_injector/providers.pyx":3085 * * * cdef class Selector(Provider): # <<<<<<<<<<<<<< @@ -2039,7 +2052,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_Selector { static struct __pyx_vtabstruct_19dependency_injector_9providers_Selector *__pyx_vtabptr_19dependency_injector_9providers_Selector; -/* "dependency_injector/providers.pyx":2926 +/* "dependency_injector/providers.pyx":3182 * * * cdef class ProvidedInstance(Provider): # <<<<<<<<<<<<<< @@ -2053,7 +2066,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ProvidedInstance { static struct __pyx_vtabstruct_19dependency_injector_9providers_ProvidedInstance *__pyx_vtabptr_19dependency_injector_9providers_ProvidedInstance; -/* "dependency_injector/providers.pyx":2993 +/* "dependency_injector/providers.pyx":3249 * * * cdef class AttributeGetter(Provider): # <<<<<<<<<<<<<< @@ -2067,7 +2080,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_AttributeGetter { static struct __pyx_vtabstruct_19dependency_injector_9providers_AttributeGetter *__pyx_vtabptr_19dependency_injector_9providers_AttributeGetter; -/* "dependency_injector/providers.pyx":3043 +/* "dependency_injector/providers.pyx":3309 * * * cdef class ItemGetter(Provider): # <<<<<<<<<<<<<< @@ -2081,7 +2094,7 @@ struct __pyx_vtabstruct_19dependency_injector_9providers_ItemGetter { static struct __pyx_vtabstruct_19dependency_injector_9providers_ItemGetter *__pyx_vtabptr_19dependency_injector_9providers_ItemGetter; -/* "dependency_injector/providers.pyx":3093 +/* "dependency_injector/providers.pyx":3369 * * * cdef class MethodCaller(Provider): # <<<<<<<<<<<<<< @@ -2436,6 +2449,19 @@ static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *, PyObject *); /* GetAttr3.proto */ static CYTHON_INLINE PyObject *__Pyx_GetAttr3(PyObject *, PyObject *, PyObject *); +/* FastTypeChecks.proto */ +#if CYTHON_COMPILING_IN_CPYTHON +#define __Pyx_TypeCheck(obj, type) __Pyx_IsSubtype(Py_TYPE(obj), (PyTypeObject *)type) +static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b); +static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject *type); +static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *type1, PyObject *type2); +#else +#define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type) +#define __Pyx_PyErr_GivenExceptionMatches(err, type) PyErr_GivenExceptionMatches(err, type) +#define __Pyx_PyErr_GivenExceptionMatches2(err, type1, type2) (PyErr_GivenExceptionMatches(err, type1) || PyErr_GivenExceptionMatches(err, type2)) +#endif +#define __Pyx_PyException_Check(obj) __Pyx_TypeCheck(obj, PyExc_Exception) + /* dict_getitem_default.proto */ static PyObject* __Pyx_PyDict_GetItemDefault(PyObject* d, PyObject* key, PyObject* default_value); @@ -2487,19 +2513,6 @@ static PyObject* __Pyx__CallUnboundCMethod0(__Pyx_CachedCFunction* cfunc, PyObje #define __Pyx_CallUnboundCMethod0(cfunc, self) __Pyx__CallUnboundCMethod0(cfunc, self) #endif -/* FastTypeChecks.proto */ -#if CYTHON_COMPILING_IN_CPYTHON -#define __Pyx_TypeCheck(obj, type) __Pyx_IsSubtype(Py_TYPE(obj), (PyTypeObject *)type) -static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b); -static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject *type); -static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *type1, PyObject *type2); -#else -#define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type) -#define __Pyx_PyErr_GivenExceptionMatches(err, type) PyErr_GivenExceptionMatches(err, type) -#define __Pyx_PyErr_GivenExceptionMatches2(err, type1, type2) (PyErr_GivenExceptionMatches(err, type1) || PyErr_GivenExceptionMatches(err, type2)) -#endif -#define __Pyx_PyException_Check(obj) __Pyx_TypeCheck(obj, PyExc_Exception) - /* RaiseTooManyValuesToUnpack.proto */ static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected); @@ -2586,6 +2599,9 @@ static PyObject* __Pyx__PyList_PopIndex(PyObject* L, PyObject* py_ix, Py_ssize_t __Pyx__PyObject_PopIndex(L, py_ix)) #endif +/* py_dict_pop.proto */ +static CYTHON_INLINE PyObject *__Pyx_PyDict_Pop(PyObject *d, PyObject *key, PyObject *default_value); + /* PyDictContains.proto */ static CYTHON_INLINE int __Pyx_PyDict_ContainsTF(PyObject* item, PyObject* dict, int eq) { int result = PyDict_Contains(dict, item); @@ -2657,6 +2673,11 @@ static PyObject* __Pyx_PyUnicode_Join(PyObject* value_tuple, Py_ssize_t value_co #define __Pyx_PyIter_Next(obj) __Pyx_PyIter_Next2(obj, NULL) static CYTHON_INLINE PyObject *__Pyx_PyIter_Next2(PyObject *, PyObject *); +/* StopAsyncIteration.proto */ +#define __Pyx_StopAsyncIteration_USED +static PyObject *__Pyx_PyExc_StopAsyncIteration; +static int __pyx_StopAsyncIteration_init(void); + /* Import.proto */ static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level); @@ -2712,41 +2733,23 @@ static CYTHON_INLINE int __Pyx_PyList_Extend(PyObject* L, PyObject* v) { /* RaiseNoneIterError.proto */ static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void); -/* PyObject_GenericGetAttrNoDict.proto */ -#if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000 -static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name); +/* ListCompAppend.proto */ +#if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS +static CYTHON_INLINE int __Pyx_ListComp_Append(PyObject* list, PyObject* x) { + PyListObject* L = (PyListObject*) list; + Py_ssize_t len = Py_SIZE(list); + if (likely(L->allocated > len)) { + Py_INCREF(x); + PyList_SET_ITEM(list, len, x); + __Pyx_SET_SIZE(list, len + 1); + return 0; + } + return PyList_Append(list, x); +} #else -#define __Pyx_PyObject_GenericGetAttrNoDict PyObject_GenericGetAttr +#define __Pyx_ListComp_Append(L,x) PyList_Append(L,x) #endif -/* PyObject_GenericGetAttr.proto */ -#if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000 -static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name); -#else -#define __Pyx_PyObject_GenericGetAttr PyObject_GenericGetAttr -#endif - -/* SetVTable.proto */ -static int __Pyx_SetVtable(PyObject *dict, void *vtable); - -/* PyObjectGetAttrStrNoError.proto */ -static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStrNoError(PyObject* obj, PyObject* attr_name); - -/* SetupReduce.proto */ -static int __Pyx_setup_reduce(PyObject* type_obj); - -/* PatchModuleWithCoroutine.proto */ -static PyObject* __Pyx_Coroutine_patch_module(PyObject* module, const char* py_code); - -/* PatchInspect.proto */ -static PyObject* __Pyx_patch_inspect(PyObject* module); - -/* PatchAsyncIO.proto */ -static PyObject* __Pyx_patch_asyncio(PyObject* module); - -/* PyIntCompare.proto */ -static CYTHON_INLINE PyObject* __Pyx_PyInt_EqObjC(PyObject *op1, PyObject *op2, long intval, long inplace); - /* FetchCommonType.proto */ static PyTypeObject* __Pyx_FetchCommonType(PyTypeObject* type); @@ -2810,6 +2813,41 @@ static PyObject *__Pyx_CyFunction_New(PyMethodDef *ml, PyObject *module, PyObject *globals, PyObject* code); +/* PyObject_GenericGetAttrNoDict.proto */ +#if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000 +static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name); +#else +#define __Pyx_PyObject_GenericGetAttrNoDict PyObject_GenericGetAttr +#endif + +/* PyObject_GenericGetAttr.proto */ +#if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000 +static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name); +#else +#define __Pyx_PyObject_GenericGetAttr PyObject_GenericGetAttr +#endif + +/* SetVTable.proto */ +static int __Pyx_SetVtable(PyObject *dict, void *vtable); + +/* PyObjectGetAttrStrNoError.proto */ +static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStrNoError(PyObject* obj, PyObject* attr_name); + +/* SetupReduce.proto */ +static int __Pyx_setup_reduce(PyObject* type_obj); + +/* PatchModuleWithCoroutine.proto */ +static PyObject* __Pyx_Coroutine_patch_module(PyObject* module, const char* py_code); + +/* PatchInspect.proto */ +static PyObject* __Pyx_patch_inspect(PyObject* module); + +/* PatchAsyncIO.proto */ +static PyObject* __Pyx_patch_asyncio(PyObject* module); + +/* PyIntCompare.proto */ +static CYTHON_INLINE PyObject* __Pyx_PyInt_EqObjC(PyObject *op1, PyObject *op2, long intval, long inplace); + /* CalculateMetaclass.proto */ static PyObject *__Pyx_CalculateMetaclass(PyTypeObject *metaclass, PyObject *bases); @@ -2974,6 +3012,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_17AbstractCoroutine__p static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption__provide(struct __pyx_obj_19dependency_injector_9providers_ConfigurationOption *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_args, CYTHON_UNUSED PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch); /* proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_7Factory__provide(struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch); /* proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_15AbstractFactory__provide(CYTHON_UNUSED struct __pyx_obj_19dependency_injector_9providers_AbstractFactory *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_args, CYTHON_UNUSED PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch); /* proto*/ +static PyObject *__pyx_f_19dependency_injector_9providers_16FactoryAggregate__provide(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch); /* proto*/ static struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_f_19dependency_injector_9providers_16FactoryAggregate___get_factory(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_factory_name); /* proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_9Singleton__provide(struct __pyx_obj_19dependency_injector_9providers_Singleton *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch); /* proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton__provide(struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch); /* proto*/ @@ -3039,7 +3078,12 @@ static PyTypeObject *__pyx_ptype_19dependency_injector_9providers___pyx_scope_st static PyTypeObject *__pyx_ptype_19dependency_injector_9providers___pyx_scope_struct_1_genexpr = 0; static PyTypeObject *__pyx_ptype_19dependency_injector_9providers___pyx_scope_struct_2___str__ = 0; static PyTypeObject *__pyx_ptype_19dependency_injector_9providers___pyx_scope_struct_3_genexpr = 0; +static PyTypeObject *__pyx_ptype___pyx_scope_struct____Pyx_CFunc_void____object___to_py = 0; static PyObject *__pyx_v_19dependency_injector_9providers_CLASS_TYPES = 0; +static int __pyx_v_19dependency_injector_9providers___has_isawaitable; +static int __pyx_v_19dependency_injector_9providers_ASYNC_MODE_UNDEFINED; +static int __pyx_v_19dependency_injector_9providers_ASYNC_MODE_ENABLED; +static int __pyx_v_19dependency_injector_9providers_ASYNC_MODE_DISABLED; static PyObject *__pyx_f_19dependency_injector_9providers_parse_positional_injections(PyObject *, int __pyx_skip_dispatch); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections(PyObject *, int __pyx_skip_dispatch); /*proto*/ static int __pyx_f_19dependency_injector_9providers_is_provider(PyObject *, int __pyx_skip_dispatch); /*proto*/ @@ -3053,10 +3097,17 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separate_prefixed_kwargs(PyObject *); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provide_positional_args(PyObject *, PyObject *, int); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provide_keyword_args(PyObject *, PyObject *, int); /*proto*/ -static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___inject_attributes(PyObject *, PyObject *, int); /*proto*/ +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___awaitable_args_kwargs_future(PyObject *, PyObject *); /*proto*/ +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_prepare_args_kwargs_callback(PyObject *); /*proto*/ +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provide_attributes(PyObject *, int); /*proto*/ +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___async_inject_attributes(PyObject *, PyObject *); /*proto*/ +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_inject_attributes_callback(PyObject *); /*proto*/ +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___inject_attributes(PyObject *, PyObject *); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___call(PyObject *, PyObject *, PyObject *, int, PyObject *, PyObject *, int); /*proto*/ +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_call_callback(PyObject *); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callable_call(struct __pyx_obj_19dependency_injector_9providers_Callable *, PyObject *, PyObject *); /*proto*/ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___factory_call(struct __pyx_obj_19dependency_injector_9providers_Factory *, PyObject *, PyObject *); /*proto*/ +static CYTHON_INLINE int __pyx_f_19dependency_injector_9providers___isawaitable(PyObject *); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provider__set_state(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object__set_state(struct __pyx_obj_19dependency_injector_9providers_Object *, PyObject *); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegate__set_state(struct __pyx_obj_19dependency_injector_9providers_Delegate *, PyObject *); /*proto*/ @@ -3101,13 +3152,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Injection__set_state(struct __pyx_obj_19dependency_injector_9providers_Injection *, PyObject *); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_PositionalInjection__set_state(struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *, PyObject *); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_NamedInjection__set_state(struct __pyx_obj_19dependency_injector_9providers_NamedInjection *, PyObject *); /*proto*/ +static PyObject *__Pyx_CFunc_void____object___to_py(void (*)(PyObject *)); /*proto*/ #define __Pyx_MODULE_NAME "dependency_injector.providers" extern int __pyx_module_is_main_dependency_injector__providers; int __pyx_module_is_main_dependency_injector__providers = 0; /* Implementation of 'dependency_injector.providers' */ -static PyObject *__pyx_builtin_range; static PyObject *__pyx_builtin_ImportError; +static PyObject *__pyx_builtin_range; +static PyObject *__pyx_builtin_zip; static PyObject *__pyx_builtin_object; static PyObject *__pyx_builtin_staticmethod; static PyObject *__pyx_builtin_super; @@ -3119,22 +3172,23 @@ static PyObject *__pyx_builtin_DeprecationWarning; static PyObject *__pyx_builtin_NotImplementedError; static PyObject *__pyx_builtin_TypeError; static PyObject *__pyx_builtin_AttributeError; +static PyObject *__pyx_builtin_KeyError; static PyObject *__pyx_builtin_StopIteration; static PyObject *__pyx_builtin_hex; static const char __pyx_k_[] = "_"; static const char __pyx_k__4[] = "__"; static const char __pyx_k__5[] = "."; -static const char __pyx_k__8[] = "("; -static const char __pyx_k__9[] = ")"; +static const char __pyx_k__9[] = "("; static const char __pyx_k_id[] = "id"; static const char __pyx_k_os[] = "os"; static const char __pyx_k_re[] = "re"; static const char __pyx_k_0_1[] = "{0}={1}"; -static const char __pyx_k__11[] = ""; -static const char __pyx_k__12[] = ", "; -static const char __pyx_k__13[] = "('"; -static const char __pyx_k__14[] = "')"; -static const char __pyx_k__16[] = "\\$\\{([^}^{]+)\\}"; +static const char __pyx_k__10[] = ")"; +static const char __pyx_k__12[] = ""; +static const char __pyx_k__13[] = ", "; +static const char __pyx_k__14[] = "('"; +static const char __pyx_k__15[] = "')"; +static const char __pyx_k__19[] = "\\$\\{([^}^{]+)\\}"; static const char __pyx_k_cls[] = "cls"; static const char __pyx_k_doc[] = "__doc__"; static const char __pyx_k_get[] = "get"; @@ -3147,6 +3201,7 @@ static const char __pyx_k_ref[] = "ref"; static const char __pyx_k_set[] = "set"; static const char __pyx_k_str[] = "__str__"; static const char __pyx_k_sys[] = "sys"; +static const char __pyx_k_zip[] = "zip"; static const char __pyx_k_Dict[] = "Dict"; static const char __pyx_k_List[] = "List"; static const char __pyx_k_True[] = "True"; @@ -3171,10 +3226,13 @@ static const char __pyx_k_self[] = "self"; static const char __pyx_k_send[] = "send"; static const char __pyx_k_test[] = "__test__"; static const char __pyx_k_warn[] = "warn"; +static const char __pyx_k_wrap[] = "wrap"; static const char __pyx_k_yaml[] = "yaml"; static const char __pyx_k_Error[] = "Error"; static const char __pyx_k_False[] = "False"; static const char __pyx_k_RLock[] = "RLock"; +static const char __pyx_k_anext[] = "__anext__"; +static const char __pyx_k_asend[] = "asend"; static const char __pyx_k_class[] = "__class__"; static const char __pyx_k_close[] = "close"; static const char __pyx_k_dict1[] = "dict1"; @@ -3191,13 +3249,17 @@ static const char __pyx_k_super[] = "super"; static const char __pyx_k_throw[] = "throw"; static const char __pyx_k_types[] = "types"; static const char __pyx_k_value[] = "value"; +static const char __pyx_k_Future[] = "Future"; static const char __pyx_k_Loader[] = "Loader"; static const char __pyx_k_Object[] = "Object"; +static const char __pyx_k_cancel[] = "cancel"; static const char __pyx_k_config[] = "config"; static const char __pyx_k_copied[] = "copied"; static const char __pyx_k_dict_2[] = "dict_"; static const char __pyx_k_errors[] = "errors"; static const char __pyx_k_format[] = "format"; +static const char __pyx_k_future[] = "future"; +static const char __pyx_k_gather[] = "gather"; static const char __pyx_k_getenv[] = "getenv"; static const char __pyx_k_import[] = "__import__"; static const char __pyx_k_init_2[] = "init"; @@ -3228,12 +3290,14 @@ static const char __pyx_k_genexpr[] = "genexpr"; static const char __pyx_k_im_func[] = "im_func"; static const char __pyx_k_im_self[] = "im_self"; static const char __pyx_k_inspect[] = "inspect"; +static const char __pyx_k_partial[] = "partial"; static const char __pyx_k_prepare[] = "__prepare__"; static const char __pyx_k_provide[] = "_provide"; static const char __pyx_k_section[] = "section"; static const char __pyx_k_weakref[] = "weakref"; static const char __pyx_k_Callable[] = "Callable"; static const char __pyx_k_Delegate[] = "Delegate"; +static const char __pyx_k_KeyError[] = "KeyError"; static const char __pyx_k_Provider[] = "Provider"; static const char __pyx_k_Resource[] = "Resource"; static const char __pyx_k_Selector[] = "Selector"; @@ -3273,6 +3337,7 @@ static const char __pyx_k_attribute[] = "attribute"; static const char __pyx_k_container[] = "container"; static const char __pyx_k_coroutine[] = "coroutine"; static const char __pyx_k_factories[] = "factories"; +static const char __pyx_k_functools[] = "functools"; static const char __pyx_k_metaclass[] = "__metaclass__"; static const char __pyx_k_providers[] = "providers"; static const char __pyx_k_pyx_state[] = "__pyx_state"; @@ -3295,16 +3360,19 @@ static const char __pyx_k_overriding[] = "overriding"; static const char __pyx_k_pyx_result[] = "__pyx_result"; static const char __pyx_k_pyx_vtable[] = "__pyx_vtable__"; static const char __pyx_k_set_kwargs[] = "set_kwargs"; +static const char __pyx_k_set_result[] = "set_result"; +static const char __pyx_k_shutdowner[] = "shutdowner"; static const char __pyx_k_startswith[] = "startswith"; -static const char __pyx_k_0_is_not_an[] = "{0} is not an "; static const char __pyx_k_CLASS_TYPES[] = "CLASS_TYPES"; static const char __pyx_k_IS_PROVIDER[] = "__IS_PROVIDER__"; static const char __pyx_k_ImportError[] = "ImportError"; static const char __pyx_k_PickleError[] = "PickleError"; +static const char __pyx_k_cfunc_to_py[] = "cfunc.to_py"; static const char __pyx_k_config_file[] = "config_file"; static const char __pyx_k_initialized[] = ", initialized="; static const char __pyx_k_initializer[] = "initializer"; static const char __pyx_k_instance_of[] = "instance_of"; +static const char __pyx_k_isawaitable[] = "isawaitable"; static const char __pyx_k_merge_dicts[] = "merge_dicts"; static const char __pyx_k_reset_cache[] = "reset_cache"; static const char __pyx_k_ConfigParser[] = "ConfigParser"; @@ -3320,18 +3388,22 @@ static const char __pyx_k_staticmethod[] = "staticmethod"; static const char __pyx_k_storage_lock[] = "storage_lock"; static const char __pyx_k_stringsource[] = "stringsource"; static const char __pyx_k_version_info[] = "version_info"; +static const char __pyx_k_AsyncResource[] = "AsyncResource"; static const char __pyx_k_BaseSingleton[] = "BaseSingleton"; static const char __pyx_k_Configuration[] = "Configuration"; static const char __pyx_k_StopIteration[] = "StopIteration"; +static const char __pyx_k_async_provide[] = "_async_provide"; static const char __pyx_k_asyncio_tasks[] = "asyncio.tasks"; static const char __pyx_k_class_getitem[] = "__class_getitem__"; static const char __pyx_k_config_string[] = "config_string"; static const char __pyx_k_container_cls[] = "container_cls"; +static const char __pyx_k_ensure_future[] = "ensure_future"; +static const char __pyx_k_future_result[] = "future_result"; static const char __pyx_k_get_self_name[] = "_get_self_name"; -static const char __pyx_k_instance_of_0[] = "instance of {0}"; static const char __pyx_k_interpolation[] = "interpolation"; static const char __pyx_k_provided_type[] = "provided_type"; static const char __pyx_k_reduce_cython[] = "__reduce_cython__"; +static const char __pyx_k_set_exception[] = "set_exception"; static const char __pyx_k_AttributeError[] = "AttributeError"; static const char __pyx_k_NamedInjection[] = "NamedInjection"; static const char __pyx_k_add_attributes[] = "add_attributes"; @@ -3344,6 +3416,7 @@ static const char __pyx_k_AttributeGetter[] = "AttributeGetter"; static const char __pyx_k_FactoryDelegate[] = "FactoryDelegate"; static const char __pyx_k_add_constructor[] = "add_constructor"; static const char __pyx_k_add_sys_streams[] = "__add_sys_streams"; +static const char __pyx_k_has_isawaitable[] = "__has_isawaitable"; static const char __pyx_k_iniconfigparser[] = "iniconfigparser"; static const char __pyx_k_last_overriding[] = "last_overriding"; static const char __pyx_k_overriding_lock[] = "overriding_lock"; @@ -3364,7 +3437,9 @@ static const char __pyx_k_CoroutineDelegate[] = "CoroutineDelegate"; static const char __pyx_k_DelegatedCallable[] = "DelegatedCallable"; static const char __pyx_k_OverridingContext[] = "OverridingContext"; static const char __pyx_k_SingletonDelegate[] = "SingletonDelegate"; +static const char __pyx_k_add_done_callback[] = "add_done_callback"; static const char __pyx_k_deepcopy_dispatch[] = "_deepcopy_dispatch"; +static const char __pyx_k_enable_async_mode[] = "enable_async_mode"; static const char __pyx_k_pyx_unpickle_Dict[] = "__pyx_unpickle_Dict"; static const char __pyx_k_pyx_unpickle_List[] = "__pyx_unpickle_List"; static const char __pyx_k_BasicInterpolation[] = "BasicInterpolation"; @@ -3374,12 +3449,18 @@ static const char __pyx_k_DeprecationWarning[] = "DeprecationWarning"; static const char __pyx_k_ExternalDependency[] = "ExternalDependency"; static const char __pyx_k_asyncio_coroutines[] = "asyncio.coroutines"; static const char __pyx_k_cline_in_traceback[] = "cline_in_traceback"; +static const char __pyx_k_create_init_future[] = "_create_init_future"; +static const char __pyx_k_disable_async_mode[] = "disable_async_mode"; +static const char __pyx_k_isasyncgenfunction[] = "isasyncgenfunction"; static const char __pyx_k_override_providers[] = "_override_providers"; static const char __pyx_k_ConfigurationOption[] = "ConfigurationOption"; static const char __pyx_k_NoSuchProviderError[] = "NoSuchProviderError"; static const char __pyx_k_NotImplementedError[] = "NotImplementedError"; static const char __pyx_k_PositionalInjection[] = "PositionalInjection"; static const char __pyx_k_ThreadSafeSingleton[] = "ThreadSafeSingleton"; +static const char __pyx_k_async_init_callback[] = "_async_init_callback"; +static const char __pyx_k_async_init_instance[] = "_async_init_instance"; +static const char __pyx_k_check_instance_type[] = "_check_instance_type"; static const char __pyx_k_is_coroutine_marker[] = "_is_coroutine_marker"; static const char __pyx_k_iscoroutinefunction[] = "iscoroutinefunction"; static const char __pyx_k_isgeneratorfunction[] = "isgeneratorfunction"; @@ -3391,23 +3472,30 @@ static const char __pyx_k_pyx_unpickle_Factory[] = "__pyx_unpickle_Factory"; static const char __pyx_k_str___locals_genexpr[] = "__str__..genexpr"; static const char __pyx_k_DependenciesContainer[] = "DependenciesContainer"; static const char __pyx_k_add_implicit_resolver[] = "add_implicit_resolver"; +static const char __pyx_k_is_async_mode_enabled[] = "is_async_mode_enabled"; static const char __pyx_k_pyx_unpickle_Callable[] = "__pyx_unpickle_Callable"; static const char __pyx_k_pyx_unpickle_Delegate[] = "__pyx_unpickle_Delegate"; static const char __pyx_k_pyx_unpickle_Provider[] = "__pyx_unpickle_Provider"; static const char __pyx_k_pyx_unpickle_Resource[] = "__pyx_unpickle_Resource"; static const char __pyx_k_pyx_unpickle_Selector[] = "__pyx_unpickle_Selector"; static const char __pyx_k_reset_last_overriding[] = "reset_last_overriding"; +static const char __pyx_k_create_shutdown_future[] = "_create_shutdown_future"; +static const char __pyx_k_is_async_mode_disabled[] = "is_async_mode_disabled"; static const char __pyx_k_pyx_unpickle_Container[] = "__pyx_unpickle_Container"; static const char __pyx_k_pyx_unpickle_Coroutine[] = "__pyx_unpickle_Coroutine"; static const char __pyx_k_pyx_unpickle_Injection[] = "__pyx_unpickle_Injection"; static const char __pyx_k_pyx_unpickle_Singleton[] = "__pyx_unpickle_Singleton"; +static const char __pyx_k_async_shutdown_callback[] = "_async_shutdown_callback"; +static const char __pyx_k_is_async_mode_undefined[] = "is_async_mode_undefined"; static const char __pyx_k_pyx_unpickle_Dependency[] = "__pyx_unpickle_Dependency"; static const char __pyx_k_pyx_unpickle_ItemGetter[] = "__pyx_unpickle_ItemGetter"; static const char __pyx_k_yaml_env_marker_pattern[] = "yaml_env_marker_pattern"; static const char __pyx_k_TypedConfigurationOption[] = "TypedConfigurationOption"; +static const char __pyx_k_0_is_not_an_instance_of_1[] = "{0} is not an instance of {1}"; static const char __pyx_k_Dependency_is_not_defined[] = "Dependency is not defined"; static const char __pyx_k_pyx_unpickle_MethodCaller[] = "__pyx_unpickle_MethodCaller"; static const char __pyx_k_Selector_has_no_0_provider[] = "Selector has no \"{0}\" provider"; +static const char __pyx_k_is_async_resource_subclass[] = "_is_async_resource_subclass"; static const char __pyx_k_pyx_unpickle_BaseSingleton[] = "__pyx_unpickle_BaseSingleton"; static const char __pyx_k_pyx_unpickle_Configuration[] = "__pyx_unpickle_Configuration"; static const char __pyx_k_0_can_wrap_only_1_providers[] = "{0} can wrap only {1} providers"; @@ -3423,6 +3511,7 @@ static const char __pyx_k_pyx_unpickle_AbstractFactory[] = "__pyx_unpickle_Abstr static const char __pyx_k_pyx_unpickle_AttributeGetter[] = "__pyx_unpickle_AttributeGetter"; static const char __pyx_k_pyx_unpickle_FactoryDelegate[] = "__pyx_unpickle_FactoryDelegate"; static const char __pyx_k_DelegatedThreadLocalSingleton[] = "DelegatedThreadLocalSingleton"; +static const char __pyx_k_Pyx_CFunc_void____object___to[] = "__Pyx_CFunc_void____object___to_py..wrap"; static const char __pyx_k_dependency_injector_providers[] = "dependency_injector.providers"; static const char __pyx_k_pyx_unpickle_AbstractCallable[] = "__pyx_unpickle_AbstractCallable"; static const char __pyx_k_pyx_unpickle_CallableDelegate[] = "__pyx_unpickle_CallableDelegate"; @@ -3460,28 +3549,30 @@ static const char __pyx_k_Can_not_copy_initialized_resourc[] = "Can not copy ini static const char __pyx_k_Configuration_option_can_only_be[] = "Configuration option can only be overridden by a value"; static const char __pyx_k_Configuration_option_does_not_su[] = "Configuration option does not support this method"; static const char __pyx_k_Expected_provider_instance_got_0[] = "Expected provider instance, got {0}"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x03[] = "Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x04[] = "Incompatible checksums (%s vs 0x0433d08 = (__container, __container_cls, __last_overriding, __overridden, __overriding_providers))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x0c[] = "Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x0d[] = "Incompatible checksums (%s vs 0x0d07ffc = (__last_overriding, __overridden, __provider))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x0f[] = "Incompatible checksums (%s vs 0x0f5c5dd = (__last_overriding, __overridden))"; +static const char __pyx_k_Factory_missing_1_required_posit[] = "Factory missing 1 required positional argument: 'factory_name'"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x1b[] = "Incompatible checksums (%s vs 0x1bd47ec = (__async_mode, __container, __container_cls, __last_overriding, __overridden, __overriding_providers))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x1c[] = "Incompatible checksums (%s vs 0x1cf9f6d = (__async_mode, __last_overriding, __overridden, __providers, __provides))"; static const char __pyx_k_Incompatible_checksums_s_vs_0x20[] = "Incompatible checksums (%s vs 0x2071b6b = (__overridden, __overriding))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x2a[] = "Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))"; static const char __pyx_k_Incompatible_checksums_s_vs_0x2e[] = "Incompatible checksums (%s vs 0x2e1d18f = (__call, __is_delegated, __is_provider, __value))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x3f[] = "Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x57[] = "Incompatible checksums (%s vs 0x570b822 = (__last_overriding, __overridden, __providers, __selector))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x58[] = "Incompatible checksums (%s vs 0x5818eae = (__item, __last_overriding, __overridden, __provider))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x63[] = "Incompatible checksums (%s vs 0x631cff7 = (__args, __args_len, __last_overriding, __overridden))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x32[] = "Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x34[] = "Incompatible checksums (%s vs 0x3460d23 = (__async_mode, __children, __last_overriding, __name, __overridden, __provides))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x3e[] = "Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x42[] = "Incompatible checksums (%s vs 0x42b6146 = (__args, __args_len, __async_mode, __last_overriding, __overridden))"; static const char __pyx_k_Incompatible_checksums_s_vs_0x64[] = "Incompatible checksums (%s vs 0x64f395f = (__call, __is_delegated, __is_provider, __name, __value))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x76[] = "Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x97[] = "Incompatible checksums (%s vs 0x97c970c = (__kwargs, __kwargs_len, __last_overriding, __overridden))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0xa5[] = "Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0xa6[] = "Incompatible checksums (%s vs 0xa6696fd = (__factories, __last_overriding, __overridden))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0xa7[] = "Incompatible checksums (%s vs 0xa7663cf = (__children, __last_overriding, __name, __overridden, __provides))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0xb2[] = "Incompatible checksums (%s vs 0xb205ea7 = (__cache, __children, __last_overriding, __name, __overridden, __root_ref))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0xd8[] = "Incompatible checksums (%s vs 0xd8553c7 = (__last_overriding, __overridden, __providers, __provides))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0xe0[] = "Incompatible checksums (%s vs 0xe01ff48 = (__attribute, __last_overriding, __overridden, __provider))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0xe8[] = "Incompatible checksums (%s vs 0xe8b92e4 = (__args, __args_len, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0xf1[] = "Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x66[] = "Incompatible checksums (%s vs 0x66bc620 = (__async_mode, __cache, __children, __last_overriding, __name, __overridden, __root_ref))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x6a[] = "Incompatible checksums (%s vs 0x6a94d6b = (__async_mode, __last_overriding, __overridden, __providers, __selector))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x73[] = "Incompatible checksums (%s vs 0x734cfcb = (__args, __args_len, __async_mode, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x75[] = "Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0x7e[] = "Incompatible checksums (%s vs 0x7ec84e3 = (__async_mode, __attribute, __last_overriding, __overridden, __provider))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0xa0[] = "Incompatible checksums (%s vs 0xa0575be = (__async_mode, __item, __last_overriding, __overridden, __provider))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0xa2[] = "Incompatible checksums (%s vs 0xa264cf2 = (__async_mode, __factories, __last_overriding, __overridden))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0xce[] = "Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0xd5[] = "Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0xe5[] = "Incompatible checksums (%s vs 0xe57552f = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0xfd[] = "Incompatible checksums (%s vs 0xfd61095 = (__async_mode, __last_overriding, __overridden, __provider))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0xfe[] = "Incompatible checksums (%s vs 0xfeb8198 = (__async_mode, __last_overriding, __overridden))"; +static const char __pyx_k_Incompatible_checksums_s_vs_0xff[] = "Incompatible checksums (%s vs 0xff73c9f = (__async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden))"; static const char __pyx_k_Interpolation_which_expands_envi[] = "Interpolation which expands environment variables in values."; static const char __pyx_k_Method_delegate_is_deprecated_si[] = "Method \".delegate()\" is deprecated since version 4.0.0. Use \".provider\" attribute instead."; static const char __pyx_k_Package_asyncio_is_not_available[] = "Package asyncio is not available"; @@ -3492,15 +3583,13 @@ static const char __pyx_k_Provider_0_expected_to_get_corou[] = "Provider {0} exp static const char __pyx_k_Unable_to_load_yaml_configuratio[] = "Unable to load yaml configuration - PyYAML is not installed. Install PyYAML or install Dependency Injector with yaml extras: \"pip install dependency-injector[yaml]\""; static const char __pyx_k_Unknown_type_of_resource_initial[] = "Unknown type of resource initializer"; static const char __pyx_k_src_dependency_injector_provider[] = "src/dependency_injector/providers.pyx"; -static const char __pyx_k_Incompatible_checksums_s_vs_0x20_2[] = "Incompatible checksums (%s vs 0x2026b20 = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))"; -static const char __pyx_k_Incompatible_checksums_s_vs_0xa7_2[] = "Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))"; static PyObject *__pyx_n_s_; static PyObject *__pyx_kp_s_0_1; static PyObject *__pyx_kp_s_0_can_aggregate_only_instances; static PyObject *__pyx_kp_s_0_can_provide_only_1_instances; static PyObject *__pyx_kp_s_0_can_wrap_only_1_providers; static PyObject *__pyx_kp_s_0_does_not_contain_factory_with; -static PyObject *__pyx_kp_s_0_is_not_an; +static PyObject *__pyx_kp_s_0_is_not_an_instance_of_1; static PyObject *__pyx_kp_s_0_must_be_overridden_before_cal; static PyObject *__pyx_kp_s_0_must_be_overridden_only_by_1; static PyObject *__pyx_kp_s_0_providers_could_not_be_overri; @@ -3510,6 +3599,7 @@ static PyObject *__pyx_n_s_AbstractFactory; static PyObject *__pyx_n_s_AbstractSingleton; static PyObject *__pyx_kp_s_Abstract_provider_forward_provid; static PyObject *__pyx_kp_s_Argument_instance_of_has_incorre; +static PyObject *__pyx_n_s_AsyncResource; static PyObject *__pyx_n_s_AttributeError; static PyObject *__pyx_n_s_AttributeGetter; static PyObject *__pyx_n_s_BaseSingleton; @@ -3548,39 +3638,41 @@ static PyObject *__pyx_n_s_ExternalDependency; static PyObject *__pyx_n_s_Factory; static PyObject *__pyx_n_s_FactoryAggregate; static PyObject *__pyx_n_s_FactoryDelegate; +static PyObject *__pyx_kp_s_Factory_missing_1_required_posit; static PyObject *__pyx_n_u_False; +static PyObject *__pyx_n_s_Future; static PyObject *__pyx_n_s_IOError; static PyObject *__pyx_n_s_IS_DELEGATED; static PyObject *__pyx_n_s_IS_PROVIDER; static PyObject *__pyx_n_s_ImportError; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x03; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x04; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x0c; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x0d; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x0f; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x1b; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x1c; static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x20; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x20_2; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x2a; static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x2e; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x3f; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x57; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x58; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x63; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x32; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x34; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x3e; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x42; static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x64; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x76; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x97; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xa5; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xa6; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xa7; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xa7_2; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xb2; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xd8; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xe0; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xe8; -static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xf1; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x66; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x6a; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x73; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x75; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x7e; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xa0; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xa2; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xce; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xd5; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xe5; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xfd; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xfe; +static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xff; static PyObject *__pyx_n_s_IndexError; static PyObject *__pyx_n_s_Injection; static PyObject *__pyx_kp_s_Interpolation_which_expands_envi; static PyObject *__pyx_n_s_ItemGetter; +static PyObject *__pyx_n_s_KeyError; static PyObject *__pyx_n_s_List; static PyObject *__pyx_n_s_Loader; static PyObject *__pyx_n_s_MethodCaller; @@ -3601,6 +3693,7 @@ static PyObject *__pyx_kp_s_Provider_0_could_not_be_overridd; static PyObject *__pyx_kp_s_Provider_0_expected_to_get_calla; static PyObject *__pyx_kp_s_Provider_0_expected_to_get_corou; static PyObject *__pyx_kp_s_Provider_0_is_not_overridden; +static PyObject *__pyx_n_s_Pyx_CFunc_void____object___to; static PyObject *__pyx_n_s_RLock; static PyObject *__pyx_n_s_Resource; static PyObject *__pyx_n_s_Selector; @@ -3618,23 +3711,30 @@ static PyObject *__pyx_n_s_TypedConfigurationOption; static PyObject *__pyx_n_s_UNDEFINED; static PyObject *__pyx_kp_s_Unable_to_load_yaml_configuratio; static PyObject *__pyx_kp_s_Unknown_type_of_resource_initial; -static PyObject *__pyx_n_s__11; -static PyObject *__pyx_kp_s__12; -static PyObject *__pyx_kp_u__13; +static PyObject *__pyx_kp_u__10; +static PyObject *__pyx_n_s__12; +static PyObject *__pyx_kp_s__13; static PyObject *__pyx_kp_u__14; -static PyObject *__pyx_kp_s__16; +static PyObject *__pyx_kp_u__15; +static PyObject *__pyx_kp_s__19; static PyObject *__pyx_n_s__4; static PyObject *__pyx_kp_s__5; -static PyObject *__pyx_kp_u__8; static PyObject *__pyx_kp_u__9; static PyObject *__pyx_n_s_add_args; static PyObject *__pyx_n_s_add_attributes; static PyObject *__pyx_n_s_add_constructor; +static PyObject *__pyx_n_s_add_done_callback; static PyObject *__pyx_n_s_add_implicit_resolver; static PyObject *__pyx_n_s_add_kwargs; static PyObject *__pyx_n_s_add_sys_streams; static PyObject *__pyx_n_s_address; +static PyObject *__pyx_n_s_anext; static PyObject *__pyx_n_s_args; +static PyObject *__pyx_n_s_asend; +static PyObject *__pyx_n_s_async_init_callback; +static PyObject *__pyx_n_s_async_init_instance; +static PyObject *__pyx_n_s_async_provide; +static PyObject *__pyx_n_s_async_shutdown_callback; static PyObject *__pyx_n_s_asyncio; static PyObject *__pyx_n_s_asyncio_coroutines; static PyObject *__pyx_n_s_asyncio_tasks; @@ -3645,7 +3745,10 @@ static PyObject *__pyx_n_s_before_get; static PyObject *__pyx_n_s_call; static PyObject *__pyx_n_s_callable; static PyObject *__pyx_n_s_callback; +static PyObject *__pyx_n_s_cancel; static PyObject *__pyx_n_s_category; +static PyObject *__pyx_n_s_cfunc_to_py; +static PyObject *__pyx_n_s_check_instance_type; static PyObject *__pyx_n_s_class; static PyObject *__pyx_n_s_class_getitem; static PyObject *__pyx_n_s_clear_args; @@ -3667,6 +3770,8 @@ static PyObject *__pyx_n_s_copy; static PyObject *__pyx_n_s_copy_overridings; static PyObject *__pyx_n_s_coroutine; static PyObject *__pyx_n_s_coroutines; +static PyObject *__pyx_n_s_create_init_future; +static PyObject *__pyx_n_s_create_shutdown_future; static PyObject *__pyx_n_s_deepcopy; static PyObject *__pyx_n_s_deepcopy_dispatch; static PyObject *__pyx_n_s_default; @@ -3676,8 +3781,11 @@ static PyObject *__pyx_n_s_dict; static PyObject *__pyx_n_s_dict1; static PyObject *__pyx_n_s_dict2; static PyObject *__pyx_n_s_dict_2; +static PyObject *__pyx_n_s_disable_async_mode; static PyObject *__pyx_n_s_doc; +static PyObject *__pyx_n_s_enable_async_mode; static PyObject *__pyx_n_s_endswith; +static PyObject *__pyx_n_s_ensure_future; static PyObject *__pyx_n_s_enter; static PyObject *__pyx_n_s_errors; static PyObject *__pyx_n_s_exit; @@ -3687,6 +3795,10 @@ static PyObject *__pyx_n_s_factory; static PyObject *__pyx_n_s_factory_name; static PyObject *__pyx_n_s_filepath; static PyObject *__pyx_n_s_format; +static PyObject *__pyx_n_s_functools; +static PyObject *__pyx_n_s_future; +static PyObject *__pyx_n_s_future_result; +static PyObject *__pyx_n_s_gather; static PyObject *__pyx_n_s_genexpr; static PyObject *__pyx_n_s_get; static PyObject *__pyx_n_s_get_name; @@ -3694,6 +3806,7 @@ static PyObject *__pyx_n_s_get_self_name; static PyObject *__pyx_n_s_get_self_name_locals_genexpr; static PyObject *__pyx_n_s_getenv; static PyObject *__pyx_n_s_getstate; +static PyObject *__pyx_n_s_has_isawaitable; static PyObject *__pyx_n_s_hex; static PyObject *__pyx_n_s_id; static PyObject *__pyx_n_s_im_class; @@ -3709,11 +3822,16 @@ static PyObject *__pyx_n_s_initializer; static PyObject *__pyx_n_s_inspect; static PyObject *__pyx_n_s_instance; static PyObject *__pyx_n_s_instance_of; -static PyObject *__pyx_kp_s_instance_of_0; static PyObject *__pyx_n_s_interpolation; +static PyObject *__pyx_n_s_is_async_mode_disabled; +static PyObject *__pyx_n_s_is_async_mode_enabled; +static PyObject *__pyx_n_s_is_async_mode_undefined; +static PyObject *__pyx_n_s_is_async_resource_subclass; static PyObject *__pyx_n_s_is_coroutine; static PyObject *__pyx_n_s_is_coroutine_marker; static PyObject *__pyx_n_s_is_resource_subclass; +static PyObject *__pyx_n_s_isasyncgenfunction; +static PyObject *__pyx_n_s_isawaitable; static PyObject *__pyx_n_s_iscoroutinefunction; static PyObject *__pyx_n_s_isgeneratorfunction; static PyObject *__pyx_n_s_item; @@ -3747,6 +3865,7 @@ static PyObject *__pyx_n_s_overriding; static PyObject *__pyx_n_s_overriding_lock; static PyObject *__pyx_n_s_parse_ini_file; static PyObject *__pyx_n_s_parser; +static PyObject *__pyx_n_s_partial; static PyObject *__pyx_n_s_path; static PyObject *__pyx_kp_s_path_2; static PyObject *__pyx_n_s_pickle; @@ -3834,10 +3953,13 @@ static PyObject *__pyx_n_s_send; static PyObject *__pyx_n_s_set; static PyObject *__pyx_n_s_set_args; static PyObject *__pyx_n_s_set_attributes; +static PyObject *__pyx_n_s_set_exception; static PyObject *__pyx_n_s_set_kwargs; +static PyObject *__pyx_n_s_set_result; static PyObject *__pyx_n_s_setstate; static PyObject *__pyx_n_s_setstate_cython; static PyObject *__pyx_n_s_shutdown; +static PyObject *__pyx_n_s_shutdowner; static PyObject *__pyx_n_s_singleton; static PyObject *__pyx_n_s_split; static PyObject *__pyx_kp_s_src_dependency_injector_provider; @@ -3863,9 +3985,11 @@ static PyObject *__pyx_n_s_version_info; static PyObject *__pyx_n_s_warn; static PyObject *__pyx_n_s_warnings; static PyObject *__pyx_n_s_weakref; +static PyObject *__pyx_n_s_wrap; static PyObject *__pyx_n_s_yaml; static PyObject *__pyx_n_s_yaml_env_marker_constructor; static PyObject *__pyx_n_s_yaml_env_marker_pattern; +static PyObject *__pyx_n_s_zip; static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_memo); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_yaml_env_marker_constructor(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v__, PyObject *__pyx_v_node); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_before_get(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_self, PyObject *__pyx_v_parser, PyObject *__pyx_v_section, PyObject *__pyx_v_option, PyObject *__pyx_v_value, PyObject *__pyx_v_defaults); /* proto */ @@ -3882,13 +4006,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_15last_over static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v_provider); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_last_overriding(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_override(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_18delegate(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_18async_(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_20delegate(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_8provider___get__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_8provided___get__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_20_provide(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_22_copy_overridings(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_copied, PyObject *__pyx_v_memo); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_26__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_22enable_async_mode(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24disable_async_mode(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_26reset_async_mode(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_28is_async_mode_enabled(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_30is_async_mode_disabled(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_32is_async_mode_undefined(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_34_provide(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_36_copy_overridings(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_copied, PyObject *__pyx_v_memo); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_38__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_40__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static int __pyx_pf_19dependency_injector_9providers_6Object___init__(struct __pyx_obj_19dependency_injector_9providers_Object *__pyx_v_self, PyObject *__pyx_v_provides); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_2__deepcopy__(struct __pyx_obj_19dependency_injector_9providers_Object *__pyx_v_self, PyObject *__pyx_v_memo); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_4__str__(struct __pyx_obj_19dependency_injector_9providers_Object *__pyx_v_self); /* proto */ @@ -3911,8 +4042,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_6__str__ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_8__repr__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_11instance_of___get__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_10provided_by(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self, PyObject *__pyx_v_provider); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_14__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12_async_provide(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_future); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_14_check_instance_type(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self, PyObject *__pyx_v_instance); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_16__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_18__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency___reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_ExternalDependency *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_2__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_ExternalDependency *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static int __pyx_pf_19dependency_injector_9providers_21DependenciesContainer___init__(struct __pyx_obj_19dependency_injector_9providers_DependenciesContainer *__pyx_v_self, PyObject *__pyx_v_dependencies); /* proto */ @@ -4047,11 +4180,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_4__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_FactoryDelegate *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_factories); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_2__deepcopy__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_memo); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_4__call__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_factory_name, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_6__getattr__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_factory_name); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_8__str__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_4__getattr__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_factory_name); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_6__str__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_9factories___get__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_10override(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v__); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_8override(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v__); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_10_provide(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_14__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self, PyObject *__pyx_v_provides, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ @@ -4071,8 +4204,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_18add static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_20set_attributes(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self, PyObject *__pyx_v_kwargs); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_22clear_attributes(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_24reset(CYTHON_UNUSED struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_26__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_28__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_26_async_init_instance(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_result); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_28__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_30__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static int __pyx_pf_19dependency_injector_9providers_9Singleton___init__(struct __pyx_obj_19dependency_injector_9providers_Singleton *__pyx_v_self, PyObject *__pyx_v_provides, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_2reset(struct __pyx_obj_19dependency_injector_9providers_Singleton *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_4_provide(struct __pyx_obj_19dependency_injector_9providers_Singleton *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ @@ -4090,8 +4224,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe static int __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton___init__(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self, PyObject *__pyx_v_provides, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_2reset(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_4_provide(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_6__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_8__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_6_async_init_instance(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_result); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_8__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_10__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLocalSingleton___reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadLocalSingleton *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLocalSingleton_2__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadLocalSingleton *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton___call__(struct __pyx_obj_19dependency_injector_9providers_AbstractSingleton *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ @@ -4137,9 +4272,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_11initializ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_18init(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_20shutdown(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_22_provide(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_is_resource_subclass(PyObject *__pyx_v_instance); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_28__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_create_init_future(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v_future, PyObject *__pyx_v_shutdowner); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26_async_init_callback(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v_initializer, PyObject *__pyx_v_shutdowner); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_28_create_shutdown_future(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v_shutdown_future); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_30_async_shutdown_callback(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_shutdowner); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_32_is_resource_subclass(PyObject *__pyx_v_instance); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_34_is_async_resource_subclass(PyObject *__pyx_v_instance); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_36__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_38__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct __pyx_obj_19dependency_injector_9providers_Container *__pyx_v_self, PyObject *__pyx_v_container_cls, PyObject *__pyx_v_container, PyObject *__pyx_v_overriding_providers); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcopy__(struct __pyx_obj_19dependency_injector_9providers_Container *__pyx_v_self, PyObject *__pyx_v_memo); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_4__getattr__(struct __pyx_obj_19dependency_injector_9providers_Container *__pyx_v_self, PyObject *__pyx_v_name); /* proto */ @@ -4176,8 +4316,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_8pr static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4name___get__(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_10call(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_12_provide(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_16__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_async_provide(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_future); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_16__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_18__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static int __pyx_pf_19dependency_injector_9providers_10ItemGetter___init__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_provider, PyObject *__pyx_v_item); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_2__repr__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepcopy__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, PyObject *__pyx_v_memo); /* proto */ @@ -4187,8 +4328,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_8provide static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4name___get__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_10call(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_12_provide(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_16__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14_async_provide(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_future); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_16__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_18__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static int __pyx_pf_19dependency_injector_9providers_12MethodCaller___init__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v_provider, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_2__repr__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__deepcopy__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v_memo); /* proto */ @@ -4199,8 +4341,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4args_ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6kwargs___get__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_10call(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_12_provide(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_16__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14_async_provide(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, PyObject *__pyx_v_future); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_16__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_18__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_9Injection___reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Injection *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_9Injection_2__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Injection *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___init__(struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *__pyx_v_self, PyObject *__pyx_v_value); /* proto */ @@ -4225,50 +4368,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16represent_provider( static PyObject *__pyx_pf_19dependency_injector_9providers_18deepcopy(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_instance, PyObject *__pyx_v_memo); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_20__add_sys_streams(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_memo); /* proto */ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_dict1, PyObject *__pyx_v_dict2); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_25__pyx_unpickle_Provider(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_27__pyx_unpickle_Object(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_29__pyx_unpickle_Delegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Dependency(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_ExternalDependency(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_DependenciesContainer(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_37__pyx_unpickle_OverridingContext(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_Callable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_DelegatedCallable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_AbstractCallable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_CallableDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_Coroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_DelegatedCoroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_AbstractCoroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_CoroutineDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_ConfigurationOption(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_TypedConfigurationOption(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_Configuration(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_Factory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_DelegatedFactory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_AbstractFactory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_FactoryDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_FactoryAggregate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_BaseSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_Singleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_DelegatedSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_ThreadSafeSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_DelegatedThreadSafeSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_ThreadLocalSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_DelegatedThreadLocalSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_AbstractSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_SingletonDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_List(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_Dict(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_Resource(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_Container(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Selector(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_ProvidedInstance(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_AttributeGetter(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_ItemGetter(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_MethodCaller(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_107__pyx_unpickle_Injection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_109__pyx_unpickle_PositionalInjection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ -static PyObject *__pyx_pf_19dependency_injector_9providers_111__pyx_unpickle_NamedInjection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_24isawaitable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_26iscoroutinefunction(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_28isasyncgenfunction(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Provider(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_Object(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_Delegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_37__pyx_unpickle_Dependency(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_ExternalDependency(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_DependenciesContainer(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_OverridingContext(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_Callable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_DelegatedCallable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_AbstractCallable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_CallableDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_Coroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_DelegatedCoroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_AbstractCoroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_CoroutineDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_ConfigurationOption(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_TypedConfigurationOption(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_Configuration(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_Factory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_DelegatedFactory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_AbstractFactory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_FactoryDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_FactoryAggregate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_BaseSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_Singleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_DelegatedSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_ThreadSafeSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_DelegatedThreadSafeSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_ThreadLocalSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_DelegatedThreadLocalSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_AbstractSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_SingletonDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_List(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Dict(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_Resource(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_Container(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_Selector(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_ProvidedInstance(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_107__pyx_unpickle_AttributeGetter(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_109__pyx_unpickle_ItemGetter(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_111__pyx_unpickle_MethodCaller(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_113__pyx_unpickle_Injection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_115__pyx_unpickle_PositionalInjection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_19dependency_injector_9providers_117__pyx_unpickle_NamedInjection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */ +static PyObject *__pyx_pf_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_wrap(PyObject *__pyx_self, PyObject *__pyx_v_future); /* proto */ static PyObject *__pyx_tp_new_19dependency_injector_9providers_Provider(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_19dependency_injector_9providers_Object(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_19dependency_injector_9providers_Delegate(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ @@ -4317,149 +4464,161 @@ static PyObject *__pyx_tp_new_19dependency_injector_9providers___pyx_scope_struc static PyObject *__pyx_tp_new_19dependency_injector_9providers___pyx_scope_struct_1_genexpr(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_19dependency_injector_9providers___pyx_scope_struct_2___str__(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_19dependency_injector_9providers___pyx_scope_struct_3_genexpr(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ +static PyObject *__pyx_tp_new___pyx_scope_struct____Pyx_CFunc_void____object___to_py(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static __Pyx_CachedCFunction __pyx_umethod_PyDict_Type_get = {0, &__pyx_n_s_get, 0, 0, 0}; static __Pyx_CachedCFunction __pyx_umethod_PyDict_Type_items = {0, &__pyx_n_s_items, 0, 0, 0}; +static __Pyx_CachedCFunction __pyx_umethod_PyDict_Type_pop = {0, &__pyx_n_s_pop, 0, 0, 0}; static __Pyx_CachedCFunction __pyx_umethod_PyDict_Type_values = {0, &__pyx_n_s_values, 0, 0, 0}; static PyObject *__pyx_int_0; static PyObject *__pyx_int_2; static PyObject *__pyx_int_3; static PyObject *__pyx_int_5; -static PyObject *__pyx_int_3297756; -static PyObject *__pyx_int_4406536; -static PyObject *__pyx_int_12885488; -static PyObject *__pyx_int_13664252; -static PyObject *__pyx_int_16106973; -static PyObject *__pyx_int_33712928; +static PyObject *__pyx_int_29181932; +static PyObject *__pyx_int_30383981; static PyObject *__pyx_int_34020203; +static PyObject *__pyx_int_44395068; static PyObject *__pyx_int_48353679; -static PyObject *__pyx_int_66364342; -static PyObject *__pyx_int_91273250; -static PyObject *__pyx_int_92376750; -static PyObject *__pyx_int_103927799; +static PyObject *__pyx_int_52983931; +static PyObject *__pyx_int_54922531; +static PyObject *__pyx_int_65022886; +static PyObject *__pyx_int_69951814; static PyObject *__pyx_int_105855327; -static PyObject *__pyx_int_124696738; -static PyObject *__pyx_int_159160076; -static PyObject *__pyx_int_173552623; -static PyObject *__pyx_int_174495485; -static PyObject *__pyx_int_175356006; -static PyObject *__pyx_int_175530959; -static PyObject *__pyx_int_186670759; -static PyObject *__pyx_int_226841543; -static PyObject *__pyx_int_235011912; -static PyObject *__pyx_int_244028132; -static PyObject *__pyx_int_253710871; +static PyObject *__pyx_int_107726368; +static PyObject *__pyx_int_111758699; +static PyObject *__pyx_int_120901579; +static PyObject *__pyx_int_122966839; +static PyObject *__pyx_int_132941027; +static PyObject *__pyx_int_168129982; +static PyObject *__pyx_int_170282226; +static PyObject *__pyx_int_216322617; +static PyObject *__pyx_int_223699277; +static PyObject *__pyx_int_240604463; +static PyObject *__pyx_int_265687189; +static PyObject *__pyx_int_267092376; +static PyObject *__pyx_int_267861151; static PyObject *__pyx_k__7; static PyObject *__pyx_tuple__2; static PyObject *__pyx_tuple__3; static PyObject *__pyx_tuple__6; -static PyObject *__pyx_tuple__10; -static PyObject *__pyx_tuple__15; -static PyObject *__pyx_tuple__17; +static PyObject *__pyx_tuple__8; +static PyObject *__pyx_tuple__11; +static PyObject *__pyx_tuple__16; static PyObject *__pyx_tuple__18; static PyObject *__pyx_tuple__20; -static PyObject *__pyx_tuple__22; -static PyObject *__pyx_tuple__24; -static PyObject *__pyx_tuple__26; -static PyObject *__pyx_tuple__28; -static PyObject *__pyx_tuple__30; -static PyObject *__pyx_tuple__32; -static PyObject *__pyx_tuple__34; -static PyObject *__pyx_tuple__36; -static PyObject *__pyx_tuple__38; -static PyObject *__pyx_tuple__40; -static PyObject *__pyx_tuple__42; -static PyObject *__pyx_tuple__44; -static PyObject *__pyx_tuple__46; -static PyObject *__pyx_tuple__48; -static PyObject *__pyx_tuple__50; -static PyObject *__pyx_tuple__52; -static PyObject *__pyx_tuple__54; -static PyObject *__pyx_tuple__56; -static PyObject *__pyx_tuple__58; -static PyObject *__pyx_tuple__60; -static PyObject *__pyx_tuple__62; -static PyObject *__pyx_tuple__64; -static PyObject *__pyx_tuple__66; -static PyObject *__pyx_tuple__68; -static PyObject *__pyx_tuple__70; -static PyObject *__pyx_tuple__72; -static PyObject *__pyx_tuple__74; -static PyObject *__pyx_tuple__76; -static PyObject *__pyx_tuple__78; -static PyObject *__pyx_tuple__80; -static PyObject *__pyx_tuple__82; -static PyObject *__pyx_tuple__84; -static PyObject *__pyx_tuple__86; -static PyObject *__pyx_tuple__88; -static PyObject *__pyx_tuple__90; -static PyObject *__pyx_tuple__92; -static PyObject *__pyx_tuple__94; -static PyObject *__pyx_tuple__96; -static PyObject *__pyx_tuple__98; -static PyObject *__pyx_tuple__100; -static PyObject *__pyx_tuple__102; -static PyObject *__pyx_tuple__104; -static PyObject *__pyx_tuple__106; -static PyObject *__pyx_tuple__108; -static PyObject *__pyx_tuple__110; -static PyObject *__pyx_tuple__112; -static PyObject *__pyx_tuple__114; -static PyObject *__pyx_tuple__116; -static PyObject *__pyx_tuple__118; -static PyObject *__pyx_codeobj__19; -static PyObject *__pyx_codeobj__21; -static PyObject *__pyx_codeobj__23; -static PyObject *__pyx_codeobj__25; -static PyObject *__pyx_codeobj__27; -static PyObject *__pyx_codeobj__29; -static PyObject *__pyx_codeobj__31; -static PyObject *__pyx_codeobj__33; -static PyObject *__pyx_codeobj__35; -static PyObject *__pyx_codeobj__37; -static PyObject *__pyx_codeobj__39; -static PyObject *__pyx_codeobj__41; -static PyObject *__pyx_codeobj__43; -static PyObject *__pyx_codeobj__45; -static PyObject *__pyx_codeobj__47; -static PyObject *__pyx_codeobj__49; -static PyObject *__pyx_codeobj__51; -static PyObject *__pyx_codeobj__53; -static PyObject *__pyx_codeobj__55; -static PyObject *__pyx_codeobj__57; -static PyObject *__pyx_codeobj__59; -static PyObject *__pyx_codeobj__61; -static PyObject *__pyx_codeobj__63; -static PyObject *__pyx_codeobj__65; -static PyObject *__pyx_codeobj__67; -static PyObject *__pyx_codeobj__69; -static PyObject *__pyx_codeobj__71; -static PyObject *__pyx_codeobj__73; -static PyObject *__pyx_codeobj__75; -static PyObject *__pyx_codeobj__77; -static PyObject *__pyx_codeobj__79; -static PyObject *__pyx_codeobj__81; -static PyObject *__pyx_codeobj__83; -static PyObject *__pyx_codeobj__85; -static PyObject *__pyx_codeobj__87; -static PyObject *__pyx_codeobj__89; -static PyObject *__pyx_codeobj__91; -static PyObject *__pyx_codeobj__93; -static PyObject *__pyx_codeobj__95; -static PyObject *__pyx_codeobj__97; -static PyObject *__pyx_codeobj__99; -static PyObject *__pyx_codeobj__101; -static PyObject *__pyx_codeobj__103; -static PyObject *__pyx_codeobj__105; -static PyObject *__pyx_codeobj__107; -static PyObject *__pyx_codeobj__109; -static PyObject *__pyx_codeobj__111; -static PyObject *__pyx_codeobj__113; -static PyObject *__pyx_codeobj__115; -static PyObject *__pyx_codeobj__117; -static PyObject *__pyx_codeobj__119; +static PyObject *__pyx_tuple__21; +static PyObject *__pyx_tuple__23; +static PyObject *__pyx_tuple__25; +static PyObject *__pyx_tuple__27; +static PyObject *__pyx_tuple__29; +static PyObject *__pyx_tuple__31; +static PyObject *__pyx_tuple__33; +static PyObject *__pyx_tuple__35; +static PyObject *__pyx_tuple__37; +static PyObject *__pyx_tuple__39; +static PyObject *__pyx_tuple__41; +static PyObject *__pyx_tuple__43; +static PyObject *__pyx_tuple__45; +static PyObject *__pyx_tuple__47; +static PyObject *__pyx_tuple__49; +static PyObject *__pyx_tuple__51; +static PyObject *__pyx_tuple__53; +static PyObject *__pyx_tuple__55; +static PyObject *__pyx_tuple__57; +static PyObject *__pyx_tuple__59; +static PyObject *__pyx_tuple__61; +static PyObject *__pyx_tuple__63; +static PyObject *__pyx_tuple__65; +static PyObject *__pyx_tuple__67; +static PyObject *__pyx_tuple__69; +static PyObject *__pyx_tuple__71; +static PyObject *__pyx_tuple__73; +static PyObject *__pyx_tuple__75; +static PyObject *__pyx_tuple__77; +static PyObject *__pyx_tuple__79; +static PyObject *__pyx_tuple__81; +static PyObject *__pyx_tuple__83; +static PyObject *__pyx_tuple__85; +static PyObject *__pyx_tuple__87; +static PyObject *__pyx_tuple__89; +static PyObject *__pyx_tuple__91; +static PyObject *__pyx_tuple__93; +static PyObject *__pyx_tuple__95; +static PyObject *__pyx_tuple__97; +static PyObject *__pyx_tuple__99; +static PyObject *__pyx_tuple__101; +static PyObject *__pyx_tuple__103; +static PyObject *__pyx_tuple__105; +static PyObject *__pyx_tuple__107; +static PyObject *__pyx_tuple__109; +static PyObject *__pyx_tuple__111; +static PyObject *__pyx_tuple__113; +static PyObject *__pyx_tuple__115; +static PyObject *__pyx_tuple__117; +static PyObject *__pyx_tuple__119; +static PyObject *__pyx_tuple__121; +static PyObject *__pyx_tuple__123; +static PyObject *__pyx_tuple__125; +static PyObject *__pyx_tuple__127; +static PyObject *__pyx_tuple__129; +static PyObject *__pyx_codeobj__17; +static PyObject *__pyx_codeobj__22; +static PyObject *__pyx_codeobj__24; +static PyObject *__pyx_codeobj__26; +static PyObject *__pyx_codeobj__28; +static PyObject *__pyx_codeobj__30; +static PyObject *__pyx_codeobj__32; +static PyObject *__pyx_codeobj__34; +static PyObject *__pyx_codeobj__36; +static PyObject *__pyx_codeobj__38; +static PyObject *__pyx_codeobj__40; +static PyObject *__pyx_codeobj__42; +static PyObject *__pyx_codeobj__44; +static PyObject *__pyx_codeobj__46; +static PyObject *__pyx_codeobj__48; +static PyObject *__pyx_codeobj__50; +static PyObject *__pyx_codeobj__52; +static PyObject *__pyx_codeobj__54; +static PyObject *__pyx_codeobj__56; +static PyObject *__pyx_codeobj__58; +static PyObject *__pyx_codeobj__60; +static PyObject *__pyx_codeobj__62; +static PyObject *__pyx_codeobj__64; +static PyObject *__pyx_codeobj__66; +static PyObject *__pyx_codeobj__68; +static PyObject *__pyx_codeobj__70; +static PyObject *__pyx_codeobj__72; +static PyObject *__pyx_codeobj__74; +static PyObject *__pyx_codeobj__76; +static PyObject *__pyx_codeobj__78; +static PyObject *__pyx_codeobj__80; +static PyObject *__pyx_codeobj__82; +static PyObject *__pyx_codeobj__84; +static PyObject *__pyx_codeobj__86; +static PyObject *__pyx_codeobj__88; +static PyObject *__pyx_codeobj__90; +static PyObject *__pyx_codeobj__92; +static PyObject *__pyx_codeobj__94; +static PyObject *__pyx_codeobj__96; +static PyObject *__pyx_codeobj__98; +static PyObject *__pyx_codeobj__100; +static PyObject *__pyx_codeobj__102; +static PyObject *__pyx_codeobj__104; +static PyObject *__pyx_codeobj__106; +static PyObject *__pyx_codeobj__108; +static PyObject *__pyx_codeobj__110; +static PyObject *__pyx_codeobj__112; +static PyObject *__pyx_codeobj__114; +static PyObject *__pyx_codeobj__116; +static PyObject *__pyx_codeobj__118; +static PyObject *__pyx_codeobj__120; +static PyObject *__pyx_codeobj__122; +static PyObject *__pyx_codeobj__124; +static PyObject *__pyx_codeobj__126; +static PyObject *__pyx_codeobj__128; +static PyObject *__pyx_codeobj__130; /* Late includes */ -/* "dependency_injector/providers.pyx":51 +/* "dependency_injector/providers.pyx":52 * * copy._deepcopy_dispatch[types.MethodType] = \ * lambda obj, memo: type(obj)(obj.im_func, # <<<<<<<<<<<<<< @@ -4468,9 +4627,9 @@ static PyObject *__pyx_codeobj__119; */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_24lambda(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_24lambda = {"lambda", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_24lambda, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_24lambda(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_30lambda(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_30lambda = {"lambda", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_30lambda, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_30lambda(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_obj = 0; PyObject *__pyx_v_memo = 0; int __pyx_lineno = 0; @@ -4502,11 +4661,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_24lambda(PyObject *__ case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_memo)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("lambda", 1, 2, 2, 1); __PYX_ERR(1, 51, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("lambda", 1, 2, 2, 1); __PYX_ERR(1, 52, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "lambda") < 0)) __PYX_ERR(1, 51, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "lambda") < 0)) __PYX_ERR(1, 52, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -4519,7 +4678,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_24lambda(PyObject *__ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("lambda", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 51, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("lambda", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 52, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.lambda", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -4548,22 +4707,22 @@ static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CY int __pyx_clineno = 0; __Pyx_RefNannySetupContext("lambda", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_obj, __pyx_n_s_im_func); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 51, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_obj, __pyx_n_s_im_func); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 52, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - /* "dependency_injector/providers.pyx":52 + /* "dependency_injector/providers.pyx":53 * copy._deepcopy_dispatch[types.MethodType] = \ * lambda obj, memo: type(obj)(obj.im_func, * copy.deepcopy(obj.im_self, memo), # <<<<<<<<<<<<<< * obj.im_class) * */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_copy); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 52, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_copy); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 53, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_deepcopy); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 52, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_deepcopy); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 53, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_obj, __pyx_n_s_im_self); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 52, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_obj, __pyx_n_s_im_self); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 53, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = NULL; __pyx_t_7 = 0; @@ -4580,7 +4739,7 @@ static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CY #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_4, __pyx_v_memo}; - __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 52, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 53, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -4589,14 +4748,14 @@ static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CY #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_4, __pyx_v_memo}; - __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 52, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 53, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { - __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 52, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 53, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; @@ -4607,20 +4766,20 @@ static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CY __Pyx_GIVEREF(__pyx_v_memo); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_7, __pyx_v_memo); __pyx_t_4 = 0; - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 52, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 53, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":53 + /* "dependency_injector/providers.pyx":54 * lambda obj, memo: type(obj)(obj.im_func, * copy.deepcopy(obj.im_self, memo), * obj.im_class) # <<<<<<<<<<<<<< * * if yaml: */ - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_obj, __pyx_n_s_im_class); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 53, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_obj, __pyx_n_s_im_class); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 54, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_INCREF(((PyObject *)Py_TYPE(__pyx_v_obj))); __pyx_t_8 = ((PyObject *)Py_TYPE(__pyx_v_obj)); __pyx_t_4 = NULL; @@ -4638,7 +4797,7 @@ static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CY #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_8)) { PyObject *__pyx_temp[4] = {__pyx_t_4, __pyx_t_2, __pyx_t_3, __pyx_t_5}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_8, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 51, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_8, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 52, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -4649,7 +4808,7 @@ static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CY #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_8)) { PyObject *__pyx_temp[4] = {__pyx_t_4, __pyx_t_2, __pyx_t_3, __pyx_t_5}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_8, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 51, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_8, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 52, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -4658,7 +4817,7 @@ static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CY } else #endif { - __pyx_t_6 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 51, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 52, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -4672,7 +4831,7 @@ static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CY __pyx_t_2 = 0; __pyx_t_3 = 0; __pyx_t_5 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 51, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 52, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -4681,7 +4840,7 @@ static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CY __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":51 + /* "dependency_injector/providers.pyx":52 * * copy._deepcopy_dispatch[types.MethodType] = \ * lambda obj, memo: type(obj)(obj.im_func, # <<<<<<<<<<<<<< @@ -4706,7 +4865,7 @@ static PyObject *__pyx_lambda_funcdef_19dependency_injector_9providers_lambda(CY return __pyx_r; } -/* "dependency_injector/providers.pyx":57 +/* "dependency_injector/providers.pyx":58 * if yaml: * yaml_env_marker_pattern = re.compile(r'\$\{([^}^{]+)\}') * def yaml_env_marker_constructor(_, node): # <<<<<<<<<<<<<< @@ -4750,11 +4909,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_1yaml_env_marker_cons case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_node)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("yaml_env_marker_constructor", 1, 2, 2, 1); __PYX_ERR(1, 57, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("yaml_env_marker_constructor", 1, 2, 2, 1); __PYX_ERR(1, 58, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "yaml_env_marker_constructor") < 0)) __PYX_ERR(1, 57, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "yaml_env_marker_constructor") < 0)) __PYX_ERR(1, 58, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -4767,7 +4926,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_1yaml_env_marker_cons } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("yaml_env_marker_constructor", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 57, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("yaml_env_marker_constructor", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 58, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.yaml_env_marker_constructor", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -4792,7 +4951,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_yaml_env_marker_const int __pyx_clineno = 0; __Pyx_RefNannySetupContext("yaml_env_marker_constructor", 0); - /* "dependency_injector/providers.pyx":59 + /* "dependency_injector/providers.pyx":60 * def yaml_env_marker_constructor(_, node): * """"Replace environment variable marker with its value.""" * return os.path.expandvars(node.value) # <<<<<<<<<<<<<< @@ -4800,15 +4959,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_yaml_env_marker_const * yaml.add_implicit_resolver('!path', yaml_env_marker_pattern) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_os); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 59, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_os); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 60, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_path); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 59, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_path); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 60, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_expandvars); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 59, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_expandvars); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 60, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 59, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 60, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -4823,14 +4982,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_yaml_env_marker_const __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 59, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 60, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":57 + /* "dependency_injector/providers.pyx":58 * if yaml: * yaml_env_marker_pattern = re.compile(r'\$\{([^}^{]+)\}') * def yaml_env_marker_constructor(_, node): # <<<<<<<<<<<<<< @@ -4852,7 +5011,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_yaml_env_marker_const return __pyx_r; } -/* "dependency_injector/providers.pyx":68 +/* "dependency_injector/providers.pyx":69 * """Interpolation which expands environment variables in values.""" * * def before_get(self, parser, section, option, value, defaults): # <<<<<<<<<<<<<< @@ -4907,35 +5066,35 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_16EnvInterpolation_1b case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_parser)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, 1); __PYX_ERR(1, 68, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, 1); __PYX_ERR(1, 69, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 2: if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_section)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, 2); __PYX_ERR(1, 68, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, 2); __PYX_ERR(1, 69, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 3: if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_option)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, 3); __PYX_ERR(1, 68, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, 3); __PYX_ERR(1, 69, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 4: if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, 4); __PYX_ERR(1, 68, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, 4); __PYX_ERR(1, 69, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 5: if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_defaults)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, 5); __PYX_ERR(1, 68, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, 5); __PYX_ERR(1, 69, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "before_get") < 0)) __PYX_ERR(1, 68, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "before_get") < 0)) __PYX_ERR(1, 69, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 6) { goto __pyx_L5_argtuple_error; @@ -4956,7 +5115,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_16EnvInterpolation_1b } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 68, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("before_get", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 69, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.EnvInterpolation.before_get", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -4983,7 +5142,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_be __Pyx_RefNannySetupContext("before_get", 0); __Pyx_INCREF(__pyx_v_value); - /* "dependency_injector/providers.pyx":69 + /* "dependency_injector/providers.pyx":70 * * def before_get(self, parser, section, option, value, defaults): * value = super().before_get(parser, section, option, value, defaults) # <<<<<<<<<<<<<< @@ -4991,9 +5150,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_be * */ __pyx_t_2 = __Pyx_CyFunction_GetClassObj(__pyx_self); - if (!__pyx_t_2) { PyErr_SetString(PyExc_SystemError, "super(): empty __class__ cell"); __PYX_ERR(1, 69, __pyx_L1_error) } + if (!__pyx_t_2) { PyErr_SetString(PyExc_SystemError, "super(): empty __class__ cell"); __PYX_ERR(1, 70, __pyx_L1_error) } __Pyx_INCREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 69, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 70, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); @@ -5001,10 +5160,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_be __Pyx_GIVEREF(__pyx_v_self); PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_self); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 69, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 70, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_before_get); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 69, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_before_get); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 70, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -5022,7 +5181,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_be #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[6] = {__pyx_t_2, __pyx_v_parser, __pyx_v_section, __pyx_v_option, __pyx_v_value, __pyx_v_defaults}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 5+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 69, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 5+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 70, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -5030,13 +5189,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_be #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[6] = {__pyx_t_2, __pyx_v_parser, __pyx_v_section, __pyx_v_option, __pyx_v_value, __pyx_v_defaults}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 5+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 69, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 5+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 70, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_5 = PyTuple_New(5+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 69, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(5+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 70, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (__pyx_t_2) { __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_2); __pyx_t_2 = NULL; @@ -5056,7 +5215,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_be __Pyx_INCREF(__pyx_v_defaults); __Pyx_GIVEREF(__pyx_v_defaults); PyTuple_SET_ITEM(__pyx_t_5, 4+__pyx_t_4, __pyx_v_defaults); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 69, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 70, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } @@ -5064,7 +5223,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_be __Pyx_DECREF_SET(__pyx_v_value, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":70 + /* "dependency_injector/providers.pyx":71 * def before_get(self, parser, section, option, value, defaults): * value = super().before_get(parser, section, option, value, defaults) * return os.path.expandvars(value) # <<<<<<<<<<<<<< @@ -5072,12 +5231,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_be * def _parse_ini_file(filepath): */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_os); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 70, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_os); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 71, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_path); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 70, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_path); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 71, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_expandvars); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 70, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_expandvars); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 71, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -5092,14 +5251,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_be } __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_5, __pyx_v_value) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_value); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 70, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 71, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":68 + /* "dependency_injector/providers.pyx":69 * """Interpolation which expands environment variables in values.""" * * def before_get(self, parser, section, option, value, defaults): # <<<<<<<<<<<<<< @@ -5122,7 +5281,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16EnvInterpolation_be return __pyx_r; } -/* "dependency_injector/providers.pyx":72 +/* "dependency_injector/providers.pyx":73 * return os.path.expandvars(value) * * def _parse_ini_file(filepath): # <<<<<<<<<<<<<< @@ -5158,21 +5317,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_2_parse_ini_file(CYTH int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_parse_ini_file", 0); - /* "dependency_injector/providers.pyx":73 + /* "dependency_injector/providers.pyx":74 * * def _parse_ini_file(filepath): * parser = iniconfigparser.ConfigParser(interpolation=EnvInterpolation()) # <<<<<<<<<<<<<< * parser.read(filepath) * return parser */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_iniconfigparser); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 73, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_iniconfigparser); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 74, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_ConfigParser); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 73, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_ConfigParser); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 74, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 73, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 74, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_EnvInterpolation); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 73, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_EnvInterpolation); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 74, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { @@ -5186,26 +5345,26 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_2_parse_ini_file(CYTH } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 73, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 74, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (PyDict_SetItem(__pyx_t_1, __pyx_n_s_interpolation, __pyx_t_3) < 0) __PYX_ERR(1, 73, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_1, __pyx_n_s_interpolation, __pyx_t_3) < 0) __PYX_ERR(1, 74, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 73, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 74, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_parser = __pyx_t_3; __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":74 + /* "dependency_injector/providers.pyx":75 * def _parse_ini_file(filepath): * parser = iniconfigparser.ConfigParser(interpolation=EnvInterpolation()) * parser.read(filepath) # <<<<<<<<<<<<<< * return parser * else: */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_read); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 74, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_read); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 75, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -5219,12 +5378,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_2_parse_ini_file(CYTH } __pyx_t_3 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_2, __pyx_v_filepath) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_filepath); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 74, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 75, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":75 + /* "dependency_injector/providers.pyx":76 * parser = iniconfigparser.ConfigParser(interpolation=EnvInterpolation()) * parser.read(filepath) * return parser # <<<<<<<<<<<<<< @@ -5236,7 +5395,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_2_parse_ini_file(CYTH __pyx_r = __pyx_v_parser; goto __pyx_L0; - /* "dependency_injector/providers.pyx":72 + /* "dependency_injector/providers.pyx":73 * return os.path.expandvars(value) * * def _parse_ini_file(filepath): # <<<<<<<<<<<<<< @@ -5260,7 +5419,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_2_parse_ini_file(CYTH return __pyx_r; } -/* "dependency_injector/providers.pyx":79 +/* "dependency_injector/providers.pyx":80 * import StringIO * * def _parse_ini_file(filepath): # <<<<<<<<<<<<<< @@ -5309,16 +5468,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_parse_ini_file", 0); - /* "dependency_injector/providers.pyx":80 + /* "dependency_injector/providers.pyx":81 * * def _parse_ini_file(filepath): * parser = iniconfigparser.ConfigParser() # <<<<<<<<<<<<<< * try: * with open(filepath) as config_file: */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_iniconfigparser); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 80, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_iniconfigparser); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 81, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ConfigParser); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 80, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ConfigParser); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 81, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -5333,13 +5492,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 80, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 81, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_v_parser = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":81 + /* "dependency_injector/providers.pyx":82 * def _parse_ini_file(filepath): * parser = iniconfigparser.ConfigParser() * try: # <<<<<<<<<<<<<< @@ -5355,7 +5514,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH __Pyx_XGOTREF(__pyx_t_6); /*try:*/ { - /* "dependency_injector/providers.pyx":82 + /* "dependency_injector/providers.pyx":83 * parser = iniconfigparser.ConfigParser() * try: * with open(filepath) as config_file: # <<<<<<<<<<<<<< @@ -5363,11 +5522,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH * except IOError: */ /*with:*/ { - __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_open, __pyx_v_filepath); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 82, __pyx_L3_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_open, __pyx_v_filepath); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 83, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 82, __pyx_L3_error) + __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 83, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_7); - __pyx_t_2 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 82, __pyx_L9_error) + __pyx_t_2 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 83, __pyx_L9_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -5381,7 +5540,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH } __pyx_t_3 = (__pyx_t_8) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_8) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 82, __pyx_L9_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 83, __pyx_L9_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __pyx_t_3; @@ -5399,22 +5558,22 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH __pyx_v_config_file = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":83 + /* "dependency_injector/providers.pyx":84 * try: * with open(filepath) as config_file: * config_string = os.path.expandvars(config_file.read()) # <<<<<<<<<<<<<< * except IOError: * return parser */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_os); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 83, __pyx_L13_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_os); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 84, __pyx_L13_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_path); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 83, __pyx_L13_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_path); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 84, __pyx_L13_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_expandvars); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 83, __pyx_L13_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_expandvars); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 84, __pyx_L13_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_config_file, __pyx_n_s_read); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 83, __pyx_L13_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_config_file, __pyx_n_s_read); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 84, __pyx_L13_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -5428,7 +5587,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH } __pyx_t_3 = (__pyx_t_12) ? __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_12) : __Pyx_PyObject_CallNoArg(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 83, __pyx_L13_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 84, __pyx_L13_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_t_8 = NULL; @@ -5444,13 +5603,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH __pyx_t_2 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_8, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_3); __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 83, __pyx_L13_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 84, __pyx_L13_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_config_string = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":82 + /* "dependency_injector/providers.pyx":83 * parser = iniconfigparser.ConfigParser() * try: * with open(filepath) as config_file: # <<<<<<<<<<<<<< @@ -5470,20 +5629,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; /*except:*/ { __Pyx_AddTraceback("dependency_injector.providers._parse_ini_file", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_2, &__pyx_t_1, &__pyx_t_3) < 0) __PYX_ERR(1, 82, __pyx_L15_except_error) + if (__Pyx_GetException(&__pyx_t_2, &__pyx_t_1, &__pyx_t_3) < 0) __PYX_ERR(1, 83, __pyx_L15_except_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_3); - __pyx_t_8 = PyTuple_Pack(3, __pyx_t_2, __pyx_t_1, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 82, __pyx_L15_except_error) + __pyx_t_8 = PyTuple_Pack(3, __pyx_t_2, __pyx_t_1, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 83, __pyx_L15_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 82, __pyx_L15_except_error) + if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 83, __pyx_L15_except_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_14 = __Pyx_PyObject_IsTrue(__pyx_t_13); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; - if (__pyx_t_14 < 0) __PYX_ERR(1, 82, __pyx_L15_except_error) + if (__pyx_t_14 < 0) __PYX_ERR(1, 83, __pyx_L15_except_error) __pyx_t_15 = ((!(__pyx_t_14 != 0)) != 0); if (__pyx_t_15) { __Pyx_GIVEREF(__pyx_t_2); @@ -5491,7 +5650,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ErrRestoreWithState(__pyx_t_2, __pyx_t_1, __pyx_t_3); __pyx_t_2 = 0; __pyx_t_1 = 0; __pyx_t_3 = 0; - __PYX_ERR(1, 82, __pyx_L15_except_error) + __PYX_ERR(1, 83, __pyx_L15_except_error) } __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -5517,7 +5676,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH if (__pyx_t_7) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 82, __pyx_L3_error) + if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 83, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } @@ -5532,7 +5691,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH __pyx_L22:; } - /* "dependency_injector/providers.pyx":81 + /* "dependency_injector/providers.pyx":82 * def _parse_ini_file(filepath): * parser = iniconfigparser.ConfigParser() * try: # <<<<<<<<<<<<<< @@ -5541,7 +5700,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH */ } - /* "dependency_injector/providers.pyx":87 + /* "dependency_injector/providers.pyx":88 * return parser * else: * parser.readfp(StringIO.StringIO(config_string)) # <<<<<<<<<<<<<< @@ -5549,14 +5708,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH * */ /*else:*/ { - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_readfp); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 87, __pyx_L5_except_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_readfp); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 88, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_StringIO); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 87, __pyx_L5_except_error) + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_StringIO); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 88, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_StringIO); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 87, __pyx_L5_except_error) + __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_StringIO); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 88, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_v_config_string)) { __Pyx_RaiseUnboundLocalError("config_string"); __PYX_ERR(1, 87, __pyx_L5_except_error) } + if (unlikely(!__pyx_v_config_string)) { __Pyx_RaiseUnboundLocalError("config_string"); __PYX_ERR(1, 88, __pyx_L5_except_error) } __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_12))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_12); @@ -5569,7 +5728,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH } __pyx_t_2 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_12, __pyx_t_8, __pyx_v_config_string) : __Pyx_PyObject_CallOneArg(__pyx_t_12, __pyx_v_config_string); __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 87, __pyx_L5_except_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 88, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __pyx_t_12 = NULL; @@ -5585,12 +5744,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH __pyx_t_3 = (__pyx_t_12) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_12, __pyx_t_2) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_2); __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 87, __pyx_L5_except_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 88, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":88 + /* "dependency_injector/providers.pyx":89 * else: * parser.readfp(StringIO.StringIO(config_string)) * return parser # <<<<<<<<<<<<<< @@ -5609,7 +5768,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":84 + /* "dependency_injector/providers.pyx":85 * with open(filepath) as config_file: * config_string = os.path.expandvars(config_file.read()) * except IOError: # <<<<<<<<<<<<<< @@ -5619,12 +5778,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH __pyx_t_16 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_IOError); if (__pyx_t_16) { __Pyx_AddTraceback("dependency_injector.providers._parse_ini_file", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_3, &__pyx_t_1, &__pyx_t_2) < 0) __PYX_ERR(1, 84, __pyx_L5_except_error) + if (__Pyx_GetException(&__pyx_t_3, &__pyx_t_1, &__pyx_t_2) < 0) __PYX_ERR(1, 85, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_2); - /* "dependency_injector/providers.pyx":85 + /* "dependency_injector/providers.pyx":86 * config_string = os.path.expandvars(config_file.read()) * except IOError: * return parser # <<<<<<<<<<<<<< @@ -5642,7 +5801,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH goto __pyx_L5_except_error; __pyx_L5_except_error:; - /* "dependency_injector/providers.pyx":81 + /* "dependency_injector/providers.pyx":82 * def _parse_ini_file(filepath): * parser = iniconfigparser.ConfigParser() * try: # <<<<<<<<<<<<<< @@ -5662,7 +5821,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH goto __pyx_L0; } - /* "dependency_injector/providers.pyx":79 + /* "dependency_injector/providers.pyx":80 * import StringIO * * def _parse_ini_file(filepath): # <<<<<<<<<<<<<< @@ -5688,7 +5847,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4_parse_ini_file(CYTH return __pyx_r; } -/* "dependency_injector/providers.pyx":147 +/* "dependency_injector/providers.pyx":153 * """ * * def __init__(self): # <<<<<<<<<<<<<< @@ -5727,14 +5886,14 @@ static int __pyx_pf_19dependency_injector_9providers_8Provider___init__(struct _ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":149 + /* "dependency_injector/providers.pyx":155 * def __init__(self): * """Initializer.""" * self.__overridden = tuple() # <<<<<<<<<<<<<< * self.__last_overriding = None - * super(Provider, self).__init__() + * self.__async_mode = ASYNC_MODE_UNDEFINED */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 149, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 155, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___overridden); @@ -5742,12 +5901,12 @@ static int __pyx_pf_19dependency_injector_9providers_8Provider___init__(struct _ __pyx_v_self->__pyx___overridden = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":150 + /* "dependency_injector/providers.pyx":156 * """Initializer.""" * self.__overridden = tuple() * self.__last_overriding = None # <<<<<<<<<<<<<< + * self.__async_mode = ASYNC_MODE_UNDEFINED * super(Provider, self).__init__() - * */ __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); @@ -5755,14 +5914,23 @@ static int __pyx_pf_19dependency_injector_9providers_8Provider___init__(struct _ __Pyx_DECREF(((PyObject *)__pyx_v_self->__pyx___last_overriding)); __pyx_v_self->__pyx___last_overriding = ((struct __pyx_obj_19dependency_injector_9providers_Provider *)Py_None); - /* "dependency_injector/providers.pyx":151 + /* "dependency_injector/providers.pyx":157 * self.__overridden = tuple() * self.__last_overriding = None + * self.__async_mode = ASYNC_MODE_UNDEFINED # <<<<<<<<<<<<<< + * super(Provider, self).__init__() + * + */ + __pyx_v_self->__pyx___async_mode = __pyx_v_19dependency_injector_9providers_ASYNC_MODE_UNDEFINED; + + /* "dependency_injector/providers.pyx":158 + * self.__last_overriding = None + * self.__async_mode = ASYNC_MODE_UNDEFINED * super(Provider, self).__init__() # <<<<<<<<<<<<<< * * def __call__(self, *args, **kwargs): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 151, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 158, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider)); @@ -5770,10 +5938,10 @@ static int __pyx_pf_19dependency_injector_9providers_8Provider___init__(struct _ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 151, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 158, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 151, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 158, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -5788,12 +5956,12 @@ static int __pyx_pf_19dependency_injector_9providers_8Provider___init__(struct _ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 151, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 158, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":147 + /* "dependency_injector/providers.pyx":153 * """ * * def __init__(self): # <<<<<<<<<<<<<< @@ -5815,7 +5983,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Provider___init__(struct _ return __pyx_r; } -/* "dependency_injector/providers.pyx":153 +/* "dependency_injector/providers.pyx":160 * super(Provider, self).__init__() * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -5850,65 +6018,378 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_3__call__(P } static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_2__call__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs) { + PyObject *__pyx_v_result = NULL; + PyObject *__pyx_v_future_result = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; int __pyx_t_2; PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__call__", 0); - /* "dependency_injector/providers.pyx":158 + /* "dependency_injector/providers.pyx":165 * Callable interface implementation. * """ * if self.__last_overriding is not None: # <<<<<<<<<<<<<< - * return self.__last_overriding(*args, **kwargs) - * return self._provide(args, kwargs) + * result = self.__last_overriding(*args, **kwargs) + * else: */ __pyx_t_1 = (((PyObject *)__pyx_v_self->__pyx___last_overriding) != Py_None); __pyx_t_2 = (__pyx_t_1 != 0); if (__pyx_t_2) { - /* "dependency_injector/providers.pyx":159 + /* "dependency_injector/providers.pyx":166 * """ * if self.__last_overriding is not None: - * return self.__last_overriding(*args, **kwargs) # <<<<<<<<<<<<<< - * return self._provide(args, kwargs) - * + * result = self.__last_overriding(*args, **kwargs) # <<<<<<<<<<<<<< + * else: + * result = self._provide(args, kwargs) */ - __Pyx_XDECREF(__pyx_r); - __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx___last_overriding), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 159, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx___last_overriding), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 166, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_r = __pyx_t_3; + __pyx_v_result = __pyx_t_3; __pyx_t_3 = 0; - goto __pyx_L0; - /* "dependency_injector/providers.pyx":158 + /* "dependency_injector/providers.pyx":165 * Callable interface implementation. * """ * if self.__last_overriding is not None: # <<<<<<<<<<<<<< - * return self.__last_overriding(*args, **kwargs) - * return self._provide(args, kwargs) + * result = self.__last_overriding(*args, **kwargs) + * else: + */ + goto __pyx_L3; + } + + /* "dependency_injector/providers.pyx":168 + * result = self.__last_overriding(*args, **kwargs) + * else: + * result = self._provide(args, kwargs) # <<<<<<<<<<<<<< + * + * if self.is_async_mode_disabled(): + */ + /*else*/ { + __pyx_t_3 = ((struct __pyx_vtabstruct_19dependency_injector_9providers_Provider *)__pyx_v_self->__pyx_vtab)->_provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 168, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_v_result = __pyx_t_3; + __pyx_t_3 = 0; + } + __pyx_L3:; + + /* "dependency_injector/providers.pyx":170 + * result = self._provide(args, kwargs) + * + * if self.is_async_mode_disabled(): # <<<<<<<<<<<<<< + * return result + * elif self.is_async_mode_enabled(): + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_async_mode_disabled); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 170, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 170, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 170, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":171 + * + * if self.is_async_mode_disabled(): + * return result # <<<<<<<<<<<<<< + * elif self.is_async_mode_enabled(): + * if not __isawaitable(result): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_result); + __pyx_r = __pyx_v_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":170 + * result = self._provide(args, kwargs) + * + * if self.is_async_mode_disabled(): # <<<<<<<<<<<<<< + * return result + * elif self.is_async_mode_enabled(): + */ + } + + /* "dependency_injector/providers.pyx":172 + * if self.is_async_mode_disabled(): + * return result + * elif self.is_async_mode_enabled(): # <<<<<<<<<<<<<< + * if not __isawaitable(result): + * future_result = asyncio.Future() + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_async_mode_enabled); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 172, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 172, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 172, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":173 + * return result + * elif self.is_async_mode_enabled(): + * if not __isawaitable(result): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * future_result.set_result(result) + */ + __pyx_t_2 = ((!(__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_result) != 0)) != 0); + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":174 + * elif self.is_async_mode_enabled(): + * if not __isawaitable(result): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * future_result.set_result(result) + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 174, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_Future); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 174, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 174, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_future_result = __pyx_t_3; + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":175 + * if not __isawaitable(result): + * future_result = asyncio.Future() + * future_result.set_result(result) # <<<<<<<<<<<<<< + * return future_result + * return result + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 175, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 175, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":176 + * future_result = asyncio.Future() + * future_result.set_result(result) + * return future_result # <<<<<<<<<<<<<< + * return result + * elif self.is_async_mode_undefined(): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":173 + * return result + * elif self.is_async_mode_enabled(): + * if not __isawaitable(result): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * future_result.set_result(result) + */ + } + + /* "dependency_injector/providers.pyx":177 + * future_result.set_result(result) + * return future_result + * return result # <<<<<<<<<<<<<< + * elif self.is_async_mode_undefined(): + * if __isawaitable(result): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_result); + __pyx_r = __pyx_v_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":172 + * if self.is_async_mode_disabled(): + * return result + * elif self.is_async_mode_enabled(): # <<<<<<<<<<<<<< + * if not __isawaitable(result): + * future_result = asyncio.Future() + */ + } + + /* "dependency_injector/providers.pyx":178 + * return future_result + * return result + * elif self.is_async_mode_undefined(): # <<<<<<<<<<<<<< + * if __isawaitable(result): + * self.enable_async_mode() + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_async_mode_undefined); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 178, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 178, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 178, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":179 + * return result + * elif self.is_async_mode_undefined(): + * if __isawaitable(result): # <<<<<<<<<<<<<< + * self.enable_async_mode() + * else: + */ + __pyx_t_2 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_result) != 0); + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":180 + * elif self.is_async_mode_undefined(): + * if __isawaitable(result): + * self.enable_async_mode() # <<<<<<<<<<<<<< + * else: + * self.disable_async_mode() + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_enable_async_mode); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 180, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 180, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":179 + * return result + * elif self.is_async_mode_undefined(): + * if __isawaitable(result): # <<<<<<<<<<<<<< + * self.enable_async_mode() + * else: + */ + goto __pyx_L6; + } + + /* "dependency_injector/providers.pyx":182 + * self.enable_async_mode() + * else: + * self.disable_async_mode() # <<<<<<<<<<<<<< + * return result + * + */ + /*else*/ { + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_disable_async_mode); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 182, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 182, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + } + __pyx_L6:; + + /* "dependency_injector/providers.pyx":183 + * else: + * self.disable_async_mode() + * return result # <<<<<<<<<<<<<< + * + * def __deepcopy__(self, memo): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_result); + __pyx_r = __pyx_v_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":178 + * return future_result + * return result + * elif self.is_async_mode_undefined(): # <<<<<<<<<<<<<< + * if __isawaitable(result): + * self.enable_async_mode() */ } /* "dependency_injector/providers.pyx":160 - * if self.__last_overriding is not None: - * return self.__last_overriding(*args, **kwargs) - * return self._provide(args, kwargs) # <<<<<<<<<<<<<< - * - * def __deepcopy__(self, memo): - */ - __Pyx_XDECREF(__pyx_r); - __pyx_t_3 = ((struct __pyx_vtabstruct_19dependency_injector_9providers_Provider *)__pyx_v_self->__pyx_vtab)->_provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 160, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_r = __pyx_t_3; - __pyx_t_3 = 0; - goto __pyx_L0; - - /* "dependency_injector/providers.pyx":153 * super(Provider, self).__init__() * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -5917,18 +6398,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_2__call__(s */ /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __Pyx_AddTraceback("dependency_injector.providers.Provider.__call__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; + __Pyx_XDECREF(__pyx_v_result); + __Pyx_XDECREF(__pyx_v_future_result); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "dependency_injector/providers.pyx":162 - * return self._provide(args, kwargs) +/* "dependency_injector/providers.pyx":185 + * return result * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< * """Create and return full copy of provider.""" @@ -5964,16 +6451,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_4__deepcopy int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":164 + /* "dependency_injector/providers.pyx":187 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 164, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 187, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 164, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 187, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -5988,13 +6475,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_4__deepcopy __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 164, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 187, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":165 + /* "dependency_injector/providers.pyx":188 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -6005,7 +6492,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_4__deepcopy __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":166 + /* "dependency_injector/providers.pyx":189 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -6017,7 +6504,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_4__deepcopy __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":165 + /* "dependency_injector/providers.pyx":188 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -6026,14 +6513,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_4__deepcopy */ } - /* "dependency_injector/providers.pyx":168 + /* "dependency_injector/providers.pyx":191 * return copied * * copied = self.__class__() # <<<<<<<<<<<<<< * * self._copy_overridings(copied, memo) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 168, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 191, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -6047,24 +6534,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_4__deepcopy } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 168, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 191, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":170 + /* "dependency_injector/providers.pyx":193 * copied = self.__class__() * * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 170, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 170, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 193, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 193, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_Provider *)__pyx_v_self->__pyx_vtab)->_copy_overridings(__pyx_v_self, ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":172 + /* "dependency_injector/providers.pyx":195 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -6076,8 +6563,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_4__deepcopy __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":162 - * return self._provide(args, kwargs) + /* "dependency_injector/providers.pyx":185 + * return result * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< * """Create and return full copy of provider.""" @@ -6099,7 +6586,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_4__deepcopy return __pyx_r; } -/* "dependency_injector/providers.pyx":175 +/* "dependency_injector/providers.pyx":198 * * @classmethod * def __class_getitem__(cls, item): # <<<<<<<<<<<<<< @@ -6125,7 +6612,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_6__class_ge __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__class_getitem__", 0); - /* "dependency_injector/providers.pyx":176 + /* "dependency_injector/providers.pyx":199 * @classmethod * def __class_getitem__(cls, item): * return cls # <<<<<<<<<<<<<< @@ -6137,7 +6624,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_6__class_ge __pyx_r = ((PyObject *)__pyx_v_cls); goto __pyx_L0; - /* "dependency_injector/providers.pyx":175 + /* "dependency_injector/providers.pyx":198 * * @classmethod * def __class_getitem__(cls, item): # <<<<<<<<<<<<<< @@ -6152,7 +6639,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_6__class_ge return __pyx_r; } -/* "dependency_injector/providers.pyx":178 +/* "dependency_injector/providers.pyx":201 * return cls * * def __str__(self): # <<<<<<<<<<<<<< @@ -6186,7 +6673,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_8__str__(st int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":183 + /* "dependency_injector/providers.pyx":206 * :rtype: str * """ * return represent_provider(provider=self, provides=None) # <<<<<<<<<<<<<< @@ -6194,13 +6681,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_8__str__(st * def __repr__(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), Py_None, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 183, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), Py_None, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 206, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":178 + /* "dependency_injector/providers.pyx":201 * return cls * * def __str__(self): # <<<<<<<<<<<<<< @@ -6219,7 +6706,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_8__str__(st return __pyx_r; } -/* "dependency_injector/providers.pyx":185 +/* "dependency_injector/providers.pyx":208 * return represent_provider(provider=self, provides=None) * * def __repr__(self): # <<<<<<<<<<<<<< @@ -6255,7 +6742,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10__repr__( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__repr__", 0); - /* "dependency_injector/providers.pyx":190 + /* "dependency_injector/providers.pyx":213 * :rtype: str * """ * return self.__str__() # <<<<<<<<<<<<<< @@ -6263,7 +6750,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10__repr__( * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_str); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 190, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_str); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 213, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -6277,14 +6764,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10__repr__( } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 190, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 213, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":185 + /* "dependency_injector/providers.pyx":208 * return represent_provider(provider=self, provides=None) * * def __repr__(self): # <<<<<<<<<<<<<< @@ -6305,7 +6792,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10__repr__( return __pyx_r; } -/* "dependency_injector/providers.pyx":193 +/* "dependency_injector/providers.pyx":216 * * @property * def overridden(self): # <<<<<<<<<<<<<< @@ -6342,7 +6829,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10overridde int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":195 + /* "dependency_injector/providers.pyx":218 * def overridden(self): * """Return tuple of overriding providers.""" * with self.overriding_lock: # <<<<<<<<<<<<<< @@ -6350,11 +6837,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10overridde * */ /*with:*/ { - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_overriding_lock); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 195, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_overriding_lock); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 218, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 195, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 218, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 195, __pyx_L3_error) + __pyx_t_4 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 218, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -6368,7 +6855,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10overridde } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 195, __pyx_L3_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 218, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -6378,7 +6865,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10overridde (void)__pyx_t_6; (void)__pyx_t_7; (void)__pyx_t_8; /* mark used */ /*try:*/ { - /* "dependency_injector/providers.pyx":196 + /* "dependency_injector/providers.pyx":219 * """Return tuple of overriding providers.""" * with self.overriding_lock: * return self.__overridden # <<<<<<<<<<<<<< @@ -6390,7 +6877,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10overridde __pyx_r = __pyx_v_self->__pyx___overridden; goto __pyx_L11_try_return; - /* "dependency_injector/providers.pyx":195 + /* "dependency_injector/providers.pyx":218 * def overridden(self): * """Return tuple of overriding providers.""" * with self.overriding_lock: # <<<<<<<<<<<<<< @@ -6407,7 +6894,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10overridde if (__pyx_t_2) { __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 195, __pyx_L1_error) + if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 218, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } @@ -6419,7 +6906,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10overridde if (__pyx_t_2) { __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 195, __pyx_L1_error) + if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 218, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } @@ -6436,7 +6923,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10overridde __pyx_L13:; } - /* "dependency_injector/providers.pyx":193 + /* "dependency_injector/providers.pyx":216 * * @property * def overridden(self): # <<<<<<<<<<<<<< @@ -6460,7 +6947,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_10overridde return __pyx_r; } -/* "dependency_injector/providers.pyx":199 +/* "dependency_injector/providers.pyx":222 * * @property * def last_overriding(self): # <<<<<<<<<<<<<< @@ -6486,7 +6973,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_15last_over __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":204 + /* "dependency_injector/providers.pyx":227 * If provider is not overridden, then None is returned. * """ * return self.__last_overriding # <<<<<<<<<<<<<< @@ -6498,7 +6985,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_15last_over __pyx_r = ((PyObject *)__pyx_v_self->__pyx___last_overriding); goto __pyx_L0; - /* "dependency_injector/providers.pyx":199 + /* "dependency_injector/providers.pyx":222 * * @property * def last_overriding(self): # <<<<<<<<<<<<<< @@ -6513,7 +7000,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_15last_over return __pyx_r; } -/* "dependency_injector/providers.pyx":206 +/* "dependency_injector/providers.pyx":229 * return self.__last_overriding * * def override(self, provider): # <<<<<<<<<<<<<< @@ -6556,7 +7043,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __Pyx_RefNannySetupContext("override", 0); __Pyx_INCREF(__pyx_v_provider); - /* "dependency_injector/providers.pyx":217 + /* "dependency_injector/providers.pyx":240 * :rtype: :py:class:`OverridingContext` * """ * if provider is self: # <<<<<<<<<<<<<< @@ -6567,24 +7054,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":218 + /* "dependency_injector/providers.pyx":241 * """ * if provider is self: * raise Error('Provider {0} could not be overridden ' # <<<<<<<<<<<<<< * 'with itself'.format(self)) * */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 218, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 241, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/providers.pyx":219 + /* "dependency_injector/providers.pyx":242 * if provider is self: * raise Error('Provider {0} could not be overridden ' * 'with itself'.format(self)) # <<<<<<<<<<<<<< * * if not is_provider(provider): */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Provider_0_could_not_be_overridd, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 219, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Provider_0_could_not_be_overridd, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 242, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -6598,7 +7085,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, ((PyObject *)__pyx_v_self)) : __Pyx_PyObject_CallOneArg(__pyx_t_6, ((PyObject *)__pyx_v_self)); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 219, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 242, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -6614,14 +7101,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 218, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 241, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 218, __pyx_L1_error) + __PYX_ERR(1, 241, __pyx_L1_error) - /* "dependency_injector/providers.pyx":217 + /* "dependency_injector/providers.pyx":240 * :rtype: :py:class:`OverridingContext` * """ * if provider is self: # <<<<<<<<<<<<<< @@ -6630,7 +7117,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( */ } - /* "dependency_injector/providers.pyx":221 + /* "dependency_injector/providers.pyx":244 * 'with itself'.format(self)) * * if not is_provider(provider): # <<<<<<<<<<<<<< @@ -6640,19 +7127,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __pyx_t_2 = ((!(__pyx_f_19dependency_injector_9providers_is_provider(__pyx_v_provider, 0) != 0)) != 0); if (__pyx_t_2) { - /* "dependency_injector/providers.pyx":222 + /* "dependency_injector/providers.pyx":245 * * if not is_provider(provider): * provider = Object(provider) # <<<<<<<<<<<<<< * * with self.overriding_lock: */ - __pyx_t_3 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Object), __pyx_v_provider); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 222, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Object), __pyx_v_provider); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF_SET(__pyx_v_provider, __pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":221 + /* "dependency_injector/providers.pyx":244 * 'with itself'.format(self)) * * if not is_provider(provider): # <<<<<<<<<<<<<< @@ -6661,7 +7148,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( */ } - /* "dependency_injector/providers.pyx":224 + /* "dependency_injector/providers.pyx":247 * provider = Object(provider) * * with self.overriding_lock: # <<<<<<<<<<<<<< @@ -6669,11 +7156,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( * self.__last_overriding = provider */ /*with:*/ { - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_overriding_lock); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 224, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_overriding_lock); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 247, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_8 = __Pyx_PyObject_LookupSpecial(__pyx_t_3, __pyx_n_s_exit); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 224, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_LookupSpecial(__pyx_t_3, __pyx_n_s_exit); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 247, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_3, __pyx_n_s_enter); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 224, __pyx_L5_error) + __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_3, __pyx_n_s_enter); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 247, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { @@ -6687,7 +7174,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( } __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 224, __pyx_L5_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 247, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -6702,19 +7189,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { - /* "dependency_injector/providers.pyx":225 + /* "dependency_injector/providers.pyx":248 * * with self.overriding_lock: * self.__overridden += (provider,) # <<<<<<<<<<<<<< * self.__last_overriding = provider * */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 225, __pyx_L9_error) + __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 248, __pyx_L9_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v_provider); __Pyx_GIVEREF(__pyx_v_provider); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_provider); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___overridden, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 225, __pyx_L9_error) + __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___overridden, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 248, __pyx_L9_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GIVEREF(__pyx_t_4); @@ -6723,14 +7210,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __pyx_v_self->__pyx___overridden = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":226 + /* "dependency_injector/providers.pyx":249 * with self.overriding_lock: * self.__overridden += (provider,) * self.__last_overriding = provider # <<<<<<<<<<<<<< * * return OverridingContext(self, provider) */ - if (!(likely(((__pyx_v_provider) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 226, __pyx_L9_error) + if (!(likely(((__pyx_v_provider) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 249, __pyx_L9_error) __pyx_t_4 = __pyx_v_provider; __Pyx_INCREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); @@ -6739,7 +7226,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __pyx_v_self->__pyx___last_overriding = ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":224 + /* "dependency_injector/providers.pyx":247 * provider = Object(provider) * * with self.overriding_lock: # <<<<<<<<<<<<<< @@ -6759,20 +7246,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; /*except:*/ { __Pyx_AddTraceback("dependency_injector.providers.Provider.override", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_3, &__pyx_t_5) < 0) __PYX_ERR(1, 224, __pyx_L11_except_error) + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_3, &__pyx_t_5) < 0) __PYX_ERR(1, 247, __pyx_L11_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_3); __Pyx_GOTREF(__pyx_t_5); - __pyx_t_6 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_3, __pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 224, __pyx_L11_except_error) + __pyx_t_6 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_3, __pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 247, __pyx_L11_except_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_6, NULL); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 224, __pyx_L11_except_error) + if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 247, __pyx_L11_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_12); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; - if (__pyx_t_2 < 0) __PYX_ERR(1, 224, __pyx_L11_except_error) + if (__pyx_t_2 < 0) __PYX_ERR(1, 247, __pyx_L11_except_error) __pyx_t_1 = ((!(__pyx_t_2 != 0)) != 0); if (__pyx_t_1) { __Pyx_GIVEREF(__pyx_t_4); @@ -6780,7 +7267,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __Pyx_XGIVEREF(__pyx_t_5); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_3, __pyx_t_5); __pyx_t_4 = 0; __pyx_t_3 = 0; __pyx_t_5 = 0; - __PYX_ERR(1, 224, __pyx_L11_except_error) + __PYX_ERR(1, 247, __pyx_L11_except_error) } __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -6806,7 +7293,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( if (__pyx_t_8) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 224, __pyx_L1_error) + if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 247, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } @@ -6821,7 +7308,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __pyx_L18:; } - /* "dependency_injector/providers.pyx":228 + /* "dependency_injector/providers.pyx":251 * self.__last_overriding = provider * * return OverridingContext(self, provider) # <<<<<<<<<<<<<< @@ -6829,7 +7316,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( * def reset_last_overriding(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 228, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 251, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); @@ -6837,14 +7324,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( __Pyx_INCREF(__pyx_v_provider); __Pyx_GIVEREF(__pyx_v_provider); PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_v_provider); - __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_OverridingContext), __pyx_t_5, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 228, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_OverridingContext), __pyx_t_5, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 251, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":206 + /* "dependency_injector/providers.pyx":229 * return self.__last_overriding * * def override(self, provider): # <<<<<<<<<<<<<< @@ -6868,7 +7355,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_12override( return __pyx_r; } -/* "dependency_injector/providers.pyx":230 +/* "dependency_injector/providers.pyx":253 * return OverridingContext(self, provider) * * def reset_last_overriding(self): # <<<<<<<<<<<<<< @@ -6915,7 +7402,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_last_overriding", 0); - /* "dependency_injector/providers.pyx":238 + /* "dependency_injector/providers.pyx":261 * :rtype: None * """ * with self.overriding_lock: # <<<<<<<<<<<<<< @@ -6923,11 +7410,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las * raise Error('Provider {0} is not overridden'.format(str(self))) */ /*with:*/ { - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_overriding_lock); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 238, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_overriding_lock); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 238, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 238, __pyx_L3_error) + __pyx_t_4 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 261, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -6941,7 +7428,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 238, __pyx_L3_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 261, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -6956,7 +7443,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __Pyx_XGOTREF(__pyx_t_8); /*try:*/ { - /* "dependency_injector/providers.pyx":239 + /* "dependency_injector/providers.pyx":262 * """ * with self.overriding_lock: * if len(self.__overridden) == 0: # <<<<<<<<<<<<<< @@ -6967,25 +7454,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 239, __pyx_L7_error) + __PYX_ERR(1, 262, __pyx_L7_error) } - __pyx_t_9 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_9 == ((Py_ssize_t)-1))) __PYX_ERR(1, 239, __pyx_L7_error) + __pyx_t_9 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_9 == ((Py_ssize_t)-1))) __PYX_ERR(1, 262, __pyx_L7_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_10 = ((__pyx_t_9 == 0) != 0); if (unlikely(__pyx_t_10)) { - /* "dependency_injector/providers.pyx":240 + /* "dependency_injector/providers.pyx":263 * with self.overriding_lock: * if len(self.__overridden) == 0: * raise Error('Provider {0} is not overridden'.format(str(self))) # <<<<<<<<<<<<<< * * self.__overridden = self.__overridden[:-1] */ - __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_Error); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 240, __pyx_L7_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_Error); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 263, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Provider_0_is_not_overridden, __pyx_n_s_format); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 240, __pyx_L7_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Provider_0_is_not_overridden, __pyx_n_s_format); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 263, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_11 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyString_Type)), ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 240, __pyx_L7_error) + __pyx_t_11 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyString_Type)), ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 263, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_11); __pyx_t_12 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { @@ -7000,7 +7487,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __pyx_t_4 = (__pyx_t_12) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_12, __pyx_t_11) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_11); __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 240, __pyx_L7_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 263, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -7016,14 +7503,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 240, __pyx_L7_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 263, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 240, __pyx_L7_error) + __PYX_ERR(1, 263, __pyx_L7_error) - /* "dependency_injector/providers.pyx":239 + /* "dependency_injector/providers.pyx":262 * """ * with self.overriding_lock: * if len(self.__overridden) == 0: # <<<<<<<<<<<<<< @@ -7032,7 +7519,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las */ } - /* "dependency_injector/providers.pyx":242 + /* "dependency_injector/providers.pyx":265 * raise Error('Provider {0} is not overridden'.format(str(self))) * * self.__overridden = self.__overridden[:-1] # <<<<<<<<<<<<<< @@ -7041,9 +7528,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las */ if (unlikely(__pyx_v_self->__pyx___overridden == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 242, __pyx_L7_error) + __PYX_ERR(1, 265, __pyx_L7_error) } - __pyx_t_1 = __Pyx_PyTuple_GetSlice(__pyx_v_self->__pyx___overridden, 0, -1L); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 242, __pyx_L7_error) + __pyx_t_1 = __Pyx_PyTuple_GetSlice(__pyx_v_self->__pyx___overridden, 0, -1L); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 265, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___overridden); @@ -7051,7 +7538,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __pyx_v_self->__pyx___overridden = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":243 + /* "dependency_injector/providers.pyx":266 * * self.__overridden = self.__overridden[:-1] * try: # <<<<<<<<<<<<<< @@ -7067,7 +7554,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __Pyx_XGOTREF(__pyx_t_15); /*try:*/ { - /* "dependency_injector/providers.pyx":244 + /* "dependency_injector/providers.pyx":267 * self.__overridden = self.__overridden[:-1] * try: * self.__last_overriding = self.__overridden[-1] # <<<<<<<<<<<<<< @@ -7076,18 +7563,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las */ if (unlikely(__pyx_v_self->__pyx___overridden == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 244, __pyx_L14_error) + __PYX_ERR(1, 267, __pyx_L14_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___overridden, -1L, long, 1, __Pyx_PyInt_From_long, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 244, __pyx_L14_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___overridden, -1L, long, 1, __Pyx_PyInt_From_long, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 267, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 244, __pyx_L14_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 267, __pyx_L14_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___last_overriding); __Pyx_DECREF(((PyObject *)__pyx_v_self->__pyx___last_overriding)); __pyx_v_self->__pyx___last_overriding = ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":243 + /* "dependency_injector/providers.pyx":266 * * self.__overridden = self.__overridden[:-1] * try: # <<<<<<<<<<<<<< @@ -7107,7 +7594,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":245 + /* "dependency_injector/providers.pyx":268 * try: * self.__last_overriding = self.__overridden[-1] * except IndexError: # <<<<<<<<<<<<<< @@ -7117,12 +7604,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __pyx_t_16 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_IndexError); if (__pyx_t_16) { __Pyx_AddTraceback("dependency_injector.providers.Provider.reset_last_overriding", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_3, &__pyx_t_4) < 0) __PYX_ERR(1, 245, __pyx_L16_except_error) + if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_3, &__pyx_t_4) < 0) __PYX_ERR(1, 268, __pyx_L16_except_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_3); __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/providers.pyx":246 + /* "dependency_injector/providers.pyx":269 * self.__last_overriding = self.__overridden[-1] * except IndexError: * self.__last_overriding = None # <<<<<<<<<<<<<< @@ -7142,7 +7629,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las goto __pyx_L16_except_error; __pyx_L16_except_error:; - /* "dependency_injector/providers.pyx":243 + /* "dependency_injector/providers.pyx":266 * * self.__overridden = self.__overridden[:-1] * try: # <<<<<<<<<<<<<< @@ -7162,7 +7649,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __pyx_L19_try_end:; } - /* "dependency_injector/providers.pyx":238 + /* "dependency_injector/providers.pyx":261 * :rtype: None * """ * with self.overriding_lock: # <<<<<<<<<<<<<< @@ -7183,20 +7670,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; /*except:*/ { __Pyx_AddTraceback("dependency_injector.providers.Provider.reset_last_overriding", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_3, &__pyx_t_1) < 0) __PYX_ERR(1, 238, __pyx_L9_except_error) + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_3, &__pyx_t_1) < 0) __PYX_ERR(1, 261, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_3); __Pyx_GOTREF(__pyx_t_1); - __pyx_t_5 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_3, __pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 238, __pyx_L9_except_error) + __pyx_t_5 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_3, __pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 261, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 238, __pyx_L9_except_error) + if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 261, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_10 = __Pyx_PyObject_IsTrue(__pyx_t_15); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; - if (__pyx_t_10 < 0) __PYX_ERR(1, 238, __pyx_L9_except_error) + if (__pyx_t_10 < 0) __PYX_ERR(1, 261, __pyx_L9_except_error) __pyx_t_17 = ((!(__pyx_t_10 != 0)) != 0); if (__pyx_t_17) { __Pyx_GIVEREF(__pyx_t_4); @@ -7204,7 +7691,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __Pyx_XGIVEREF(__pyx_t_1); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_3, __pyx_t_1); __pyx_t_4 = 0; __pyx_t_3 = 0; __pyx_t_1 = 0; - __PYX_ERR(1, 238, __pyx_L9_except_error) + __PYX_ERR(1, 261, __pyx_L9_except_error) } __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -7230,7 +7717,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las if (__pyx_t_2) { __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 238, __pyx_L1_error) + if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } @@ -7245,7 +7732,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las __pyx_L25:; } - /* "dependency_injector/providers.pyx":230 + /* "dependency_injector/providers.pyx":253 * return OverridingContext(self, provider) * * def reset_last_overriding(self): # <<<<<<<<<<<<<< @@ -7271,7 +7758,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_14reset_las return __pyx_r; } -/* "dependency_injector/providers.pyx":248 +/* "dependency_injector/providers.pyx":271 * self.__last_overriding = None * * def reset_override(self): # <<<<<<<<<<<<<< @@ -7312,7 +7799,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_override", 0); - /* "dependency_injector/providers.pyx":253 + /* "dependency_injector/providers.pyx":276 * :rtype: None * """ * with self.overriding_lock: # <<<<<<<<<<<<<< @@ -7320,11 +7807,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove * self.__last_overriding = None */ /*with:*/ { - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_overriding_lock); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 253, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_overriding_lock); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 253, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 253, __pyx_L3_error) + __pyx_t_4 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 276, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -7338,7 +7825,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 253, __pyx_L3_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 276, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -7353,14 +7840,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove __Pyx_XGOTREF(__pyx_t_8); /*try:*/ { - /* "dependency_injector/providers.pyx":254 + /* "dependency_injector/providers.pyx":277 * """ * with self.overriding_lock: * self.__overridden = tuple() # <<<<<<<<<<<<<< * self.__last_overriding = None * */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 254, __pyx_L7_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 277, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___overridden); @@ -7368,12 +7855,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove __pyx_v_self->__pyx___overridden = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":255 + /* "dependency_injector/providers.pyx":278 * with self.overriding_lock: * self.__overridden = tuple() * self.__last_overriding = None # <<<<<<<<<<<<<< * - * def delegate(self): + * def async_(self, *args, **kwargs): */ __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); @@ -7381,7 +7868,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove __Pyx_DECREF(((PyObject *)__pyx_v_self->__pyx___last_overriding)); __pyx_v_self->__pyx___last_overriding = ((struct __pyx_obj_19dependency_injector_9providers_Provider *)Py_None); - /* "dependency_injector/providers.pyx":253 + /* "dependency_injector/providers.pyx":276 * :rtype: None * """ * with self.overriding_lock: # <<<<<<<<<<<<<< @@ -7400,20 +7887,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; /*except:*/ { __Pyx_AddTraceback("dependency_injector.providers.Provider.reset_override", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_3, &__pyx_t_4) < 0) __PYX_ERR(1, 253, __pyx_L9_except_error) + if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_3, &__pyx_t_4) < 0) __PYX_ERR(1, 276, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_3); __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = PyTuple_Pack(3, __pyx_t_1, __pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 253, __pyx_L9_except_error) + __pyx_t_5 = PyTuple_Pack(3, __pyx_t_1, __pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 276, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_9 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 253, __pyx_L9_except_error) + if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 276, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_10 = __Pyx_PyObject_IsTrue(__pyx_t_9); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - if (__pyx_t_10 < 0) __PYX_ERR(1, 253, __pyx_L9_except_error) + if (__pyx_t_10 < 0) __PYX_ERR(1, 276, __pyx_L9_except_error) __pyx_t_11 = ((!(__pyx_t_10 != 0)) != 0); if (__pyx_t_11) { __Pyx_GIVEREF(__pyx_t_1); @@ -7421,7 +7908,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove __Pyx_XGIVEREF(__pyx_t_4); __Pyx_ErrRestoreWithState(__pyx_t_1, __pyx_t_3, __pyx_t_4); __pyx_t_1 = 0; __pyx_t_3 = 0; __pyx_t_4 = 0; - __PYX_ERR(1, 253, __pyx_L9_except_error) + __PYX_ERR(1, 276, __pyx_L9_except_error) } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -7447,7 +7934,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove if (__pyx_t_2) { __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 253, __pyx_L1_error) + if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } @@ -7462,7 +7949,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove __pyx_L16:; } - /* "dependency_injector/providers.pyx":248 + /* "dependency_injector/providers.pyx":271 * self.__last_overriding = None * * def reset_override(self): # <<<<<<<<<<<<<< @@ -7486,29 +7973,111 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_16reset_ove return __pyx_r; } -/* "dependency_injector/providers.pyx":257 +/* "dependency_injector/providers.pyx":280 * self.__last_overriding = None * + * def async_(self, *args, **kwargs): # <<<<<<<<<<<<<< + * """Return provided object asynchronously. + * + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_19async_(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_8Provider_18async_[] = "Return provided object asynchronously.\n\n This method is a synonym of __call__().\n It provides typing stubs for correct type checking with\n `await` expression:\n\n .. code-block:: python\n\n database_provider: Provider[DatabaseConnection] = Resource(init_db_async)\n\n async def main():\n db: DatabaseConnection = await database_provider.async_()\n ...\n "; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_19async_(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_args = 0; + PyObject *__pyx_v_kwargs = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("async_ (wrapper)", 0); + if (unlikely(__pyx_kwds) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "async_", 1))) return NULL; + if (unlikely(__pyx_kwds)) { + __pyx_v_kwargs = PyDict_Copy(__pyx_kwds); if (unlikely(!__pyx_v_kwargs)) return NULL; + __Pyx_GOTREF(__pyx_v_kwargs); + } else { + __pyx_v_kwargs = NULL; + } + __Pyx_INCREF(__pyx_args); + __pyx_v_args = __pyx_args; + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_18async_(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); + + /* function exit code */ + __Pyx_XDECREF(__pyx_v_args); + __Pyx_XDECREF(__pyx_v_kwargs); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_18async_(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("async_", 0); + + /* "dependency_injector/providers.pyx":295 + * ... + * """ + * return self.__call__(*args, **kwargs) # <<<<<<<<<<<<<< + * + * def delegate(self): + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 295, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 295, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":280 + * self.__last_overriding = None + * + * def async_(self, *args, **kwargs): # <<<<<<<<<<<<<< + * """Return provided object asynchronously. + * + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_AddTraceback("dependency_injector.providers.Provider.async_", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":297 + * return self.__call__(*args, **kwargs) + * * def delegate(self): # <<<<<<<<<<<<<< * """Return provider's delegate. * */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_19delegate(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ -static char __pyx_doc_19dependency_injector_9providers_8Provider_18delegate[] = "Return provider's delegate.\n\n :rtype: :py:class:`Delegate`\n "; -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_19delegate(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_21delegate(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_8Provider_20delegate[] = "Return provider's delegate.\n\n :rtype: :py:class:`Delegate`\n "; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_21delegate(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("delegate (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_18delegate(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_20delegate(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_18delegate(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self) { +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_20delegate(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -7519,44 +8088,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_18delegate( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("delegate", 0); - /* "dependency_injector/providers.pyx":262 + /* "dependency_injector/providers.pyx":302 * :rtype: :py:class:`Delegate` * """ * warnings.warn( # <<<<<<<<<<<<<< * 'Method ".delegate()" is deprecated since version 4.0.0. ' * 'Use ".provider" attribute instead.', */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_warnings); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 262, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_warnings); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 302, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_warn); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 262, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_warn); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 302, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":265 + /* "dependency_injector/providers.pyx":305 * 'Method ".delegate()" is deprecated since version 4.0.0. ' * 'Use ".provider" attribute instead.', * category=DeprecationWarning, # <<<<<<<<<<<<<< * ) * return Delegate(self) */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 265, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 305, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_t_1, __pyx_n_s_category, __pyx_builtin_DeprecationWarning) < 0) __PYX_ERR(1, 265, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_1, __pyx_n_s_category, __pyx_builtin_DeprecationWarning) < 0) __PYX_ERR(1, 305, __pyx_L1_error) - /* "dependency_injector/providers.pyx":262 + /* "dependency_injector/providers.pyx":302 * :rtype: :py:class:`Delegate` * """ * warnings.warn( # <<<<<<<<<<<<<< * 'Method ".delegate()" is deprecated since version 4.0.0. ' * 'Use ".provider" attribute instead.', */ - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__3, __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 262, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__3, __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 302, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":267 + /* "dependency_injector/providers.pyx":307 * category=DeprecationWarning, * ) * return Delegate(self) # <<<<<<<<<<<<<< @@ -7564,14 +8133,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_18delegate( * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Delegate), ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 267, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Delegate), ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 307, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":257 - * self.__last_overriding = None + /* "dependency_injector/providers.pyx":297 + * return self.__call__(*args, **kwargs) * * def delegate(self): # <<<<<<<<<<<<<< * """Return provider's delegate. @@ -7591,7 +8160,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_18delegate( return __pyx_r; } -/* "dependency_injector/providers.pyx":270 +/* "dependency_injector/providers.pyx":310 * * @property * def provider(self): # <<<<<<<<<<<<<< @@ -7621,7 +8190,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_8provider__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":275 + /* "dependency_injector/providers.pyx":315 * :rtype: :py:class:`Delegate` * """ * return Delegate(self) # <<<<<<<<<<<<<< @@ -7629,13 +8198,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_8provider__ * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Delegate), ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 275, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Delegate), ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 315, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":270 + /* "dependency_injector/providers.pyx":310 * * @property * def provider(self): # <<<<<<<<<<<<<< @@ -7654,7 +8223,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_8provider__ return __pyx_r; } -/* "dependency_injector/providers.pyx":278 +/* "dependency_injector/providers.pyx":318 * * @property * def provided(self): # <<<<<<<<<<<<<< @@ -7684,21 +8253,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_8provided__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":280 + /* "dependency_injector/providers.pyx":320 * def provided(self): * """Return :py:class:`ProvidedInstance` provider.""" * return ProvidedInstance(self) # <<<<<<<<<<<<<< * - * cpdef object _provide(self, tuple args, dict kwargs): + * def enable_async_mode(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ProvidedInstance), ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 280, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ProvidedInstance), ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 320, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":278 + /* "dependency_injector/providers.pyx":318 * * @property * def provided(self): # <<<<<<<<<<<<<< @@ -7717,15 +8286,360 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_8provided__ return __pyx_r; } -/* "dependency_injector/providers.pyx":282 +/* "dependency_injector/providers.pyx":322 * return ProvidedInstance(self) * + * def enable_async_mode(self): # <<<<<<<<<<<<<< + * """Enable async mode.""" + * self.__async_mode = ASYNC_MODE_ENABLED + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_23enable_async_mode(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_8Provider_22enable_async_mode[] = "Enable async mode."; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_23enable_async_mode(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("enable_async_mode (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_22enable_async_mode(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_22enable_async_mode(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("enable_async_mode", 0); + + /* "dependency_injector/providers.pyx":324 + * def enable_async_mode(self): + * """Enable async mode.""" + * self.__async_mode = ASYNC_MODE_ENABLED # <<<<<<<<<<<<<< + * + * def disable_async_mode(self): + */ + __pyx_v_self->__pyx___async_mode = __pyx_v_19dependency_injector_9providers_ASYNC_MODE_ENABLED; + + /* "dependency_injector/providers.pyx":322 + * return ProvidedInstance(self) + * + * def enable_async_mode(self): # <<<<<<<<<<<<<< + * """Enable async mode.""" + * self.__async_mode = ASYNC_MODE_ENABLED + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":326 + * self.__async_mode = ASYNC_MODE_ENABLED + * + * def disable_async_mode(self): # <<<<<<<<<<<<<< + * """Disable async mode.""" + * self.__async_mode = ASYNC_MODE_DISABLED + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_25disable_async_mode(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_8Provider_24disable_async_mode[] = "Disable async mode."; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_25disable_async_mode(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("disable_async_mode (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_24disable_async_mode(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24disable_async_mode(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("disable_async_mode", 0); + + /* "dependency_injector/providers.pyx":328 + * def disable_async_mode(self): + * """Disable async mode.""" + * self.__async_mode = ASYNC_MODE_DISABLED # <<<<<<<<<<<<<< + * + * def reset_async_mode(self): + */ + __pyx_v_self->__pyx___async_mode = __pyx_v_19dependency_injector_9providers_ASYNC_MODE_DISABLED; + + /* "dependency_injector/providers.pyx":326 + * self.__async_mode = ASYNC_MODE_ENABLED + * + * def disable_async_mode(self): # <<<<<<<<<<<<<< + * """Disable async mode.""" + * self.__async_mode = ASYNC_MODE_DISABLED + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":330 + * self.__async_mode = ASYNC_MODE_DISABLED + * + * def reset_async_mode(self): # <<<<<<<<<<<<<< + * """Reset async mode. + * + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_27reset_async_mode(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_8Provider_26reset_async_mode[] = "Reset async mode.\n\n Provider will automatically set the mode on the next call.\n "; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_27reset_async_mode(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("reset_async_mode (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_26reset_async_mode(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_26reset_async_mode(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("reset_async_mode", 0); + + /* "dependency_injector/providers.pyx":335 + * Provider will automatically set the mode on the next call. + * """ + * self.__async_mode = ASYNC_MODE_UNDEFINED # <<<<<<<<<<<<<< + * + * def is_async_mode_enabled(self): + */ + __pyx_v_self->__pyx___async_mode = __pyx_v_19dependency_injector_9providers_ASYNC_MODE_UNDEFINED; + + /* "dependency_injector/providers.pyx":330 + * self.__async_mode = ASYNC_MODE_DISABLED + * + * def reset_async_mode(self): # <<<<<<<<<<<<<< + * """Reset async mode. + * + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":337 + * self.__async_mode = ASYNC_MODE_UNDEFINED + * + * def is_async_mode_enabled(self): # <<<<<<<<<<<<<< + * """Check if async mode is enabled.""" + * return self.__async_mode == ASYNC_MODE_ENABLED + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_29is_async_mode_enabled(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_8Provider_28is_async_mode_enabled[] = "Check if async mode is enabled."; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_29is_async_mode_enabled(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("is_async_mode_enabled (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_28is_async_mode_enabled(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_28is_async_mode_enabled(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("is_async_mode_enabled", 0); + + /* "dependency_injector/providers.pyx":339 + * def is_async_mode_enabled(self): + * """Check if async mode is enabled.""" + * return self.__async_mode == ASYNC_MODE_ENABLED # <<<<<<<<<<<<<< + * + * def is_async_mode_disabled(self): + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_1 = __Pyx_PyBool_FromLong((__pyx_v_self->__pyx___async_mode == __pyx_v_19dependency_injector_9providers_ASYNC_MODE_ENABLED)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 339, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":337 + * self.__async_mode = ASYNC_MODE_UNDEFINED + * + * def is_async_mode_enabled(self): # <<<<<<<<<<<<<< + * """Check if async mode is enabled.""" + * return self.__async_mode == ASYNC_MODE_ENABLED + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_AddTraceback("dependency_injector.providers.Provider.is_async_mode_enabled", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":341 + * return self.__async_mode == ASYNC_MODE_ENABLED + * + * def is_async_mode_disabled(self): # <<<<<<<<<<<<<< + * """Check if async mode is disabled.""" + * return self.__async_mode == ASYNC_MODE_DISABLED + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_31is_async_mode_disabled(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_8Provider_30is_async_mode_disabled[] = "Check if async mode is disabled."; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_31is_async_mode_disabled(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("is_async_mode_disabled (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_30is_async_mode_disabled(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_30is_async_mode_disabled(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("is_async_mode_disabled", 0); + + /* "dependency_injector/providers.pyx":343 + * def is_async_mode_disabled(self): + * """Check if async mode is disabled.""" + * return self.__async_mode == ASYNC_MODE_DISABLED # <<<<<<<<<<<<<< + * + * def is_async_mode_undefined(self): + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_1 = __Pyx_PyBool_FromLong((__pyx_v_self->__pyx___async_mode == __pyx_v_19dependency_injector_9providers_ASYNC_MODE_DISABLED)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 343, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":341 + * return self.__async_mode == ASYNC_MODE_ENABLED + * + * def is_async_mode_disabled(self): # <<<<<<<<<<<<<< + * """Check if async mode is disabled.""" + * return self.__async_mode == ASYNC_MODE_DISABLED + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_AddTraceback("dependency_injector.providers.Provider.is_async_mode_disabled", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":345 + * return self.__async_mode == ASYNC_MODE_DISABLED + * + * def is_async_mode_undefined(self): # <<<<<<<<<<<<<< + * """Check if async mode is undefined.""" + * return self.__async_mode == ASYNC_MODE_UNDEFINED + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_33is_async_mode_undefined(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_8Provider_32is_async_mode_undefined[] = "Check if async mode is undefined."; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_33is_async_mode_undefined(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("is_async_mode_undefined (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_32is_async_mode_undefined(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_32is_async_mode_undefined(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("is_async_mode_undefined", 0); + + /* "dependency_injector/providers.pyx":347 + * def is_async_mode_undefined(self): + * """Check if async mode is undefined.""" + * return self.__async_mode == ASYNC_MODE_UNDEFINED # <<<<<<<<<<<<<< + * + * cpdef object _provide(self, tuple args, dict kwargs): + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_1 = __Pyx_PyBool_FromLong((__pyx_v_self->__pyx___async_mode == __pyx_v_19dependency_injector_9providers_ASYNC_MODE_UNDEFINED)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 347, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":345 + * return self.__async_mode == ASYNC_MODE_DISABLED + * + * def is_async_mode_undefined(self): # <<<<<<<<<<<<<< + * """Check if async mode is undefined.""" + * return self.__async_mode == ASYNC_MODE_UNDEFINED + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_AddTraceback("dependency_injector.providers.Provider.is_async_mode_undefined", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":349 + * return self.__async_mode == ASYNC_MODE_UNDEFINED + * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * """Providing strategy implementation. * */ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_21_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_35_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_8Provider__provide(CYTHON_UNUSED struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_args, CYTHON_UNUSED PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations @@ -7748,9 +8662,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Provider__provide(CYT if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 282, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 349, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_8Provider_21_provide)) { + if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_8Provider_35_provide)) { __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_t_1); __pyx_t_3 = __pyx_t_1; __pyx_t_4 = NULL; @@ -7768,7 +8682,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Provider__provide(CYT #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 282, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 349, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -7776,13 +8690,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Provider__provide(CYT #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 282, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 349, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 282, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 349, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -7793,7 +8707,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Provider__provide(CYT __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 282, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 349, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -7816,21 +8730,21 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Provider__provide(CYT #endif } - /* "dependency_injector/providers.pyx":289 + /* "dependency_injector/providers.pyx":356 * overridden provider is called. Need to be overridden in subclasses. * """ * raise NotImplementedError() # <<<<<<<<<<<<<< * * cpdef void _copy_overridings(self, Provider copied, dict memo): */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_builtin_NotImplementedError); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 289, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_builtin_NotImplementedError); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 356, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 289, __pyx_L1_error) + __PYX_ERR(1, 356, __pyx_L1_error) - /* "dependency_injector/providers.pyx":282 - * return ProvidedInstance(self) + /* "dependency_injector/providers.pyx":349 + * return self.__async_mode == ASYNC_MODE_UNDEFINED * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * """Providing strategy implementation. @@ -7853,9 +8767,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Provider__provide(CYT } /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_21_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static char __pyx_doc_19dependency_injector_9providers_8Provider_20_provide[] = "Providing strategy implementation.\n\n Abstract protected method that implements providing strategy of\n particular provider. Current method is called every time when not\n overridden provider is called. Need to be overridden in subclasses.\n "; -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_21_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_35_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_8Provider_34_provide[] = "Providing strategy implementation.\n\n Abstract protected method that implements providing strategy of\n particular provider. Current method is called every time when not\n overridden provider is called. Need to be overridden in subclasses.\n "; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_35_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_args = 0; PyObject *__pyx_v_kwargs = 0; int __pyx_lineno = 0; @@ -7887,11 +8801,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_21_provide( case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 282, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 349, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 282, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 349, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -7904,15 +8818,15 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_21_provide( } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 282, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 349, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Provider._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 282, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 282, __pyx_L1_error) - __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_20_provide(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 349, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 349, __pyx_L1_error) + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_34_provide(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ goto __pyx_L0; @@ -7923,7 +8837,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_21_provide( return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_20_provide(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs) { +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_34_provide(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -7932,7 +8846,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_20_provide( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_8Provider__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 282, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_8Provider__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 349, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -7949,7 +8863,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_20_provide( return __pyx_r; } -/* "dependency_injector/providers.pyx":291 +/* "dependency_injector/providers.pyx":358 * raise NotImplementedError() * * cpdef void _copy_overridings(self, Provider copied, dict memo): # <<<<<<<<<<<<<< @@ -7957,7 +8871,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_20_provide( * copied.__overridden = deepcopy(self.__overridden, memo) */ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_23_copy_overridings(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_37_copy_overridings(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static void __pyx_f_19dependency_injector_9providers_8Provider__copy_overridings(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_copied, PyObject *__pyx_v_memo, int __pyx_skip_dispatch) { __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -7980,9 +8894,9 @@ static void __pyx_f_19dependency_injector_9providers_8Provider__copy_overridings if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_copy_overridings); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 291, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_copy_overridings); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 358, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_8Provider_23_copy_overridings)) { + if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_8Provider_37_copy_overridings)) { __Pyx_INCREF(__pyx_t_1); __pyx_t_3 = __pyx_t_1; __pyx_t_4 = NULL; __pyx_t_5 = 0; @@ -7999,7 +8913,7 @@ static void __pyx_f_19dependency_injector_9providers_8Provider__copy_overridings #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_copied), __pyx_v_memo}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 291, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 358, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -8007,13 +8921,13 @@ static void __pyx_f_19dependency_injector_9providers_8Provider__copy_overridings #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_copied), __pyx_v_memo}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 291, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 358, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 291, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 358, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -8024,7 +8938,7 @@ static void __pyx_f_19dependency_injector_9providers_8Provider__copy_overridings __Pyx_INCREF(__pyx_v_memo); __Pyx_GIVEREF(__pyx_v_memo); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_memo); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 291, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 358, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -8046,7 +8960,7 @@ static void __pyx_f_19dependency_injector_9providers_8Provider__copy_overridings #endif } - /* "dependency_injector/providers.pyx":293 + /* "dependency_injector/providers.pyx":360 * cpdef void _copy_overridings(self, Provider copied, dict memo): * """Copy provider overridings to a newly copied provider.""" * copied.__overridden = deepcopy(self.__overridden, memo) # <<<<<<<<<<<<<< @@ -8057,17 +8971,17 @@ static void __pyx_f_19dependency_injector_9providers_8Provider__copy_overridings __Pyx_INCREF(__pyx_t_1); __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = __pyx_v_memo; - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 293, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 360, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (!(likely(PyTuple_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_2)->tp_name), 0))) __PYX_ERR(1, 293, __pyx_L1_error) + if (!(likely(PyTuple_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_2)->tp_name), 0))) __PYX_ERR(1, 360, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_2); __Pyx_GOTREF(__pyx_v_copied->__pyx___overridden); __Pyx_DECREF(__pyx_v_copied->__pyx___overridden); __pyx_v_copied->__pyx___overridden = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":294 + /* "dependency_injector/providers.pyx":361 * """Copy provider overridings to a newly copied provider.""" * copied.__overridden = deepcopy(self.__overridden, memo) * copied.__last_overriding = deepcopy(self.__last_overriding, memo) # <<<<<<<<<<<<<< @@ -8078,17 +8992,17 @@ static void __pyx_f_19dependency_injector_9providers_8Provider__copy_overridings __Pyx_INCREF(__pyx_t_2); __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = __pyx_v_memo; - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 294, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 361, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 294, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 361, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_copied->__pyx___last_overriding); __Pyx_DECREF(((PyObject *)__pyx_v_copied->__pyx___last_overriding)); __pyx_v_copied->__pyx___last_overriding = ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":291 + /* "dependency_injector/providers.pyx":358 * raise NotImplementedError() * * cpdef void _copy_overridings(self, Provider copied, dict memo): # <<<<<<<<<<<<<< @@ -8110,9 +9024,9 @@ static void __pyx_f_19dependency_injector_9providers_8Provider__copy_overridings } /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_23_copy_overridings(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static char __pyx_doc_19dependency_injector_9providers_8Provider_22_copy_overridings[] = "Copy provider overridings to a newly copied provider."; -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_23_copy_overridings(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_37_copy_overridings(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_8Provider_36_copy_overridings[] = "Copy provider overridings to a newly copied provider."; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_37_copy_overridings(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_copied = 0; PyObject *__pyx_v_memo = 0; int __pyx_lineno = 0; @@ -8144,11 +9058,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_23_copy_ove case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_memo)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_copy_overridings", 1, 2, 2, 1); __PYX_ERR(1, 291, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_copy_overridings", 1, 2, 2, 1); __PYX_ERR(1, 358, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_copy_overridings") < 0)) __PYX_ERR(1, 291, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_copy_overridings") < 0)) __PYX_ERR(1, 358, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -8161,15 +9075,15 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_23_copy_ove } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_copy_overridings", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 291, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_copy_overridings", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 358, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Provider._copy_overridings", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_copied), __pyx_ptype_19dependency_injector_9providers_Provider, 1, "copied", 0))) __PYX_ERR(1, 291, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_memo), (&PyDict_Type), 1, "memo", 1))) __PYX_ERR(1, 291, __pyx_L1_error) - __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_22_copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), __pyx_v_copied, __pyx_v_memo); + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_copied), __pyx_ptype_19dependency_injector_9providers_Provider, 1, "copied", 0))) __PYX_ERR(1, 358, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_memo), (&PyDict_Type), 1, "memo", 1))) __PYX_ERR(1, 358, __pyx_L1_error) + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_36_copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), __pyx_v_copied, __pyx_v_memo); /* function exit code */ goto __pyx_L0; @@ -8180,7 +9094,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_23_copy_ove return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_22_copy_overridings(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_copied, PyObject *__pyx_v_memo) { +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_36_copy_overridings(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_copied, PyObject *__pyx_v_memo) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -8189,7 +9103,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_22_copy_ove int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_copy_overridings", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_void_to_None(__pyx_f_19dependency_injector_9providers_8Provider__copy_overridings(__pyx_v_self, __pyx_v_copied, __pyx_v_memo, 1)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 291, __pyx_L1_error) + __pyx_t_1 = __Pyx_void_to_None(__pyx_f_19dependency_injector_9providers_8Provider__copy_overridings(__pyx_v_self, __pyx_v_copied, __pyx_v_memo, 1)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 358, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -8213,28 +9127,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_22_copy_ove */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_25__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_25__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_39__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_39__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_38__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self) { +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_38__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self) { PyObject *__pyx_v_state = 0; PyObject *__pyx_v__dict = 0; int __pyx_v_use_setstate; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -8245,43 +9159,48 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx___overridden); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx___overridden); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -8290,16 +9209,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_ * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -8311,7 +9230,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -8325,21 +9244,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Provider, (type(self), 0x0f5c5dd, None), state + * return __pyx_unpickle_Provider, (type(self), 0xfeb8198, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - __pyx_t_3 = __pyx_t_2; + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -8347,44 +9266,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Provider, (type(self), 0x0f5c5dd, None), state + * return __pyx_unpickle_Provider, (type(self), 0xfeb8198, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__last_overriding is not None or self.__overridden is not None * if use_setstate: - * return __pyx_unpickle_Provider, (type(self), 0x0f5c5dd, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Provider, (type(self), 0xfeb8198, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Provider, (type(self), 0x0f5c5dd, state) + * return __pyx_unpickle_Provider, (type(self), 0xfeb8198, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Provider); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Provider); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_16106973); - __Pyx_GIVEREF(__pyx_int_16106973); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_16106973); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_267092376); + __Pyx_GIVEREF(__pyx_int_267092376); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_267092376); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -8393,15 +9312,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Provider, (type(self), 0x0f5c5dd, None), state + * return __pyx_unpickle_Provider, (type(self), 0xfeb8198, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Provider, (type(self), 0x0f5c5dd, None), state + * return __pyx_unpickle_Provider, (type(self), 0xfeb8198, None), state * else: - * return __pyx_unpickle_Provider, (type(self), 0x0f5c5dd, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Provider, (type(self), 0xfeb8198, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Provider__set_state(self, __pyx_state) */ @@ -8409,27 +9328,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_ __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_Provider); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_16106973); - __Pyx_GIVEREF(__pyx_int_16106973); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_16106973); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_267092376); + __Pyx_GIVEREF(__pyx_int_267092376); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_267092376); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -8442,7 +9361,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.Provider.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -8456,25 +9375,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_24__reduce_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Provider, (type(self), 0x0f5c5dd, state) + * return __pyx_unpickle_Provider, (type(self), 0xfeb8198, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Provider__set_state(self, __pyx_state) */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_27__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_27__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_41__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Provider_41__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_26__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Provider_40__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_26__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_40__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -8484,7 +9403,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_26__setstat __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Provider, (type(self), 0x0f5c5dd, state) + * return __pyx_unpickle_Provider, (type(self), 0xfeb8198, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Provider__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -8495,7 +9414,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_26__setstat /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Provider, (type(self), 0x0f5c5dd, state) + * return __pyx_unpickle_Provider, (type(self), 0xfeb8198, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Provider__set_state(self, __pyx_state) */ @@ -8513,7 +9432,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Provider_26__setstat return __pyx_r; } -/* "dependency_injector/providers.pyx":307 +/* "dependency_injector/providers.pyx":374 * """ * * def __init__(self, provides): # <<<<<<<<<<<<<< @@ -8554,7 +9473,7 @@ static int __pyx_pw_19dependency_injector_9providers_6Object_1__init__(PyObject else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 307, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 374, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -8565,7 +9484,7 @@ static int __pyx_pw_19dependency_injector_9providers_6Object_1__init__(PyObject } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 307, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 374, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Object.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -8589,7 +9508,7 @@ static int __pyx_pf_19dependency_injector_9providers_6Object___init__(struct __p int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":313 + /* "dependency_injector/providers.pyx":380 * :type provides: object * """ * self.__provides = provides # <<<<<<<<<<<<<< @@ -8602,14 +9521,14 @@ static int __pyx_pf_19dependency_injector_9providers_6Object___init__(struct __p __Pyx_DECREF(__pyx_v_self->__pyx___provides); __pyx_v_self->__pyx___provides = __pyx_v_provides; - /* "dependency_injector/providers.pyx":314 + /* "dependency_injector/providers.pyx":381 * """ * self.__provides = provides * super(Object, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 314, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 381, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Object)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Object)); @@ -8617,10 +9536,10 @@ static int __pyx_pf_19dependency_injector_9providers_6Object___init__(struct __p __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 314, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 381, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 314, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 381, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -8635,12 +9554,12 @@ static int __pyx_pf_19dependency_injector_9providers_6Object___init__(struct __p } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 314, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 381, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":307 + /* "dependency_injector/providers.pyx":374 * """ * * def __init__(self, provides): # <<<<<<<<<<<<<< @@ -8662,7 +9581,7 @@ static int __pyx_pf_19dependency_injector_9providers_6Object___init__(struct __p return __pyx_r; } -/* "dependency_injector/providers.pyx":316 +/* "dependency_injector/providers.pyx":383 * super(Object, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -8699,16 +9618,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_2__deepcopy__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":318 + /* "dependency_injector/providers.pyx":385 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 318, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 385, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 318, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 385, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -8723,13 +9642,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_2__deepcopy__ __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 318, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 385, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":319 + /* "dependency_injector/providers.pyx":386 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -8740,7 +9659,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_2__deepcopy__ __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":320 + /* "dependency_injector/providers.pyx":387 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -8752,7 +9671,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_2__deepcopy__ __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":319 + /* "dependency_injector/providers.pyx":386 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -8761,14 +9680,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_2__deepcopy__ */ } - /* "dependency_injector/providers.pyx":322 + /* "dependency_injector/providers.pyx":389 * return copied * * copied = self.__class__(self.__provides) # <<<<<<<<<<<<<< * * self._copy_overridings(copied, memo) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 322, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 389, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -8782,24 +9701,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_2__deepcopy__ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_self->__pyx___provides) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_self->__pyx___provides); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 322, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 389, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":324 + /* "dependency_injector/providers.pyx":391 * copied = self.__class__(self.__provides) * * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 324, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 324, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 391, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 391, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_Object *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":326 + /* "dependency_injector/providers.pyx":393 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -8811,7 +9730,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_2__deepcopy__ __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":316 + /* "dependency_injector/providers.pyx":383 * super(Object, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -8834,7 +9753,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_2__deepcopy__ return __pyx_r; } -/* "dependency_injector/providers.pyx":328 +/* "dependency_injector/providers.pyx":395 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -8869,7 +9788,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_4__str__(stru int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":333 + /* "dependency_injector/providers.pyx":400 * :rtype: str * """ * return represent_provider(provider=self, provides=self.__provides) # <<<<<<<<<<<<<< @@ -8879,14 +9798,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_4__str__(stru __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __pyx_v_self->__pyx___provides; __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 333, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 400, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":328 + /* "dependency_injector/providers.pyx":395 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -8906,7 +9825,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_4__str__(stru return __pyx_r; } -/* "dependency_injector/providers.pyx":335 +/* "dependency_injector/providers.pyx":402 * return represent_provider(provider=self, provides=self.__provides) * * def __repr__(self): # <<<<<<<<<<<<<< @@ -8942,7 +9861,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_6__repr__(str int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__repr__", 0); - /* "dependency_injector/providers.pyx":340 + /* "dependency_injector/providers.pyx":407 * :rtype: str * """ * return self.__str__() # <<<<<<<<<<<<<< @@ -8950,7 +9869,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_6__repr__(str * cpdef object _provide(self, tuple args, dict kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_str); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 340, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_str); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 407, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -8964,14 +9883,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_6__repr__(str } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 340, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 407, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":335 + /* "dependency_injector/providers.pyx":402 * return represent_provider(provider=self, provides=self.__provides) * * def __repr__(self): # <<<<<<<<<<<<<< @@ -8992,7 +9911,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_6__repr__(str return __pyx_r; } -/* "dependency_injector/providers.pyx":342 +/* "dependency_injector/providers.pyx":409 * return self.__str__() * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -9023,7 +9942,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_6Object__provide(struc if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 342, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 409, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_6Object_9_provide)) { __Pyx_XDECREF(__pyx_r); @@ -9043,7 +9962,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_6Object__provide(struc #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 342, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 409, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -9051,13 +9970,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_6Object__provide(struc #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 342, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 409, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 342, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 409, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -9068,7 +9987,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_6Object__provide(struc __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 342, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 409, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -9091,7 +10010,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_6Object__provide(struc #endif } - /* "dependency_injector/providers.pyx":353 + /* "dependency_injector/providers.pyx":420 * :rtype: object * """ * return self.__provides # <<<<<<<<<<<<<< @@ -9103,7 +10022,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_6Object__provide(struc __pyx_r = __pyx_v_self->__pyx___provides; goto __pyx_L0; - /* "dependency_injector/providers.pyx":342 + /* "dependency_injector/providers.pyx":409 * return self.__str__() * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -9161,11 +10080,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_6Object_9_provide(PyO case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 342, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 409, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 342, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 409, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -9178,14 +10097,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_6Object_9_provide(PyO } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 342, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 409, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Object._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 342, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 342, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 409, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 409, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_6Object_8_provide(((struct __pyx_obj_19dependency_injector_9providers_Object *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -9206,7 +10125,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_8_provide(str int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_6Object__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 342, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_6Object__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 409, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -9249,9 +10168,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_10__reduce_cy PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -9262,46 +10181,51 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_10__reduce_cy /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx___provides); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx___provides); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -9310,16 +10234,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_10__reduce_cy * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -9331,7 +10255,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_10__reduce_cy __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -9345,28 +10269,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_10__reduce_cy * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Object, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_Object, (type(self), 0x328787b, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx___provides != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx___provides != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -9374,44 +10298,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_10__reduce_cy * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Object, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_Object, (type(self), 0x328787b, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_Object, (type(self), 0x3f4a3b6, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Object, (type(self), 0x328787b, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Object, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_Object, (type(self), 0x328787b, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Object); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Object); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -9420,15 +10344,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_10__reduce_cy * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Object, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_Object, (type(self), 0x328787b, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Object, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_Object, (type(self), 0x328787b, None), state * else: - * return __pyx_unpickle_Object, (type(self), 0x3f4a3b6, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Object, (type(self), 0x328787b, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Object__set_state(self, __pyx_state) */ @@ -9436,27 +10360,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_10__reduce_cy __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_Object); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -9469,7 +10393,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_10__reduce_cy /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.Object.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -9483,7 +10407,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_10__reduce_cy /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Object, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_Object, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Object__set_state(self, __pyx_state) */ @@ -9511,7 +10435,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_12__setstate_ __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Object, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_Object, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Object__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -9522,7 +10446,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_12__setstate_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Object, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_Object, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Object__set_state(self, __pyx_state) */ @@ -9540,7 +10464,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6Object_12__setstate_ return __pyx_r; } -/* "dependency_injector/providers.pyx":366 +/* "dependency_injector/providers.pyx":433 * """ * * def __init__(self, provides): # <<<<<<<<<<<<<< @@ -9581,7 +10505,7 @@ static int __pyx_pw_19dependency_injector_9providers_8Delegate_1__init__(PyObjec else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 366, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 433, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -9592,7 +10516,7 @@ static int __pyx_pw_19dependency_injector_9providers_8Delegate_1__init__(PyObjec } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 366, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 433, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Delegate.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -9616,14 +10540,14 @@ static int __pyx_pf_19dependency_injector_9providers_8Delegate___init__(struct _ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":372 + /* "dependency_injector/providers.pyx":439 * :type provides: :py:class:`Provider` * """ * self.__provides = ensure_is_provider(provides) # <<<<<<<<<<<<<< * super(Delegate, self).__init__() * */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_ensure_is_provider(__pyx_v_provides, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 372, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_ensure_is_provider(__pyx_v_provides, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 439, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___provides); @@ -9631,14 +10555,14 @@ static int __pyx_pf_19dependency_injector_9providers_8Delegate___init__(struct _ __pyx_v_self->__pyx___provides = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":373 + /* "dependency_injector/providers.pyx":440 * """ * self.__provides = ensure_is_provider(provides) * super(Delegate, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 373, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 440, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Delegate)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Delegate)); @@ -9646,10 +10570,10 @@ static int __pyx_pf_19dependency_injector_9providers_8Delegate___init__(struct _ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 373, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 440, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 373, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 440, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -9664,12 +10588,12 @@ static int __pyx_pf_19dependency_injector_9providers_8Delegate___init__(struct _ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 373, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 440, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":366 + /* "dependency_injector/providers.pyx":433 * """ * * def __init__(self, provides): # <<<<<<<<<<<<<< @@ -9691,7 +10615,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Delegate___init__(struct _ return __pyx_r; } -/* "dependency_injector/providers.pyx":375 +/* "dependency_injector/providers.pyx":442 * super(Delegate, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -9729,16 +10653,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_2__deepcopy int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":377 + /* "dependency_injector/providers.pyx":444 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 377, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 444, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 377, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 444, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -9753,13 +10677,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_2__deepcopy __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 377, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 444, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":378 + /* "dependency_injector/providers.pyx":445 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -9770,7 +10694,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_2__deepcopy __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":379 + /* "dependency_injector/providers.pyx":446 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -9782,7 +10706,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_2__deepcopy __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":378 + /* "dependency_injector/providers.pyx":445 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -9791,21 +10715,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_2__deepcopy */ } - /* "dependency_injector/providers.pyx":381 + /* "dependency_injector/providers.pyx":448 * return copied * * copied = self.__class__(deepcopy(self.__provides, memo)) # <<<<<<<<<<<<<< * * self._copy_overridings(copied, memo) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 381, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = __pyx_v_self->__pyx___provides; __Pyx_INCREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 381, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 448, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 381, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -9821,24 +10745,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_2__deepcopy __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 381, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":383 + /* "dependency_injector/providers.pyx":450 * copied = self.__class__(deepcopy(self.__provides, memo)) * * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 383, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 383, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 450, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 450, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_Delegate *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":385 + /* "dependency_injector/providers.pyx":452 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -9850,7 +10774,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_2__deepcopy __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":375 + /* "dependency_injector/providers.pyx":442 * super(Delegate, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -9873,7 +10797,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_2__deepcopy return __pyx_r; } -/* "dependency_injector/providers.pyx":387 +/* "dependency_injector/providers.pyx":454 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -9908,7 +10832,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_4__str__(st int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":392 + /* "dependency_injector/providers.pyx":459 * :rtype: str * """ * return represent_provider(provider=self, provides=self.__provides) # <<<<<<<<<<<<<< @@ -9918,14 +10842,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_4__str__(st __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __pyx_v_self->__pyx___provides; __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 392, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 459, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":387 + /* "dependency_injector/providers.pyx":454 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -9945,7 +10869,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_4__str__(st return __pyx_r; } -/* "dependency_injector/providers.pyx":394 +/* "dependency_injector/providers.pyx":461 * return represent_provider(provider=self, provides=self.__provides) * * def __repr__(self): # <<<<<<<<<<<<<< @@ -9981,7 +10905,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_6__repr__(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__repr__", 0); - /* "dependency_injector/providers.pyx":399 + /* "dependency_injector/providers.pyx":466 * :rtype: str * """ * return self.__str__() # <<<<<<<<<<<<<< @@ -9989,7 +10913,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_6__repr__(s * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_str); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 399, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_str); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 466, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -10003,14 +10927,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_6__repr__(s } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 399, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 466, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":394 + /* "dependency_injector/providers.pyx":461 * return represent_provider(provider=self, provides=self.__provides) * * def __repr__(self): # <<<<<<<<<<<<<< @@ -10031,7 +10955,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_6__repr__(s return __pyx_r; } -/* "dependency_injector/providers.pyx":402 +/* "dependency_injector/providers.pyx":469 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -10057,7 +10981,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_8provides__ __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":404 + /* "dependency_injector/providers.pyx":471 * def provides(self): * """Return provider.""" * return self.__provides # <<<<<<<<<<<<<< @@ -10069,7 +10993,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_8provides__ __pyx_r = __pyx_v_self->__pyx___provides; goto __pyx_L0; - /* "dependency_injector/providers.pyx":402 + /* "dependency_injector/providers.pyx":469 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -10084,7 +11008,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_8provides__ return __pyx_r; } -/* "dependency_injector/providers.pyx":406 +/* "dependency_injector/providers.pyx":473 * return self.__provides * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -10115,7 +11039,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Delegate__provide(str if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 406, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 473, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_8Delegate_9_provide)) { __Pyx_XDECREF(__pyx_r); @@ -10135,7 +11059,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Delegate__provide(str #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 406, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 473, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -10143,13 +11067,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Delegate__provide(str #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 406, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 473, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 406, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 473, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -10160,7 +11084,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Delegate__provide(str __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 406, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 473, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -10183,7 +11107,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Delegate__provide(str #endif } - /* "dependency_injector/providers.pyx":417 + /* "dependency_injector/providers.pyx":484 * :rtype: object * """ * return self.__provides # <<<<<<<<<<<<<< @@ -10195,7 +11119,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Delegate__provide(str __pyx_r = __pyx_v_self->__pyx___provides; goto __pyx_L0; - /* "dependency_injector/providers.pyx":406 + /* "dependency_injector/providers.pyx":473 * return self.__provides * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -10253,11 +11177,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Delegate_9_provide(P case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 406, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 473, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 406, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 473, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -10270,14 +11194,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Delegate_9_provide(P } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 406, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 473, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Delegate._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 406, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 406, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 473, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 473, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_8Delegate_8_provide(((struct __pyx_obj_19dependency_injector_9providers_Delegate *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -10298,7 +11222,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_8_provide(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_8Delegate__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 406, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_8Delegate__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 473, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -10341,9 +11265,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_10__reduce_ PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -10354,46 +11278,51 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_10__reduce_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx___provides); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx___provides); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -10402,16 +11331,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_10__reduce_ * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -10423,7 +11352,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_10__reduce_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -10437,28 +11366,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_10__reduce_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Delegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_Delegate, (type(self), 0x328787b, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx___provides != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx___provides != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -10466,44 +11395,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_10__reduce_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Delegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_Delegate, (type(self), 0x328787b, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_Delegate, (type(self), 0x3f4a3b6, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Delegate, (type(self), 0x328787b, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Delegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_Delegate, (type(self), 0x328787b, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Delegate); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Delegate); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -10512,15 +11441,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_10__reduce_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Delegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_Delegate, (type(self), 0x328787b, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Delegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_Delegate, (type(self), 0x328787b, None), state * else: - * return __pyx_unpickle_Delegate, (type(self), 0x3f4a3b6, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Delegate, (type(self), 0x328787b, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Delegate__set_state(self, __pyx_state) */ @@ -10528,27 +11457,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_10__reduce_ __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_Delegate); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -10561,7 +11490,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_10__reduce_ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.Delegate.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -10575,7 +11504,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_10__reduce_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Delegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_Delegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Delegate__set_state(self, __pyx_state) */ @@ -10603,7 +11532,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_12__setstat __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Delegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_Delegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Delegate__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -10614,7 +11543,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_12__setstat /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Delegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_Delegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Delegate__set_state(self, __pyx_state) */ @@ -10632,7 +11561,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Delegate_12__setstat return __pyx_r; } -/* "dependency_injector/providers.pyx":443 +/* "dependency_injector/providers.pyx":510 * """ * * def __init__(self, object instance_of=object): # <<<<<<<<<<<<<< @@ -10676,7 +11605,7 @@ static int __pyx_pw_19dependency_injector_9providers_10Dependency_1__init__(PyOb } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 443, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 510, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -10690,7 +11619,7 @@ static int __pyx_pw_19dependency_injector_9providers_10Dependency_1__init__(PyOb } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 443, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 510, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Dependency.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -10718,7 +11647,7 @@ static int __pyx_pf_19dependency_injector_9providers_10Dependency___init__(struc int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":445 + /* "dependency_injector/providers.pyx":512 * def __init__(self, object instance_of=object): * """Initializer.""" * if not isinstance(instance_of, CLASS_TYPES): # <<<<<<<<<<<<<< @@ -10727,22 +11656,22 @@ static int __pyx_pf_19dependency_injector_9providers_10Dependency___init__(struc */ __pyx_t_1 = __pyx_v_19dependency_injector_9providers_CLASS_TYPES; __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = PyObject_IsInstance(__pyx_v_instance_of, __pyx_t_1); if (unlikely(__pyx_t_2 == ((int)-1))) __PYX_ERR(1, 445, __pyx_L1_error) + __pyx_t_2 = PyObject_IsInstance(__pyx_v_instance_of, __pyx_t_1); if (unlikely(__pyx_t_2 == ((int)-1))) __PYX_ERR(1, 512, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = ((!(__pyx_t_2 != 0)) != 0); if (unlikely(__pyx_t_3)) { - /* "dependency_injector/providers.pyx":447 + /* "dependency_injector/providers.pyx":514 * if not isinstance(instance_of, CLASS_TYPES): * raise TypeError( * 'Argument \'instance_of\' has incorrect type (expected {0}, got {1}))'.format( # <<<<<<<<<<<<<< * CLASS_TYPES, * instance_of, */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Argument_instance_of_has_incorre, __pyx_n_s_format); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 447, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Argument_instance_of_has_incorre, __pyx_n_s_format); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 514, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/providers.pyx":449 + /* "dependency_injector/providers.pyx":516 * 'Argument \'instance_of\' has incorrect type (expected {0}, got {1}))'.format( * CLASS_TYPES, * instance_of, # <<<<<<<<<<<<<< @@ -10764,7 +11693,7 @@ static int __pyx_pf_19dependency_injector_9providers_10Dependency___init__(struc #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_v_19dependency_injector_9providers_CLASS_TYPES, __pyx_v_instance_of}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 447, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 514, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -10772,13 +11701,13 @@ static int __pyx_pf_19dependency_injector_9providers_10Dependency___init__(struc #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_v_19dependency_injector_9providers_CLASS_TYPES, __pyx_v_instance_of}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 447, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 514, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 447, __pyx_L1_error) + __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 514, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_5) { __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL; @@ -10789,27 +11718,27 @@ static int __pyx_pf_19dependency_injector_9providers_10Dependency___init__(struc __Pyx_INCREF(__pyx_v_instance_of); __Pyx_GIVEREF(__pyx_v_instance_of); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_v_instance_of); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 447, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 514, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":446 + /* "dependency_injector/providers.pyx":513 * """Initializer.""" * if not isinstance(instance_of, CLASS_TYPES): * raise TypeError( # <<<<<<<<<<<<<< * 'Argument \'instance_of\' has incorrect type (expected {0}, got {1}))'.format( * CLASS_TYPES, */ - __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_builtin_TypeError, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 446, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_builtin_TypeError, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 513, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __PYX_ERR(1, 446, __pyx_L1_error) + __PYX_ERR(1, 513, __pyx_L1_error) - /* "dependency_injector/providers.pyx":445 + /* "dependency_injector/providers.pyx":512 * def __init__(self, object instance_of=object): * """Initializer.""" * if not isinstance(instance_of, CLASS_TYPES): # <<<<<<<<<<<<<< @@ -10818,7 +11747,7 @@ static int __pyx_pf_19dependency_injector_9providers_10Dependency___init__(struc */ } - /* "dependency_injector/providers.pyx":453 + /* "dependency_injector/providers.pyx":520 * ) * * self.__instance_of = instance_of # <<<<<<<<<<<<<< @@ -10831,14 +11760,14 @@ static int __pyx_pf_19dependency_injector_9providers_10Dependency___init__(struc __Pyx_DECREF(__pyx_v_self->__pyx___instance_of); __pyx_v_self->__pyx___instance_of = __pyx_v_instance_of; - /* "dependency_injector/providers.pyx":454 + /* "dependency_injector/providers.pyx":521 * * self.__instance_of = instance_of * super(Dependency, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 454, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 521, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Dependency)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Dependency)); @@ -10846,10 +11775,10 @@ static int __pyx_pf_19dependency_injector_9providers_10Dependency___init__(struc __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_7 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 454, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 521, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 454, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 521, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_7 = NULL; @@ -10864,12 +11793,12 @@ static int __pyx_pf_19dependency_injector_9providers_10Dependency___init__(struc } __pyx_t_4 = (__pyx_t_7) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_7) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 454, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 521, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":443 + /* "dependency_injector/providers.pyx":510 * """ * * def __init__(self, object instance_of=object): # <<<<<<<<<<<<<< @@ -10892,7 +11821,7 @@ static int __pyx_pf_19dependency_injector_9providers_10Dependency___init__(struc return __pyx_r; } -/* "dependency_injector/providers.pyx":456 +/* "dependency_injector/providers.pyx":523 * super(Dependency, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -10929,16 +11858,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_2__deepc int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":458 + /* "dependency_injector/providers.pyx":525 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 458, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 525, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 458, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 525, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -10953,13 +11882,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_2__deepc __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 458, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 525, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":459 + /* "dependency_injector/providers.pyx":526 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -10970,7 +11899,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_2__deepc __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":460 + /* "dependency_injector/providers.pyx":527 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -10982,7 +11911,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_2__deepc __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":459 + /* "dependency_injector/providers.pyx":526 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -10991,14 +11920,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_2__deepc */ } - /* "dependency_injector/providers.pyx":462 + /* "dependency_injector/providers.pyx":529 * return copied * * copied = self.__class__(self.__instance_of) # <<<<<<<<<<<<<< * * self._copy_overridings(copied, memo) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 462, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 529, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -11012,24 +11941,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_2__deepc } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_self->__pyx___instance_of) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_self->__pyx___instance_of); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 462, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 529, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":464 + /* "dependency_injector/providers.pyx":531 * copied = self.__class__(self.__instance_of) * * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 464, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 464, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 531, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 531, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_Dependency *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":466 + /* "dependency_injector/providers.pyx":533 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -11041,7 +11970,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_2__deepc __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":456 + /* "dependency_injector/providers.pyx":523 * super(Dependency, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -11064,7 +11993,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_2__deepc return __pyx_r; } -/* "dependency_injector/providers.pyx":468 +/* "dependency_injector/providers.pyx":535 * return copied * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -11103,7 +12032,8 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_5__call_ } static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_4__call__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs) { - PyObject *__pyx_v_instance = 0; + PyObject *__pyx_v_result = NULL; + PyObject *__pyx_v_future_result = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; @@ -11114,15 +12044,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_4__call_ PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; - PyObject *__pyx_t_9 = NULL; + int __pyx_t_9; + PyObject *__pyx_t_10 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__call__", 0); - /* "dependency_injector/providers.pyx":477 - * cdef object instance - * + /* "dependency_injector/providers.pyx":542 + * :rtype: object + * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< * raise Error('Dependency is not defined') * @@ -11131,14 +12062,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_4__call_ __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":478 - * + /* "dependency_injector/providers.pyx":543 + * """ * if self.__last_overriding is None: * raise Error('Dependency is not defined') # <<<<<<<<<<<<<< * - * instance = self.__last_overriding(*args, **kwargs) + * result = self.__last_overriding(*args, **kwargs) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 478, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 543, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { @@ -11152,156 +12083,716 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_4__call_ } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_kp_s_Dependency_is_not_defined) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_kp_s_Dependency_is_not_defined); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 478, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 543, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 478, __pyx_L1_error) + __PYX_ERR(1, 543, __pyx_L1_error) - /* "dependency_injector/providers.pyx":477 - * cdef object instance - * + /* "dependency_injector/providers.pyx":542 + * :rtype: object + * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< * raise Error('Dependency is not defined') * */ } - /* "dependency_injector/providers.pyx":480 + /* "dependency_injector/providers.pyx":545 * raise Error('Dependency is not defined') * - * instance = self.__last_overriding(*args, **kwargs) # <<<<<<<<<<<<<< + * result = self.__last_overriding(*args, **kwargs) # <<<<<<<<<<<<<< + * * - * if not isinstance(instance, self.instance_of): */ - __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 480, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 545, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_v_instance = __pyx_t_3; + __pyx_v_result = __pyx_t_3; __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":482 - * instance = self.__last_overriding(*args, **kwargs) + /* "dependency_injector/providers.pyx":548 * - * if not isinstance(instance, self.instance_of): # <<<<<<<<<<<<<< - * raise Error('{0} is not an '.format(instance) + - * 'instance of {0}'.format(self.instance_of)) + * + * if self.is_async_mode_disabled(): # <<<<<<<<<<<<<< + * self._check_instance_type(result) + * return result */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_instance_of); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 482, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_async_mode_disabled); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 548, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 548, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_2 = PyObject_IsInstance(__pyx_v_instance, __pyx_t_3); if (unlikely(__pyx_t_2 == ((int)-1))) __PYX_ERR(1, 482, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 548, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_1 = ((!(__pyx_t_2 != 0)) != 0); - if (unlikely(__pyx_t_1)) { + if (__pyx_t_2) { - /* "dependency_injector/providers.pyx":483 - * - * if not isinstance(instance, self.instance_of): - * raise Error('{0} is not an '.format(instance) + # <<<<<<<<<<<<<< - * 'instance of {0}'.format(self.instance_of)) + /* "dependency_injector/providers.pyx":549 * + * if self.is_async_mode_disabled(): + * self._check_instance_type(result) # <<<<<<<<<<<<<< + * return result + * elif self.is_async_mode_enabled(): */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 483, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_check_instance_type); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 549, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_is_not_an, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 483, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { - __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); - if (likely(__pyx_t_7)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); - __Pyx_INCREF(__pyx_t_7); - __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_6, function); - } - } - __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_instance); - __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 483, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - - /* "dependency_injector/providers.pyx":484 - * if not isinstance(instance, self.instance_of): - * raise Error('{0} is not an '.format(instance) + - * 'instance of {0}'.format(self.instance_of)) # <<<<<<<<<<<<<< - * - * return instance - */ - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_instance_of_0, __pyx_n_s_format); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 484, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_7); - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_instance_of); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 484, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - __pyx_t_9 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_9)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_9); - __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); - } - } - __pyx_t_6 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_9, __pyx_t_8) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); - __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 484, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - - /* "dependency_injector/providers.pyx":483 - * - * if not isinstance(instance, self.instance_of): - * raise Error('{0} is not an '.format(instance) + # <<<<<<<<<<<<<< - * 'instance of {0}'.format(self.instance_of)) - * - */ - __pyx_t_7 = PyNumber_Add(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 483, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - __pyx_t_6 = NULL; - if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { - __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_4); - if (likely(__pyx_t_6)) { + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); - __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); } } - __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_7); - __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 483, __pyx_L1_error) + __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 549, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 483, __pyx_L1_error) - /* "dependency_injector/providers.pyx":482 - * instance = self.__last_overriding(*args, **kwargs) + /* "dependency_injector/providers.pyx":550 + * if self.is_async_mode_disabled(): + * self._check_instance_type(result) + * return result # <<<<<<<<<<<<<< + * elif self.is_async_mode_enabled(): + * if __isawaitable(result): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_result); + __pyx_r = __pyx_v_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":548 * - * if not isinstance(instance, self.instance_of): # <<<<<<<<<<<<<< - * raise Error('{0} is not an '.format(instance) + - * 'instance of {0}'.format(self.instance_of)) + * + * if self.is_async_mode_disabled(): # <<<<<<<<<<<<<< + * self._check_instance_type(result) + * return result */ } - /* "dependency_injector/providers.pyx":486 - * 'instance of {0}'.format(self.instance_of)) + /* "dependency_injector/providers.pyx":551 + * self._check_instance_type(result) + * return result + * elif self.is_async_mode_enabled(): # <<<<<<<<<<<<<< + * if __isawaitable(result): + * future_result = asyncio.Future() + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_async_mode_enabled); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 551, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 551, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 551, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":552 + * return result + * elif self.is_async_mode_enabled(): + * if __isawaitable(result): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * result = asyncio.ensure_future(result) + */ + __pyx_t_2 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_result) != 0); + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":553 + * elif self.is_async_mode_enabled(): + * if __isawaitable(result): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * result = asyncio.ensure_future(result) + * result.add_done_callback(functools.partial(self._async_provide, future_result)) + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 553, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_Future); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 553, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 553, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_future_result = __pyx_t_3; + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":554 + * if __isawaitable(result): + * future_result = asyncio.Future() + * result = asyncio.ensure_future(result) # <<<<<<<<<<<<<< + * result.add_done_callback(functools.partial(self._async_provide, future_result)) + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 554, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 554, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 554, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF_SET(__pyx_v_result, __pyx_t_3); + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":555 + * future_result = asyncio.Future() + * result = asyncio.ensure_future(result) + * result.add_done_callback(functools.partial(self._async_provide, future_result)) # <<<<<<<<<<<<<< + * return future_result + * else: + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_result, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 555, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_functools); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 555, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_partial); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 555, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_async_provide); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 555, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_8 = NULL; + __pyx_t_9 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) { + __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); + if (likely(__pyx_t_8)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); + __Pyx_INCREF(__pyx_t_8); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_7, function); + __pyx_t_9 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_7)) { + PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_6, __pyx_v_future_result}; + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 555, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) { + PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_6, __pyx_v_future_result}; + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 555, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + { + __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 555, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_10); + if (__pyx_t_8) { + __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_8); __pyx_t_8 = NULL; + } + __Pyx_GIVEREF(__pyx_t_6); + PyTuple_SET_ITEM(__pyx_t_10, 0+__pyx_t_9, __pyx_t_6); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_9, __pyx_v_future_result); + __pyx_t_6 = 0; + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 555, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; + } + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_7 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_7)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_7); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_3 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_7, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); + __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 555, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":556 + * result = asyncio.ensure_future(result) + * result.add_done_callback(functools.partial(self._async_provide, future_result)) + * return future_result # <<<<<<<<<<<<<< + * else: + * self._check_instance_type(result) + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":552 + * return result + * elif self.is_async_mode_enabled(): + * if __isawaitable(result): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * result = asyncio.ensure_future(result) + */ + } + + /* "dependency_injector/providers.pyx":558 + * return future_result + * else: + * self._check_instance_type(result) # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * future_result.set_result(result) + */ + /*else*/ { + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_check_instance_type); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 558, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 558, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":559 + * else: + * self._check_instance_type(result) + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * future_result.set_result(result) + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 559, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_Future); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 559, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 559, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_future_result = __pyx_t_3; + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":560 + * self._check_instance_type(result) + * future_result = asyncio.Future() + * future_result.set_result(result) # <<<<<<<<<<<<<< + * return future_result + * elif self.is_async_mode_undefined(): + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 560, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 560, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":561 + * future_result = asyncio.Future() + * future_result.set_result(result) + * return future_result # <<<<<<<<<<<<<< + * elif self.is_async_mode_undefined(): + * if __isawaitable(result): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + } + + /* "dependency_injector/providers.pyx":551 + * self._check_instance_type(result) + * return result + * elif self.is_async_mode_enabled(): # <<<<<<<<<<<<<< + * if __isawaitable(result): + * future_result = asyncio.Future() + */ + } + + /* "dependency_injector/providers.pyx":562 + * future_result.set_result(result) + * return future_result + * elif self.is_async_mode_undefined(): # <<<<<<<<<<<<<< + * if __isawaitable(result): + * self.enable_async_mode() + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_async_mode_undefined); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 562, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 562, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 562, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":563 + * return future_result + * elif self.is_async_mode_undefined(): + * if __isawaitable(result): # <<<<<<<<<<<<<< + * self.enable_async_mode() * - * return instance # <<<<<<<<<<<<<< + */ + __pyx_t_2 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_result) != 0); + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":564 + * elif self.is_async_mode_undefined(): + * if __isawaitable(result): + * self.enable_async_mode() # <<<<<<<<<<<<<< + * + * future_result = asyncio.Future() + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_enable_async_mode); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 564, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 564, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":566 + * self.enable_async_mode() + * + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * result = asyncio.ensure_future(result) + * result.add_done_callback(functools.partial(self._async_provide, future_result)) + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 566, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_Future); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 566, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 566, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_v_future_result = __pyx_t_3; + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":567 + * + * future_result = asyncio.Future() + * result = asyncio.ensure_future(result) # <<<<<<<<<<<<<< + * result.add_done_callback(functools.partial(self._async_provide, future_result)) + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 567, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 567, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 567, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF_SET(__pyx_v_result, __pyx_t_3); + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":568 + * future_result = asyncio.Future() + * result = asyncio.ensure_future(result) + * result.add_done_callback(functools.partial(self._async_provide, future_result)) # <<<<<<<<<<<<<< + * return future_result + * else: + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_result, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 568, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_functools); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 568, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_partial); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 568, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_10); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_async_provide); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 568, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_6 = NULL; + __pyx_t_9 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_10))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_10); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_10); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_10, function); + __pyx_t_9 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_10)) { + PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_7, __pyx_v_future_result}; + __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 568, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_10)) { + PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_7, __pyx_v_future_result}; + __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 568, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + } else + #endif + { + __pyx_t_8 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 568, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + if (__pyx_t_6) { + __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; + } + __Pyx_GIVEREF(__pyx_t_7); + PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_9, __pyx_t_7); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_9, __pyx_v_future_result); + __pyx_t_7 = 0; + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_t_8, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 568, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + } + __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; + __pyx_t_10 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_10)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_10); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_10) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_10, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4); + __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 568, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":569 + * result = asyncio.ensure_future(result) + * result.add_done_callback(functools.partial(self._async_provide, future_result)) + * return future_result # <<<<<<<<<<<<<< + * else: + * self.disable_async_mode() + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":563 + * return future_result + * elif self.is_async_mode_undefined(): + * if __isawaitable(result): # <<<<<<<<<<<<<< + * self.enable_async_mode() + * + */ + } + + /* "dependency_injector/providers.pyx":571 + * return future_result + * else: + * self.disable_async_mode() # <<<<<<<<<<<<<< + * self._check_instance_type(result) + * return result + */ + /*else*/ { + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_disable_async_mode); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 571, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 571, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":572 + * else: + * self.disable_async_mode() + * self._check_instance_type(result) # <<<<<<<<<<<<<< + * return result + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_check_instance_type); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 572, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 572, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":573 + * self.disable_async_mode() + * self._check_instance_type(result) + * return result # <<<<<<<<<<<<<< * * def __str__(self): */ - __Pyx_XDECREF(__pyx_r); - __Pyx_INCREF(__pyx_v_instance); - __pyx_r = __pyx_v_instance; - goto __pyx_L0; + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_result); + __pyx_r = __pyx_v_result; + goto __pyx_L0; + } - /* "dependency_injector/providers.pyx":468 + /* "dependency_injector/providers.pyx":562 + * future_result.set_result(result) + * return future_result + * elif self.is_async_mode_undefined(): # <<<<<<<<<<<<<< + * if __isawaitable(result): + * self.enable_async_mode() + */ + } + + /* "dependency_injector/providers.pyx":535 * return copied * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -11310,6 +12801,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_4__call_ */ /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); @@ -11317,18 +12810,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_4__call_ __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); - __Pyx_XDECREF(__pyx_t_9); + __Pyx_XDECREF(__pyx_t_10); __Pyx_AddTraceback("dependency_injector.providers.Dependency.__call__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; - __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_result); + __Pyx_XDECREF(__pyx_v_future_result); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "dependency_injector/providers.pyx":488 - * return instance +/* "dependency_injector/providers.pyx":575 + * return result * * def __str__(self): # <<<<<<<<<<<<<< * """Return string representation of provider. @@ -11362,7 +12856,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_6__str__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":493 + /* "dependency_injector/providers.pyx":580 * :rtype: str * """ * return represent_provider(provider=self, provides=self.__instance_of) # <<<<<<<<<<<<<< @@ -11372,15 +12866,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_6__str__ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __pyx_v_self->__pyx___instance_of; __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 493, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 580, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":488 - * return instance + /* "dependency_injector/providers.pyx":575 + * return result * * def __str__(self): # <<<<<<<<<<<<<< * """Return string representation of provider. @@ -11399,7 +12893,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_6__str__ return __pyx_r; } -/* "dependency_injector/providers.pyx":495 +/* "dependency_injector/providers.pyx":582 * return represent_provider(provider=self, provides=self.__instance_of) * * def __repr__(self): # <<<<<<<<<<<<<< @@ -11435,7 +12929,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_8__repr_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__repr__", 0); - /* "dependency_injector/providers.pyx":500 + /* "dependency_injector/providers.pyx":587 * :rtype: str * """ * return self.__str__() # <<<<<<<<<<<<<< @@ -11443,7 +12937,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_8__repr_ * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_str); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 500, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_str); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 587, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -11457,14 +12951,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_8__repr_ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 500, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 587, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":495 + /* "dependency_injector/providers.pyx":582 * return represent_provider(provider=self, provides=self.__instance_of) * * def __repr__(self): # <<<<<<<<<<<<<< @@ -11485,7 +12979,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_8__repr_ return __pyx_r; } -/* "dependency_injector/providers.pyx":503 +/* "dependency_injector/providers.pyx":590 * * @property * def instance_of(self): # <<<<<<<<<<<<<< @@ -11511,7 +13005,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_11instan __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":505 + /* "dependency_injector/providers.pyx":592 * def instance_of(self): * """Return class of required dependency.""" * return self.__instance_of # <<<<<<<<<<<<<< @@ -11523,7 +13017,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_11instan __pyx_r = __pyx_v_self->__pyx___instance_of; goto __pyx_L0; - /* "dependency_injector/providers.pyx":503 + /* "dependency_injector/providers.pyx":590 * * @property * def instance_of(self): # <<<<<<<<<<<<<< @@ -11538,7 +13032,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_11instan return __pyx_r; } -/* "dependency_injector/providers.pyx":507 +/* "dependency_injector/providers.pyx":594 * return self.__instance_of * * def provided_by(self, provider): # <<<<<<<<<<<<<< @@ -11571,15 +13065,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_10provid int __pyx_clineno = 0; __Pyx_RefNannySetupContext("provided_by", 0); - /* "dependency_injector/providers.pyx":515 + /* "dependency_injector/providers.pyx":602 * :rtype: None * """ * return self.override(provider) # <<<<<<<<<<<<<< * - * + * def _async_provide(self, future_result, future): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 515, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 602, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -11593,14 +13087,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_10provid } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_provider); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 515, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 602, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":507 + /* "dependency_injector/providers.pyx":594 * return self.__instance_of * * def provided_by(self, provider): # <<<<<<<<<<<<<< @@ -11621,6 +13115,485 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_10provid return __pyx_r; } +/* "dependency_injector/providers.pyx":604 + * return self.override(provider) + * + * def _async_provide(self, future_result, future): # <<<<<<<<<<<<<< + * instance = future.result() + * try: + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_13_async_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_13_async_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_future_result = 0; + PyObject *__pyx_v_future = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_async_provide (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_future_result,&__pyx_n_s_future,0}; + PyObject* values[2] = {0,0}; + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future_result)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + CYTHON_FALLTHROUGH; + case 1: + if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future)) != 0)) kw_args--; + else { + __Pyx_RaiseArgtupleInvalid("_async_provide", 1, 2, 2, 1); __PYX_ERR(1, 604, __pyx_L3_error) + } + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_async_provide") < 0)) __PYX_ERR(1, 604, __pyx_L3_error) + } + } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { + goto __pyx_L5_argtuple_error; + } else { + values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + } + __pyx_v_future_result = values[0]; + __pyx_v_future = values[1]; + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_async_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 604, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.Dependency._async_provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + __pyx_r = __pyx_pf_19dependency_injector_9providers_10Dependency_12_async_provide(((struct __pyx_obj_19dependency_injector_9providers_Dependency *)__pyx_v_self), __pyx_v_future_result, __pyx_v_future); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12_async_provide(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_future) { + PyObject *__pyx_v_instance = NULL; + PyObject *__pyx_v_exception = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + PyObject *__pyx_t_7 = NULL; + int __pyx_t_8; + PyObject *__pyx_t_9 = NULL; + PyObject *__pyx_t_10 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_async_provide", 0); + + /* "dependency_injector/providers.pyx":605 + * + * def _async_provide(self, future_result, future): + * instance = future.result() # <<<<<<<<<<<<<< + * try: + * self._check_instance_type(instance) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 605, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 605, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_instance = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":606 + * def _async_provide(self, future_result, future): + * instance = future.result() + * try: # <<<<<<<<<<<<<< + * self._check_instance_type(instance) + * except Error as exception: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_4, &__pyx_t_5, &__pyx_t_6); + __Pyx_XGOTREF(__pyx_t_4); + __Pyx_XGOTREF(__pyx_t_5); + __Pyx_XGOTREF(__pyx_t_6); + /*try:*/ { + + /* "dependency_injector/providers.pyx":607 + * instance = future.result() + * try: + * self._check_instance_type(instance) # <<<<<<<<<<<<<< + * except Error as exception: + * future_result.set_exception(exception) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_check_instance_type); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 607, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 607, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":606 + * def _async_provide(self, future_result, future): + * instance = future.result() + * try: # <<<<<<<<<<<<<< + * self._check_instance_type(instance) + * except Error as exception: + */ + } + + /* "dependency_injector/providers.pyx":611 + * future_result.set_exception(exception) + * else: + * future_result.set_result(instance) # <<<<<<<<<<<<<< + * + * def _check_instance_type(self, instance): + */ + /*else:*/ { + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 611, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 611, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + } + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + goto __pyx_L8_try_end; + __pyx_L3_error:; + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":608 + * try: + * self._check_instance_type(instance) + * except Error as exception: # <<<<<<<<<<<<<< + * future_result.set_exception(exception) + * else: + */ + __Pyx_ErrFetch(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); + __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_Error); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 608, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_8 = __Pyx_PyErr_GivenExceptionMatches(__pyx_t_1, __pyx_t_7); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_ErrRestore(__pyx_t_1, __pyx_t_2, __pyx_t_3); + __pyx_t_1 = 0; __pyx_t_2 = 0; __pyx_t_3 = 0; + if (__pyx_t_8) { + __Pyx_AddTraceback("dependency_injector.providers.Dependency._async_provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_3, &__pyx_t_2, &__pyx_t_1) < 0) __PYX_ERR(1, 608, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_t_2); + __pyx_v_exception = __pyx_t_2; + + /* "dependency_injector/providers.pyx":609 + * self._check_instance_type(instance) + * except Error as exception: + * future_result.set_exception(exception) # <<<<<<<<<<<<<< + * else: + * future_result.set_result(instance) + */ + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_exception); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 609, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_9); + __pyx_t_10 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_9))) { + __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_9); + if (likely(__pyx_t_10)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9); + __Pyx_INCREF(__pyx_t_10); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_9, function); + } + } + __pyx_t_7 = (__pyx_t_10) ? __Pyx_PyObject_Call2Args(__pyx_t_9, __pyx_t_10, __pyx_v_exception) : __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_exception); + __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; + if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 609, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_7); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + goto __pyx_L4_exception_handled; + } + goto __pyx_L5_except_error; + __pyx_L5_except_error:; + + /* "dependency_injector/providers.pyx":606 + * def _async_provide(self, future_result, future): + * instance = future.result() + * try: # <<<<<<<<<<<<<< + * self._check_instance_type(instance) + * except Error as exception: + */ + __Pyx_XGIVEREF(__pyx_t_4); + __Pyx_XGIVEREF(__pyx_t_5); + __Pyx_XGIVEREF(__pyx_t_6); + __Pyx_ExceptionReset(__pyx_t_4, __pyx_t_5, __pyx_t_6); + goto __pyx_L1_error; + __pyx_L4_exception_handled:; + __Pyx_XGIVEREF(__pyx_t_4); + __Pyx_XGIVEREF(__pyx_t_5); + __Pyx_XGIVEREF(__pyx_t_6); + __Pyx_ExceptionReset(__pyx_t_4, __pyx_t_5, __pyx_t_6); + __pyx_L8_try_end:; + } + + /* "dependency_injector/providers.pyx":604 + * return self.override(provider) + * + * def _async_provide(self, future_result, future): # <<<<<<<<<<<<<< + * instance = future.result() + * try: + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); + __Pyx_XDECREF(__pyx_t_10); + __Pyx_AddTraceback("dependency_injector.providers.Dependency._async_provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_exception); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":613 + * future_result.set_result(instance) + * + * def _check_instance_type(self, instance): # <<<<<<<<<<<<<< + * if not isinstance(instance, self.instance_of): + * raise Error('{0} is not an instance of {1}'.format(instance, self.instance_of)) + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_15_check_instance_type(PyObject *__pyx_v_self, PyObject *__pyx_v_instance); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_15_check_instance_type(PyObject *__pyx_v_self, PyObject *__pyx_v_instance) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_check_instance_type (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_10Dependency_14_check_instance_type(((struct __pyx_obj_19dependency_injector_9providers_Dependency *)__pyx_v_self), ((PyObject *)__pyx_v_instance)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_14_check_instance_type(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self, PyObject *__pyx_v_instance) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_t_2; + int __pyx_t_3; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + PyObject *__pyx_t_7 = NULL; + PyObject *__pyx_t_8 = NULL; + int __pyx_t_9; + PyObject *__pyx_t_10 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_check_instance_type", 0); + + /* "dependency_injector/providers.pyx":614 + * + * def _check_instance_type(self, instance): + * if not isinstance(instance, self.instance_of): # <<<<<<<<<<<<<< + * raise Error('{0} is not an instance of {1}'.format(instance, self.instance_of)) + * + */ + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_instance_of); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 614, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyObject_IsInstance(__pyx_v_instance, __pyx_t_1); if (unlikely(__pyx_t_2 == ((int)-1))) __PYX_ERR(1, 614, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_3 = ((!(__pyx_t_2 != 0)) != 0); + if (unlikely(__pyx_t_3)) { + + /* "dependency_injector/providers.pyx":615 + * def _check_instance_type(self, instance): + * if not isinstance(instance, self.instance_of): + * raise Error('{0} is not an instance of {1}'.format(instance, self.instance_of)) # <<<<<<<<<<<<<< + * + * + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 615, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_is_not_an_instance_of_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 615, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_instance_of); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 615, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_8 = NULL; + __pyx_t_9 = 0; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { + __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); + if (likely(__pyx_t_8)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); + __Pyx_INCREF(__pyx_t_8); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_6, function); + __pyx_t_9 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_6)) { + PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_v_instance, __pyx_t_7}; + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 615, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { + PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_v_instance, __pyx_t_7}; + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 615, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + } else + #endif + { + __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 615, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_10); + if (__pyx_t_8) { + __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_8); __pyx_t_8 = NULL; + } + __Pyx_INCREF(__pyx_v_instance); + __Pyx_GIVEREF(__pyx_v_instance); + PyTuple_SET_ITEM(__pyx_t_10, 0+__pyx_t_9, __pyx_v_instance); + __Pyx_GIVEREF(__pyx_t_7); + PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_9, __pyx_t_7); + __pyx_t_7 = 0; + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 615, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; + } + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 615, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_Raise(__pyx_t_1, 0, 0, 0); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __PYX_ERR(1, 615, __pyx_L1_error) + + /* "dependency_injector/providers.pyx":614 + * + * def _check_instance_type(self, instance): + * if not isinstance(instance, self.instance_of): # <<<<<<<<<<<<<< + * raise Error('{0} is not an instance of {1}'.format(instance, self.instance_of)) + * + */ + } + + /* "dependency_injector/providers.pyx":613 + * future_result.set_result(instance) + * + * def _check_instance_type(self, instance): # <<<<<<<<<<<<<< + * if not isinstance(instance, self.instance_of): + * raise Error('{0} is not an instance of {1}'.format(instance, self.instance_of)) + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_10); + __Pyx_AddTraceback("dependency_injector.providers.Dependency._check_instance_type", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + /* "(tree fragment)":1 * def __reduce_cython__(self): # <<<<<<<<<<<<<< * cdef tuple state @@ -11628,28 +13601,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_10provid */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_13__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_13__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { +static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_17__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_17__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_10Dependency_12__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_Dependency *)__pyx_v_self)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_10Dependency_16__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_Dependency *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self) { +static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_16__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self) { PyObject *__pyx_v_state = 0; PyObject *__pyx_v__dict = 0; int __pyx_v_use_setstate; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -11660,46 +13633,51 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__redu /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__instance_of, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__instance_of, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx___instance_of); __Pyx_GIVEREF(__pyx_v_self->__pyx___instance_of); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->__pyx___instance_of); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->__pyx___instance_of); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx___overridden); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___overridden); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__instance_of, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instance_of, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__instance_of, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instance_of, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -11708,16 +13686,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__redu * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -11729,7 +13707,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__redu __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__instance_of, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instance_of, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -11743,28 +13721,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__redu * else: * use_setstate = self.__instance_of is not None or self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Dependency, (type(self), 0xf1f5217, None), state + * return __pyx_unpickle_Dependency, (type(self), 0xd55614d, None), state */ /*else*/ { - __pyx_t_2 = (__pyx_v_self->__pyx___instance_of != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx___instance_of != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -11772,44 +13750,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__redu * else: * use_setstate = self.__instance_of is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Dependency, (type(self), 0xf1f5217, None), state + * return __pyx_unpickle_Dependency, (type(self), 0xd55614d, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__instance_of is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: - * return __pyx_unpickle_Dependency, (type(self), 0xf1f5217, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Dependency, (type(self), 0xd55614d, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Dependency, (type(self), 0xf1f5217, state) + * return __pyx_unpickle_Dependency, (type(self), 0xd55614d, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Dependency); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Dependency); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_253710871); - __Pyx_GIVEREF(__pyx_int_253710871); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_253710871); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_223699277); + __Pyx_GIVEREF(__pyx_int_223699277); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_223699277); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -11818,15 +13796,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__redu * else: * use_setstate = self.__instance_of is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Dependency, (type(self), 0xf1f5217, None), state + * return __pyx_unpickle_Dependency, (type(self), 0xd55614d, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Dependency, (type(self), 0xf1f5217, None), state + * return __pyx_unpickle_Dependency, (type(self), 0xd55614d, None), state * else: - * return __pyx_unpickle_Dependency, (type(self), 0xf1f5217, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Dependency, (type(self), 0xd55614d, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Dependency__set_state(self, __pyx_state) */ @@ -11834,27 +13812,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__redu __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_Dependency); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_253710871); - __Pyx_GIVEREF(__pyx_int_253710871); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_253710871); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_223699277); + __Pyx_GIVEREF(__pyx_int_223699277); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_223699277); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -11867,7 +13845,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__redu /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.Dependency.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -11881,25 +13859,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_12__redu /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Dependency, (type(self), 0xf1f5217, state) + * return __pyx_unpickle_Dependency, (type(self), 0xd55614d, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Dependency__set_state(self, __pyx_state) */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_15__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_15__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_19__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_10Dependency_19__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_10Dependency_14__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_Dependency *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_10Dependency_18__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_Dependency *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_14__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_18__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -11909,7 +13887,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_14__sets __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Dependency, (type(self), 0xf1f5217, state) + * return __pyx_unpickle_Dependency, (type(self), 0xd55614d, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Dependency__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -11920,7 +13898,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10Dependency_14__sets /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Dependency, (type(self), 0xf1f5217, state) + * return __pyx_unpickle_Dependency, (type(self), 0xd55614d, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Dependency__set_state(self, __pyx_state) */ @@ -11964,9 +13942,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -11977,46 +13955,51 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__instance_of, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__instance_of, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___instance_of); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___instance_of); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->__pyx_base.__pyx___instance_of); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->__pyx_base.__pyx___instance_of); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__instance_of, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instance_of, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__instance_of, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instance_of, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -12025,16 +14008,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -12046,7 +14029,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__instance_of, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instance_of, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -12060,28 +14043,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ * else: * use_setstate = self.__instance_of is not None or self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_ExternalDependency, (type(self), 0xf1f5217, None), state + * return __pyx_unpickle_ExternalDependency, (type(self), 0xd55614d, None), state */ /*else*/ { - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___instance_of != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___instance_of != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -12089,44 +14072,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ * else: * use_setstate = self.__instance_of is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ExternalDependency, (type(self), 0xf1f5217, None), state + * return __pyx_unpickle_ExternalDependency, (type(self), 0xd55614d, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__instance_of is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: - * return __pyx_unpickle_ExternalDependency, (type(self), 0xf1f5217, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_ExternalDependency, (type(self), 0xd55614d, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_ExternalDependency, (type(self), 0xf1f5217, state) + * return __pyx_unpickle_ExternalDependency, (type(self), 0xd55614d, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_ExternalDependenc); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_ExternalDependenc); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_253710871); - __Pyx_GIVEREF(__pyx_int_253710871); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_253710871); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_223699277); + __Pyx_GIVEREF(__pyx_int_223699277); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_223699277); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -12135,15 +14118,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ * else: * use_setstate = self.__instance_of is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ExternalDependency, (type(self), 0xf1f5217, None), state + * return __pyx_unpickle_ExternalDependency, (type(self), 0xd55614d, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_ExternalDependency, (type(self), 0xf1f5217, None), state + * return __pyx_unpickle_ExternalDependency, (type(self), 0xd55614d, None), state * else: - * return __pyx_unpickle_ExternalDependency, (type(self), 0xf1f5217, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_ExternalDependency, (type(self), 0xd55614d, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ExternalDependency__set_state(self, __pyx_state) */ @@ -12151,27 +14134,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_ExternalDependenc); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_253710871); - __Pyx_GIVEREF(__pyx_int_253710871); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_253710871); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_223699277); + __Pyx_GIVEREF(__pyx_int_223699277); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_223699277); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -12184,7 +14167,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.ExternalDependency.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -12198,7 +14181,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ExternalDependency, (type(self), 0xf1f5217, state) + * return __pyx_unpickle_ExternalDependency, (type(self), 0xd55614d, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ExternalDependency__set_state(self, __pyx_state) */ @@ -12226,7 +14209,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_ExternalDependency, (type(self), 0xf1f5217, state) + * return __pyx_unpickle_ExternalDependency, (type(self), 0xd55614d, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ExternalDependency__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -12237,7 +14220,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ExternalDependency, (type(self), 0xf1f5217, state) + * return __pyx_unpickle_ExternalDependency, (type(self), 0xd55614d, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ExternalDependency__set_state(self, __pyx_state) */ @@ -12255,7 +14238,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18ExternalDependency_ return __pyx_r; } -/* "dependency_injector/providers.pyx":580 +/* "dependency_injector/providers.pyx":680 * """ * * def __init__(self, **dependencies): # <<<<<<<<<<<<<< @@ -12298,7 +14281,7 @@ static int __pyx_pf_19dependency_injector_9providers_21DependenciesContainer___i int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":582 + /* "dependency_injector/providers.pyx":682 * def __init__(self, **dependencies): * """Initializer.""" * self.__providers = dependencies # <<<<<<<<<<<<<< @@ -12311,14 +14294,14 @@ static int __pyx_pf_19dependency_injector_9providers_21DependenciesContainer___i __Pyx_DECREF(__pyx_v_self->__pyx___providers); __pyx_v_self->__pyx___providers = __pyx_v_dependencies; - /* "dependency_injector/providers.pyx":583 + /* "dependency_injector/providers.pyx":683 * """Initializer.""" * self.__providers = dependencies * super(DependenciesContainer, self).__init__(None) # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 583, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 683, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_DependenciesContainer)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_DependenciesContainer)); @@ -12326,10 +14309,10 @@ static int __pyx_pf_19dependency_injector_9providers_21DependenciesContainer___i __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 583, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 683, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 583, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 683, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -12344,12 +14327,12 @@ static int __pyx_pf_19dependency_injector_9providers_21DependenciesContainer___i } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, Py_None) : __Pyx_PyObject_CallOneArg(__pyx_t_2, Py_None); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 583, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 683, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":580 + /* "dependency_injector/providers.pyx":680 * """ * * def __init__(self, **dependencies): # <<<<<<<<<<<<<< @@ -12371,7 +14354,7 @@ static int __pyx_pf_19dependency_injector_9providers_21DependenciesContainer___i return __pyx_r; } -/* "dependency_injector/providers.pyx":585 +/* "dependency_injector/providers.pyx":685 * super(DependenciesContainer, self).__init__(None) * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -12409,16 +14392,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":589 + /* "dependency_injector/providers.pyx":689 * cdef DependenciesContainer copied * * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 589, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 689, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 589, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 689, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -12433,14 +14416,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 589, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 689, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_DependenciesContainer))))) __PYX_ERR(1, 589, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_DependenciesContainer))))) __PYX_ERR(1, 689, __pyx_L1_error) __pyx_v_copied = ((struct __pyx_obj_19dependency_injector_9providers_DependenciesContainer *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":590 + /* "dependency_injector/providers.pyx":690 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -12451,7 +14434,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":591 + /* "dependency_injector/providers.pyx":691 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -12463,7 +14446,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":590 + /* "dependency_injector/providers.pyx":690 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -12472,14 +14455,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ } - /* "dependency_injector/providers.pyx":593 + /* "dependency_injector/providers.pyx":693 * return copied * * copied = self.__class__() # <<<<<<<<<<<<<< * copied.__provides = deepcopy(self.__provides, memo) * copied.__providers = deepcopy(self.__providers, memo) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 593, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 693, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -12493,14 +14476,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 593, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 693, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_DependenciesContainer))))) __PYX_ERR(1, 593, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_DependenciesContainer))))) __PYX_ERR(1, 693, __pyx_L1_error) __Pyx_DECREF_SET(__pyx_v_copied, ((struct __pyx_obj_19dependency_injector_9providers_DependenciesContainer *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":594 + /* "dependency_injector/providers.pyx":694 * * copied = self.__class__() * copied.__provides = deepcopy(self.__provides, memo) # <<<<<<<<<<<<<< @@ -12509,10 +14492,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ __pyx_t_1 = __pyx_v_self->__pyx_base.__pyx___provides; __Pyx_INCREF(__pyx_t_1); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 594, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 694, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 594, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 694, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GIVEREF(__pyx_t_2); @@ -12521,7 +14504,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __pyx_v_copied->__pyx_base.__pyx___provides = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":595 + /* "dependency_injector/providers.pyx":695 * copied = self.__class__() * copied.__provides = deepcopy(self.__provides, memo) * copied.__providers = deepcopy(self.__providers, memo) # <<<<<<<<<<<<<< @@ -12530,30 +14513,30 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ __pyx_t_2 = __pyx_v_self->__pyx___providers; __Pyx_INCREF(__pyx_t_2); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 595, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 695, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 595, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 695, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 595, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 695, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_copied->__pyx___providers); __Pyx_DECREF(__pyx_v_copied->__pyx___providers); __pyx_v_copied->__pyx___providers = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":597 + /* "dependency_injector/providers.pyx":697 * copied.__providers = deepcopy(self.__providers, memo) * * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 597, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 697, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_DependenciesContainer *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":599 + /* "dependency_injector/providers.pyx":699 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -12565,7 +14548,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":585 + /* "dependency_injector/providers.pyx":685 * super(DependenciesContainer, self).__init__(None) * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -12588,7 +14571,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain return __pyx_r; } -/* "dependency_injector/providers.pyx":601 +/* "dependency_injector/providers.pyx":701 * return copied * * def __getattr__(self, name): # <<<<<<<<<<<<<< @@ -12630,14 +14613,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getattr__", 0); - /* "dependency_injector/providers.pyx":603 + /* "dependency_injector/providers.pyx":703 * def __getattr__(self, name): * """Return dependency provider.""" * if name.startswith('__') and name.endswith('__'): # <<<<<<<<<<<<<< * raise AttributeError( * '\'{cls}\' object has no attribute ' */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_startswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 603, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_startswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 703, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -12651,17 +14634,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 603, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 703, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 603, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 703, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (__pyx_t_5) { } else { __pyx_t_1 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_endswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 603, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_endswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 703, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -12675,70 +14658,70 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 603, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 703, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 603, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 703, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_1 = __pyx_t_5; __pyx_L4_bool_binop_done:; if (unlikely(__pyx_t_1)) { - /* "dependency_injector/providers.pyx":606 + /* "dependency_injector/providers.pyx":706 * raise AttributeError( * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, # <<<<<<<<<<<<<< * attribute_name=name)) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_cls_object_has_no_attribute_att, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 606, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_cls_object_has_no_attribute_att, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 706, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 606, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 706, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 606, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 706, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 606, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 706, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_cls, __pyx_t_6) < 0) __PYX_ERR(1, 606, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_cls, __pyx_t_6) < 0) __PYX_ERR(1, 706, __pyx_L1_error) __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":607 + /* "dependency_injector/providers.pyx":707 * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, * attribute_name=name)) # <<<<<<<<<<<<<< * * provider = self.__providers.get(name) */ - if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_attribute_name, __pyx_v_name) < 0) __PYX_ERR(1, 606, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_attribute_name, __pyx_v_name) < 0) __PYX_ERR(1, 706, __pyx_L1_error) - /* "dependency_injector/providers.pyx":606 + /* "dependency_injector/providers.pyx":706 * raise AttributeError( * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, # <<<<<<<<<<<<<< * attribute_name=name)) * */ - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 606, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 706, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":604 + /* "dependency_injector/providers.pyx":704 * """Return dependency provider.""" * if name.startswith('__') and name.endswith('__'): * raise AttributeError( # <<<<<<<<<<<<<< * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, */ - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 604, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 704, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 604, __pyx_L1_error) + __PYX_ERR(1, 704, __pyx_L1_error) - /* "dependency_injector/providers.pyx":603 + /* "dependency_injector/providers.pyx":703 * def __getattr__(self, name): * """Return dependency provider.""" * if name.startswith('__') and name.endswith('__'): # <<<<<<<<<<<<<< @@ -12747,7 +14730,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ } - /* "dependency_injector/providers.pyx":609 + /* "dependency_injector/providers.pyx":709 * attribute_name=name)) * * provider = self.__providers.get(name) # <<<<<<<<<<<<<< @@ -12756,37 +14739,37 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ if (unlikely(__pyx_v_self->__pyx___providers == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "get"); - __PYX_ERR(1, 609, __pyx_L1_error) + __PYX_ERR(1, 709, __pyx_L1_error) } - __pyx_t_3 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___providers, __pyx_v_name, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 609, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___providers, __pyx_v_name, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 709, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_v_provider = __pyx_t_3; __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":610 + /* "dependency_injector/providers.pyx":710 * * provider = self.__providers.get(name) * if not provider: # <<<<<<<<<<<<<< * provider = Dependency() * self.__providers[name] = provider */ - __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_provider); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 610, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_provider); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 710, __pyx_L1_error) __pyx_t_5 = ((!__pyx_t_1) != 0); if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":611 + /* "dependency_injector/providers.pyx":711 * provider = self.__providers.get(name) * if not provider: * provider = Dependency() # <<<<<<<<<<<<<< * self.__providers[name] = provider * */ - __pyx_t_3 = __Pyx_PyObject_CallNoArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Dependency)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 611, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallNoArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Dependency)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 711, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF_SET(__pyx_v_provider, __pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":612 + /* "dependency_injector/providers.pyx":712 * if not provider: * provider = Dependency() * self.__providers[name] = provider # <<<<<<<<<<<<<< @@ -12795,18 +14778,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ if (unlikely(__pyx_v_self->__pyx___providers == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 612, __pyx_L1_error) + __PYX_ERR(1, 712, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_v_self->__pyx___providers, __pyx_v_name, __pyx_v_provider) < 0)) __PYX_ERR(1, 612, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_self->__pyx___providers, __pyx_v_name, __pyx_v_provider) < 0)) __PYX_ERR(1, 712, __pyx_L1_error) - /* "dependency_injector/providers.pyx":614 + /* "dependency_injector/providers.pyx":714 * self.__providers[name] = provider * * container = self.__call__() # <<<<<<<<<<<<<< * if container: * dependency_provider = container.providers.get(name) */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 614, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 714, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -12820,32 +14803,32 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_3 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_6); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 614, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 714, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_v_container = __pyx_t_3; __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":615 + /* "dependency_injector/providers.pyx":715 * * container = self.__call__() * if container: # <<<<<<<<<<<<<< * dependency_provider = container.providers.get(name) * if dependency_provider: */ - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_container); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 615, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_container); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 715, __pyx_L1_error) if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":616 + /* "dependency_injector/providers.pyx":716 * container = self.__call__() * if container: * dependency_provider = container.providers.get(name) # <<<<<<<<<<<<<< * if dependency_provider: * provider.override(dependency_provider) */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_providers); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 616, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_providers); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 716, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 616, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 716, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -12860,30 +14843,30 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_6, __pyx_v_name) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_name); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 616, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 716, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_dependency_provider = __pyx_t_3; __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":617 + /* "dependency_injector/providers.pyx":717 * if container: * dependency_provider = container.providers.get(name) * if dependency_provider: # <<<<<<<<<<<<<< * provider.override(dependency_provider) * */ - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_dependency_provider); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 617, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_dependency_provider); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 717, __pyx_L1_error) if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":618 + /* "dependency_injector/providers.pyx":718 * dependency_provider = container.providers.get(name) * if dependency_provider: * provider.override(dependency_provider) # <<<<<<<<<<<<<< * * return provider */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 618, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 718, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -12897,12 +14880,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_6, __pyx_v_dependency_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_dependency_provider); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 618, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 718, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":617 + /* "dependency_injector/providers.pyx":717 * if container: * dependency_provider = container.providers.get(name) * if dependency_provider: # <<<<<<<<<<<<<< @@ -12911,7 +14894,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ } - /* "dependency_injector/providers.pyx":615 + /* "dependency_injector/providers.pyx":715 * * container = self.__call__() * if container: # <<<<<<<<<<<<<< @@ -12920,7 +14903,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ } - /* "dependency_injector/providers.pyx":610 + /* "dependency_injector/providers.pyx":710 * * provider = self.__providers.get(name) * if not provider: # <<<<<<<<<<<<<< @@ -12929,7 +14912,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ } - /* "dependency_injector/providers.pyx":620 + /* "dependency_injector/providers.pyx":720 * provider.override(dependency_provider) * * return provider # <<<<<<<<<<<<<< @@ -12941,7 +14924,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __pyx_r = __pyx_v_provider; goto __pyx_L0; - /* "dependency_injector/providers.pyx":601 + /* "dependency_injector/providers.pyx":701 * return copied * * def __getattr__(self, name): # <<<<<<<<<<<<<< @@ -12966,7 +14949,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain return __pyx_r; } -/* "dependency_injector/providers.pyx":623 +/* "dependency_injector/providers.pyx":723 * * @property * def providers(self): # <<<<<<<<<<<<<< @@ -12992,7 +14975,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":625 + /* "dependency_injector/providers.pyx":725 * def providers(self): * """Read-only dictionary of dependency providers.""" * return self.__providers # <<<<<<<<<<<<<< @@ -13004,7 +14987,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __pyx_r = __pyx_v_self->__pyx___providers; goto __pyx_L0; - /* "dependency_injector/providers.pyx":623 + /* "dependency_injector/providers.pyx":723 * * @property * def providers(self): # <<<<<<<<<<<<<< @@ -13019,7 +15002,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain return __pyx_r; } -/* "dependency_injector/providers.pyx":627 +/* "dependency_injector/providers.pyx":727 * return self.__providers * * def override(self, provider): # <<<<<<<<<<<<<< @@ -13052,18 +15035,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/providers.pyx":638 + /* "dependency_injector/providers.pyx":738 * :rtype: :py:class:`OverridingContext` * """ * self._override_providers(container=provider) # <<<<<<<<<<<<<< * return super(DependenciesContainer, self).override(provider) * */ - __pyx_t_1 = ((struct __pyx_vtabstruct_19dependency_injector_9providers_DependenciesContainer *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->_override_providers(__pyx_v_self, __pyx_v_provider, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 638, __pyx_L1_error) + __pyx_t_1 = ((struct __pyx_vtabstruct_19dependency_injector_9providers_DependenciesContainer *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->_override_providers(__pyx_v_self, __pyx_v_provider, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 738, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":639 + /* "dependency_injector/providers.pyx":739 * """ * self._override_providers(container=provider) * return super(DependenciesContainer, self).override(provider) # <<<<<<<<<<<<<< @@ -13071,7 +15054,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain * def reset_last_overriding(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 639, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 739, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_DependenciesContainer)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_DependenciesContainer)); @@ -13079,10 +15062,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 639, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 739, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 639, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 739, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -13097,14 +15080,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_provider); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 639, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 739, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":627 + /* "dependency_injector/providers.pyx":727 * return self.__providers * * def override(self, provider): # <<<<<<<<<<<<<< @@ -13125,7 +15108,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain return __pyx_r; } -/* "dependency_injector/providers.pyx":641 +/* "dependency_injector/providers.pyx":741 * return super(DependenciesContainer, self).override(provider) * * def reset_last_overriding(self): # <<<<<<<<<<<<<< @@ -13167,7 +15150,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_last_overriding", 0); - /* "dependency_injector/providers.pyx":649 + /* "dependency_injector/providers.pyx":749 * :rtype: None * """ * for child in self.__providers.values(): # <<<<<<<<<<<<<< @@ -13176,17 +15159,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ if (unlikely(__pyx_v_self->__pyx___providers == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "values"); - __PYX_ERR(1, 649, __pyx_L1_error) + __PYX_ERR(1, 749, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_Values(__pyx_v_self->__pyx___providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 649, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_Values(__pyx_v_self->__pyx___providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 749, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; __pyx_t_4 = NULL; } else { - __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 649, __pyx_L1_error) + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 749, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 649, __pyx_L1_error) + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 749, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -13194,17 +15177,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 649, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 749, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 649, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 749, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 649, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 749, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 649, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 749, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -13214,7 +15197,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 649, __pyx_L1_error) + else __PYX_ERR(1, 749, __pyx_L1_error) } break; } @@ -13223,7 +15206,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __Pyx_XDECREF_SET(__pyx_v_child, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":650 + /* "dependency_injector/providers.pyx":750 * """ * for child in self.__providers.values(): * try: # <<<<<<<<<<<<<< @@ -13239,14 +15222,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __Pyx_XGOTREF(__pyx_t_7); /*try:*/ { - /* "dependency_injector/providers.pyx":651 + /* "dependency_injector/providers.pyx":751 * for child in self.__providers.values(): * try: * child.reset_last_overriding() # <<<<<<<<<<<<<< * except Error: * pass */ - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_child, __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 651, __pyx_L5_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_child, __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 751, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -13260,12 +15243,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_9) : __Pyx_PyObject_CallNoArg(__pyx_t_8); __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 651, __pyx_L5_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 751, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":650 + /* "dependency_injector/providers.pyx":750 * """ * for child in self.__providers.values(): * try: # <<<<<<<<<<<<<< @@ -13282,7 +15265,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/providers.pyx":652 + /* "dependency_injector/providers.pyx":752 * try: * child.reset_last_overriding() * except Error: # <<<<<<<<<<<<<< @@ -13290,7 +15273,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain * super(DependenciesContainer, self).reset_last_overriding() */ __Pyx_ErrFetch(&__pyx_t_1, &__pyx_t_8, &__pyx_t_9); - __Pyx_GetModuleGlobalName(__pyx_t_10, __pyx_n_s_Error); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 652, __pyx_L7_except_error) + __Pyx_GetModuleGlobalName(__pyx_t_10, __pyx_n_s_Error); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 752, __pyx_L7_except_error) __Pyx_GOTREF(__pyx_t_10); __pyx_t_11 = __Pyx_PyErr_GivenExceptionMatches(__pyx_t_1, __pyx_t_10); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; @@ -13303,7 +15286,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain goto __pyx_L7_except_error; __pyx_L7_except_error:; - /* "dependency_injector/providers.pyx":650 + /* "dependency_injector/providers.pyx":750 * """ * for child in self.__providers.values(): * try: # <<<<<<<<<<<<<< @@ -13323,7 +15306,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __pyx_L12_try_end:; } - /* "dependency_injector/providers.pyx":649 + /* "dependency_injector/providers.pyx":749 * :rtype: None * """ * for child in self.__providers.values(): # <<<<<<<<<<<<<< @@ -13333,14 +15316,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":654 + /* "dependency_injector/providers.pyx":754 * except Error: * pass * super(DependenciesContainer, self).reset_last_overriding() # <<<<<<<<<<<<<< * * def reset_override(self): */ - __pyx_t_9 = PyTuple_New(2); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 654, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 754, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_DependenciesContainer)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_DependenciesContainer)); @@ -13348,10 +15331,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_9, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_9, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 654, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_9, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 754, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 654, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 754, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_t_8 = NULL; @@ -13366,12 +15349,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_2 = (__pyx_t_8) ? __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_t_8) : __Pyx_PyObject_CallNoArg(__pyx_t_9); __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 654, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 754, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":641 + /* "dependency_injector/providers.pyx":741 * return super(DependenciesContainer, self).override(provider) * * def reset_last_overriding(self): # <<<<<<<<<<<<<< @@ -13397,7 +15380,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain return __pyx_r; } -/* "dependency_injector/providers.pyx":656 +/* "dependency_injector/providers.pyx":756 * super(DependenciesContainer, self).reset_last_overriding() * * def reset_override(self): # <<<<<<<<<<<<<< @@ -13434,7 +15417,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_override", 0); - /* "dependency_injector/providers.pyx":661 + /* "dependency_injector/providers.pyx":761 * :rtype: None * """ * for child in self.__providers.values(): # <<<<<<<<<<<<<< @@ -13443,17 +15426,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain */ if (unlikely(__pyx_v_self->__pyx___providers == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "values"); - __PYX_ERR(1, 661, __pyx_L1_error) + __PYX_ERR(1, 761, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_Values(__pyx_v_self->__pyx___providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 661, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_Values(__pyx_v_self->__pyx___providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 761, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; __pyx_t_4 = NULL; } else { - __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 661, __pyx_L1_error) + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 761, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 661, __pyx_L1_error) + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 761, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -13461,17 +15444,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 661, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 761, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 661, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 761, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 661, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 761, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 661, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 761, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -13481,7 +15464,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 661, __pyx_L1_error) + else __PYX_ERR(1, 761, __pyx_L1_error) } break; } @@ -13490,14 +15473,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __Pyx_XDECREF_SET(__pyx_v_child, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":662 + /* "dependency_injector/providers.pyx":762 * """ * for child in self.__providers.values(): * child.reset_override() # <<<<<<<<<<<<<< * super(DependenciesContainer, self).reset_override() * */ - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_child, __pyx_n_s_reset_override); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 662, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_child, __pyx_n_s_reset_override); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 762, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { @@ -13511,12 +15494,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 662, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 762, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":661 + /* "dependency_injector/providers.pyx":761 * :rtype: None * """ * for child in self.__providers.values(): # <<<<<<<<<<<<<< @@ -13526,14 +15509,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":663 + /* "dependency_injector/providers.pyx":763 * for child in self.__providers.values(): * child.reset_override() * super(DependenciesContainer, self).reset_override() # <<<<<<<<<<<<<< * * cpdef object _override_providers(self, object container): */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 663, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 763, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_DependenciesContainer)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_DependenciesContainer)); @@ -13541,10 +15524,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 663, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 763, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_reset_override); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 663, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_reset_override); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 763, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -13559,12 +15542,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain } __pyx_t_2 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 663, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 763, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":656 + /* "dependency_injector/providers.pyx":756 * super(DependenciesContainer, self).reset_last_overriding() * * def reset_override(self): # <<<<<<<<<<<<<< @@ -13589,7 +15572,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain return __pyx_r; } -/* "dependency_injector/providers.pyx":665 +/* "dependency_injector/providers.pyx":765 * super(DependenciesContainer, self).reset_override() * * cpdef object _override_providers(self, object container): # <<<<<<<<<<<<<< @@ -13627,7 +15610,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 665, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 765, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_21DependenciesContainer_13_override_providers)) { __Pyx_XDECREF(__pyx_r); @@ -13644,7 +15627,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_v_container) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_container); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 665, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 765, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_r = __pyx_t_2; @@ -13665,16 +15648,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine #endif } - /* "dependency_injector/providers.pyx":667 + /* "dependency_injector/providers.pyx":767 * cpdef object _override_providers(self, object container): * """Override providers with providers from provided container.""" * for name, dependency_provider in container.providers.items(): # <<<<<<<<<<<<<< * provider = self.__providers.get(name) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_providers); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_items); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_items); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -13689,16 +15672,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 667, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_3 = __pyx_t_1; __Pyx_INCREF(__pyx_t_3); __pyx_t_5 = 0; __pyx_t_6 = NULL; } else { - __pyx_t_5 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_5 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_6 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_6 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 767, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -13706,17 +15689,17 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine if (likely(PyList_CheckExact(__pyx_t_3))) { if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(1, 767, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_3)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(1, 767, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -13726,7 +15709,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 667, __pyx_L1_error) + else __PYX_ERR(1, 767, __pyx_L1_error) } break; } @@ -13738,7 +15721,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(1, 667, __pyx_L1_error) + __PYX_ERR(1, 767, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -13751,15 +15734,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(__pyx_t_4); #else - __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 667, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -13767,7 +15750,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine __Pyx_GOTREF(__pyx_t_2); index = 1; __pyx_t_4 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_4)) goto __pyx_L5_unpacking_failed; __Pyx_GOTREF(__pyx_t_4); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 667, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 767, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L6_unpacking_done; @@ -13775,7 +15758,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(1, 667, __pyx_L1_error) + __PYX_ERR(1, 767, __pyx_L1_error) __pyx_L6_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_2); @@ -13783,7 +15766,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine __Pyx_XDECREF_SET(__pyx_v_dependency_provider, __pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":668 + /* "dependency_injector/providers.pyx":768 * """Override providers with providers from provided container.""" * for name, dependency_provider in container.providers.items(): * provider = self.__providers.get(name) # <<<<<<<<<<<<<< @@ -13792,25 +15775,25 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine */ if (unlikely(__pyx_v_self->__pyx___providers == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "get"); - __PYX_ERR(1, 668, __pyx_L1_error) + __PYX_ERR(1, 768, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___providers, __pyx_v_name, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 668, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___providers, __pyx_v_name, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 768, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_XDECREF_SET(__pyx_v_provider, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":670 + /* "dependency_injector/providers.pyx":770 * provider = self.__providers.get(name) * * if not provider: # <<<<<<<<<<<<<< * continue * */ - __pyx_t_9 = __Pyx_PyObject_IsTrue(__pyx_v_provider); if (unlikely(__pyx_t_9 < 0)) __PYX_ERR(1, 670, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_IsTrue(__pyx_v_provider); if (unlikely(__pyx_t_9 < 0)) __PYX_ERR(1, 770, __pyx_L1_error) __pyx_t_10 = ((!__pyx_t_9) != 0); if (__pyx_t_10) { - /* "dependency_injector/providers.pyx":671 + /* "dependency_injector/providers.pyx":771 * * if not provider: * continue # <<<<<<<<<<<<<< @@ -13819,7 +15802,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine */ goto __pyx_L3_continue; - /* "dependency_injector/providers.pyx":670 + /* "dependency_injector/providers.pyx":770 * provider = self.__providers.get(name) * * if not provider: # <<<<<<<<<<<<<< @@ -13828,21 +15811,21 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine */ } - /* "dependency_injector/providers.pyx":673 + /* "dependency_injector/providers.pyx":773 * continue * * if provider.last_overriding is dependency_provider: # <<<<<<<<<<<<<< * continue * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_last_overriding); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 673, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_last_overriding); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 773, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_10 = (__pyx_t_1 == __pyx_v_dependency_provider); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_9 = (__pyx_t_10 != 0); if (__pyx_t_9) { - /* "dependency_injector/providers.pyx":674 + /* "dependency_injector/providers.pyx":774 * * if provider.last_overriding is dependency_provider: * continue # <<<<<<<<<<<<<< @@ -13851,7 +15834,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine */ goto __pyx_L3_continue; - /* "dependency_injector/providers.pyx":673 + /* "dependency_injector/providers.pyx":773 * continue * * if provider.last_overriding is dependency_provider: # <<<<<<<<<<<<<< @@ -13860,14 +15843,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine */ } - /* "dependency_injector/providers.pyx":676 + /* "dependency_injector/providers.pyx":776 * continue * * provider.override(dependency_provider) # <<<<<<<<<<<<<< * * */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 676, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 776, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -13881,12 +15864,12 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_2, __pyx_v_dependency_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_dependency_provider); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 676, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 776, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":667 + /* "dependency_injector/providers.pyx":767 * cpdef object _override_providers(self, object container): * """Override providers with providers from provided container.""" * for name, dependency_provider in container.providers.items(): # <<<<<<<<<<<<<< @@ -13897,7 +15880,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_21DependenciesContaine } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":665 + /* "dependency_injector/providers.pyx":765 * super(DependenciesContainer, self).reset_override() * * cpdef object _override_providers(self, object container): # <<<<<<<<<<<<<< @@ -13948,7 +15931,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_override_providers", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_21DependenciesContainer__override_providers(__pyx_v_self, __pyx_v_container, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 665, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_21DependenciesContainer__override_providers(__pyx_v_self, __pyx_v_container, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 765, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -13991,9 +15974,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -14004,49 +15987,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__providers, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__providers, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx___providers); __Pyx_GIVEREF(__pyx_v_self->__pyx___providers); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx___providers); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx___providers); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx_base.__pyx___provides); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx___provides); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__providers, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__providers, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__providers, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__providers, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -14055,16 +16043,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -14076,7 +16064,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__providers, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__providers, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -14090,35 +16078,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__providers is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_DependenciesContainer, (type(self), 0xd8553c7, None), state + * return __pyx_unpickle_DependenciesContainer, (type(self), 0x1cf9f6d, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx___providers != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx___providers != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - __pyx_t_3 = __pyx_t_2; + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -14126,44 +16114,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__providers is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DependenciesContainer, (type(self), 0xd8553c7, None), state + * return __pyx_unpickle_DependenciesContainer, (type(self), 0x1cf9f6d, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__providers is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_DependenciesContainer, (type(self), 0xd8553c7, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_DependenciesContainer, (type(self), 0x1cf9f6d, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_DependenciesContainer, (type(self), 0xd8553c7, state) + * return __pyx_unpickle_DependenciesContainer, (type(self), 0x1cf9f6d, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_DependenciesConta); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_DependenciesConta); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_226841543); - __Pyx_GIVEREF(__pyx_int_226841543); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_226841543); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_30383981); + __Pyx_GIVEREF(__pyx_int_30383981); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_30383981); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -14172,15 +16160,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__providers is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DependenciesContainer, (type(self), 0xd8553c7, None), state + * return __pyx_unpickle_DependenciesContainer, (type(self), 0x1cf9f6d, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_DependenciesContainer, (type(self), 0xd8553c7, None), state + * return __pyx_unpickle_DependenciesContainer, (type(self), 0x1cf9f6d, None), state * else: - * return __pyx_unpickle_DependenciesContainer, (type(self), 0xd8553c7, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_DependenciesContainer, (type(self), 0x1cf9f6d, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DependenciesContainer__set_state(self, __pyx_state) */ @@ -14188,27 +16176,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_DependenciesConta); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_226841543); - __Pyx_GIVEREF(__pyx_int_226841543); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_226841543); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_30383981); + __Pyx_GIVEREF(__pyx_int_30383981); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_30383981); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -14221,7 +16209,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.DependenciesContainer.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -14235,7 +16223,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DependenciesContainer, (type(self), 0xd8553c7, state) + * return __pyx_unpickle_DependenciesContainer, (type(self), 0x1cf9f6d, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DependenciesContainer__set_state(self, __pyx_state) */ @@ -14263,7 +16251,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_DependenciesContainer, (type(self), 0xd8553c7, state) + * return __pyx_unpickle_DependenciesContainer, (type(self), 0x1cf9f6d, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DependenciesContainer__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -14274,7 +16262,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DependenciesContainer, (type(self), 0xd8553c7, state) + * return __pyx_unpickle_DependenciesContainer, (type(self), 0x1cf9f6d, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DependenciesContainer__set_state(self, __pyx_state) */ @@ -14292,7 +16280,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_21DependenciesContain return __pyx_r; } -/* "dependency_injector/providers.pyx":693 +/* "dependency_injector/providers.pyx":793 * """ * * def __init__(self, Provider overridden, Provider overriding): # <<<<<<<<<<<<<< @@ -14338,11 +16326,11 @@ static int __pyx_pw_19dependency_injector_9providers_17OverridingContext_1__init case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_overriding)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, 1); __PYX_ERR(1, 693, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, 1); __PYX_ERR(1, 793, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 693, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 793, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -14355,14 +16343,14 @@ static int __pyx_pw_19dependency_injector_9providers_17OverridingContext_1__init } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 693, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 793, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.OverridingContext.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return -1; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_overridden), __pyx_ptype_19dependency_injector_9providers_Provider, 1, "overridden", 0))) __PYX_ERR(1, 693, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_overriding), __pyx_ptype_19dependency_injector_9providers_Provider, 1, "overriding", 0))) __PYX_ERR(1, 693, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_overridden), __pyx_ptype_19dependency_injector_9providers_Provider, 1, "overridden", 0))) __PYX_ERR(1, 793, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_overriding), __pyx_ptype_19dependency_injector_9providers_Provider, 1, "overriding", 0))) __PYX_ERR(1, 793, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_17OverridingContext___init__(((struct __pyx_obj_19dependency_injector_9providers_OverridingContext *)__pyx_v_self), __pyx_v_overridden, __pyx_v_overriding); /* function exit code */ @@ -14385,7 +16373,7 @@ static int __pyx_pf_19dependency_injector_9providers_17OverridingContext___init_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":702 + /* "dependency_injector/providers.pyx":802 * :type overriding: :py:class:`Provider` * """ * self.__overridden = overridden # <<<<<<<<<<<<<< @@ -14398,7 +16386,7 @@ static int __pyx_pf_19dependency_injector_9providers_17OverridingContext___init_ __Pyx_DECREF(((PyObject *)__pyx_v_self->__pyx___overridden)); __pyx_v_self->__pyx___overridden = __pyx_v_overridden; - /* "dependency_injector/providers.pyx":703 + /* "dependency_injector/providers.pyx":803 * """ * self.__overridden = overridden * self.__overriding = overriding # <<<<<<<<<<<<<< @@ -14411,14 +16399,14 @@ static int __pyx_pf_19dependency_injector_9providers_17OverridingContext___init_ __Pyx_DECREF(((PyObject *)__pyx_v_self->__pyx___overriding)); __pyx_v_self->__pyx___overriding = __pyx_v_overriding; - /* "dependency_injector/providers.pyx":704 + /* "dependency_injector/providers.pyx":804 * self.__overridden = overridden * self.__overriding = overriding * super(OverridingContext, self).__init__() # <<<<<<<<<<<<<< * * def __enter__(self): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 704, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 804, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_OverridingContext)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_OverridingContext)); @@ -14426,10 +16414,10 @@ static int __pyx_pf_19dependency_injector_9providers_17OverridingContext___init_ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 704, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 804, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 704, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 804, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -14444,12 +16432,12 @@ static int __pyx_pf_19dependency_injector_9providers_17OverridingContext___init_ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 704, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 804, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":693 + /* "dependency_injector/providers.pyx":793 * """ * * def __init__(self, Provider overridden, Provider overriding): # <<<<<<<<<<<<<< @@ -14471,7 +16459,7 @@ static int __pyx_pf_19dependency_injector_9providers_17OverridingContext___init_ return __pyx_r; } -/* "dependency_injector/providers.pyx":706 +/* "dependency_injector/providers.pyx":806 * super(OverridingContext, self).__init__() * * def __enter__(self): # <<<<<<<<<<<<<< @@ -14498,7 +16486,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17OverridingContext_2 __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__enter__", 0); - /* "dependency_injector/providers.pyx":708 + /* "dependency_injector/providers.pyx":808 * def __enter__(self): * """Do nothing.""" * return self.__overriding # <<<<<<<<<<<<<< @@ -14510,7 +16498,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17OverridingContext_2 __pyx_r = ((PyObject *)__pyx_v_self->__pyx___overriding); goto __pyx_L0; - /* "dependency_injector/providers.pyx":706 + /* "dependency_injector/providers.pyx":806 * super(OverridingContext, self).__init__() * * def __enter__(self): # <<<<<<<<<<<<<< @@ -14525,7 +16513,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17OverridingContext_2 return __pyx_r; } -/* "dependency_injector/providers.pyx":710 +/* "dependency_injector/providers.pyx":810 * return self.__overriding * * def __exit__(self, *_): # <<<<<<<<<<<<<< @@ -14563,14 +16551,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17OverridingContext_4 int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__exit__", 0); - /* "dependency_injector/providers.pyx":712 + /* "dependency_injector/providers.pyx":812 * def __exit__(self, *_): * """Exit overriding context.""" * self.__overridden.reset_last_overriding() # <<<<<<<<<<<<<< * * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___overridden), __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 712, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___overridden), __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 812, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -14584,12 +16572,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17OverridingContext_4 } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 712, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 812, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":710 + /* "dependency_injector/providers.pyx":810 * return self.__overriding * * def __exit__(self, *_): # <<<<<<<<<<<<<< @@ -14919,7 +16907,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17OverridingContext_8 return __pyx_r; } -/* "dependency_injector/providers.pyx":739 +/* "dependency_injector/providers.pyx":839 * """ * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -14976,7 +16964,7 @@ static int __pyx_pw_19dependency_injector_9providers_8Callable_1__init__(PyObjec } if (unlikely(kw_args > 0)) { const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 739, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 839, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { goto __pyx_L5_argtuple_error; @@ -14987,7 +16975,7 @@ static int __pyx_pw_19dependency_injector_9providers_8Callable_1__init__(PyObjec } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 739, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 839, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; @@ -15022,63 +17010,63 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":745 + /* "dependency_injector/providers.pyx":845 * :type provides: callable * """ * if not callable(provides): # <<<<<<<<<<<<<< * raise Error('Provider {0} expected to get callable, ' * 'got {0}'.format('.'.join((self.__class__.__module__, */ - __pyx_t_1 = __Pyx_PyCallable_Check(__pyx_v_provides); if (unlikely(__pyx_t_1 == ((int)-1))) __PYX_ERR(1, 745, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCallable_Check(__pyx_v_provides); if (unlikely(__pyx_t_1 == ((int)-1))) __PYX_ERR(1, 845, __pyx_L1_error) __pyx_t_2 = ((!(__pyx_t_1 != 0)) != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":746 + /* "dependency_injector/providers.pyx":846 * """ * if not callable(provides): * raise Error('Provider {0} expected to get callable, ' # <<<<<<<<<<<<<< * 'got {0}'.format('.'.join((self.__class__.__module__, * self.__class__.__name__)), */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 746, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 846, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/providers.pyx":747 + /* "dependency_injector/providers.pyx":847 * if not callable(provides): * raise Error('Provider {0} expected to get callable, ' * 'got {0}'.format('.'.join((self.__class__.__module__, # <<<<<<<<<<<<<< * self.__class__.__name__)), * provides)) */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Provider_0_expected_to_get_calla, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 747, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Provider_0_expected_to_get_calla, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 847, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 747, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 847, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_module); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 747, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_module); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 847, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/providers.pyx":748 + /* "dependency_injector/providers.pyx":848 * raise Error('Provider {0} expected to get callable, ' * 'got {0}'.format('.'.join((self.__class__.__module__, * self.__class__.__name__)), # <<<<<<<<<<<<<< * provides)) * self.__provides = provides */ - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 748, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 848, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_name); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 748, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_name); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 848, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/providers.pyx":747 + /* "dependency_injector/providers.pyx":847 * if not callable(provides): * raise Error('Provider {0} expected to get callable, ' * 'got {0}'.format('.'.join((self.__class__.__module__, # <<<<<<<<<<<<<< * self.__class__.__name__)), * provides)) */ - __pyx_t_7 = PyTuple_New(2); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 747, __pyx_L1_error) + __pyx_t_7 = PyTuple_New(2); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 847, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); @@ -15086,11 +17074,11 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ PyTuple_SET_ITEM(__pyx_t_7, 1, __pyx_t_9); __pyx_t_8 = 0; __pyx_t_9 = 0; - __pyx_t_9 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_7); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 747, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_7); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 847, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/providers.pyx":749 + /* "dependency_injector/providers.pyx":849 * 'got {0}'.format('.'.join((self.__class__.__module__, * self.__class__.__name__)), * provides)) # <<<<<<<<<<<<<< @@ -15112,7 +17100,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_t_9, __pyx_v_provides}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 747, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 847, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; @@ -15121,14 +17109,14 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_t_9, __pyx_v_provides}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 747, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 847, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } else #endif { - __pyx_t_8 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 747, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 847, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -15139,7 +17127,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ __Pyx_GIVEREF(__pyx_v_provides); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_10, __pyx_v_provides); __pyx_t_9 = 0; - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 747, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 847, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } @@ -15157,14 +17145,14 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 746, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 846, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 746, __pyx_L1_error) + __PYX_ERR(1, 846, __pyx_L1_error) - /* "dependency_injector/providers.pyx":745 + /* "dependency_injector/providers.pyx":845 * :type provides: callable * """ * if not callable(provides): # <<<<<<<<<<<<<< @@ -15173,7 +17161,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ */ } - /* "dependency_injector/providers.pyx":750 + /* "dependency_injector/providers.pyx":850 * self.__class__.__name__)), * provides)) * self.__provides = provides # <<<<<<<<<<<<<< @@ -15186,14 +17174,14 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ __Pyx_DECREF(__pyx_v_self->__pyx___provides); __pyx_v_self->__pyx___provides = __pyx_v_provides; - /* "dependency_injector/providers.pyx":752 + /* "dependency_injector/providers.pyx":852 * self.__provides = provides * * self.__args = tuple() # <<<<<<<<<<<<<< * self.__args_len = 0 * self.set_args(*args) */ - __pyx_t_3 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 752, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 852, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_3); __Pyx_GOTREF(__pyx_v_self->__pyx___args); @@ -15201,7 +17189,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":753 + /* "dependency_injector/providers.pyx":853 * * self.__args = tuple() * self.__args_len = 0 # <<<<<<<<<<<<<< @@ -15210,28 +17198,28 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ */ __pyx_v_self->__pyx___args_len = 0; - /* "dependency_injector/providers.pyx":754 + /* "dependency_injector/providers.pyx":854 * self.__args = tuple() * self.__args_len = 0 * self.set_args(*args) # <<<<<<<<<<<<<< * * self.__kwargs = tuple() */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_set_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 754, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_set_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 854, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_v_args, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 754, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_v_args, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 854, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":756 + /* "dependency_injector/providers.pyx":856 * self.set_args(*args) * * self.__kwargs = tuple() # <<<<<<<<<<<<<< * self.__kwargs_len = 0 * self.set_kwargs(**kwargs) */ - __pyx_t_4 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 756, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 856, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __Pyx_GOTREF(__pyx_v_self->__pyx___kwargs); @@ -15239,7 +17227,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":757 + /* "dependency_injector/providers.pyx":857 * * self.__kwargs = tuple() * self.__kwargs_len = 0 # <<<<<<<<<<<<<< @@ -15248,28 +17236,28 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ */ __pyx_v_self->__pyx___kwargs_len = 0; - /* "dependency_injector/providers.pyx":758 + /* "dependency_injector/providers.pyx":858 * self.__kwargs = tuple() * self.__kwargs_len = 0 * self.set_kwargs(**kwargs) # <<<<<<<<<<<<<< * * super(Callable, self).__init__() */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_set_kwargs); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 758, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_set_kwargs); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 858, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 758, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 858, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":760 + /* "dependency_injector/providers.pyx":860 * self.set_kwargs(**kwargs) * * super(Callable, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 760, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 860, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)); @@ -15277,10 +17265,10 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 760, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 860, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 760, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 860, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -15295,12 +17283,12 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 760, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 860, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":739 + /* "dependency_injector/providers.pyx":839 * """ * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -15326,7 +17314,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Callable___init__(struct _ return __pyx_r; } -/* "dependency_injector/providers.pyx":762 +/* "dependency_injector/providers.pyx":862 * super(Callable, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -15366,16 +17354,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_2__deepcopy int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":764 + /* "dependency_injector/providers.pyx":864 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 764, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 864, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 764, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 864, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -15390,13 +17378,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_2__deepcopy __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 764, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 864, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":765 + /* "dependency_injector/providers.pyx":865 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -15407,7 +17395,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_2__deepcopy __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":766 + /* "dependency_injector/providers.pyx":866 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -15419,7 +17407,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_2__deepcopy __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":765 + /* "dependency_injector/providers.pyx":865 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -15428,19 +17416,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_2__deepcopy */ } - /* "dependency_injector/providers.pyx":768 + /* "dependency_injector/providers.pyx":868 * return copied * * provides = self.provides # <<<<<<<<<<<<<< * if isinstance(provides, Provider): * provides = deepcopy(provides, memo) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provides); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 768, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provides); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 868, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_provides = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":769 + /* "dependency_injector/providers.pyx":869 * * provides = self.provides * if isinstance(provides, Provider): # <<<<<<<<<<<<<< @@ -15451,22 +17439,22 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_2__deepcopy __pyx_t_5 = (__pyx_t_6 != 0); if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":770 + /* "dependency_injector/providers.pyx":870 * provides = self.provides * if isinstance(provides, Provider): * provides = deepcopy(provides, memo) # <<<<<<<<<<<<<< * * copied = self.__class__(provides, */ - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 770, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 870, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_v_provides, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 770, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_v_provides, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 870, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF_SET(__pyx_v_provides, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":769 + /* "dependency_injector/providers.pyx":869 * * provides = self.provides * if isinstance(provides, Provider): # <<<<<<<<<<<<<< @@ -15475,89 +17463,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_2__deepcopy */ } - /* "dependency_injector/providers.pyx":772 + /* "dependency_injector/providers.pyx":872 * provides = deepcopy(provides, memo) * * copied = self.__class__(provides, # <<<<<<<<<<<<<< * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 772, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 872, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 772, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 872, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_provides); __Pyx_GIVEREF(__pyx_v_provides); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_provides); - /* "dependency_injector/providers.pyx":773 + /* "dependency_injector/providers.pyx":873 * * copied = self.__class__(provides, * *deepcopy(self.args, memo), # <<<<<<<<<<<<<< * **deepcopy(self.kwargs, memo)) * */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 773, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 873, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 773, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 873, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 773, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 873, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":772 + /* "dependency_injector/providers.pyx":872 * provides = deepcopy(provides, memo) * * copied = self.__class__(provides, # <<<<<<<<<<<<<< * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) */ - __pyx_t_3 = __Pyx_PySequence_Tuple(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 772, __pyx_L1_error) + __pyx_t_3 = __Pyx_PySequence_Tuple(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 872, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = PyNumber_Add(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 772, __pyx_L1_error) + __pyx_t_4 = PyNumber_Add(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 872, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":774 + /* "dependency_injector/providers.pyx":874 * copied = self.__class__(provides, * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) # <<<<<<<<<<<<<< * * self._copy_overridings(copied, memo) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 774, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 874, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 774, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 874, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 774, __pyx_L1_error) + __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 874, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (unlikely(__pyx_t_8 == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 774, __pyx_L1_error) + __PYX_ERR(1, 874, __pyx_L1_error) } if (likely(PyDict_CheckExact(__pyx_t_8))) { - __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 774, __pyx_L1_error) + __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 874, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { - __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 772, __pyx_L1_error) + __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 872, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } - /* "dependency_injector/providers.pyx":772 + /* "dependency_injector/providers.pyx":872 * provides = deepcopy(provides, memo) * * copied = self.__class__(provides, # <<<<<<<<<<<<<< * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) */ - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 772, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 872, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -15565,18 +17553,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_2__deepcopy __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":776 + /* "dependency_injector/providers.pyx":876 * **deepcopy(self.kwargs, memo)) * * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 776, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 776, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 876, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 876, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_Callable *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":778 + /* "dependency_injector/providers.pyx":878 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -15588,7 +17576,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_2__deepcopy __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":762 + /* "dependency_injector/providers.pyx":862 * super(Callable, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -15613,7 +17601,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_2__deepcopy return __pyx_r; } -/* "dependency_injector/providers.pyx":780 +/* "dependency_injector/providers.pyx":880 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -15648,7 +17636,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_4__str__(st int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":785 + /* "dependency_injector/providers.pyx":885 * :rtype: str * """ * return represent_provider(provider=self, provides=self.__provides) # <<<<<<<<<<<<<< @@ -15658,14 +17646,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_4__str__(st __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __pyx_v_self->__pyx___provides; __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 785, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 885, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":780 + /* "dependency_injector/providers.pyx":880 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -15685,7 +17673,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_4__str__(st return __pyx_r; } -/* "dependency_injector/providers.pyx":788 +/* "dependency_injector/providers.pyx":888 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -15711,7 +17699,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_8provides__ __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":790 + /* "dependency_injector/providers.pyx":890 * def provides(self): * """Return wrapped callable.""" * return self.__provides # <<<<<<<<<<<<<< @@ -15723,7 +17711,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_8provides__ __pyx_r = __pyx_v_self->__pyx___provides; goto __pyx_L0; - /* "dependency_injector/providers.pyx":788 + /* "dependency_injector/providers.pyx":888 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -15738,7 +17726,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_8provides__ return __pyx_r; } -/* "dependency_injector/providers.pyx":793 +/* "dependency_injector/providers.pyx":893 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -15775,19 +17763,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_4args___get int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":799 + /* "dependency_injector/providers.pyx":899 * cdef list args * * args = list() # <<<<<<<<<<<<<< * for index in range(self.__args_len): * arg = self.__args[index] */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 799, __pyx_L1_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 899, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":800 + /* "dependency_injector/providers.pyx":900 * * args = list() * for index in range(self.__args_len): # <<<<<<<<<<<<<< @@ -15799,7 +17787,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_4args___get for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_index = __pyx_t_4; - /* "dependency_injector/providers.pyx":801 + /* "dependency_injector/providers.pyx":901 * args = list() * for index in range(self.__args_len): * arg = self.__args[index] # <<<<<<<<<<<<<< @@ -15808,15 +17796,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_4args___get */ if (unlikely(__pyx_v_self->__pyx___args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 801, __pyx_L1_error) + __PYX_ERR(1, 901, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___args, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 801, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___args, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 901, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_PositionalInjection))))) __PYX_ERR(1, 801, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_PositionalInjection))))) __PYX_ERR(1, 901, __pyx_L1_error) __Pyx_XDECREF_SET(__pyx_v_arg, ((struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":802 + /* "dependency_injector/providers.pyx":902 * for index in range(self.__args_len): * arg = self.__args[index] * args.append(arg.__value) # <<<<<<<<<<<<<< @@ -15825,11 +17813,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_4args___get */ __pyx_t_1 = __pyx_v_arg->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_1); - __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_args, __pyx_t_1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 802, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_args, __pyx_t_1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 902, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - /* "dependency_injector/providers.pyx":803 + /* "dependency_injector/providers.pyx":903 * arg = self.__args[index] * args.append(arg.__value) * return tuple(args) # <<<<<<<<<<<<<< @@ -15837,13 +17825,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_4args___get * def add_args(self, *args): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyList_AsTuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 803, __pyx_L1_error) + __pyx_t_1 = PyList_AsTuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 903, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":793 + /* "dependency_injector/providers.pyx":893 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -15864,7 +17852,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_4args___get return __pyx_r; } -/* "dependency_injector/providers.pyx":805 +/* "dependency_injector/providers.pyx":905 * return tuple(args) * * def add_args(self, *args): # <<<<<<<<<<<<<< @@ -15902,16 +17890,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6add_args(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_args", 0); - /* "dependency_injector/providers.pyx":810 + /* "dependency_injector/providers.pyx":910 * :return: Reference ``self`` * """ * self.__args += parse_positional_injections(args) # <<<<<<<<<<<<<< * self.__args_len = len(self.__args) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 810, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 910, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___args, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 810, __pyx_L1_error) + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___args, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 910, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GIVEREF(__pyx_t_2); @@ -15920,7 +17908,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6add_args(s __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":811 + /* "dependency_injector/providers.pyx":911 * """ * self.__args += parse_positional_injections(args) * self.__args_len = len(self.__args) # <<<<<<<<<<<<<< @@ -15931,13 +17919,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6add_args(s __Pyx_INCREF(__pyx_t_2); if (unlikely(__pyx_t_2 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 811, __pyx_L1_error) + __PYX_ERR(1, 911, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 811, __pyx_L1_error) + __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 911, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_self->__pyx___args_len = __pyx_t_3; - /* "dependency_injector/providers.pyx":812 + /* "dependency_injector/providers.pyx":912 * self.__args += parse_positional_injections(args) * self.__args_len = len(self.__args) * return self # <<<<<<<<<<<<<< @@ -15949,7 +17937,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6add_args(s __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":805 + /* "dependency_injector/providers.pyx":905 * return tuple(args) * * def add_args(self, *args): # <<<<<<<<<<<<<< @@ -15969,7 +17957,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6add_args(s return __pyx_r; } -/* "dependency_injector/providers.pyx":814 +/* "dependency_injector/providers.pyx":914 * return self * * def set_args(self, *args): # <<<<<<<<<<<<<< @@ -16006,14 +17994,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_8set_args(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_args", 0); - /* "dependency_injector/providers.pyx":821 + /* "dependency_injector/providers.pyx":921 * :return: Reference ``self`` * """ * self.__args = parse_positional_injections(args) # <<<<<<<<<<<<<< * self.__args_len = len(self.__args) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 821, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 921, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___args); @@ -16021,7 +18009,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_8set_args(s __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":822 + /* "dependency_injector/providers.pyx":922 * """ * self.__args = parse_positional_injections(args) * self.__args_len = len(self.__args) # <<<<<<<<<<<<<< @@ -16032,13 +18020,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_8set_args(s __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 822, __pyx_L1_error) + __PYX_ERR(1, 922, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 822, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 922, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___args_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":823 + /* "dependency_injector/providers.pyx":923 * self.__args = parse_positional_injections(args) * self.__args_len = len(self.__args) * return self # <<<<<<<<<<<<<< @@ -16050,7 +18038,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_8set_args(s __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":814 + /* "dependency_injector/providers.pyx":914 * return self * * def set_args(self, *args): # <<<<<<<<<<<<<< @@ -16069,7 +18057,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_8set_args(s return __pyx_r; } -/* "dependency_injector/providers.pyx":825 +/* "dependency_injector/providers.pyx":925 * return self * * def clear_args(self): # <<<<<<<<<<<<<< @@ -16101,14 +18089,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_10clear_arg int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_args", 0); - /* "dependency_injector/providers.pyx":830 + /* "dependency_injector/providers.pyx":930 * :return: Reference ``self`` * """ * self.__args = tuple() # <<<<<<<<<<<<<< * self.__args_len = len(self.__args) * return self */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 830, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 930, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___args); @@ -16116,7 +18104,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_10clear_arg __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":831 + /* "dependency_injector/providers.pyx":931 * """ * self.__args = tuple() * self.__args_len = len(self.__args) # <<<<<<<<<<<<<< @@ -16127,13 +18115,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_10clear_arg __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 831, __pyx_L1_error) + __PYX_ERR(1, 931, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 831, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 931, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___args_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":832 + /* "dependency_injector/providers.pyx":932 * self.__args = tuple() * self.__args_len = len(self.__args) * return self # <<<<<<<<<<<<<< @@ -16145,7 +18133,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_10clear_arg __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":825 + /* "dependency_injector/providers.pyx":925 * return self * * def clear_args(self): # <<<<<<<<<<<<<< @@ -16164,7 +18152,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_10clear_arg return __pyx_r; } -/* "dependency_injector/providers.pyx":835 +/* "dependency_injector/providers.pyx":935 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -16200,19 +18188,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6kwargs___g int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":841 + /* "dependency_injector/providers.pyx":941 * cdef dict kwargs * * kwargs = dict() # <<<<<<<<<<<<<< * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 841, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 941, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":842 + /* "dependency_injector/providers.pyx":942 * * kwargs = dict() * for index in range(self.__kwargs_len): # <<<<<<<<<<<<<< @@ -16224,7 +18212,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6kwargs___g for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_index = __pyx_t_4; - /* "dependency_injector/providers.pyx":843 + /* "dependency_injector/providers.pyx":943 * kwargs = dict() * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] # <<<<<<<<<<<<<< @@ -16233,15 +18221,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6kwargs___g */ if (unlikely(__pyx_v_self->__pyx___kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 843, __pyx_L1_error) + __PYX_ERR(1, 943, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___kwargs, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 843, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___kwargs, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 943, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_NamedInjection))))) __PYX_ERR(1, 843, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_NamedInjection))))) __PYX_ERR(1, 943, __pyx_L1_error) __Pyx_XDECREF_SET(__pyx_v_kwarg, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":844 + /* "dependency_injector/providers.pyx":944 * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] * kwargs[kwarg.__name] = kwarg.__value # <<<<<<<<<<<<<< @@ -16250,11 +18238,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6kwargs___g */ __pyx_t_1 = __pyx_v_kwarg->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_1); - if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_kwarg->__pyx___name, __pyx_t_1) < 0)) __PYX_ERR(1, 844, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_kwarg->__pyx___name, __pyx_t_1) < 0)) __PYX_ERR(1, 944, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - /* "dependency_injector/providers.pyx":845 + /* "dependency_injector/providers.pyx":945 * kwarg = self.__kwargs[index] * kwargs[kwarg.__name] = kwarg.__value * return kwargs # <<<<<<<<<<<<<< @@ -16266,7 +18254,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6kwargs___g __pyx_r = __pyx_v_kwargs; goto __pyx_L0; - /* "dependency_injector/providers.pyx":835 + /* "dependency_injector/providers.pyx":935 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -16287,7 +18275,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_6kwargs___g return __pyx_r; } -/* "dependency_injector/providers.pyx":847 +/* "dependency_injector/providers.pyx":947 * return kwargs * * def add_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -16327,16 +18315,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_12add_kwarg int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_kwargs", 0); - /* "dependency_injector/providers.pyx":852 + /* "dependency_injector/providers.pyx":952 * :return: Reference ``self`` * """ * self.__kwargs += parse_named_injections(kwargs) # <<<<<<<<<<<<<< * self.__kwargs_len = len(self.__kwargs) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 852, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 952, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___kwargs, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 852, __pyx_L1_error) + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___kwargs, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 952, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GIVEREF(__pyx_t_2); @@ -16345,7 +18333,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_12add_kwarg __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":853 + /* "dependency_injector/providers.pyx":953 * """ * self.__kwargs += parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) # <<<<<<<<<<<<<< @@ -16356,13 +18344,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_12add_kwarg __Pyx_INCREF(__pyx_t_2); if (unlikely(__pyx_t_2 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 853, __pyx_L1_error) + __PYX_ERR(1, 953, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 853, __pyx_L1_error) + __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 953, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_self->__pyx___kwargs_len = __pyx_t_3; - /* "dependency_injector/providers.pyx":854 + /* "dependency_injector/providers.pyx":954 * self.__kwargs += parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) * return self # <<<<<<<<<<<<<< @@ -16374,7 +18362,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_12add_kwarg __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":847 + /* "dependency_injector/providers.pyx":947 * return kwargs * * def add_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -16394,7 +18382,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_12add_kwarg return __pyx_r; } -/* "dependency_injector/providers.pyx":856 +/* "dependency_injector/providers.pyx":956 * return self * * def set_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -16433,14 +18421,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_14set_kwarg int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_kwargs", 0); - /* "dependency_injector/providers.pyx":863 + /* "dependency_injector/providers.pyx":963 * :return: Reference ``self`` * """ * self.__kwargs = parse_named_injections(kwargs) # <<<<<<<<<<<<<< * self.__kwargs_len = len(self.__kwargs) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 863, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 963, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___kwargs); @@ -16448,7 +18436,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_14set_kwarg __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":864 + /* "dependency_injector/providers.pyx":964 * """ * self.__kwargs = parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) # <<<<<<<<<<<<<< @@ -16459,13 +18447,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_14set_kwarg __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 864, __pyx_L1_error) + __PYX_ERR(1, 964, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 864, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 964, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___kwargs_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":865 + /* "dependency_injector/providers.pyx":965 * self.__kwargs = parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) * return self # <<<<<<<<<<<<<< @@ -16477,7 +18465,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_14set_kwarg __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":856 + /* "dependency_injector/providers.pyx":956 * return self * * def set_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -16496,7 +18484,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_14set_kwarg return __pyx_r; } -/* "dependency_injector/providers.pyx":867 +/* "dependency_injector/providers.pyx":967 * return self * * def clear_kwargs(self): # <<<<<<<<<<<<<< @@ -16528,14 +18516,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_16clear_kwa int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_kwargs", 0); - /* "dependency_injector/providers.pyx":872 + /* "dependency_injector/providers.pyx":972 * :return: Reference ``self`` * """ * self.__kwargs = tuple() # <<<<<<<<<<<<<< * self.__kwargs_len = len(self.__kwargs) * return self */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 872, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 972, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___kwargs); @@ -16543,7 +18531,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_16clear_kwa __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":873 + /* "dependency_injector/providers.pyx":973 * """ * self.__kwargs = tuple() * self.__kwargs_len = len(self.__kwargs) # <<<<<<<<<<<<<< @@ -16554,13 +18542,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_16clear_kwa __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 873, __pyx_L1_error) + __PYX_ERR(1, 973, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 873, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 973, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___kwargs_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":874 + /* "dependency_injector/providers.pyx":974 * self.__kwargs = tuple() * self.__kwargs_len = len(self.__kwargs) * return self # <<<<<<<<<<<<<< @@ -16572,7 +18560,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_16clear_kwa __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":867 + /* "dependency_injector/providers.pyx":967 * return self * * def clear_kwargs(self): # <<<<<<<<<<<<<< @@ -16591,7 +18579,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_16clear_kwa return __pyx_r; } -/* "dependency_injector/providers.pyx":876 +/* "dependency_injector/providers.pyx":976 * return self * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -16622,7 +18610,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Callable__provide(str if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 876, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 976, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_8Callable_19_provide)) { __Pyx_XDECREF(__pyx_r); @@ -16642,7 +18630,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Callable__provide(str #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 876, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 976, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -16650,13 +18638,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Callable__provide(str #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 876, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 976, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 876, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 976, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -16667,7 +18655,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Callable__provide(str __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 876, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 976, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -16690,7 +18678,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Callable__provide(str #endif } - /* "dependency_injector/providers.pyx":878 + /* "dependency_injector/providers.pyx":978 * cpdef object _provide(self, tuple args, dict kwargs): * """Return result of provided callable's call.""" * return __callable_call(self, args, kwargs) # <<<<<<<<<<<<<< @@ -16698,13 +18686,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Callable__provide(str * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___callable_call(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 878, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___callable_call(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 978, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":876 + /* "dependency_injector/providers.pyx":976 * return self * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -16762,11 +18750,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Callable_19_provide( case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 876, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 976, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 876, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 976, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -16779,14 +18767,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Callable_19_provide( } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 876, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 976, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Callable._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 876, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 876, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 976, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 976, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_8Callable_18_provide(((struct __pyx_obj_19dependency_injector_9providers_Callable *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -16807,7 +18795,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_18_provide( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_8Callable__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 876, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_8Callable__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 976, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -16852,9 +18840,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_20__reduce_ PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; - int __pyx_t_4; + PyObject *__pyx_t_4 = NULL; int __pyx_t_5; int __pyx_t_6; + int __pyx_t_7; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -16863,62 +18852,67 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_20__reduce_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(7); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(8); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v_self->__pyx___args); __Pyx_GIVEREF(__pyx_v_self->__pyx___args); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->__pyx___args); + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->__pyx___args); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2); __Pyx_INCREF(__pyx_v_self->__pyx___kwargs); __Pyx_GIVEREF(__pyx_v_self->__pyx___kwargs); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_self->__pyx___kwargs); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_3, 3, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_v_self->__pyx___kwargs); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_4, 4, __pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_4, 5, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_4, 6, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_3, 6, __pyx_v_self->__pyx___provides); + PyTuple_SET_ITEM(__pyx_t_4, 7, __pyx_v_self->__pyx___provides); __pyx_t_1 = 0; __pyx_t_2 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_4); + __pyx_t_4 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_v__dict = __pyx_t_3; - __pyx_t_3 = 0; + __pyx_t_4 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_v__dict = __pyx_t_4; + __pyx_t_4 = 0; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_4 = (__pyx_v__dict != Py_None); - __pyx_t_5 = (__pyx_t_4 != 0); - if (__pyx_t_5) { + __pyx_t_5 = (__pyx_v__dict != Py_None); + __pyx_t_6 = (__pyx_t_5 != 0); + if (__pyx_t_6) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -16927,16 +18921,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_20__reduce_ * use_setstate = True * else: */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__dict); + __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3)); + __pyx_t_3 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -16948,7 +18942,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_20__reduce_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -16962,42 +18956,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_20__reduce_ * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Callable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_Callable, (type(self), 0x3e02ba6, None), state */ /*else*/ { - __pyx_t_4 = (__pyx_v_self->__pyx___args != ((PyObject*)Py_None)); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (__pyx_v_self->__pyx___args != ((PyObject*)Py_None)); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx___kwargs != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx___kwargs != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (__pyx_v_self->__pyx___provides != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - __pyx_t_5 = __pyx_t_6; + __pyx_t_5 = (__pyx_v_self->__pyx___provides != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + __pyx_t_6 = __pyx_t_7; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_5; + __pyx_v_use_setstate = __pyx_t_6; } __pyx_L3:; @@ -17005,89 +18999,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_20__reduce_ * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Callable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_Callable, (type(self), 0x3e02ba6, None), state * else: */ - __pyx_t_5 = (__pyx_v_use_setstate != 0); - if (__pyx_t_5) { + __pyx_t_6 = (__pyx_v_use_setstate != 0); + if (__pyx_t_6) { /* "(tree fragment)":13 * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_Callable, (type(self), 0x03251dc, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Callable, (type(self), 0x3e02ba6, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Callable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_Callable, (type(self), 0x3e02ba6, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_Callable); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_Callable); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, Py_None); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); __pyx_t_3 = 0; - __pyx_r = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Callable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_Callable, (type(self), 0x3e02ba6, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Callable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_Callable, (type(self), 0x3e02ba6, None), state * else: - * return __pyx_unpickle_Callable, (type(self), 0x03251dc, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Callable, (type(self), 0x3e02ba6, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Callable__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Callable); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_Callable); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); - __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); - __pyx_t_1 = 0; - __pyx_t_3 = 0; - __pyx_r = __pyx_t_2; + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state); + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_3; + __pyx_t_3 = 0; goto __pyx_L0; } @@ -17102,6 +19096,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_20__reduce_ __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("dependency_injector.providers.Callable.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -17114,7 +19109,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_20__reduce_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Callable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_Callable, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Callable__set_state(self, __pyx_state) */ @@ -17142,7 +19137,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_22__setstat __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Callable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_Callable, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Callable__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -17153,7 +19148,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Callable_22__setstat /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Callable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_Callable, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Callable__set_state(self, __pyx_state) */ @@ -17199,9 +19194,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable__ PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; - int __pyx_t_4; + PyObject *__pyx_t_4 = NULL; int __pyx_t_5; int __pyx_t_6; + int __pyx_t_7; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -17210,62 +19206,67 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable__ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(7); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(8); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___args); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->__pyx_base.__pyx___args); + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___kwargs); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___kwargs); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_self->__pyx_base.__pyx___kwargs); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_3, 3, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_v_self->__pyx_base.__pyx___kwargs); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_4, 4, __pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_4, 5, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_4, 6, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_3, 6, __pyx_v_self->__pyx_base.__pyx___provides); + PyTuple_SET_ITEM(__pyx_t_4, 7, __pyx_v_self->__pyx_base.__pyx___provides); __pyx_t_1 = 0; __pyx_t_2 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_4); + __pyx_t_4 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_v__dict = __pyx_t_3; - __pyx_t_3 = 0; + __pyx_t_4 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_v__dict = __pyx_t_4; + __pyx_t_4 = 0; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_4 = (__pyx_v__dict != Py_None); - __pyx_t_5 = (__pyx_t_4 != 0); - if (__pyx_t_5) { + __pyx_t_5 = (__pyx_v__dict != Py_None); + __pyx_t_6 = (__pyx_t_5 != 0); + if (__pyx_t_6) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -17274,16 +19275,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable__ * use_setstate = True * else: */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__dict); + __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3)); + __pyx_t_3 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -17295,7 +19296,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable__ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -17309,42 +19310,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable__ * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_DelegatedCallable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_DelegatedCallable, (type(self), 0x3e02ba6, None), state */ /*else*/ { - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___args != ((PyObject*)Py_None)); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___args != ((PyObject*)Py_None)); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - __pyx_t_5 = __pyx_t_6; + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + __pyx_t_6 = __pyx_t_7; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_5; + __pyx_v_use_setstate = __pyx_t_6; } __pyx_L3:; @@ -17352,89 +19353,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable__ * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedCallable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_DelegatedCallable, (type(self), 0x3e02ba6, None), state * else: */ - __pyx_t_5 = (__pyx_v_use_setstate != 0); - if (__pyx_t_5) { + __pyx_t_6 = (__pyx_v_use_setstate != 0); + if (__pyx_t_6) { /* "(tree fragment)":13 * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_DelegatedCallable, (type(self), 0x03251dc, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedCallable, (type(self), 0x3e02ba6, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_DelegatedCallable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_DelegatedCallable, (type(self), 0x3e02ba6, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_DelegatedCallable); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_DelegatedCallable); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, Py_None); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); __pyx_t_3 = 0; - __pyx_r = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedCallable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_DelegatedCallable, (type(self), 0x3e02ba6, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_DelegatedCallable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_DelegatedCallable, (type(self), 0x3e02ba6, None), state * else: - * return __pyx_unpickle_DelegatedCallable, (type(self), 0x03251dc, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedCallable, (type(self), 0x3e02ba6, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedCallable__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_DelegatedCallable); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_DelegatedCallable); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); - __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); - __pyx_t_1 = 0; - __pyx_t_3 = 0; - __pyx_r = __pyx_t_2; + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state); + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_3; + __pyx_t_3 = 0; goto __pyx_L0; } @@ -17449,6 +19450,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable__ __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("dependency_injector.providers.DelegatedCallable.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -17461,7 +19463,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable__ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedCallable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_DelegatedCallable, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedCallable__set_state(self, __pyx_state) */ @@ -17489,7 +19491,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable_2 __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_DelegatedCallable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_DelegatedCallable, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedCallable__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -17500,7 +19502,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable_2 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedCallable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_DelegatedCallable, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedCallable__set_state(self, __pyx_state) */ @@ -17518,7 +19520,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17DelegatedCallable_2 return __pyx_r; } -/* "dependency_injector/providers.pyx":900 +/* "dependency_injector/providers.pyx":1000 * """ * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -17571,27 +19573,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable___ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__call__", 0); - /* "dependency_injector/providers.pyx":905 + /* "dependency_injector/providers.pyx":1005 * Callable interface implementation. * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) */ __pyx_t_1 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) == Py_None); __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":906 + /* "dependency_injector/providers.pyx":1006 * """ * if self.__last_overriding is None: * raise Error('{0} must be overridden before calling'.format(self)) # <<<<<<<<<<<<<< - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) * */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 906, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1006, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 906, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1006, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -17605,7 +19607,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable___ } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, ((PyObject *)__pyx_v_self)) : __Pyx_PyObject_CallOneArg(__pyx_t_6, ((PyObject *)__pyx_v_self)); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 906, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1006, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -17621,37 +19623,52 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable___ __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 906, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1006, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 906, __pyx_L1_error) + __PYX_ERR(1, 1006, __pyx_L1_error) - /* "dependency_injector/providers.pyx":905 + /* "dependency_injector/providers.pyx":1005 * Callable interface implementation. * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) */ } - /* "dependency_injector/providers.pyx":907 + /* "dependency_injector/providers.pyx":1007 * if self.__last_overriding is None: * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) # <<<<<<<<<<<<<< + * return super().__call__(*args, **kwargs) # <<<<<<<<<<<<<< * * def override(self, provider): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 907, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1007, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_r = __pyx_t_3; - __pyx_t_3 = 0; + __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractCallable)); + __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractCallable)); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractCallable)); + __Pyx_INCREF(((PyObject *)__pyx_v_self)); + __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); + PyTuple_SET_ITEM(__pyx_t_3, 1, ((PyObject *)__pyx_v_self)); + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1007, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_call); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1007, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1007, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_r = __pyx_t_4; + __pyx_t_4 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":900 + /* "dependency_injector/providers.pyx":1000 * """ * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -17674,8 +19691,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable___ return __pyx_r; } -/* "dependency_injector/providers.pyx":909 - * return self.__last_overriding(*args, **kwargs) +/* "dependency_injector/providers.pyx":1009 + * return super().__call__(*args, **kwargs) * * def override(self, provider): # <<<<<<<<<<<<<< * """Override provider with another provider. @@ -17713,7 +19730,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/providers.pyx":920 + /* "dependency_injector/providers.pyx":1020 * :rtype: :py:class:`OverridingContext` * """ * if not isinstance(provider, Callable): # <<<<<<<<<<<<<< @@ -17724,24 +19741,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o __pyx_t_2 = ((!(__pyx_t_1 != 0)) != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":921 + /* "dependency_injector/providers.pyx":1021 * """ * if not isinstance(provider, Callable): * raise Error('{0} must be overridden only by ' # <<<<<<<<<<<<<< * '{1} providers'.format(self, Callable)) * return super(AbstractCallable, self).override(provider) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 921, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1021, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/providers.pyx":922 + /* "dependency_injector/providers.pyx":1022 * if not isinstance(provider, Callable): * raise Error('{0} must be overridden only by ' * '{1} providers'.format(self, Callable)) # <<<<<<<<<<<<<< * return super(AbstractCallable, self).override(provider) * */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_only_by_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 922, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_only_by_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1022, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_8 = 0; @@ -17758,7 +19775,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, ((PyObject *)__pyx_v_self), ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 922, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1022, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else @@ -17766,13 +19783,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, ((PyObject *)__pyx_v_self), ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 922, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1022, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 922, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1022, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -17783,7 +19800,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 922, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1022, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } @@ -17801,14 +19818,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 921, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1021, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 921, __pyx_L1_error) + __PYX_ERR(1, 1021, __pyx_L1_error) - /* "dependency_injector/providers.pyx":920 + /* "dependency_injector/providers.pyx":1020 * :rtype: :py:class:`OverridingContext` * """ * if not isinstance(provider, Callable): # <<<<<<<<<<<<<< @@ -17817,7 +19834,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o */ } - /* "dependency_injector/providers.pyx":923 + /* "dependency_injector/providers.pyx":1023 * raise Error('{0} must be overridden only by ' * '{1} providers'.format(self, Callable)) * return super(AbstractCallable, self).override(provider) # <<<<<<<<<<<<<< @@ -17825,7 +19842,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o * cpdef object _provide(self, tuple args, dict kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 923, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1023, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractCallable)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractCallable)); @@ -17833,10 +19850,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 923, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1023, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 923, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1023, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -17851,15 +19868,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_provider); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 923, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1023, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":909 - * return self.__last_overriding(*args, **kwargs) + /* "dependency_injector/providers.pyx":1009 + * return super().__call__(*args, **kwargs) * * def override(self, provider): # <<<<<<<<<<<<<< * """Override provider with another provider. @@ -17882,7 +19899,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_2o return __pyx_r; } -/* "dependency_injector/providers.pyx":925 +/* "dependency_injector/providers.pyx":1025 * return super(AbstractCallable, self).override(provider) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -17913,7 +19930,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16AbstractCallable__pr if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 925, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1025, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_16AbstractCallable_5_provide)) { __Pyx_XDECREF(__pyx_r); @@ -17933,7 +19950,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16AbstractCallable__pr #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 925, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1025, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -17941,13 +19958,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16AbstractCallable__pr #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 925, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1025, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 925, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1025, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -17958,7 +19975,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16AbstractCallable__pr __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 925, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1025, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -17981,20 +19998,20 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16AbstractCallable__pr #endif } - /* "dependency_injector/providers.pyx":927 + /* "dependency_injector/providers.pyx":1027 * cpdef object _provide(self, tuple args, dict kwargs): * """Return result of provided callable's call.""" * raise NotImplementedError('Abstract provider forward providing logic ' # <<<<<<<<<<<<<< * 'to overriding provider') * */ - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_tuple__6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 927, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_tuple__6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1027, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 927, __pyx_L1_error) + __PYX_ERR(1, 1027, __pyx_L1_error) - /* "dependency_injector/providers.pyx":925 + /* "dependency_injector/providers.pyx":1025 * return super(AbstractCallable, self).override(provider) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -18052,11 +20069,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_16AbstractCallable_5_ case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 925, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 1025, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 925, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 1025, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -18069,14 +20086,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_16AbstractCallable_5_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 925, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1025, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.AbstractCallable._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 925, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 925, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 1025, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 1025, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_16AbstractCallable_4_provide(((struct __pyx_obj_19dependency_injector_9providers_AbstractCallable *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -18097,7 +20114,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_4_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_16AbstractCallable__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 925, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_16AbstractCallable__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1025, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -18142,9 +20159,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_6_ PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; - int __pyx_t_4; + PyObject *__pyx_t_4 = NULL; int __pyx_t_5; int __pyx_t_6; + int __pyx_t_7; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -18153,62 +20171,67 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_6_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(7); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(8); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___args); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->__pyx_base.__pyx___args); + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___kwargs); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___kwargs); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_self->__pyx_base.__pyx___kwargs); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_3, 3, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_v_self->__pyx_base.__pyx___kwargs); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_4, 4, __pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_4, 5, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_4, 6, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_3, 6, __pyx_v_self->__pyx_base.__pyx___provides); + PyTuple_SET_ITEM(__pyx_t_4, 7, __pyx_v_self->__pyx_base.__pyx___provides); __pyx_t_1 = 0; __pyx_t_2 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_4); + __pyx_t_4 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_v__dict = __pyx_t_3; - __pyx_t_3 = 0; + __pyx_t_4 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_v__dict = __pyx_t_4; + __pyx_t_4 = 0; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_4 = (__pyx_v__dict != Py_None); - __pyx_t_5 = (__pyx_t_4 != 0); - if (__pyx_t_5) { + __pyx_t_5 = (__pyx_v__dict != Py_None); + __pyx_t_6 = (__pyx_t_5 != 0); + if (__pyx_t_6) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -18217,16 +20240,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_6_ * use_setstate = True * else: */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__dict); + __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3)); + __pyx_t_3 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -18238,7 +20261,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_6_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -18252,42 +20275,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_6_ * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_AbstractCallable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_AbstractCallable, (type(self), 0x3e02ba6, None), state */ /*else*/ { - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___args != ((PyObject*)Py_None)); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___args != ((PyObject*)Py_None)); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - __pyx_t_5 = __pyx_t_6; + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + __pyx_t_6 = __pyx_t_7; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_5; + __pyx_v_use_setstate = __pyx_t_6; } __pyx_L3:; @@ -18295,89 +20318,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_6_ * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_AbstractCallable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_AbstractCallable, (type(self), 0x3e02ba6, None), state * else: */ - __pyx_t_5 = (__pyx_v_use_setstate != 0); - if (__pyx_t_5) { + __pyx_t_6 = (__pyx_v_use_setstate != 0); + if (__pyx_t_6) { /* "(tree fragment)":13 * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_AbstractCallable, (type(self), 0x03251dc, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_AbstractCallable, (type(self), 0x3e02ba6, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_AbstractCallable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_AbstractCallable, (type(self), 0x3e02ba6, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_AbstractCallable); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_AbstractCallable); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, Py_None); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); __pyx_t_3 = 0; - __pyx_r = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_AbstractCallable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_AbstractCallable, (type(self), 0x3e02ba6, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_AbstractCallable, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_AbstractCallable, (type(self), 0x3e02ba6, None), state * else: - * return __pyx_unpickle_AbstractCallable, (type(self), 0x03251dc, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_AbstractCallable, (type(self), 0x3e02ba6, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_AbstractCallable__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_AbstractCallable); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_AbstractCallable); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); - __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); - __pyx_t_1 = 0; - __pyx_t_3 = 0; - __pyx_r = __pyx_t_2; + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state); + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_3; + __pyx_t_3 = 0; goto __pyx_L0; } @@ -18392,6 +20415,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_6_ __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("dependency_injector.providers.AbstractCallable.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -18404,7 +20428,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_6_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_AbstractCallable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_AbstractCallable, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractCallable__set_state(self, __pyx_state) */ @@ -18432,7 +20456,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_8_ __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_AbstractCallable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_AbstractCallable, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_AbstractCallable__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -18443,7 +20467,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_8_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_AbstractCallable, (type(self), 0x03251dc, state) + * return __pyx_unpickle_AbstractCallable, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractCallable__set_state(self, __pyx_state) */ @@ -18461,7 +20485,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16AbstractCallable_8_ return __pyx_r; } -/* "dependency_injector/providers.pyx":941 +/* "dependency_injector/providers.pyx":1041 * """ * * def __init__(self, callable): # <<<<<<<<<<<<<< @@ -18502,7 +20526,7 @@ static int __pyx_pw_19dependency_injector_9providers_16CallableDelegate_1__init_ else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 941, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 1041, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -18513,7 +20537,7 @@ static int __pyx_pw_19dependency_injector_9providers_16CallableDelegate_1__init_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 941, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1041, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.CallableDelegate.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -18544,7 +20568,7 @@ static int __pyx_pf_19dependency_injector_9providers_16CallableDelegate___init__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":947 + /* "dependency_injector/providers.pyx":1047 * :type callable: object * """ * if isinstance(callable, Callable) is False: # <<<<<<<<<<<<<< @@ -18555,26 +20579,26 @@ static int __pyx_pf_19dependency_injector_9providers_16CallableDelegate___init__ __pyx_t_2 = ((__pyx_t_1 == 0) != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":948 + /* "dependency_injector/providers.pyx":1048 * """ * if isinstance(callable, Callable) is False: * raise Error('{0} can wrap only {1} providers'.format( # <<<<<<<<<<<<<< * self.__class__, Callable)) * super(CallableDelegate, self).__init__(callable) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 948, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1048, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_wrap_only_1_providers, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 948, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_wrap_only_1_providers, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1048, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - /* "dependency_injector/providers.pyx":949 + /* "dependency_injector/providers.pyx":1049 * if isinstance(callable, Callable) is False: * raise Error('{0} can wrap only {1} providers'.format( * self.__class__, Callable)) # <<<<<<<<<<<<<< * super(CallableDelegate, self).__init__(callable) * */ - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 949, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1049, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_9 = 0; @@ -18591,7 +20615,7 @@ static int __pyx_pf_19dependency_injector_9providers_16CallableDelegate___init__ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 948, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1048, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; @@ -18600,14 +20624,14 @@ static int __pyx_pf_19dependency_injector_9providers_16CallableDelegate___init__ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 948, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1048, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { - __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 948, __pyx_L1_error) + __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1048, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_8); __pyx_t_8 = NULL; @@ -18618,7 +20642,7 @@ static int __pyx_pf_19dependency_injector_9providers_16CallableDelegate___init__ __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)); PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_9, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)); __pyx_t_7 = 0; - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 948, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1048, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } @@ -18636,14 +20660,14 @@ static int __pyx_pf_19dependency_injector_9providers_16CallableDelegate___init__ __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 948, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1048, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 948, __pyx_L1_error) + __PYX_ERR(1, 1048, __pyx_L1_error) - /* "dependency_injector/providers.pyx":947 + /* "dependency_injector/providers.pyx":1047 * :type callable: object * """ * if isinstance(callable, Callable) is False: # <<<<<<<<<<<<<< @@ -18652,14 +20676,14 @@ static int __pyx_pf_19dependency_injector_9providers_16CallableDelegate___init__ */ } - /* "dependency_injector/providers.pyx":950 + /* "dependency_injector/providers.pyx":1050 * raise Error('{0} can wrap only {1} providers'.format( * self.__class__, Callable)) * super(CallableDelegate, self).__init__(callable) # <<<<<<<<<<<<<< * * */ - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 950, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1050, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_CallableDelegate)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_CallableDelegate)); @@ -18667,10 +20691,10 @@ static int __pyx_pf_19dependency_injector_9providers_16CallableDelegate___init__ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 950, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1050, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 950, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1050, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -18685,12 +20709,12 @@ static int __pyx_pf_19dependency_injector_9providers_16CallableDelegate___init__ } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_callable) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_callable); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 950, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1050, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":941 + /* "dependency_injector/providers.pyx":1041 * """ * * def __init__(self, callable): # <<<<<<<<<<<<<< @@ -18742,9 +20766,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_2_ PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -18755,46 +20779,51 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_2_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx___provides); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___provides); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -18803,16 +20832,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_2_ * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -18824,7 +20853,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_2_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -18838,28 +20867,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_2_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_CallableDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_CallableDelegate, (type(self), 0x328787b, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -18867,44 +20896,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_2_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_CallableDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_CallableDelegate, (type(self), 0x328787b, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_CallableDelegate, (type(self), 0x3f4a3b6, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_CallableDelegate, (type(self), 0x328787b, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_CallableDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_CallableDelegate, (type(self), 0x328787b, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_CallableDelegate); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_CallableDelegate); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -18913,15 +20942,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_2_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_CallableDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_CallableDelegate, (type(self), 0x328787b, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_CallableDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_CallableDelegate, (type(self), 0x328787b, None), state * else: - * return __pyx_unpickle_CallableDelegate, (type(self), 0x3f4a3b6, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_CallableDelegate, (type(self), 0x328787b, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_CallableDelegate__set_state(self, __pyx_state) */ @@ -18929,27 +20958,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_2_ __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_CallableDelegate); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -18962,7 +20991,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_2_ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.CallableDelegate.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -18976,7 +21005,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_2_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_CallableDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_CallableDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_CallableDelegate__set_state(self, __pyx_state) */ @@ -19004,7 +21033,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_4_ __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_CallableDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_CallableDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_CallableDelegate__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -19015,7 +21044,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_4_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_CallableDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_CallableDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_CallableDelegate__set_state(self, __pyx_state) */ @@ -19033,7 +21062,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16CallableDelegate_4_ return __pyx_r; } -/* "dependency_injector/providers.pyx":979 +/* "dependency_injector/providers.pyx":1079 * _is_coroutine = _is_coroutine_marker * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -19090,7 +21119,7 @@ static int __pyx_pw_19dependency_injector_9providers_9Coroutine_1__init__(PyObje } if (unlikely(kw_args > 0)) { const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 979, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 1079, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { goto __pyx_L5_argtuple_error; @@ -19101,7 +21130,7 @@ static int __pyx_pw_19dependency_injector_9providers_9Coroutine_1__init__(PyObje } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 979, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1079, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; @@ -19136,28 +21165,28 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":985 + /* "dependency_injector/providers.pyx":1085 * :type provides: callable * """ * if not asyncio: # <<<<<<<<<<<<<< * raise Error('Package asyncio is not available') * */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 985, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1085, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 985, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 1085, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = ((!__pyx_t_2) != 0); if (unlikely(__pyx_t_3)) { - /* "dependency_injector/providers.pyx":986 + /* "dependency_injector/providers.pyx":1086 * """ * if not asyncio: * raise Error('Package asyncio is not available') # <<<<<<<<<<<<<< * * if not asyncio.iscoroutinefunction(provides): */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 986, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1086, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { @@ -19171,14 +21200,14 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct } __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_kp_s_Package_asyncio_is_not_available) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_kp_s_Package_asyncio_is_not_available); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 986, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1086, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 986, __pyx_L1_error) + __PYX_ERR(1, 1086, __pyx_L1_error) - /* "dependency_injector/providers.pyx":985 + /* "dependency_injector/providers.pyx":1085 * :type provides: callable * """ * if not asyncio: # <<<<<<<<<<<<<< @@ -19187,16 +21216,16 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct */ } - /* "dependency_injector/providers.pyx":988 + /* "dependency_injector/providers.pyx":1088 * raise Error('Package asyncio is not available') * * if not asyncio.iscoroutinefunction(provides): # <<<<<<<<<<<<<< * raise Error('Provider {0} expected to get coroutine function, ' * 'got {1}'.format('.'.join((self.__class__.__module__, */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 988, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1088, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_iscoroutinefunction); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 988, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_iscoroutinefunction); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1088, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; @@ -19211,60 +21240,60 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct } __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_v_provides) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_provides); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 988, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1088, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(1, 988, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(1, 1088, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_2 = ((!__pyx_t_3) != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":989 + /* "dependency_injector/providers.pyx":1089 * * if not asyncio.iscoroutinefunction(provides): * raise Error('Provider {0} expected to get coroutine function, ' # <<<<<<<<<<<<<< * 'got {1}'.format('.'.join((self.__class__.__module__, * self.__class__.__name__)), */ - __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_Error); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 989, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_Error); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1089, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - /* "dependency_injector/providers.pyx":990 + /* "dependency_injector/providers.pyx":1090 * if not asyncio.iscoroutinefunction(provides): * raise Error('Provider {0} expected to get coroutine function, ' * 'got {1}'.format('.'.join((self.__class__.__module__, # <<<<<<<<<<<<<< * self.__class__.__name__)), * provides)) */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Provider_0_expected_to_get_corou, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 990, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Provider_0_expected_to_get_corou, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1090, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 990, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1090, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_module); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 990, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_module); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1090, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/providers.pyx":991 + /* "dependency_injector/providers.pyx":1091 * raise Error('Provider {0} expected to get coroutine function, ' * 'got {1}'.format('.'.join((self.__class__.__module__, * self.__class__.__name__)), # <<<<<<<<<<<<<< * provides)) * */ - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 991, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1091, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_name); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 991, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_name); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1091, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/providers.pyx":990 + /* "dependency_injector/providers.pyx":1090 * if not asyncio.iscoroutinefunction(provides): * raise Error('Provider {0} expected to get coroutine function, ' * 'got {1}'.format('.'.join((self.__class__.__module__, # <<<<<<<<<<<<<< * self.__class__.__name__)), * provides)) */ - __pyx_t_7 = PyTuple_New(2); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 990, __pyx_L1_error) + __pyx_t_7 = PyTuple_New(2); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1090, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); @@ -19272,11 +21301,11 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct PyTuple_SET_ITEM(__pyx_t_7, 1, __pyx_t_9); __pyx_t_8 = 0; __pyx_t_9 = 0; - __pyx_t_9 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_7); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 990, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_7); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1090, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - /* "dependency_injector/providers.pyx":992 + /* "dependency_injector/providers.pyx":1092 * 'got {1}'.format('.'.join((self.__class__.__module__, * self.__class__.__name__)), * provides)) # <<<<<<<<<<<<<< @@ -19298,7 +21327,7 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_t_9, __pyx_v_provides}; - __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 990, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1090, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; @@ -19307,14 +21336,14 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_t_9, __pyx_v_provides}; - __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 990, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1090, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } else #endif { - __pyx_t_8 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 990, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1090, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -19325,7 +21354,7 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct __Pyx_GIVEREF(__pyx_v_provides); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_10, __pyx_v_provides); __pyx_t_9 = 0; - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 990, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1090, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } @@ -19343,14 +21372,14 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 989, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1089, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 989, __pyx_L1_error) + __PYX_ERR(1, 1089, __pyx_L1_error) - /* "dependency_injector/providers.pyx":988 + /* "dependency_injector/providers.pyx":1088 * raise Error('Package asyncio is not available') * * if not asyncio.iscoroutinefunction(provides): # <<<<<<<<<<<<<< @@ -19359,14 +21388,14 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct */ } - /* "dependency_injector/providers.pyx":994 + /* "dependency_injector/providers.pyx":1094 * provides)) * * super(Coroutine, self).__init__(provides, *args, **kwargs) # <<<<<<<<<<<<<< * * */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 994, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1094, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Coroutine)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Coroutine)); @@ -19374,27 +21403,27 @@ static int __pyx_pf_19dependency_injector_9providers_9Coroutine___init__(struct __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 994, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1094, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 994, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1094, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __pyx_t_5 = PyTuple_New(1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 994, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1094, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_INCREF(__pyx_v_provides); __Pyx_GIVEREF(__pyx_v_provides); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_v_provides); - __pyx_t_4 = PyNumber_Add(__pyx_t_5, __pyx_v_args); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 994, __pyx_L1_error) + __pyx_t_4 = PyNumber_Add(__pyx_t_5, __pyx_v_args); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1094, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_v_kwargs); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 994, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_v_kwargs); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1094, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":979 + /* "dependency_injector/providers.pyx":1079 * _is_coroutine = _is_coroutine_marker * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -19448,9 +21477,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Coroutine_2__reduce_ PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; - int __pyx_t_4; + PyObject *__pyx_t_4 = NULL; int __pyx_t_5; int __pyx_t_6; + int __pyx_t_7; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -19459,62 +21489,67 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Coroutine_2__reduce_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(7); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(8); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___args); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->__pyx_base.__pyx___args); + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___kwargs); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___kwargs); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_self->__pyx_base.__pyx___kwargs); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_3, 3, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_v_self->__pyx_base.__pyx___kwargs); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_4, 4, __pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_4, 5, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_4, 6, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_3, 6, __pyx_v_self->__pyx_base.__pyx___provides); + PyTuple_SET_ITEM(__pyx_t_4, 7, __pyx_v_self->__pyx_base.__pyx___provides); __pyx_t_1 = 0; __pyx_t_2 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_4); + __pyx_t_4 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_v__dict = __pyx_t_3; - __pyx_t_3 = 0; + __pyx_t_4 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_v__dict = __pyx_t_4; + __pyx_t_4 = 0; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_4 = (__pyx_v__dict != Py_None); - __pyx_t_5 = (__pyx_t_4 != 0); - if (__pyx_t_5) { + __pyx_t_5 = (__pyx_v__dict != Py_None); + __pyx_t_6 = (__pyx_t_5 != 0); + if (__pyx_t_6) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -19523,16 +21558,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Coroutine_2__reduce_ * use_setstate = True * else: */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__dict); + __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3)); + __pyx_t_3 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -19544,7 +21579,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Coroutine_2__reduce_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -19558,42 +21593,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Coroutine_2__reduce_ * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Coroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_Coroutine, (type(self), 0x3e02ba6, None), state */ /*else*/ { - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___args != ((PyObject*)Py_None)); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___args != ((PyObject*)Py_None)); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - __pyx_t_5 = __pyx_t_6; + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + __pyx_t_6 = __pyx_t_7; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_5; + __pyx_v_use_setstate = __pyx_t_6; } __pyx_L3:; @@ -19601,89 +21636,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Coroutine_2__reduce_ * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Coroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_Coroutine, (type(self), 0x3e02ba6, None), state * else: */ - __pyx_t_5 = (__pyx_v_use_setstate != 0); - if (__pyx_t_5) { + __pyx_t_6 = (__pyx_v_use_setstate != 0); + if (__pyx_t_6) { /* "(tree fragment)":13 * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_Coroutine, (type(self), 0x03251dc, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Coroutine, (type(self), 0x3e02ba6, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Coroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_Coroutine, (type(self), 0x3e02ba6, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_Coroutine); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_Coroutine); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, Py_None); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); __pyx_t_3 = 0; - __pyx_r = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Coroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_Coroutine, (type(self), 0x3e02ba6, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Coroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_Coroutine, (type(self), 0x3e02ba6, None), state * else: - * return __pyx_unpickle_Coroutine, (type(self), 0x03251dc, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Coroutine, (type(self), 0x3e02ba6, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Coroutine__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Coroutine); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_Coroutine); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); - __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); - __pyx_t_1 = 0; - __pyx_t_3 = 0; - __pyx_r = __pyx_t_2; + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state); + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_3; + __pyx_t_3 = 0; goto __pyx_L0; } @@ -19698,6 +21733,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Coroutine_2__reduce_ __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("dependency_injector.providers.Coroutine.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -19710,7 +21746,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Coroutine_2__reduce_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Coroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_Coroutine, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Coroutine__set_state(self, __pyx_state) */ @@ -19738,7 +21774,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Coroutine_4__setstat __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Coroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_Coroutine, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Coroutine__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -19749,7 +21785,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Coroutine_4__setstat /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Coroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_Coroutine, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Coroutine__set_state(self, __pyx_state) */ @@ -19795,9 +21831,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; - int __pyx_t_4; + PyObject *__pyx_t_4 = NULL; int __pyx_t_5; int __pyx_t_6; + int __pyx_t_7; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -19806,62 +21843,67 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(7); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(8); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___args); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->__pyx_base.__pyx_base.__pyx___args); + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->__pyx_base.__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_3, 3, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_4, 4, __pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_4, 5, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_4, 6, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_3, 6, __pyx_v_self->__pyx_base.__pyx_base.__pyx___provides); + PyTuple_SET_ITEM(__pyx_t_4, 7, __pyx_v_self->__pyx_base.__pyx_base.__pyx___provides); __pyx_t_1 = 0; __pyx_t_2 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_4); + __pyx_t_4 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_v__dict = __pyx_t_3; - __pyx_t_3 = 0; + __pyx_t_4 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_v__dict = __pyx_t_4; + __pyx_t_4 = 0; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_4 = (__pyx_v__dict != Py_None); - __pyx_t_5 = (__pyx_t_4 != 0); - if (__pyx_t_5) { + __pyx_t_5 = (__pyx_v__dict != Py_None); + __pyx_t_6 = (__pyx_t_5 != 0); + if (__pyx_t_6) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -19870,16 +21912,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ * use_setstate = True * else: */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__dict); + __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3)); + __pyx_t_3 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -19891,7 +21933,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -19905,42 +21947,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x3e02ba6, None), state */ /*else*/ { - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___args != ((PyObject*)Py_None)); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___args != ((PyObject*)Py_None)); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___provides != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - __pyx_t_5 = __pyx_t_6; + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___provides != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + __pyx_t_6 = __pyx_t_7; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_5; + __pyx_v_use_setstate = __pyx_t_6; } __pyx_L3:; @@ -19948,89 +21990,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x3e02ba6, None), state * else: */ - __pyx_t_5 = (__pyx_v_use_setstate != 0); - if (__pyx_t_5) { + __pyx_t_6 = (__pyx_v_use_setstate != 0); + if (__pyx_t_6) { /* "(tree fragment)":13 * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x03251dc, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x3e02ba6, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x3e02ba6, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_DelegatedCoroutin); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_DelegatedCoroutin); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, Py_None); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); __pyx_t_3 = 0; - __pyx_r = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x3e02ba6, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x3e02ba6, None), state * else: - * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x03251dc, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x3e02ba6, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedCoroutine__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_DelegatedCoroutin); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_DelegatedCoroutin); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); - __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); - __pyx_t_1 = 0; - __pyx_t_3 = 0; - __pyx_r = __pyx_t_2; + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state); + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_3; + __pyx_t_3 = 0; goto __pyx_L0; } @@ -20045,6 +22087,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("dependency_injector.providers.DelegatedCoroutine.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -20057,7 +22100,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedCoroutine__set_state(self, __pyx_state) */ @@ -20085,7 +22128,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedCoroutine__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -20096,7 +22139,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_DelegatedCoroutine, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedCoroutine__set_state(self, __pyx_state) */ @@ -20114,7 +22157,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedCoroutine_ return __pyx_r; } -/* "dependency_injector/providers.pyx":1016 +/* "dependency_injector/providers.pyx":1116 * """ * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -20167,27 +22210,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__call__", 0); - /* "dependency_injector/providers.pyx":1021 + /* "dependency_injector/providers.pyx":1121 * Callable interface implementation. * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) */ __pyx_t_1 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding) == Py_None); __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":1022 + /* "dependency_injector/providers.pyx":1122 * """ * if self.__last_overriding is None: * raise Error('{0} must be overridden before calling'.format(self)) # <<<<<<<<<<<<<< - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) * */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1022, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1122, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1022, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1122, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -20201,7 +22244,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine__ } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, ((PyObject *)__pyx_v_self)) : __Pyx_PyObject_CallOneArg(__pyx_t_6, ((PyObject *)__pyx_v_self)); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1022, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1122, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -20217,37 +22260,52 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine__ __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1022, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1122, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 1022, __pyx_L1_error) + __PYX_ERR(1, 1122, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1021 + /* "dependency_injector/providers.pyx":1121 * Callable interface implementation. * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) */ } - /* "dependency_injector/providers.pyx":1023 + /* "dependency_injector/providers.pyx":1123 * if self.__last_overriding is None: * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) # <<<<<<<<<<<<<< + * return super().__call__(*args, **kwargs) # <<<<<<<<<<<<<< * * def override(self, provider): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1023, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1123, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_r = __pyx_t_3; - __pyx_t_3 = 0; + __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractCoroutine)); + __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractCoroutine)); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractCoroutine)); + __Pyx_INCREF(((PyObject *)__pyx_v_self)); + __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); + PyTuple_SET_ITEM(__pyx_t_3, 1, ((PyObject *)__pyx_v_self)); + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1123, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_call); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1123, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1123, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_r = __pyx_t_4; + __pyx_t_4 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1016 + /* "dependency_injector/providers.pyx":1116 * """ * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -20270,8 +22328,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine__ return __pyx_r; } -/* "dependency_injector/providers.pyx":1025 - * return self.__last_overriding(*args, **kwargs) +/* "dependency_injector/providers.pyx":1125 + * return super().__call__(*args, **kwargs) * * def override(self, provider): # <<<<<<<<<<<<<< * """Override provider with another provider. @@ -20309,7 +22367,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/providers.pyx":1036 + /* "dependency_injector/providers.pyx":1136 * :rtype: :py:class:`OverridingContext` * """ * if not isinstance(provider, Coroutine): # <<<<<<<<<<<<<< @@ -20320,24 +22378,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 __pyx_t_2 = ((!(__pyx_t_1 != 0)) != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":1037 + /* "dependency_injector/providers.pyx":1137 * """ * if not isinstance(provider, Coroutine): * raise Error('{0} must be overridden only by ' # <<<<<<<<<<<<<< * '{1} providers'.format(self, Coroutine)) * return super(AbstractCoroutine, self).override(provider) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1037, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1137, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/providers.pyx":1038 + /* "dependency_injector/providers.pyx":1138 * if not isinstance(provider, Coroutine): * raise Error('{0} must be overridden only by ' * '{1} providers'.format(self, Coroutine)) # <<<<<<<<<<<<<< * return super(AbstractCoroutine, self).override(provider) * */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_only_by_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1038, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_only_by_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1138, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_8 = 0; @@ -20354,7 +22412,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, ((PyObject *)__pyx_v_self), ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Coroutine)}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1038, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1138, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else @@ -20362,13 +22420,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, ((PyObject *)__pyx_v_self), ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Coroutine)}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1038, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1138, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1038, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1138, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -20379,7 +22437,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Coroutine)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Coroutine)); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Coroutine)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1038, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1138, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } @@ -20397,14 +22455,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1037, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1137, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 1037, __pyx_L1_error) + __PYX_ERR(1, 1137, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1036 + /* "dependency_injector/providers.pyx":1136 * :rtype: :py:class:`OverridingContext` * """ * if not isinstance(provider, Coroutine): # <<<<<<<<<<<<<< @@ -20413,7 +22471,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 */ } - /* "dependency_injector/providers.pyx":1039 + /* "dependency_injector/providers.pyx":1139 * raise Error('{0} must be overridden only by ' * '{1} providers'.format(self, Coroutine)) * return super(AbstractCoroutine, self).override(provider) # <<<<<<<<<<<<<< @@ -20421,7 +22479,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 * cpdef object _provide(self, tuple args, dict kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1039, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1139, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractCoroutine)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractCoroutine)); @@ -20429,10 +22487,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1039, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1139, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1039, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1139, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -20447,15 +22505,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_provider); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1039, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1139, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1025 - * return self.__last_overriding(*args, **kwargs) + /* "dependency_injector/providers.pyx":1125 + * return super().__call__(*args, **kwargs) * * def override(self, provider): # <<<<<<<<<<<<<< * """Override provider with another provider. @@ -20478,7 +22536,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_2 return __pyx_r; } -/* "dependency_injector/providers.pyx":1041 +/* "dependency_injector/providers.pyx":1141 * return super(AbstractCoroutine, self).override(provider) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -20509,7 +22567,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_17AbstractCoroutine__p if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1041, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1141, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_17AbstractCoroutine_5_provide)) { __Pyx_XDECREF(__pyx_r); @@ -20529,7 +22587,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_17AbstractCoroutine__p #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1041, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1141, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -20537,13 +22595,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_17AbstractCoroutine__p #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1041, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1141, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1041, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1141, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -20554,7 +22612,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_17AbstractCoroutine__p __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1041, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1141, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -20577,20 +22635,20 @@ static PyObject *__pyx_f_19dependency_injector_9providers_17AbstractCoroutine__p #endif } - /* "dependency_injector/providers.pyx":1043 + /* "dependency_injector/providers.pyx":1143 * cpdef object _provide(self, tuple args, dict kwargs): * """Return result of provided callable's call.""" * raise NotImplementedError('Abstract provider forward providing logic ' # <<<<<<<<<<<<<< * 'to overriding provider') * */ - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_tuple__6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1043, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_tuple__6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1143, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 1043, __pyx_L1_error) + __PYX_ERR(1, 1143, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1041 + /* "dependency_injector/providers.pyx":1141 * return super(AbstractCoroutine, self).override(provider) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -20648,11 +22706,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_17AbstractCoroutine_5 case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 1041, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 1141, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 1041, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 1141, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -20665,14 +22723,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_17AbstractCoroutine_5 } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1041, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1141, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.AbstractCoroutine._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 1041, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 1041, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 1141, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 1141, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_4_provide(((struct __pyx_obj_19dependency_injector_9providers_AbstractCoroutine *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -20693,7 +22751,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_4 int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_17AbstractCoroutine__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1041, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_17AbstractCoroutine__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1141, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -20738,9 +22796,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_6 PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; - int __pyx_t_4; + PyObject *__pyx_t_4 = NULL; int __pyx_t_5; int __pyx_t_6; + int __pyx_t_7; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -20749,62 +22808,67 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_6 /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(7); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(8); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___args); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->__pyx_base.__pyx_base.__pyx___args); + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->__pyx_base.__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_3, 3, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_4, 4, __pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_4, 5, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_4, 6, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_3, 6, __pyx_v_self->__pyx_base.__pyx_base.__pyx___provides); + PyTuple_SET_ITEM(__pyx_t_4, 7, __pyx_v_self->__pyx_base.__pyx_base.__pyx___provides); __pyx_t_1 = 0; __pyx_t_2 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_4); + __pyx_t_4 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_v__dict = __pyx_t_3; - __pyx_t_3 = 0; + __pyx_t_4 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_v__dict = __pyx_t_4; + __pyx_t_4 = 0; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_4 = (__pyx_v__dict != Py_None); - __pyx_t_5 = (__pyx_t_4 != 0); - if (__pyx_t_5) { + __pyx_t_5 = (__pyx_v__dict != Py_None); + __pyx_t_6 = (__pyx_t_5 != 0); + if (__pyx_t_6) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -20813,16 +22877,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_6 * use_setstate = True * else: */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__dict); + __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3)); + __pyx_t_3 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -20834,7 +22898,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_6 __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -20848,42 +22912,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_6 * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x3e02ba6, None), state */ /*else*/ { - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___args != ((PyObject*)Py_None)); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___args != ((PyObject*)Py_None)); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___provides != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - __pyx_t_5 = __pyx_t_6; + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___provides != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + __pyx_t_6 = __pyx_t_7; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_5; + __pyx_v_use_setstate = __pyx_t_6; } __pyx_L3:; @@ -20891,89 +22955,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_6 * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x3e02ba6, None), state * else: */ - __pyx_t_5 = (__pyx_v_use_setstate != 0); - if (__pyx_t_5) { + __pyx_t_6 = (__pyx_v_use_setstate != 0); + if (__pyx_t_6) { /* "(tree fragment)":13 * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x03251dc, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x3e02ba6, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x3e02ba6, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_AbstractCoroutine); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_AbstractCoroutine); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, Py_None); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); __pyx_t_3 = 0; - __pyx_r = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x3e02ba6, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x3e02ba6, None), state * else: - * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x03251dc, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x3e02ba6, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_AbstractCoroutine__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_AbstractCoroutine); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_AbstractCoroutine); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); - __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); - __pyx_t_1 = 0; - __pyx_t_3 = 0; - __pyx_r = __pyx_t_2; + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state); + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_3; + __pyx_t_3 = 0; goto __pyx_L0; } @@ -20988,6 +23052,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_6 __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("dependency_injector.providers.AbstractCoroutine.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -21000,7 +23065,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_6 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractCoroutine__set_state(self, __pyx_state) */ @@ -21028,7 +23093,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_8 __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_AbstractCoroutine__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -21039,7 +23104,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_8 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x03251dc, state) + * return __pyx_unpickle_AbstractCoroutine, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractCoroutine__set_state(self, __pyx_state) */ @@ -21057,7 +23122,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractCoroutine_8 return __pyx_r; } -/* "dependency_injector/providers.pyx":1057 +/* "dependency_injector/providers.pyx":1157 * """ * * def __init__(self, coroutine): # <<<<<<<<<<<<<< @@ -21098,7 +23163,7 @@ static int __pyx_pw_19dependency_injector_9providers_17CoroutineDelegate_1__init else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 1057, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 1157, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -21109,7 +23174,7 @@ static int __pyx_pw_19dependency_injector_9providers_17CoroutineDelegate_1__init } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1057, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1157, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.CoroutineDelegate.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -21140,7 +23205,7 @@ static int __pyx_pf_19dependency_injector_9providers_17CoroutineDelegate___init_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":1063 + /* "dependency_injector/providers.pyx":1163 * :type coroutine: object * """ * if isinstance(coroutine, Coroutine) is False: # <<<<<<<<<<<<<< @@ -21151,26 +23216,26 @@ static int __pyx_pf_19dependency_injector_9providers_17CoroutineDelegate___init_ __pyx_t_2 = ((__pyx_t_1 == 0) != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":1064 + /* "dependency_injector/providers.pyx":1164 * """ * if isinstance(coroutine, Coroutine) is False: * raise Error('{0} can wrap only {1} providers'.format( # <<<<<<<<<<<<<< * self.__class__, Callable)) * super(CoroutineDelegate, self).__init__(coroutine) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1064, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1164, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_wrap_only_1_providers, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1064, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_wrap_only_1_providers, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1164, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - /* "dependency_injector/providers.pyx":1065 + /* "dependency_injector/providers.pyx":1165 * if isinstance(coroutine, Coroutine) is False: * raise Error('{0} can wrap only {1} providers'.format( * self.__class__, Callable)) # <<<<<<<<<<<<<< * super(CoroutineDelegate, self).__init__(coroutine) * */ - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1065, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1165, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_9 = 0; @@ -21187,7 +23252,7 @@ static int __pyx_pf_19dependency_injector_9providers_17CoroutineDelegate___init_ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1064, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1164, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; @@ -21196,14 +23261,14 @@ static int __pyx_pf_19dependency_injector_9providers_17CoroutineDelegate___init_ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1064, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1164, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { - __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1064, __pyx_L1_error) + __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1164, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_8); __pyx_t_8 = NULL; @@ -21214,7 +23279,7 @@ static int __pyx_pf_19dependency_injector_9providers_17CoroutineDelegate___init_ __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)); PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_9, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable)); __pyx_t_7 = 0; - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1064, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1164, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } @@ -21232,14 +23297,14 @@ static int __pyx_pf_19dependency_injector_9providers_17CoroutineDelegate___init_ __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1064, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1164, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 1064, __pyx_L1_error) + __PYX_ERR(1, 1164, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1063 + /* "dependency_injector/providers.pyx":1163 * :type coroutine: object * """ * if isinstance(coroutine, Coroutine) is False: # <<<<<<<<<<<<<< @@ -21248,14 +23313,14 @@ static int __pyx_pf_19dependency_injector_9providers_17CoroutineDelegate___init_ */ } - /* "dependency_injector/providers.pyx":1066 + /* "dependency_injector/providers.pyx":1166 * raise Error('{0} can wrap only {1} providers'.format( * self.__class__, Callable)) * super(CoroutineDelegate, self).__init__(coroutine) # <<<<<<<<<<<<<< * * */ - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1066, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1166, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_CoroutineDelegate)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_CoroutineDelegate)); @@ -21263,10 +23328,10 @@ static int __pyx_pf_19dependency_injector_9providers_17CoroutineDelegate___init_ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1066, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1166, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1066, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1166, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -21281,12 +23346,12 @@ static int __pyx_pf_19dependency_injector_9providers_17CoroutineDelegate___init_ } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_coroutine) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_coroutine); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1066, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1166, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1057 + /* "dependency_injector/providers.pyx":1157 * """ * * def __init__(self, coroutine): # <<<<<<<<<<<<<< @@ -21338,9 +23403,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_2 PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -21351,46 +23416,51 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_2 /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx___provides); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___provides); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -21399,16 +23469,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_2 * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -21420,7 +23490,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_2 __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -21434,28 +23504,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_2 * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x328787b, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -21463,44 +23533,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_2 * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x328787b, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x3f4a3b6, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x328787b, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x328787b, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_CoroutineDelegate); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_CoroutineDelegate); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -21509,15 +23579,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_2 * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x328787b, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x328787b, None), state * else: - * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x3f4a3b6, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x328787b, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_CoroutineDelegate__set_state(self, __pyx_state) */ @@ -21525,27 +23595,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_2 __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_CoroutineDelegate); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -21558,7 +23628,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_2 /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.CoroutineDelegate.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -21572,7 +23642,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_2 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_CoroutineDelegate__set_state(self, __pyx_state) */ @@ -21600,7 +23670,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_4 __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_CoroutineDelegate__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -21611,7 +23681,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_4 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_CoroutineDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_CoroutineDelegate__set_state(self, __pyx_state) */ @@ -21629,7 +23699,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17CoroutineDelegate_4 return __pyx_r; } -/* "dependency_injector/providers.pyx":1078 +/* "dependency_injector/providers.pyx":1178 * UNDEFINED = object() * * def __init__(self, name, root): # <<<<<<<<<<<<<< @@ -21671,11 +23741,11 @@ static int __pyx_pw_19dependency_injector_9providers_19ConfigurationOption_1__in case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_root)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, 1); __PYX_ERR(1, 1078, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, 1); __PYX_ERR(1, 1178, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 1078, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 1178, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -21688,7 +23758,7 @@ static int __pyx_pw_19dependency_injector_9providers_19ConfigurationOption_1__in } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1078, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1178, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ConfigurationOption.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -21712,14 +23782,14 @@ static int __pyx_pf_19dependency_injector_9providers_19ConfigurationOption___ini int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":1079 + /* "dependency_injector/providers.pyx":1179 * * def __init__(self, name, root): * self.__name = name # <<<<<<<<<<<<<< * self.__root_ref = weakref.ref(root) * self.__children = {} */ - if (!(likely(PyTuple_CheckExact(__pyx_v_name))||((__pyx_v_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v_name)->tp_name), 0))) __PYX_ERR(1, 1079, __pyx_L1_error) + if (!(likely(PyTuple_CheckExact(__pyx_v_name))||((__pyx_v_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v_name)->tp_name), 0))) __PYX_ERR(1, 1179, __pyx_L1_error) __pyx_t_1 = __pyx_v_name; __Pyx_INCREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); @@ -21728,16 +23798,16 @@ static int __pyx_pf_19dependency_injector_9providers_19ConfigurationOption___ini __pyx_v_self->__pyx___name = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1080 + /* "dependency_injector/providers.pyx":1180 * def __init__(self, name, root): * self.__name = name * self.__root_ref = weakref.ref(root) # <<<<<<<<<<<<<< * self.__children = {} * self.__cache = self.UNDEFINED */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_weakref); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1080, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_weakref); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1180, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ref); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1080, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ref); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1180, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -21752,7 +23822,7 @@ static int __pyx_pf_19dependency_injector_9providers_19ConfigurationOption___ini } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, __pyx_v_root) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_root); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1080, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1180, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GIVEREF(__pyx_t_1); @@ -21761,14 +23831,14 @@ static int __pyx_pf_19dependency_injector_9providers_19ConfigurationOption___ini __pyx_v_self->__pyx___root_ref = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1081 + /* "dependency_injector/providers.pyx":1181 * self.__name = name * self.__root_ref = weakref.ref(root) * self.__children = {} # <<<<<<<<<<<<<< * self.__cache = self.UNDEFINED * super().__init__() */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1081, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1181, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___children); @@ -21776,14 +23846,14 @@ static int __pyx_pf_19dependency_injector_9providers_19ConfigurationOption___ini __pyx_v_self->__pyx___children = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1082 + /* "dependency_injector/providers.pyx":1182 * self.__root_ref = weakref.ref(root) * self.__children = {} * self.__cache = self.UNDEFINED # <<<<<<<<<<<<<< * super().__init__() * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_UNDEFINED); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1082, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_UNDEFINED); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1182, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___cache); @@ -21791,14 +23861,14 @@ static int __pyx_pf_19dependency_injector_9providers_19ConfigurationOption___ini __pyx_v_self->__pyx___cache = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1083 + /* "dependency_injector/providers.pyx":1183 * self.__children = {} * self.__cache = self.UNDEFINED * super().__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1083, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption)); @@ -21806,10 +23876,10 @@ static int __pyx_pf_19dependency_injector_9providers_19ConfigurationOption___ini __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_3, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1083, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1083, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -21824,12 +23894,12 @@ static int __pyx_pf_19dependency_injector_9providers_19ConfigurationOption___ini } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1083, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1078 + /* "dependency_injector/providers.pyx":1178 * UNDEFINED = object() * * def __init__(self, name, root): # <<<<<<<<<<<<<< @@ -21851,7 +23921,7 @@ static int __pyx_pf_19dependency_injector_9providers_19ConfigurationOption___ini return __pyx_r; } -/* "dependency_injector/providers.pyx":1085 +/* "dependency_injector/providers.pyx":1185 * super().__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -21892,16 +23962,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":1088 + /* "dependency_injector/providers.pyx":1188 * cdef ConfigurationOption copied * * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1088, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1188, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1088, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1188, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -21916,14 +23986,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1088, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1188, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_ConfigurationOption))))) __PYX_ERR(1, 1088, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_ConfigurationOption))))) __PYX_ERR(1, 1188, __pyx_L1_error) __pyx_v_copied = ((struct __pyx_obj_19dependency_injector_9providers_ConfigurationOption *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1089 + /* "dependency_injector/providers.pyx":1189 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -21934,7 +24004,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":1090 + /* "dependency_injector/providers.pyx":1190 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -21946,7 +24016,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1089 + /* "dependency_injector/providers.pyx":1189 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -21955,7 +24025,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ } - /* "dependency_injector/providers.pyx":1092 + /* "dependency_injector/providers.pyx":1192 * return copied * * copied_name = deepcopy(self.__name, memo) # <<<<<<<<<<<<<< @@ -21964,16 +24034,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ __pyx_t_1 = __pyx_v_self->__pyx___name; __Pyx_INCREF(__pyx_t_1); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1092, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1192, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1092, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1192, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_copied_name = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1094 + /* "dependency_injector/providers.pyx":1194 * copied_name = deepcopy(self.__name, memo) * * root = self.__root_ref() # <<<<<<<<<<<<<< @@ -21993,22 +24063,22 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1094, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1194, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_root = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1095 + /* "dependency_injector/providers.pyx":1195 * * root = self.__root_ref() * copied_root = memo.get(id(root)) # <<<<<<<<<<<<<< * if copied_root is None: * copied_root = deepcopy(root, memo) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1095, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1195, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_v_root); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1095, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_v_root); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1195, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -22023,13 +24093,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1095, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1195, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_copied_root = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1096 + /* "dependency_injector/providers.pyx":1196 * root = self.__root_ref() * copied_root = memo.get(id(root)) * if copied_root is None: # <<<<<<<<<<<<<< @@ -22040,22 +24110,22 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_5 = (__pyx_t_6 != 0); if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":1097 + /* "dependency_injector/providers.pyx":1197 * copied_root = memo.get(id(root)) * if copied_root is None: * copied_root = deepcopy(root, memo) # <<<<<<<<<<<<<< * * copied = self.__class__(copied_name, copied_root) */ - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1097, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1197, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_v_root, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1097, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_v_root, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1197, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF_SET(__pyx_v_copied_root, __pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1096 + /* "dependency_injector/providers.pyx":1196 * root = self.__root_ref() * copied_root = memo.get(id(root)) * if copied_root is None: # <<<<<<<<<<<<<< @@ -22064,14 +24134,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ } - /* "dependency_injector/providers.pyx":1099 + /* "dependency_injector/providers.pyx":1199 * copied_root = deepcopy(root, memo) * * copied = self.__class__(copied_name, copied_root) # <<<<<<<<<<<<<< * copied.__children = deepcopy(self.__children, memo) * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1099, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1199, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = NULL; __pyx_t_8 = 0; @@ -22088,7 +24158,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_1)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_v_copied_name, __pyx_v_copied_root}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1099, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1199, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -22096,13 +24166,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_v_copied_name, __pyx_v_copied_root}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1099, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1199, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_4 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1099, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1199, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); if (__pyx_t_3) { __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL; @@ -22113,16 +24183,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_INCREF(__pyx_v_copied_root); __Pyx_GIVEREF(__pyx_v_copied_root); PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_8, __pyx_v_copied_root); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1099, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1199, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_19dependency_injector_9providers_ConfigurationOption))))) __PYX_ERR(1, 1099, __pyx_L1_error) + if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_19dependency_injector_9providers_ConfigurationOption))))) __PYX_ERR(1, 1199, __pyx_L1_error) __Pyx_DECREF_SET(__pyx_v_copied, ((struct __pyx_obj_19dependency_injector_9providers_ConfigurationOption *)__pyx_t_2)); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1100 + /* "dependency_injector/providers.pyx":1200 * * copied = self.__class__(copied_name, copied_root) * copied.__children = deepcopy(self.__children, memo) # <<<<<<<<<<<<<< @@ -22131,20 +24201,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ __pyx_t_2 = __pyx_v_self->__pyx___children; __Pyx_INCREF(__pyx_t_2); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1100, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1200, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1100, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1200, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 1100, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 1200, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_copied->__pyx___children); __Pyx_DECREF(__pyx_v_copied->__pyx___children); __pyx_v_copied->__pyx___children = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1102 + /* "dependency_injector/providers.pyx":1202 * copied.__children = deepcopy(self.__children, memo) * * return copied # <<<<<<<<<<<<<< @@ -22156,7 +24226,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1085 + /* "dependency_injector/providers.pyx":1185 * super().__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -22182,7 +24252,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1104 +/* "dependency_injector/providers.pyx":1204 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -22214,7 +24284,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":1105 + /* "dependency_injector/providers.pyx":1205 * * def __str__(self): * return represent_provider(provider=self, provides=self.get_name()) # <<<<<<<<<<<<<< @@ -22222,7 +24292,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * def __getattr__(self, item): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_get_name); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1105, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_get_name); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1205, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -22236,17 +24306,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1105, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1205, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1105, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1205, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1104 + /* "dependency_injector/providers.pyx":1204 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -22267,7 +24337,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1107 +/* "dependency_injector/providers.pyx":1207 * return represent_provider(provider=self, provides=self.get_name()) * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -22304,14 +24374,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getattr__", 0); - /* "dependency_injector/providers.pyx":1108 + /* "dependency_injector/providers.pyx":1208 * * def __getattr__(self, item): * if item.startswith('__') and item.endswith('__'): # <<<<<<<<<<<<<< * raise AttributeError( * '\'{cls}\' object has no attribute ' */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_item, __pyx_n_s_startswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1108, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_item, __pyx_n_s_startswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1208, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -22325,17 +24395,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1108, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1208, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 1108, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 1208, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (__pyx_t_5) { } else { __pyx_t_1 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_item, __pyx_n_s_endswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1108, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_item, __pyx_n_s_endswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1208, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -22349,70 +24419,70 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1108, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1208, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 1108, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 1208, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_1 = __pyx_t_5; __pyx_L4_bool_binop_done:; if (unlikely(__pyx_t_1)) { - /* "dependency_injector/providers.pyx":1111 + /* "dependency_injector/providers.pyx":1211 * raise AttributeError( * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, # <<<<<<<<<<<<<< * attribute_name=item)) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_cls_object_has_no_attribute_att, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1111, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_cls_object_has_no_attribute_att, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1211, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1111, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1211, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1111, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1211, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1111, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1211, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_cls, __pyx_t_6) < 0) __PYX_ERR(1, 1111, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_cls, __pyx_t_6) < 0) __PYX_ERR(1, 1211, __pyx_L1_error) __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":1112 + /* "dependency_injector/providers.pyx":1212 * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, * attribute_name=item)) # <<<<<<<<<<<<<< * * child = self.__children.get(item) */ - if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_attribute_name, __pyx_v_item) < 0) __PYX_ERR(1, 1111, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_attribute_name, __pyx_v_item) < 0) __PYX_ERR(1, 1211, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1111 + /* "dependency_injector/providers.pyx":1211 * raise AttributeError( * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, # <<<<<<<<<<<<<< * attribute_name=item)) * */ - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1111, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1211, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1109 + /* "dependency_injector/providers.pyx":1209 * def __getattr__(self, item): * if item.startswith('__') and item.endswith('__'): * raise AttributeError( # <<<<<<<<<<<<<< * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, */ - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1109, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1209, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 1109, __pyx_L1_error) + __PYX_ERR(1, 1209, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1108 + /* "dependency_injector/providers.pyx":1208 * * def __getattr__(self, item): * if item.startswith('__') and item.endswith('__'): # <<<<<<<<<<<<<< @@ -22421,7 +24491,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ } - /* "dependency_injector/providers.pyx":1114 + /* "dependency_injector/providers.pyx":1214 * attribute_name=item)) * * child = self.__children.get(item) # <<<<<<<<<<<<<< @@ -22430,14 +24500,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ if (unlikely(__pyx_v_self->__pyx___children == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "get"); - __PYX_ERR(1, 1114, __pyx_L1_error) + __PYX_ERR(1, 1214, __pyx_L1_error) } - __pyx_t_3 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___children, __pyx_v_item, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1114, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___children, __pyx_v_item, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1214, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_v_child = __pyx_t_3; __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1115 + /* "dependency_injector/providers.pyx":1215 * * child = self.__children.get(item) * if child is None: # <<<<<<<<<<<<<< @@ -22448,25 +24518,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_5 = (__pyx_t_1 != 0); if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":1116 + /* "dependency_injector/providers.pyx":1216 * child = self.__children.get(item) * if child is None: * child_name = self.__name + (item,) # <<<<<<<<<<<<<< * child = ConfigurationOption(child_name, self.__root_ref()) * self.__children[item] = child */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1116, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1216, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_item); - __pyx_t_6 = PyNumber_Add(__pyx_v_self->__pyx___name, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1116, __pyx_L1_error) + __pyx_t_6 = PyNumber_Add(__pyx_v_self->__pyx___name, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1216, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_v_child_name = ((PyObject*)__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":1117 + /* "dependency_injector/providers.pyx":1217 * if child is None: * child_name = self.__name + (item,) * child = ConfigurationOption(child_name, self.__root_ref()) # <<<<<<<<<<<<<< @@ -22486,10 +24556,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_6 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1117, __pyx_L1_error) + if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1217, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1117, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1217, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v_child_name); __Pyx_GIVEREF(__pyx_v_child_name); @@ -22497,13 +24567,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_6); __pyx_t_6 = 0; - __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption), __pyx_t_3, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1117, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption), __pyx_t_3, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1217, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF_SET(__pyx_v_child, __pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":1118 + /* "dependency_injector/providers.pyx":1218 * child_name = self.__name + (item,) * child = ConfigurationOption(child_name, self.__root_ref()) * self.__children[item] = child # <<<<<<<<<<<<<< @@ -22512,11 +24582,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ if (unlikely(__pyx_v_self->__pyx___children == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 1118, __pyx_L1_error) + __PYX_ERR(1, 1218, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_v_self->__pyx___children, __pyx_v_item, __pyx_v_child) < 0)) __PYX_ERR(1, 1118, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_self->__pyx___children, __pyx_v_item, __pyx_v_child) < 0)) __PYX_ERR(1, 1218, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1115 + /* "dependency_injector/providers.pyx":1215 * * child = self.__children.get(item) * if child is None: # <<<<<<<<<<<<<< @@ -22525,7 +24595,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ } - /* "dependency_injector/providers.pyx":1119 + /* "dependency_injector/providers.pyx":1219 * child = ConfigurationOption(child_name, self.__root_ref()) * self.__children[item] = child * return child # <<<<<<<<<<<<<< @@ -22537,7 +24607,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_r = __pyx_v_child; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1107 + /* "dependency_injector/providers.pyx":1207 * return represent_provider(provider=self, provides=self.get_name()) * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -22561,7 +24631,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1121 +/* "dependency_injector/providers.pyx":1221 * return child * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -22597,7 +24667,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getitem__", 0); - /* "dependency_injector/providers.pyx":1122 + /* "dependency_injector/providers.pyx":1222 * * def __getitem__(self, item): * child = self.__children.get(item) # <<<<<<<<<<<<<< @@ -22606,14 +24676,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ if (unlikely(__pyx_v_self->__pyx___children == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "get"); - __PYX_ERR(1, 1122, __pyx_L1_error) + __PYX_ERR(1, 1222, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___children, __pyx_v_item, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1122, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___children, __pyx_v_item, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1222, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_child = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1123 + /* "dependency_injector/providers.pyx":1223 * def __getitem__(self, item): * child = self.__children.get(item) * if child is None: # <<<<<<<<<<<<<< @@ -22624,25 +24694,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_3 = (__pyx_t_2 != 0); if (__pyx_t_3) { - /* "dependency_injector/providers.pyx":1124 + /* "dependency_injector/providers.pyx":1224 * child = self.__children.get(item) * if child is None: * child_name = self.__name + (item,) # <<<<<<<<<<<<<< * child = ConfigurationOption(child_name, self.__root_ref()) * self.__children[item] = child */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1124, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1224, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_item); - __pyx_t_4 = PyNumber_Add(__pyx_v_self->__pyx___name, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1124, __pyx_L1_error) + __pyx_t_4 = PyNumber_Add(__pyx_v_self->__pyx___name, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1224, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_child_name = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":1125 + /* "dependency_injector/providers.pyx":1225 * if child is None: * child_name = self.__name + (item,) * child = ConfigurationOption(child_name, self.__root_ref()) # <<<<<<<<<<<<<< @@ -22662,10 +24732,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_4 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1125, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1225, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1125, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1225, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_v_child_name); __Pyx_GIVEREF(__pyx_v_child_name); @@ -22673,13 +24743,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption), __pyx_t_1, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1125, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption), __pyx_t_1, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1225, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF_SET(__pyx_v_child, __pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":1126 + /* "dependency_injector/providers.pyx":1226 * child_name = self.__name + (item,) * child = ConfigurationOption(child_name, self.__root_ref()) * self.__children[item] = child # <<<<<<<<<<<<<< @@ -22688,11 +24758,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ if (unlikely(__pyx_v_self->__pyx___children == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 1126, __pyx_L1_error) + __PYX_ERR(1, 1226, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_v_self->__pyx___children, __pyx_v_item, __pyx_v_child) < 0)) __PYX_ERR(1, 1126, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_self->__pyx___children, __pyx_v_item, __pyx_v_child) < 0)) __PYX_ERR(1, 1226, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1123 + /* "dependency_injector/providers.pyx":1223 * def __getitem__(self, item): * child = self.__children.get(item) * if child is None: # <<<<<<<<<<<<<< @@ -22701,7 +24771,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ } - /* "dependency_injector/providers.pyx":1127 + /* "dependency_injector/providers.pyx":1227 * child = ConfigurationOption(child_name, self.__root_ref()) * self.__children[item] = child * return child # <<<<<<<<<<<<<< @@ -22713,7 +24783,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_r = __pyx_v_child; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1121 + /* "dependency_injector/providers.pyx":1221 * return child * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -22736,7 +24806,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1129 +/* "dependency_injector/providers.pyx":1229 * return child * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -22771,7 +24841,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1129, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1229, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_19ConfigurationOption_11_provide)) { __Pyx_XDECREF(__pyx_r); @@ -22791,7 +24861,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1129, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1229, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -22799,13 +24869,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1129, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1229, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1129, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1229, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -22816,7 +24886,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1129, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1229, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -22839,21 +24909,21 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ #endif } - /* "dependency_injector/providers.pyx":1131 + /* "dependency_injector/providers.pyx":1231 * cpdef object _provide(self, tuple args, dict kwargs): * """Return new instance.""" * if self.__cache is not self.UNDEFINED: # <<<<<<<<<<<<<< * return self.__cache * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_UNDEFINED); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1131, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_UNDEFINED); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1231, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_7 = (__pyx_v_self->__pyx___cache != __pyx_t_1); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = (__pyx_t_7 != 0); if (__pyx_t_8) { - /* "dependency_injector/providers.pyx":1132 + /* "dependency_injector/providers.pyx":1232 * """Return new instance.""" * if self.__cache is not self.UNDEFINED: * return self.__cache # <<<<<<<<<<<<<< @@ -22865,7 +24935,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ __pyx_r = __pyx_v_self->__pyx___cache; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1131 + /* "dependency_injector/providers.pyx":1231 * cpdef object _provide(self, tuple args, dict kwargs): * """Return new instance.""" * if self.__cache is not self.UNDEFINED: # <<<<<<<<<<<<<< @@ -22874,7 +24944,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ */ } - /* "dependency_injector/providers.pyx":1134 + /* "dependency_injector/providers.pyx":1234 * return self.__cache * * root = self.__root_ref() # <<<<<<<<<<<<<< @@ -22894,22 +24964,22 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1134, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1234, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_root = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1135 + /* "dependency_injector/providers.pyx":1235 * * root = self.__root_ref() * value = root.get(self._get_self_name()) # <<<<<<<<<<<<<< * self.__cache = value * return value */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1135, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1235, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_get_self_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1135, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_get_self_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1235, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -22923,7 +24993,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ } __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_6); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1135, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1235, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -22939,13 +25009,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_6, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1135, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1235, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_value = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1136 + /* "dependency_injector/providers.pyx":1236 * root = self.__root_ref() * value = root.get(self._get_self_name()) * self.__cache = value # <<<<<<<<<<<<<< @@ -22958,7 +25028,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ __Pyx_DECREF(__pyx_v_self->__pyx___cache); __pyx_v_self->__pyx___cache = __pyx_v_value; - /* "dependency_injector/providers.pyx":1137 + /* "dependency_injector/providers.pyx":1237 * value = root.get(self._get_self_name()) * self.__cache = value * return value # <<<<<<<<<<<<<< @@ -22970,7 +25040,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ConfigurationOption_ __pyx_r = __pyx_v_value; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1129 + /* "dependency_injector/providers.pyx":1229 * return child * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -23030,11 +25100,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19ConfigurationOption case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 1129, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 1229, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 1129, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 1229, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -23047,14 +25117,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19ConfigurationOption } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1129, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1229, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ConfigurationOption._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 1129, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 1129, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 1229, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 1229, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_19ConfigurationOption_10_provide(((struct __pyx_obj_19dependency_injector_9providers_ConfigurationOption *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -23075,7 +25145,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_19ConfigurationOption__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1129, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_19ConfigurationOption__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1229, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -23092,7 +25162,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1139 +/* "dependency_injector/providers.pyx":1239 * return value * * def _get_self_name(self): # <<<<<<<<<<<<<< @@ -23114,7 +25184,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19ConfigurationOption } static PyObject *__pyx_gb_19dependency_injector_9providers_19ConfigurationOption_14_get_self_name_2generator(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "dependency_injector/providers.pyx":1141 +/* "dependency_injector/providers.pyx":1241 * def _get_self_name(self): * return '.'.join( * segment() if is_provider(segment) else segment for segment in self.__name # <<<<<<<<<<<<<< @@ -23134,7 +25204,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct_1_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(1, 1141, __pyx_L1_error) + __PYX_ERR(1, 1241, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -23142,7 +25212,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_19dependency_injector_9providers_19ConfigurationOption_14_get_self_name_2generator, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_get_self_name_locals_genexpr, __pyx_n_s_dependency_injector_providers); if (unlikely(!gen)) __PYX_ERR(1, 1141, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_19dependency_injector_9providers_19ConfigurationOption_14_get_self_name_2generator, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_get_self_name_locals_genexpr, __pyx_n_s_dependency_injector_providers); if (unlikely(!gen)) __PYX_ERR(1, 1241, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -23181,19 +25251,19 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_19ConfigurationOption return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(1, 1141, __pyx_L1_error) - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_self)) { __Pyx_RaiseClosureNameError("self"); __PYX_ERR(1, 1141, __pyx_L1_error) } + if (unlikely(!__pyx_sent_value)) __PYX_ERR(1, 1241, __pyx_L1_error) + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_self)) { __Pyx_RaiseClosureNameError("self"); __PYX_ERR(1, 1241, __pyx_L1_error) } if (unlikely(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_self->__pyx___name == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 1141, __pyx_L1_error) + __PYX_ERR(1, 1241, __pyx_L1_error) } __pyx_t_1 = __pyx_cur_scope->__pyx_outer_scope->__pyx_v_self->__pyx___name; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyTuple_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(1, 1141, __pyx_L1_error) + __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(1, 1241, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1141, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1241, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XGOTREF(__pyx_cur_scope->__pyx_v_segment); @@ -23214,7 +25284,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1141, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1241, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_3 = __pyx_t_4; @@ -23239,7 +25309,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_19ConfigurationOption __pyx_cur_scope->__pyx_t_0 = 0; __Pyx_XGOTREF(__pyx_t_1); __pyx_t_2 = __pyx_cur_scope->__pyx_t_1; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(1, 1141, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(1, 1241, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; CYTHON_MAYBE_UNUSED_VAR(__pyx_cur_scope); @@ -23265,7 +25335,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1139 +/* "dependency_injector/providers.pyx":1239 * return value * * def _get_self_name(self): # <<<<<<<<<<<<<< @@ -23287,7 +25357,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct___get_self_name *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(1, 1139, __pyx_L1_error) + __PYX_ERR(1, 1239, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -23295,7 +25365,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_INCREF((PyObject *)__pyx_cur_scope->__pyx_v_self); __Pyx_GIVEREF((PyObject *)__pyx_cur_scope->__pyx_v_self); - /* "dependency_injector/providers.pyx":1140 + /* "dependency_injector/providers.pyx":1240 * * def _get_self_name(self): * return '.'.join( # <<<<<<<<<<<<<< @@ -23304,31 +25374,31 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ __Pyx_XDECREF(__pyx_r); - /* "dependency_injector/providers.pyx":1141 + /* "dependency_injector/providers.pyx":1241 * def _get_self_name(self): * return '.'.join( * segment() if is_provider(segment) else segment for segment in self.__name # <<<<<<<<<<<<<< * ) * */ - __pyx_t_1 = __pyx_pf_19dependency_injector_9providers_19ConfigurationOption_14_get_self_name_genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1141, __pyx_L1_error) + __pyx_t_1 = __pyx_pf_19dependency_injector_9providers_19ConfigurationOption_14_get_self_name_genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1241, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":1140 + /* "dependency_injector/providers.pyx":1240 * * def _get_self_name(self): * return '.'.join( # <<<<<<<<<<<<<< * segment() if is_provider(segment) else segment for segment in self.__name * ) */ - __pyx_t_2 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1140, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1240, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1139 + /* "dependency_injector/providers.pyx":1239 * return value * * def _get_self_name(self): # <<<<<<<<<<<<<< @@ -23349,7 +25419,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1145 +/* "dependency_injector/providers.pyx":1245 * * @property * def root(self): # <<<<<<<<<<<<<< @@ -23381,7 +25451,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":1146 + /* "dependency_injector/providers.pyx":1246 * @property * def root(self): * return self.__root_ref() # <<<<<<<<<<<<<< @@ -23402,14 +25472,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1146, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1246, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1145 + /* "dependency_injector/providers.pyx":1245 * * @property * def root(self): # <<<<<<<<<<<<<< @@ -23430,7 +25500,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1148 +/* "dependency_injector/providers.pyx":1248 * return self.__root_ref() * * def get_name(self): # <<<<<<<<<<<<<< @@ -23464,7 +25534,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_name", 0); - /* "dependency_injector/providers.pyx":1149 + /* "dependency_injector/providers.pyx":1249 * * def get_name(self): * root = self.__root_ref() # <<<<<<<<<<<<<< @@ -23484,13 +25554,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1149, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1249, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_root = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1150 + /* "dependency_injector/providers.pyx":1250 * def get_name(self): * root = self.__root_ref() * return '.'.join((root.get_name(), self._get_self_name())) # <<<<<<<<<<<<<< @@ -23498,7 +25568,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * def get_name_segments(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_get_name); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1150, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_get_name); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -23512,10 +25582,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1150, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_get_self_name); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1150, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_get_self_name); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -23529,10 +25599,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1150, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1150, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1); @@ -23540,14 +25610,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_2); __pyx_t_1 = 0; __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1150, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1148 + /* "dependency_injector/providers.pyx":1248 * return self.__root_ref() * * def get_name(self): # <<<<<<<<<<<<<< @@ -23570,7 +25640,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1152 +/* "dependency_injector/providers.pyx":1252 * return '.'.join((root.get_name(), self._get_self_name())) * * def get_name_segments(self): # <<<<<<<<<<<<<< @@ -23596,7 +25666,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_name_segments", 0); - /* "dependency_injector/providers.pyx":1153 + /* "dependency_injector/providers.pyx":1253 * * def get_name_segments(self): * return self.__name # <<<<<<<<<<<<<< @@ -23608,7 +25678,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_r = __pyx_v_self->__pyx___name; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1152 + /* "dependency_injector/providers.pyx":1252 * return '.'.join((root.get_name(), self._get_self_name())) * * def get_name_segments(self): # <<<<<<<<<<<<<< @@ -23623,7 +25693,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1155 +/* "dependency_injector/providers.pyx":1255 * return self.__name * * def as_int(self): # <<<<<<<<<<<<<< @@ -23654,7 +25724,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("as_int", 0); - /* "dependency_injector/providers.pyx":1156 + /* "dependency_injector/providers.pyx":1256 * * def as_int(self): * return TypedConfigurationOption(int, self) # <<<<<<<<<<<<<< @@ -23662,7 +25732,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * def as_float(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1156, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1256, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)(&PyInt_Type))); __Pyx_GIVEREF(((PyObject *)(&PyInt_Type))); @@ -23670,14 +25740,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1156, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1256, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1155 + /* "dependency_injector/providers.pyx":1255 * return self.__name * * def as_int(self): # <<<<<<<<<<<<<< @@ -23697,7 +25767,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1158 +/* "dependency_injector/providers.pyx":1258 * return TypedConfigurationOption(int, self) * * def as_float(self): # <<<<<<<<<<<<<< @@ -23728,7 +25798,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("as_float", 0); - /* "dependency_injector/providers.pyx":1159 + /* "dependency_injector/providers.pyx":1259 * * def as_float(self): * return TypedConfigurationOption(float, self) # <<<<<<<<<<<<<< @@ -23736,7 +25806,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * def as_(self, callback, *args, **kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1159, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1259, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)(&PyFloat_Type))); __Pyx_GIVEREF(((PyObject *)(&PyFloat_Type))); @@ -23744,14 +25814,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1159, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1259, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1158 + /* "dependency_injector/providers.pyx":1258 * return TypedConfigurationOption(int, self) * * def as_float(self): # <<<<<<<<<<<<<< @@ -23771,7 +25841,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1161 +/* "dependency_injector/providers.pyx":1261 * return TypedConfigurationOption(float, self) * * def as_(self, callback, *args, **kwargs): # <<<<<<<<<<<<<< @@ -23824,7 +25894,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19ConfigurationOption } if (unlikely(kw_args > 0)) { const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "as_") < 0)) __PYX_ERR(1, 1161, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "as_") < 0)) __PYX_ERR(1, 1261, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { goto __pyx_L5_argtuple_error; @@ -23835,7 +25905,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19ConfigurationOption } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("as_", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1161, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("as_", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1261, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; @@ -23862,7 +25932,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("as_", 0); - /* "dependency_injector/providers.pyx":1162 + /* "dependency_injector/providers.pyx":1262 * * def as_(self, callback, *args, **kwargs): * return TypedConfigurationOption(callback, self, *args, **kwargs) # <<<<<<<<<<<<<< @@ -23870,7 +25940,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * def override(self, value): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1162, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1262, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_v_callback); __Pyx_GIVEREF(__pyx_v_callback); @@ -23878,17 +25948,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1162, __pyx_L1_error) + __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1262, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption), __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1162, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption), __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1262, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1161 + /* "dependency_injector/providers.pyx":1261 * return TypedConfigurationOption(float, self) * * def as_(self, callback, *args, **kwargs): # <<<<<<<<<<<<<< @@ -23908,7 +25978,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1164 +/* "dependency_injector/providers.pyx":1264 * return TypedConfigurationOption(callback, self, *args, **kwargs) * * def override(self, value): # <<<<<<<<<<<<<< @@ -23946,7 +26016,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/providers.pyx":1165 + /* "dependency_injector/providers.pyx":1265 * * def override(self, value): * if isinstance(value, Provider): # <<<<<<<<<<<<<< @@ -23957,14 +26027,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":1166 + /* "dependency_injector/providers.pyx":1266 * def override(self, value): * if isinstance(value, Provider): * raise Error('Configuration option can only be overridden by a value') # <<<<<<<<<<<<<< * root = self.__root_ref() * return root.set(self._get_self_name(), value) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1166, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1266, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { @@ -23978,14 +26048,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_kp_s_Configuration_option_can_only_be) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_kp_s_Configuration_option_can_only_be); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1166, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1266, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 1166, __pyx_L1_error) + __PYX_ERR(1, 1266, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1165 + /* "dependency_injector/providers.pyx":1265 * * def override(self, value): * if isinstance(value, Provider): # <<<<<<<<<<<<<< @@ -23994,7 +26064,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ } - /* "dependency_injector/providers.pyx":1167 + /* "dependency_injector/providers.pyx":1267 * if isinstance(value, Provider): * raise Error('Configuration option can only be overridden by a value') * root = self.__root_ref() # <<<<<<<<<<<<<< @@ -24014,13 +26084,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1167, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1267, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_root = __pyx_t_3; __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1168 + /* "dependency_injector/providers.pyx":1268 * raise Error('Configuration option can only be overridden by a value') * root = self.__root_ref() * return root.set(self._get_self_name(), value) # <<<<<<<<<<<<<< @@ -24028,9 +26098,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * def reset_last_overriding(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_set); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1168, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_set); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1268, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_get_self_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1168, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_get_self_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1268, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -24044,7 +26114,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7) : __Pyx_PyObject_CallNoArg(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1168, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1268, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -24062,7 +26132,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_5, __pyx_v_value}; - __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1168, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1268, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; @@ -24071,14 +26141,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_5, __pyx_v_value}; - __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1168, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1268, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else #endif { - __pyx_t_7 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1168, __pyx_L1_error) + __pyx_t_7 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1268, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_6); __pyx_t_6 = NULL; @@ -24089,7 +26159,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_GIVEREF(__pyx_v_value); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_8, __pyx_v_value); __pyx_t_5 = 0; - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1168, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1268, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } @@ -24098,7 +26168,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1164 + /* "dependency_injector/providers.pyx":1264 * return TypedConfigurationOption(callback, self, *args, **kwargs) * * def override(self, value): # <<<<<<<<<<<<<< @@ -24122,7 +26192,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1170 +/* "dependency_injector/providers.pyx":1270 * return root.set(self._get_self_name(), value) * * def reset_last_overriding(self): # <<<<<<<<<<<<<< @@ -24154,14 +26224,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_last_overriding", 0); - /* "dependency_injector/providers.pyx":1171 + /* "dependency_injector/providers.pyx":1271 * * def reset_last_overriding(self): * raise Error('Configuration option does not support this method') # <<<<<<<<<<<<<< * * def reset_override(self): */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1171, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1271, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { @@ -24175,14 +26245,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_kp_s_Configuration_option_does_not_su) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_kp_s_Configuration_option_does_not_su); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1171, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1271, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 1171, __pyx_L1_error) + __PYX_ERR(1, 1271, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1170 + /* "dependency_injector/providers.pyx":1270 * return root.set(self._get_self_name(), value) * * def reset_last_overriding(self): # <<<<<<<<<<<<<< @@ -24202,7 +26272,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1173 +/* "dependency_injector/providers.pyx":1273 * raise Error('Configuration option does not support this method') * * def reset_override(self): # <<<<<<<<<<<<<< @@ -24234,14 +26304,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_override", 0); - /* "dependency_injector/providers.pyx":1174 + /* "dependency_injector/providers.pyx":1274 * * def reset_override(self): * raise Error('Configuration option does not support this method') # <<<<<<<<<<<<<< * * def reset_cache(self): */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1174, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1274, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { @@ -24255,14 +26325,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_kp_s_Configuration_option_does_not_su) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_kp_s_Configuration_option_does_not_su); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1174, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1274, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 1174, __pyx_L1_error) + __PYX_ERR(1, 1274, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1173 + /* "dependency_injector/providers.pyx":1273 * raise Error('Configuration option does not support this method') * * def reset_override(self): # <<<<<<<<<<<<<< @@ -24282,7 +26352,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1176 +/* "dependency_injector/providers.pyx":1276 * raise Error('Configuration option does not support this method') * * def reset_cache(self): # <<<<<<<<<<<<<< @@ -24318,14 +26388,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_cache", 0); - /* "dependency_injector/providers.pyx":1177 + /* "dependency_injector/providers.pyx":1277 * * def reset_cache(self): * self.__cache = self.UNDEFINED # <<<<<<<<<<<<<< * for child in self.__children.values(): * child.reset_cache() */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_UNDEFINED); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1177, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_UNDEFINED); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1277, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___cache); @@ -24333,7 +26403,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_v_self->__pyx___cache = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1178 + /* "dependency_injector/providers.pyx":1278 * def reset_cache(self): * self.__cache = self.UNDEFINED * for child in self.__children.values(): # <<<<<<<<<<<<<< @@ -24342,17 +26412,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ if (unlikely(__pyx_v_self->__pyx___children == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "values"); - __PYX_ERR(1, 1178, __pyx_L1_error) + __PYX_ERR(1, 1278, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_Values(__pyx_v_self->__pyx___children); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1178, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_Values(__pyx_v_self->__pyx___children); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1278, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; __pyx_t_4 = NULL; } else { - __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1178, __pyx_L1_error) + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1278, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1178, __pyx_L1_error) + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1278, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -24360,17 +26430,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1178, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1278, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1178, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1278, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1178, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1278, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1178, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1278, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -24380,7 +26450,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 1178, __pyx_L1_error) + else __PYX_ERR(1, 1278, __pyx_L1_error) } break; } @@ -24389,14 +26459,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_XDECREF_SET(__pyx_v_child, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1179 + /* "dependency_injector/providers.pyx":1279 * self.__cache = self.UNDEFINED * for child in self.__children.values(): * child.reset_cache() # <<<<<<<<<<<<<< * * def update(self, value): */ - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_child, __pyx_n_s_reset_cache); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1179, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_child, __pyx_n_s_reset_cache); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1279, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { @@ -24410,12 +26480,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1179, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1279, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1178 + /* "dependency_injector/providers.pyx":1278 * def reset_cache(self): * self.__cache = self.UNDEFINED * for child in self.__children.values(): # <<<<<<<<<<<<<< @@ -24425,7 +26495,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1176 + /* "dependency_injector/providers.pyx":1276 * raise Error('Configuration option does not support this method') * * def reset_cache(self): # <<<<<<<<<<<<<< @@ -24450,7 +26520,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1181 +/* "dependency_injector/providers.pyx":1281 * child.reset_cache() * * def update(self, value): # <<<<<<<<<<<<<< @@ -24483,14 +26553,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("update", 0); - /* "dependency_injector/providers.pyx":1193 + /* "dependency_injector/providers.pyx":1293 * :rtype: None * """ * self.override(value) # <<<<<<<<<<<<<< * * def from_ini(self, filepath): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1193, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1293, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -24504,12 +26574,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_value) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_value); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1193, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1293, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1181 + /* "dependency_injector/providers.pyx":1281 * child.reset_cache() * * def update(self, value): # <<<<<<<<<<<<<< @@ -24532,7 +26602,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1195 +/* "dependency_injector/providers.pyx":1295 * self.override(value) * * def from_ini(self, filepath): # <<<<<<<<<<<<<< @@ -24577,14 +26647,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("from_ini", 0); - /* "dependency_injector/providers.pyx":1205 + /* "dependency_injector/providers.pyx":1305 * :rtype: None * """ * parser = _parse_ini_file(filepath) # <<<<<<<<<<<<<< * * config = {} */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_parse_ini_file); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1205, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_parse_ini_file); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1305, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { @@ -24598,32 +26668,32 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_filepath) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_filepath); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1205, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1305, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_parser = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1207 + /* "dependency_injector/providers.pyx":1307 * parser = _parse_ini_file(filepath) * * config = {} # <<<<<<<<<<<<<< * for section in parser.sections(): * config[section] = dict(parser.items(section)) */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1207, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1307, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_config = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1208 + /* "dependency_injector/providers.pyx":1308 * * config = {} * for section in parser.sections(): # <<<<<<<<<<<<<< * config[section] = dict(parser.items(section)) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_sections); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1208, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_sections); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -24637,16 +26707,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1208, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_4 = 0; __pyx_t_5 = NULL; } else { - __pyx_t_4 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1208, __pyx_L1_error) + __pyx_t_4 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_5 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1208, __pyx_L1_error) + __pyx_t_5 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1308, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -24654,17 +26724,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 1208, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 1308, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1208, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 1208, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 1308, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1208, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -24674,7 +26744,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 1208, __pyx_L1_error) + else __PYX_ERR(1, 1308, __pyx_L1_error) } break; } @@ -24683,14 +26753,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_XDECREF_SET(__pyx_v_section, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1209 + /* "dependency_injector/providers.pyx":1309 * config = {} * for section in parser.sections(): * config[section] = dict(parser.items(section)) # <<<<<<<<<<<<<< * * current_config = self.__call__() */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_items); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1209, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_items); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1309, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -24704,16 +26774,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_6, __pyx_v_section) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_section); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1209, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1309, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1209, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1309, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(PyDict_SetItem(__pyx_v_config, __pyx_v_section, __pyx_t_3) < 0)) __PYX_ERR(1, 1209, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_config, __pyx_v_section, __pyx_t_3) < 0)) __PYX_ERR(1, 1309, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1208 + /* "dependency_injector/providers.pyx":1308 * * config = {} * for section in parser.sections(): # <<<<<<<<<<<<<< @@ -24723,14 +26793,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1211 + /* "dependency_injector/providers.pyx":1311 * config[section] = dict(parser.items(section)) * * current_config = self.__call__() # <<<<<<<<<<<<<< * if not current_config: * current_config = {} */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1211, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1311, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_1 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -24744,36 +26814,36 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_2 = (__pyx_t_1) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_1) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1211, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1311, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_v_current_config = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1212 + /* "dependency_injector/providers.pyx":1312 * * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< * current_config = {} * self.override(merge_dicts(current_config, config)) */ - __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 1212, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 1312, __pyx_L1_error) __pyx_t_8 = ((!__pyx_t_7) != 0); if (__pyx_t_8) { - /* "dependency_injector/providers.pyx":1213 + /* "dependency_injector/providers.pyx":1313 * current_config = self.__call__() * if not current_config: * current_config = {} # <<<<<<<<<<<<<< * self.override(merge_dicts(current_config, config)) * */ - __pyx_t_2 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1213, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1313, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF_SET(__pyx_v_current_config, __pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1212 + /* "dependency_injector/providers.pyx":1312 * * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< @@ -24782,16 +26852,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ } - /* "dependency_injector/providers.pyx":1214 + /* "dependency_injector/providers.pyx":1314 * if not current_config: * current_config = {} * self.override(merge_dicts(current_config, config)) # <<<<<<<<<<<<<< * * def from_yaml(self, filepath): */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1214, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1214, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_9 = NULL; __pyx_t_10 = 0; @@ -24808,7 +26878,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_v_current_config, __pyx_v_config}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1214, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1314, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -24816,13 +26886,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_v_current_config, __pyx_v_config}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1214, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1314, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_11 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 1214, __pyx_L1_error) + __pyx_t_11 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 1314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_11); if (__pyx_t_9) { __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_9); __pyx_t_9 = NULL; @@ -24833,7 +26903,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_INCREF(__pyx_v_config); __Pyx_GIVEREF(__pyx_v_config); PyTuple_SET_ITEM(__pyx_t_11, 1+__pyx_t_10, __pyx_v_config); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_11, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1214, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_11, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } @@ -24851,12 +26921,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_2 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_6, __pyx_t_1) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_1); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1214, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1195 + /* "dependency_injector/providers.pyx":1295 * self.override(value) * * def from_ini(self, filepath): # <<<<<<<<<<<<<< @@ -24886,7 +26956,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1216 +/* "dependency_injector/providers.pyx":1316 * self.override(merge_dicts(current_config, config)) * * def from_yaml(self, filepath): # <<<<<<<<<<<<<< @@ -24936,28 +27006,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("from_yaml", 0); - /* "dependency_injector/providers.pyx":1226 + /* "dependency_injector/providers.pyx":1326 * :rtype: None * """ * if yaml is None: # <<<<<<<<<<<<<< * raise Error( * 'Unable to load yaml configuration - PyYAML is not installed. ' */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1226, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1326, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = (__pyx_t_1 == Py_None); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = (__pyx_t_2 != 0); if (unlikely(__pyx_t_3)) { - /* "dependency_injector/providers.pyx":1227 + /* "dependency_injector/providers.pyx":1327 * """ * if yaml is None: * raise Error( # <<<<<<<<<<<<<< * 'Unable to load yaml configuration - PyYAML is not installed. ' * 'Install PyYAML or install Dependency Injector with yaml extras: ' */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1227, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1327, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { @@ -24971,14 +27041,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_kp_s_Unable_to_load_yaml_configuratio) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_kp_s_Unable_to_load_yaml_configuratio); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1227, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1327, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 1227, __pyx_L1_error) + __PYX_ERR(1, 1327, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1226 + /* "dependency_injector/providers.pyx":1326 * :rtype: None * """ * if yaml is None: # <<<<<<<<<<<<<< @@ -24987,7 +27057,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ } - /* "dependency_injector/providers.pyx":1233 + /* "dependency_injector/providers.pyx":1333 * ) * * try: # <<<<<<<<<<<<<< @@ -25003,7 +27073,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_XGOTREF(__pyx_t_8); /*try:*/ { - /* "dependency_injector/providers.pyx":1234 + /* "dependency_injector/providers.pyx":1334 * * try: * with open(filepath) as opened_file: # <<<<<<<<<<<<<< @@ -25011,11 +27081,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * except IOError: */ /*with:*/ { - __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_open, __pyx_v_filepath); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1234, __pyx_L4_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_open, __pyx_v_filepath); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1334, __pyx_L4_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_9 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1234, __pyx_L4_error) + __pyx_t_9 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1334, __pyx_L4_error) __Pyx_GOTREF(__pyx_t_9); - __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1234, __pyx_L10_error) + __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1334, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_10 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { @@ -25029,7 +27099,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_4 = (__pyx_t_10) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_10) : __Pyx_PyObject_CallNoArg(__pyx_t_5); __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1234, __pyx_L10_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1334, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = __pyx_t_4; @@ -25047,21 +27117,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_v_opened_file = __pyx_t_5; __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1235 + /* "dependency_injector/providers.pyx":1335 * try: * with open(filepath) as opened_file: * config = yaml.load(opened_file, yaml.Loader) # <<<<<<<<<<<<<< * except IOError: * return */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1235, __pyx_L14_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1335, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_load); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1235, __pyx_L14_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_load); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1335, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1235, __pyx_L14_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1335, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_Loader); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1235, __pyx_L14_error) + __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_Loader); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1335, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = NULL; @@ -25079,7 +27149,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_1, __pyx_v_opened_file, __pyx_t_10}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1235, __pyx_L14_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1335, __pyx_L14_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; @@ -25088,14 +27158,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_1, __pyx_v_opened_file, __pyx_t_10}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1235, __pyx_L14_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1335, __pyx_L14_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } else #endif { - __pyx_t_15 = PyTuple_New(2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1235, __pyx_L14_error) + __pyx_t_15 = PyTuple_New(2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1335, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_15); if (__pyx_t_1) { __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_1); __pyx_t_1 = NULL; @@ -25106,7 +27176,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_GIVEREF(__pyx_t_10); PyTuple_SET_ITEM(__pyx_t_15, 1+__pyx_t_14, __pyx_t_10); __pyx_t_10 = 0; - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_15, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1235, __pyx_L14_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_15, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1335, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } @@ -25114,7 +27184,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_v_config = __pyx_t_5; __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1234 + /* "dependency_injector/providers.pyx":1334 * * try: * with open(filepath) as opened_file: # <<<<<<<<<<<<<< @@ -25134,20 +27204,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; /*except:*/ { __Pyx_AddTraceback("dependency_injector.providers.ConfigurationOption.from_yaml", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 1234, __pyx_L16_except_error) + if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 1334, __pyx_L16_except_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_15); - __pyx_t_10 = PyTuple_Pack(3, __pyx_t_5, __pyx_t_4, __pyx_t_15); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1234, __pyx_L16_except_error) + __pyx_t_10 = PyTuple_Pack(3, __pyx_t_5, __pyx_t_4, __pyx_t_15); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1334, __pyx_L16_except_error) __Pyx_GOTREF(__pyx_t_10); __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; - if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 1234, __pyx_L16_except_error) + if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 1334, __pyx_L16_except_error) __Pyx_GOTREF(__pyx_t_16); __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_16); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; - if (__pyx_t_3 < 0) __PYX_ERR(1, 1234, __pyx_L16_except_error) + if (__pyx_t_3 < 0) __PYX_ERR(1, 1334, __pyx_L16_except_error) __pyx_t_2 = ((!(__pyx_t_3 != 0)) != 0); if (__pyx_t_2) { __Pyx_GIVEREF(__pyx_t_5); @@ -25155,7 +27225,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestoreWithState(__pyx_t_5, __pyx_t_4, __pyx_t_15); __pyx_t_5 = 0; __pyx_t_4 = 0; __pyx_t_15 = 0; - __PYX_ERR(1, 1234, __pyx_L16_except_error) + __PYX_ERR(1, 1334, __pyx_L16_except_error) } __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -25181,7 +27251,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption if (__pyx_t_9) { __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 1234, __pyx_L4_error) + if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 1334, __pyx_L4_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } @@ -25196,7 +27266,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_L23:; } - /* "dependency_injector/providers.pyx":1233 + /* "dependency_injector/providers.pyx":1333 * ) * * try: # <<<<<<<<<<<<<< @@ -25215,7 +27285,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1236 + /* "dependency_injector/providers.pyx":1336 * with open(filepath) as opened_file: * config = yaml.load(opened_file, yaml.Loader) * except IOError: # <<<<<<<<<<<<<< @@ -25225,12 +27295,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_14 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_IOError); if (__pyx_t_14) { __Pyx_AddTraceback("dependency_injector.providers.ConfigurationOption.from_yaml", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_15, &__pyx_t_4, &__pyx_t_5) < 0) __PYX_ERR(1, 1236, __pyx_L6_except_error) + if (__Pyx_GetException(&__pyx_t_15, &__pyx_t_4, &__pyx_t_5) < 0) __PYX_ERR(1, 1336, __pyx_L6_except_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_5); - /* "dependency_injector/providers.pyx":1237 + /* "dependency_injector/providers.pyx":1337 * config = yaml.load(opened_file, yaml.Loader) * except IOError: * return # <<<<<<<<<<<<<< @@ -25247,7 +27317,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption goto __pyx_L6_except_error; __pyx_L6_except_error:; - /* "dependency_injector/providers.pyx":1233 + /* "dependency_injector/providers.pyx":1333 * ) * * try: # <<<<<<<<<<<<<< @@ -25268,14 +27338,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_L9_try_end:; } - /* "dependency_injector/providers.pyx":1239 + /* "dependency_injector/providers.pyx":1339 * return * * current_config = self.__call__() # <<<<<<<<<<<<<< * if not current_config: * current_config = {} */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1239, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1339, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_15 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -25289,36 +27359,36 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_5 = (__pyx_t_15) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_15) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1239, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1339, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_current_config = __pyx_t_5; __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1240 + /* "dependency_injector/providers.pyx":1340 * * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< * current_config = {} * self.override(merge_dicts(current_config, config)) */ - __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 1240, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 1340, __pyx_L1_error) __pyx_t_3 = ((!__pyx_t_2) != 0); if (__pyx_t_3) { - /* "dependency_injector/providers.pyx":1241 + /* "dependency_injector/providers.pyx":1341 * current_config = self.__call__() * if not current_config: * current_config = {} # <<<<<<<<<<<<<< * self.override(merge_dicts(current_config, config)) * */ - __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1241, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1341, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF_SET(__pyx_v_current_config, __pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1240 + /* "dependency_injector/providers.pyx":1340 * * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< @@ -25327,18 +27397,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ } - /* "dependency_injector/providers.pyx":1242 + /* "dependency_injector/providers.pyx":1342 * if not current_config: * current_config = {} * self.override(merge_dicts(current_config, config)) # <<<<<<<<<<<<<< * * def from_dict(self, options): */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1242, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1342, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __Pyx_GetModuleGlobalName(__pyx_t_10, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1242, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_10, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1342, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); - if (unlikely(!__pyx_v_config)) { __Pyx_RaiseUnboundLocalError("config"); __PYX_ERR(1, 1242, __pyx_L1_error) } + if (unlikely(!__pyx_v_config)) { __Pyx_RaiseUnboundLocalError("config"); __PYX_ERR(1, 1342, __pyx_L1_error) } __pyx_t_1 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_10))) { @@ -25354,7 +27424,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_10)) { PyObject *__pyx_temp[3] = {__pyx_t_1, __pyx_v_current_config, __pyx_v_config}; - __pyx_t_15 = __Pyx_PyFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1242, __pyx_L1_error) + __pyx_t_15 = __Pyx_PyFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1342, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GOTREF(__pyx_t_15); } else @@ -25362,13 +27432,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_10)) { PyObject *__pyx_temp[3] = {__pyx_t_1, __pyx_v_current_config, __pyx_v_config}; - __pyx_t_15 = __Pyx_PyCFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1242, __pyx_L1_error) + __pyx_t_15 = __Pyx_PyCFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1342, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GOTREF(__pyx_t_15); } else #endif { - __pyx_t_17 = PyTuple_New(2+__pyx_t_14); if (unlikely(!__pyx_t_17)) __PYX_ERR(1, 1242, __pyx_L1_error) + __pyx_t_17 = PyTuple_New(2+__pyx_t_14); if (unlikely(!__pyx_t_17)) __PYX_ERR(1, 1342, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_17); if (__pyx_t_1) { __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_17, 0, __pyx_t_1); __pyx_t_1 = NULL; @@ -25379,7 +27449,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_INCREF(__pyx_v_config); __Pyx_GIVEREF(__pyx_v_config); PyTuple_SET_ITEM(__pyx_t_17, 1+__pyx_t_14, __pyx_v_config); - __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_t_17, NULL); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1242, __pyx_L1_error) + __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_t_17, NULL); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1342, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0; } @@ -25397,12 +27467,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_5 = (__pyx_t_10) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_10, __pyx_t_15) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_15); __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1242, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1342, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1216 + /* "dependency_injector/providers.pyx":1316 * self.override(merge_dicts(current_config, config)) * * def from_yaml(self, filepath): # <<<<<<<<<<<<<< @@ -25431,7 +27501,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1244 +/* "dependency_injector/providers.pyx":1344 * self.override(merge_dicts(current_config, config)) * * def from_dict(self, options): # <<<<<<<<<<<<<< @@ -25471,14 +27541,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("from_dict", 0); - /* "dependency_injector/providers.pyx":1254 + /* "dependency_injector/providers.pyx":1354 * :rtype: None * """ * current_config = self.__call__() # <<<<<<<<<<<<<< * if not current_config: * current_config = {} */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1254, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1354, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -25492,36 +27562,36 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1254, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1354, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_current_config = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1255 + /* "dependency_injector/providers.pyx":1355 * """ * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< * current_config = {} * self.override(merge_dicts(current_config, options)) */ - __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(1, 1255, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(1, 1355, __pyx_L1_error) __pyx_t_5 = ((!__pyx_t_4) != 0); if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":1256 + /* "dependency_injector/providers.pyx":1356 * current_config = self.__call__() * if not current_config: * current_config = {} # <<<<<<<<<<<<<< * self.override(merge_dicts(current_config, options)) * */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1256, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1356, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF_SET(__pyx_v_current_config, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1255 + /* "dependency_injector/providers.pyx":1355 * """ * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< @@ -25530,16 +27600,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption */ } - /* "dependency_injector/providers.pyx":1257 + /* "dependency_injector/providers.pyx":1357 * if not current_config: * current_config = {} * self.override(merge_dicts(current_config, options)) # <<<<<<<<<<<<<< * * def from_env(self, name, default=None): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1257, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1257, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_8 = 0; @@ -25556,7 +27626,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_current_config, __pyx_v_options}; - __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1257, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1357, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_3); } else @@ -25564,13 +27634,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_current_config, __pyx_v_options}; - __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1257, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1357, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_3); } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1257, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -25581,7 +27651,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_INCREF(__pyx_v_options); __Pyx_GIVEREF(__pyx_v_options); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, __pyx_v_options); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1257, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } @@ -25599,12 +27669,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_6, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1257, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1244 + /* "dependency_injector/providers.pyx":1344 * self.override(merge_dicts(current_config, config)) * * def from_dict(self, options): # <<<<<<<<<<<<<< @@ -25631,7 +27701,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1259 +/* "dependency_injector/providers.pyx":1359 * self.override(merge_dicts(current_config, options)) * * def from_env(self, name, default=None): # <<<<<<<<<<<<<< @@ -25679,7 +27749,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19ConfigurationOption } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "from_env") < 0)) __PYX_ERR(1, 1259, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "from_env") < 0)) __PYX_ERR(1, 1359, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -25695,7 +27765,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19ConfigurationOption } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("from_env", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1259, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("from_env", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1359, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ConfigurationOption.from_env", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -25722,16 +27792,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption int __pyx_clineno = 0; __Pyx_RefNannySetupContext("from_env", 0); - /* "dependency_injector/providers.pyx":1270 + /* "dependency_injector/providers.pyx":1370 * :rtype: None * """ * value = os.getenv(name, default) # <<<<<<<<<<<<<< * self.override(value) * */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_os); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1270, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_os); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1370, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_getenv); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1270, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_getenv); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1370, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -25749,7 +27819,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_2, __pyx_v_name, __pyx_v_default}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 2+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1270, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 2+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1370, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -25757,13 +27827,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_2, __pyx_v_name, __pyx_v_default}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 2+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1270, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 2+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1370, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_5 = PyTuple_New(2+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1270, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(2+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1370, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (__pyx_t_2) { __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_2); __pyx_t_2 = NULL; @@ -25774,7 +27844,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_INCREF(__pyx_v_default); __Pyx_GIVEREF(__pyx_v_default); PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_4, __pyx_v_default); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1270, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1370, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } @@ -25782,14 +27852,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_v_value = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1271 + /* "dependency_injector/providers.pyx":1371 * """ * value = os.getenv(name, default) * self.override(value) # <<<<<<<<<<<<<< * * */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1271, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1371, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -25803,12 +27873,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption } __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_5, __pyx_v_value) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_value); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1271, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1371, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1259 + /* "dependency_injector/providers.pyx":1359 * self.override(merge_dicts(current_config, options)) * * def from_env(self, name, default=None): # <<<<<<<<<<<<<< @@ -25859,9 +27929,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -25872,55 +27942,60 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__cache, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__root_ref) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__cache, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__root_ref) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(6); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(7); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx___cache); __Pyx_GIVEREF(__pyx_v_self->__pyx___cache); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->__pyx___cache); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->__pyx___cache); __Pyx_INCREF(__pyx_v_self->__pyx___children); __Pyx_GIVEREF(__pyx_v_self->__pyx___children); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx___children); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx___children); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 3, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx___name); __Pyx_GIVEREF(__pyx_v_self->__pyx___name); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx___name); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx___name); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 4, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 5, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx___root_ref); __Pyx_GIVEREF(__pyx_v_self->__pyx___root_ref); - PyTuple_SET_ITEM(__pyx_t_1, 5, __pyx_v_self->__pyx___root_ref); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 6, __pyx_v_self->__pyx___root_ref); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__cache, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__root_ref) + * state = (self.__async_mode, self.__cache, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__root_ref) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__cache, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__root_ref) + * state = (self.__async_mode, self.__cache, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__root_ref) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -25929,16 +28004,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -25950,7 +28025,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__cache, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__root_ref) + * state = (self.__async_mode, self.__cache, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__root_ref) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -25964,49 +28039,49 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * else: * use_setstate = self.__cache is not None or self.__children is not None or self.__last_overriding is not None or self.__name is not None or self.__overridden is not None or self.__root_ref is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_ConfigurationOption, (type(self), 0xb205ea7, None), state + * return __pyx_unpickle_ConfigurationOption, (type(self), 0x66bc620, None), state */ /*else*/ { - __pyx_t_2 = (__pyx_v_self->__pyx___cache != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx___cache != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx___children != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx___name != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx___root_ref != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - __pyx_t_3 = __pyx_t_2; + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -26014,44 +28089,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * else: * use_setstate = self.__cache is not None or self.__children is not None or self.__last_overriding is not None or self.__name is not None or self.__overridden is not None or self.__root_ref is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ConfigurationOption, (type(self), 0xb205ea7, None), state + * return __pyx_unpickle_ConfigurationOption, (type(self), 0x66bc620, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__cache is not None or self.__children is not None or self.__last_overriding is not None or self.__name is not None or self.__overridden is not None or self.__root_ref is not None * if use_setstate: - * return __pyx_unpickle_ConfigurationOption, (type(self), 0xb205ea7, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_ConfigurationOption, (type(self), 0x66bc620, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_ConfigurationOption, (type(self), 0xb205ea7, state) + * return __pyx_unpickle_ConfigurationOption, (type(self), 0x66bc620, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_ConfigurationOpti); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_ConfigurationOpti); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_186670759); - __Pyx_GIVEREF(__pyx_int_186670759); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_186670759); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_107726368); + __Pyx_GIVEREF(__pyx_int_107726368); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_107726368); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -26060,15 +28135,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption * else: * use_setstate = self.__cache is not None or self.__children is not None or self.__last_overriding is not None or self.__name is not None or self.__overridden is not None or self.__root_ref is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ConfigurationOption, (type(self), 0xb205ea7, None), state + * return __pyx_unpickle_ConfigurationOption, (type(self), 0x66bc620, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_ConfigurationOption, (type(self), 0xb205ea7, None), state + * return __pyx_unpickle_ConfigurationOption, (type(self), 0x66bc620, None), state * else: - * return __pyx_unpickle_ConfigurationOption, (type(self), 0xb205ea7, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_ConfigurationOption, (type(self), 0x66bc620, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ConfigurationOption__set_state(self, __pyx_state) */ @@ -26076,27 +28151,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_ConfigurationOpti); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_186670759); - __Pyx_GIVEREF(__pyx_int_186670759); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_186670759); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_107726368); + __Pyx_GIVEREF(__pyx_int_107726368); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_107726368); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -26109,7 +28184,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.ConfigurationOption.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -26123,7 +28198,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ConfigurationOption, (type(self), 0xb205ea7, state) + * return __pyx_unpickle_ConfigurationOption, (type(self), 0x66bc620, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ConfigurationOption__set_state(self, __pyx_state) */ @@ -26151,7 +28226,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_ConfigurationOption, (type(self), 0xb205ea7, state) + * return __pyx_unpickle_ConfigurationOption, (type(self), 0x66bc620, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ConfigurationOption__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -26162,7 +28237,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ConfigurationOption, (type(self), 0xb205ea7, state) + * return __pyx_unpickle_ConfigurationOption, (type(self), 0x66bc620, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ConfigurationOption__set_state(self, __pyx_state) */ @@ -26180,7 +28255,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ConfigurationOption return __pyx_r; } -/* "dependency_injector/providers.pyx":1277 +/* "dependency_injector/providers.pyx":1377 * * @property * def option(self): # <<<<<<<<<<<<<< @@ -26211,7 +28286,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":1278 + /* "dependency_injector/providers.pyx":1378 * @property * def option(self): * return self.args[0] # <<<<<<<<<<<<<< @@ -26219,16 +28294,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1278, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1378, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_GetItemInt(__pyx_t_1, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1278, __pyx_L1_error) + __pyx_t_2 = __Pyx_GetItemInt(__pyx_t_1, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1378, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1277 + /* "dependency_injector/providers.pyx":1377 * * @property * def option(self): # <<<<<<<<<<<<<< @@ -26276,9 +28351,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; - int __pyx_t_4; + PyObject *__pyx_t_4 = NULL; int __pyx_t_5; int __pyx_t_6; + int __pyx_t_7; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -26287,62 +28363,67 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(7); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(8); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___args); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->__pyx_base.__pyx___args); + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->__pyx_base.__pyx___args); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___kwargs); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___kwargs); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_self->__pyx_base.__pyx___kwargs); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_3, 3, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_v_self->__pyx_base.__pyx___kwargs); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_4, 4, __pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_4, 5, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_4, 6, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_3, 6, __pyx_v_self->__pyx_base.__pyx___provides); + PyTuple_SET_ITEM(__pyx_t_4, 7, __pyx_v_self->__pyx_base.__pyx___provides); __pyx_t_1 = 0; __pyx_t_2 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_4); + __pyx_t_4 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_v__dict = __pyx_t_3; - __pyx_t_3 = 0; + __pyx_t_4 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_v__dict = __pyx_t_4; + __pyx_t_4 = 0; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_4 = (__pyx_v__dict != Py_None); - __pyx_t_5 = (__pyx_t_4 != 0); - if (__pyx_t_5) { + __pyx_t_5 = (__pyx_v__dict != Py_None); + __pyx_t_6 = (__pyx_t_5 != 0); + if (__pyx_t_6) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -26351,16 +28432,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO * use_setstate = True * else: */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__dict); + __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3)); + __pyx_t_3 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -26372,7 +28453,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -26386,42 +28467,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x3e02ba6, None), state */ /*else*/ { - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___args != ((PyObject*)Py_None)); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___args != ((PyObject*)Py_None)); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx___kwargs != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - __pyx_t_5 = __pyx_t_6; + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + __pyx_t_6 = __pyx_t_7; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_5; + __pyx_v_use_setstate = __pyx_t_6; } __pyx_L3:; @@ -26429,89 +28510,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x3e02ba6, None), state * else: */ - __pyx_t_5 = (__pyx_v_use_setstate != 0); - if (__pyx_t_5) { + __pyx_t_6 = (__pyx_v_use_setstate != 0); + if (__pyx_t_6) { /* "(tree fragment)":13 * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x03251dc, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x3e02ba6, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x03251dc, state) + * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x3e02ba6, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_TypedConfiguratio); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_TypedConfiguratio); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, Py_None); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); __pyx_t_3 = 0; - __pyx_r = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x3e02ba6, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x03251dc, None), state + * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x3e02ba6, None), state * else: - * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x03251dc, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x3e02ba6, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_TypedConfigurationOption__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_TypedConfiguratio); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_TypedConfiguratio); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_3297756); - __Pyx_GIVEREF(__pyx_int_3297756); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3297756); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_65022886); + __Pyx_GIVEREF(__pyx_int_65022886); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_65022886); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); - __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); - __pyx_t_1 = 0; - __pyx_t_3 = 0; - __pyx_r = __pyx_t_2; + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state); + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_3; + __pyx_t_3 = 0; goto __pyx_L0; } @@ -26526,6 +28607,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("dependency_injector.providers.TypedConfigurationOption.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -26538,7 +28620,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO /* "(tree fragment)":16 * else: - * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x03251dc, state) + * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_TypedConfigurationOption__set_state(self, __pyx_state) */ @@ -26566,7 +28648,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x03251dc, state) + * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_TypedConfigurationOption__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -26577,7 +28659,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO /* "(tree fragment)":16 * else: - * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x03251dc, state) + * return __pyx_unpickle_TypedConfigurationOption, (type(self), 0x3e02ba6, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_TypedConfigurationOption__set_state(self, __pyx_state) */ @@ -26595,7 +28677,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_24TypedConfigurationO return __pyx_r; } -/* "dependency_injector/providers.pyx":1303 +/* "dependency_injector/providers.pyx":1403 * DEFAULT_NAME = 'config' * * def __init__(self, name=DEFAULT_NAME, default=None): # <<<<<<<<<<<<<< @@ -26645,7 +28727,7 @@ static int __pyx_pw_19dependency_injector_9providers_13Configuration_1__init__(P } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 1303, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 1403, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -26662,7 +28744,7 @@ static int __pyx_pw_19dependency_injector_9providers_13Configuration_1__init__(P } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 0, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1303, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 0, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1403, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Configuration.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -26689,14 +28771,14 @@ static int __pyx_pf_19dependency_injector_9providers_13Configuration___init__(st int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":1304 + /* "dependency_injector/providers.pyx":1404 * * def __init__(self, name=DEFAULT_NAME, default=None): * self.__name = name # <<<<<<<<<<<<<< * * value = {} */ - if (!(likely(PyString_CheckExact(__pyx_v_name))||((__pyx_v_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_v_name)->tp_name), 0))) __PYX_ERR(1, 1304, __pyx_L1_error) + if (!(likely(PyString_CheckExact(__pyx_v_name))||((__pyx_v_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_v_name)->tp_name), 0))) __PYX_ERR(1, 1404, __pyx_L1_error) __pyx_t_1 = __pyx_v_name; __Pyx_INCREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); @@ -26705,19 +28787,19 @@ static int __pyx_pf_19dependency_injector_9providers_13Configuration___init__(st __pyx_v_self->__pyx___name = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1306 + /* "dependency_injector/providers.pyx":1406 * self.__name = name * * value = {} # <<<<<<<<<<<<<< * if default is not None: * assert isinstance(default, dict), default */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1306, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1406, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_value = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1307 + /* "dependency_injector/providers.pyx":1407 * * value = {} * if default is not None: # <<<<<<<<<<<<<< @@ -26728,7 +28810,7 @@ static int __pyx_pf_19dependency_injector_9providers_13Configuration___init__(st __pyx_t_3 = (__pyx_t_2 != 0); if (__pyx_t_3) { - /* "dependency_injector/providers.pyx":1308 + /* "dependency_injector/providers.pyx":1408 * value = {} * if default is not None: * assert isinstance(default, dict), default # <<<<<<<<<<<<<< @@ -26739,23 +28821,23 @@ static int __pyx_pf_19dependency_injector_9providers_13Configuration___init__(st if (unlikely(!Py_OptimizeFlag)) { __pyx_t_3 = PyDict_Check(__pyx_v_default); if (unlikely(!(__pyx_t_3 != 0))) { - __pyx_t_1 = PyTuple_Pack(1, __pyx_v_default); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1308, __pyx_L1_error) + __pyx_t_1 = PyTuple_Pack(1, __pyx_v_default); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1408, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); PyErr_SetObject(PyExc_AssertionError, __pyx_t_1); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 1308, __pyx_L1_error) + __PYX_ERR(1, 1408, __pyx_L1_error) } } #endif - /* "dependency_injector/providers.pyx":1309 + /* "dependency_injector/providers.pyx":1409 * if default is not None: * assert isinstance(default, dict), default * value = default.copy() # <<<<<<<<<<<<<< * * self.__children = {} */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_default, __pyx_n_s_copy); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1309, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_default, __pyx_n_s_copy); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1409, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -26769,13 +28851,13 @@ static int __pyx_pf_19dependency_injector_9providers_13Configuration___init__(st } __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1309, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1409, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF_SET(__pyx_v_value, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1307 + /* "dependency_injector/providers.pyx":1407 * * value = {} * if default is not None: # <<<<<<<<<<<<<< @@ -26784,14 +28866,14 @@ static int __pyx_pf_19dependency_injector_9providers_13Configuration___init__(st */ } - /* "dependency_injector/providers.pyx":1311 + /* "dependency_injector/providers.pyx":1411 * value = default.copy() * * self.__children = {} # <<<<<<<<<<<<<< * * super().__init__(value) */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1311, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1411, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___children); @@ -26799,14 +28881,14 @@ static int __pyx_pf_19dependency_injector_9providers_13Configuration___init__(st __pyx_v_self->__pyx___children = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1313 + /* "dependency_injector/providers.pyx":1413 * self.__children = {} * * super().__init__(value) # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1313, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration)); @@ -26814,10 +28896,10 @@ static int __pyx_pf_19dependency_injector_9providers_13Configuration___init__(st __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1313, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1313, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -26832,12 +28914,12 @@ static int __pyx_pf_19dependency_injector_9providers_13Configuration___init__(st } __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_value) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_value); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1313, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1303 + /* "dependency_injector/providers.pyx":1403 * DEFAULT_NAME = 'config' * * def __init__(self, name=DEFAULT_NAME, default=None): # <<<<<<<<<<<<<< @@ -26860,7 +28942,7 @@ static int __pyx_pf_19dependency_injector_9providers_13Configuration___init__(st return __pyx_r; } -/* "dependency_injector/providers.pyx":1315 +/* "dependency_injector/providers.pyx":1415 * super().__init__(value) * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -26898,16 +28980,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":1318 + /* "dependency_injector/providers.pyx":1418 * cdef Configuration copied * * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1318, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1418, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1318, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1418, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -26922,14 +29004,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1318, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1418, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Configuration))))) __PYX_ERR(1, 1318, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Configuration))))) __PYX_ERR(1, 1418, __pyx_L1_error) __pyx_v_copied = ((struct __pyx_obj_19dependency_injector_9providers_Configuration *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1319 + /* "dependency_injector/providers.pyx":1419 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -26940,7 +29022,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":1320 + /* "dependency_injector/providers.pyx":1420 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -26952,7 +29034,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1319 + /* "dependency_injector/providers.pyx":1419 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -26961,14 +29043,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de */ } - /* "dependency_injector/providers.pyx":1322 + /* "dependency_injector/providers.pyx":1422 * return copied * * copied = self.__class__(self.__name, self.__provides) # <<<<<<<<<<<<<< * memo[id(self)] = copied * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1322, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1422, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; __pyx_t_7 = 0; @@ -26985,7 +29067,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_v_self->__pyx___name, __pyx_v_self->__pyx_base.__pyx___provides}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1322, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1422, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -26993,13 +29075,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_v_self->__pyx___name, __pyx_v_self->__pyx_base.__pyx___provides}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1322, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1422, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_4 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1322, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1422, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); if (__pyx_t_3) { __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL; @@ -27010,28 +29092,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_7, __pyx_v_self->__pyx_base.__pyx___provides); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1322, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1422, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Configuration))))) __PYX_ERR(1, 1322, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Configuration))))) __PYX_ERR(1, 1422, __pyx_L1_error) __Pyx_DECREF_SET(__pyx_v_copied, ((struct __pyx_obj_19dependency_injector_9providers_Configuration *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1323 + /* "dependency_injector/providers.pyx":1423 * * copied = self.__class__(self.__name, self.__provides) * memo[id(self)] = copied # <<<<<<<<<<<<<< * * copied.__children = deepcopy(self.__children, memo) */ - __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1323, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1423, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (unlikely(PyObject_SetItem(__pyx_v_memo, __pyx_t_1, ((PyObject *)__pyx_v_copied)) < 0)) __PYX_ERR(1, 1323, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_v_memo, __pyx_t_1, ((PyObject *)__pyx_v_copied)) < 0)) __PYX_ERR(1, 1423, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1325 + /* "dependency_injector/providers.pyx":1425 * memo[id(self)] = copied * * copied.__children = deepcopy(self.__children, memo) # <<<<<<<<<<<<<< @@ -27040,30 +29122,30 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de */ __pyx_t_1 = __pyx_v_self->__pyx___children; __Pyx_INCREF(__pyx_t_1); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1325, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1425, __pyx_L1_error) __pyx_t_8.__pyx_n = 1; __pyx_t_8.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_8); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1325, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_8); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1425, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (!(likely(PyDict_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_2)->tp_name), 0))) __PYX_ERR(1, 1325, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_2)->tp_name), 0))) __PYX_ERR(1, 1425, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_2); __Pyx_GOTREF(__pyx_v_copied->__pyx___children); __Pyx_DECREF(__pyx_v_copied->__pyx___children); __pyx_v_copied->__pyx___children = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1326 + /* "dependency_injector/providers.pyx":1426 * * copied.__children = deepcopy(self.__children, memo) * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1326, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1426, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_Configuration *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":1328 + /* "dependency_injector/providers.pyx":1428 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -27075,7 +29157,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1315 + /* "dependency_injector/providers.pyx":1415 * super().__init__(value) * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -27098,7 +29180,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_2__de return __pyx_r; } -/* "dependency_injector/providers.pyx":1330 +/* "dependency_injector/providers.pyx":1430 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -27129,7 +29211,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_4__st int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":1331 + /* "dependency_injector/providers.pyx":1431 * * def __str__(self): * return represent_provider(provider=self, provides=self.__name) # <<<<<<<<<<<<<< @@ -27139,14 +29221,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_4__st __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __pyx_v_self->__pyx___name; __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1331, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1431, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1330 + /* "dependency_injector/providers.pyx":1430 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -27166,7 +29248,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_4__st return __pyx_r; } -/* "dependency_injector/providers.pyx":1333 +/* "dependency_injector/providers.pyx":1433 * return represent_provider(provider=self, provides=self.__name) * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -27202,14 +29284,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getattr__", 0); - /* "dependency_injector/providers.pyx":1334 + /* "dependency_injector/providers.pyx":1434 * * def __getattr__(self, item): * if item.startswith('__') and item.endswith('__'): # <<<<<<<<<<<<<< * raise AttributeError( * '\'{cls}\' object has no attribute ' */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_item, __pyx_n_s_startswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1334, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_item, __pyx_n_s_startswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1434, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -27223,17 +29305,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1334, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1434, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 1334, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 1434, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (__pyx_t_5) { } else { __pyx_t_1 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_item, __pyx_n_s_endswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1334, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_item, __pyx_n_s_endswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1434, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -27247,70 +29329,70 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1334, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1434, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 1334, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 1434, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_1 = __pyx_t_5; __pyx_L4_bool_binop_done:; if (unlikely(__pyx_t_1)) { - /* "dependency_injector/providers.pyx":1337 + /* "dependency_injector/providers.pyx":1437 * raise AttributeError( * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, # <<<<<<<<<<<<<< * attribute_name=item)) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_cls_object_has_no_attribute_att, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1337, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_cls_object_has_no_attribute_att, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1437, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1337, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1437, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1337, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1437, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1337, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1437, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_cls, __pyx_t_6) < 0) __PYX_ERR(1, 1337, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_cls, __pyx_t_6) < 0) __PYX_ERR(1, 1437, __pyx_L1_error) __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":1338 + /* "dependency_injector/providers.pyx":1438 * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, * attribute_name=item)) # <<<<<<<<<<<<<< * * child = self.__children.get(item) */ - if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_attribute_name, __pyx_v_item) < 0) __PYX_ERR(1, 1337, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_attribute_name, __pyx_v_item) < 0) __PYX_ERR(1, 1437, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1337 + /* "dependency_injector/providers.pyx":1437 * raise AttributeError( * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, # <<<<<<<<<<<<<< * attribute_name=item)) * */ - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1337, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1437, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1335 + /* "dependency_injector/providers.pyx":1435 * def __getattr__(self, item): * if item.startswith('__') and item.endswith('__'): * raise AttributeError( # <<<<<<<<<<<<<< * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, */ - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1335, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1435, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 1335, __pyx_L1_error) + __PYX_ERR(1, 1435, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1334 + /* "dependency_injector/providers.pyx":1434 * * def __getattr__(self, item): * if item.startswith('__') and item.endswith('__'): # <<<<<<<<<<<<<< @@ -27319,7 +29401,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge */ } - /* "dependency_injector/providers.pyx":1340 + /* "dependency_injector/providers.pyx":1440 * attribute_name=item)) * * child = self.__children.get(item) # <<<<<<<<<<<<<< @@ -27328,14 +29410,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge */ if (unlikely(__pyx_v_self->__pyx___children == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "get"); - __PYX_ERR(1, 1340, __pyx_L1_error) + __PYX_ERR(1, 1440, __pyx_L1_error) } - __pyx_t_3 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___children, __pyx_v_item, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1340, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___children, __pyx_v_item, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1440, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_v_child = __pyx_t_3; __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1341 + /* "dependency_injector/providers.pyx":1441 * * child = self.__children.get(item) * if child is None: # <<<<<<<<<<<<<< @@ -27346,19 +29428,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge __pyx_t_5 = (__pyx_t_1 != 0); if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":1342 + /* "dependency_injector/providers.pyx":1442 * child = self.__children.get(item) * if child is None: * child = ConfigurationOption((item,), self) # <<<<<<<<<<<<<< * self.__children[item] = child * return child */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1342, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1442, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_item); - __pyx_t_6 = PyTuple_New(2); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1342, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1442, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_3); @@ -27366,13 +29448,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_6, 1, ((PyObject *)__pyx_v_self)); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption), __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1342, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption), __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1442, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF_SET(__pyx_v_child, __pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1343 + /* "dependency_injector/providers.pyx":1443 * if child is None: * child = ConfigurationOption((item,), self) * self.__children[item] = child # <<<<<<<<<<<<<< @@ -27381,11 +29463,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge */ if (unlikely(__pyx_v_self->__pyx___children == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 1343, __pyx_L1_error) + __PYX_ERR(1, 1443, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_v_self->__pyx___children, __pyx_v_item, __pyx_v_child) < 0)) __PYX_ERR(1, 1343, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_self->__pyx___children, __pyx_v_item, __pyx_v_child) < 0)) __PYX_ERR(1, 1443, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1341 + /* "dependency_injector/providers.pyx":1441 * * child = self.__children.get(item) * if child is None: # <<<<<<<<<<<<<< @@ -27394,7 +29476,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge */ } - /* "dependency_injector/providers.pyx":1344 + /* "dependency_injector/providers.pyx":1444 * child = ConfigurationOption((item,), self) * self.__children[item] = child * return child # <<<<<<<<<<<<<< @@ -27406,7 +29488,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge __pyx_r = __pyx_v_child; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1333 + /* "dependency_injector/providers.pyx":1433 * return represent_provider(provider=self, provides=self.__name) * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -27429,7 +29511,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_6__ge return __pyx_r; } -/* "dependency_injector/providers.pyx":1346 +/* "dependency_injector/providers.pyx":1446 * return child * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -27463,7 +29545,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_8__ge int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getitem__", 0); - /* "dependency_injector/providers.pyx":1347 + /* "dependency_injector/providers.pyx":1447 * * def __getitem__(self, item): * child = self.__children.get(item) # <<<<<<<<<<<<<< @@ -27472,14 +29554,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_8__ge */ if (unlikely(__pyx_v_self->__pyx___children == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "get"); - __PYX_ERR(1, 1347, __pyx_L1_error) + __PYX_ERR(1, 1447, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___children, __pyx_v_item, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1347, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_GetItemDefault(__pyx_v_self->__pyx___children, __pyx_v_item, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1447, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_child = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1348 + /* "dependency_injector/providers.pyx":1448 * def __getitem__(self, item): * child = self.__children.get(item) * if child is None: # <<<<<<<<<<<<<< @@ -27490,14 +29572,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_8__ge __pyx_t_3 = (__pyx_t_2 != 0); if (__pyx_t_3) { - /* "dependency_injector/providers.pyx":1349 + /* "dependency_injector/providers.pyx":1449 * child = self.__children.get(item) * if child is None: * child = ConfigurationOption(item, self) # <<<<<<<<<<<<<< * self.__children[item] = child * return child */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1349, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); @@ -27505,13 +29587,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_8__ge __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption), __pyx_t_1, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1349, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption), __pyx_t_1, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF_SET(__pyx_v_child, __pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":1350 + /* "dependency_injector/providers.pyx":1450 * if child is None: * child = ConfigurationOption(item, self) * self.__children[item] = child # <<<<<<<<<<<<<< @@ -27520,11 +29602,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_8__ge */ if (unlikely(__pyx_v_self->__pyx___children == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 1350, __pyx_L1_error) + __PYX_ERR(1, 1450, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_v_self->__pyx___children, __pyx_v_item, __pyx_v_child) < 0)) __PYX_ERR(1, 1350, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_self->__pyx___children, __pyx_v_item, __pyx_v_child) < 0)) __PYX_ERR(1, 1450, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1348 + /* "dependency_injector/providers.pyx":1448 * def __getitem__(self, item): * child = self.__children.get(item) * if child is None: # <<<<<<<<<<<<<< @@ -27533,7 +29615,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_8__ge */ } - /* "dependency_injector/providers.pyx":1351 + /* "dependency_injector/providers.pyx":1451 * child = ConfigurationOption(item, self) * self.__children[item] = child * return child # <<<<<<<<<<<<<< @@ -27545,7 +29627,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_8__ge __pyx_r = __pyx_v_child; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1346 + /* "dependency_injector/providers.pyx":1446 * return child * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -27566,7 +29648,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_8__ge return __pyx_r; } -/* "dependency_injector/providers.pyx":1353 +/* "dependency_injector/providers.pyx":1453 * return child * * def get_name(self): # <<<<<<<<<<<<<< @@ -27592,7 +29674,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_10get __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_name", 0); - /* "dependency_injector/providers.pyx":1354 + /* "dependency_injector/providers.pyx":1454 * * def get_name(self): * return self.__name # <<<<<<<<<<<<<< @@ -27604,7 +29686,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_10get __pyx_r = __pyx_v_self->__pyx___name; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1353 + /* "dependency_injector/providers.pyx":1453 * return child * * def get_name(self): # <<<<<<<<<<<<<< @@ -27619,7 +29701,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_10get return __pyx_r; } -/* "dependency_injector/providers.pyx":1356 +/* "dependency_injector/providers.pyx":1456 * return self.__name * * def get(self, selector): # <<<<<<<<<<<<<< @@ -27658,14 +29740,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_12get int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get", 0); - /* "dependency_injector/providers.pyx":1365 + /* "dependency_injector/providers.pyx":1465 * :rtype: Any * """ * keys = selector.split('.') # <<<<<<<<<<<<<< * value = self.__call__() * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_selector, __pyx_n_s_split); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1365, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_selector, __pyx_n_s_split); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1465, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -27679,20 +29761,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_12get } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_kp_s__5) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_kp_s__5); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1365, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1465, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_keys = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1366 + /* "dependency_injector/providers.pyx":1466 * """ * keys = selector.split('.') * value = self.__call__() # <<<<<<<<<<<<<< * * while len(keys) > 0: */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1366, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1466, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -27706,13 +29788,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_12get } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1366, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1466, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_value = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1368 + /* "dependency_injector/providers.pyx":1468 * value = self.__call__() * * while len(keys) > 0: # <<<<<<<<<<<<<< @@ -27720,30 +29802,30 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_12get * value = value.get(key) */ while (1) { - __pyx_t_4 = PyObject_Length(__pyx_v_keys); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1368, __pyx_L1_error) + __pyx_t_4 = PyObject_Length(__pyx_v_keys); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1468, __pyx_L1_error) __pyx_t_5 = ((__pyx_t_4 > 0) != 0); if (!__pyx_t_5) break; - /* "dependency_injector/providers.pyx":1369 + /* "dependency_injector/providers.pyx":1469 * * while len(keys) > 0: * key = keys.pop(0) # <<<<<<<<<<<<<< * value = value.get(key) * if value is None: */ - __pyx_t_1 = __Pyx_PyObject_PopIndex(__pyx_v_keys, __pyx_int_0, 0, 1, Py_ssize_t, PyInt_FromSsize_t); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1369, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_PopIndex(__pyx_v_keys, __pyx_int_0, 0, 1, Py_ssize_t, PyInt_FromSsize_t); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1469, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_XDECREF_SET(__pyx_v_key, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1370 + /* "dependency_injector/providers.pyx":1470 * while len(keys) > 0: * key = keys.pop(0) * value = value.get(key) # <<<<<<<<<<<<<< * if value is None: * break */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_value, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1370, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_value, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1470, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -27757,13 +29839,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_12get } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_key) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_key); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1370, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1470, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF_SET(__pyx_v_value, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1371 + /* "dependency_injector/providers.pyx":1471 * key = keys.pop(0) * value = value.get(key) * if value is None: # <<<<<<<<<<<<<< @@ -27774,7 +29856,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_12get __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":1372 + /* "dependency_injector/providers.pyx":1472 * value = value.get(key) * if value is None: * break # <<<<<<<<<<<<<< @@ -27783,7 +29865,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_12get */ goto __pyx_L4_break; - /* "dependency_injector/providers.pyx":1371 + /* "dependency_injector/providers.pyx":1471 * key = keys.pop(0) * value = value.get(key) * if value is None: # <<<<<<<<<<<<<< @@ -27794,7 +29876,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_12get } __pyx_L4_break:; - /* "dependency_injector/providers.pyx":1374 + /* "dependency_injector/providers.pyx":1474 * break * * return value # <<<<<<<<<<<<<< @@ -27806,7 +29888,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_12get __pyx_r = __pyx_v_value; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1356 + /* "dependency_injector/providers.pyx":1456 * return self.__name * * def get(self, selector): # <<<<<<<<<<<<<< @@ -27830,7 +29912,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_12get return __pyx_r; } -/* "dependency_injector/providers.pyx":1376 +/* "dependency_injector/providers.pyx":1476 * return value * * def set(self, selector, value): # <<<<<<<<<<<<<< @@ -27873,11 +29955,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_13Configuration_15set case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, 1); __PYX_ERR(1, 1376, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, 1); __PYX_ERR(1, 1476, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "set") < 0)) __PYX_ERR(1, 1376, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "set") < 0)) __PYX_ERR(1, 1476, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -27890,7 +29972,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_13Configuration_15set } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1376, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1476, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Configuration.set", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -27924,14 +30006,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set", 0); - /* "dependency_injector/providers.pyx":1388 + /* "dependency_injector/providers.pyx":1488 * :rtype: :py:class:`OverridingContext` * """ * keys = selector.split('.') # <<<<<<<<<<<<<< * original_value = current_value = deepcopy(self.__call__()) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_selector, __pyx_n_s_split); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1388, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_selector, __pyx_n_s_split); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -27945,20 +30027,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_kp_s__5) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_kp_s__5); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1388, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_keys = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1389 + /* "dependency_injector/providers.pyx":1489 * """ * keys = selector.split('.') * original_value = current_value = deepcopy(self.__call__()) # <<<<<<<<<<<<<< * * while len(keys) > 0: */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1389, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1489, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -27972,10 +30054,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1389, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1489, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1389, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1489, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_INCREF(__pyx_t_2); @@ -27984,7 +30066,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set __pyx_v_current_value = __pyx_t_2; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1391 + /* "dependency_injector/providers.pyx":1491 * original_value = current_value = deepcopy(self.__call__()) * * while len(keys) > 0: # <<<<<<<<<<<<<< @@ -27992,43 +30074,43 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set * if len(keys) == 0: */ while (1) { - __pyx_t_4 = PyObject_Length(__pyx_v_keys); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1391, __pyx_L1_error) + __pyx_t_4 = PyObject_Length(__pyx_v_keys); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1491, __pyx_L1_error) __pyx_t_5 = ((__pyx_t_4 > 0) != 0); if (!__pyx_t_5) break; - /* "dependency_injector/providers.pyx":1392 + /* "dependency_injector/providers.pyx":1492 * * while len(keys) > 0: * key = keys.pop(0) # <<<<<<<<<<<<<< * if len(keys) == 0: * current_value[key] = value */ - __pyx_t_2 = __Pyx_PyObject_PopIndex(__pyx_v_keys, __pyx_int_0, 0, 1, Py_ssize_t, PyInt_FromSsize_t); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1392, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_PopIndex(__pyx_v_keys, __pyx_int_0, 0, 1, Py_ssize_t, PyInt_FromSsize_t); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1492, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_XDECREF_SET(__pyx_v_key, __pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1393 + /* "dependency_injector/providers.pyx":1493 * while len(keys) > 0: * key = keys.pop(0) * if len(keys) == 0: # <<<<<<<<<<<<<< * current_value[key] = value * break */ - __pyx_t_4 = PyObject_Length(__pyx_v_keys); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1393, __pyx_L1_error) + __pyx_t_4 = PyObject_Length(__pyx_v_keys); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1493, __pyx_L1_error) __pyx_t_5 = ((__pyx_t_4 == 0) != 0); if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":1394 + /* "dependency_injector/providers.pyx":1494 * key = keys.pop(0) * if len(keys) == 0: * current_value[key] = value # <<<<<<<<<<<<<< * break * temp_value = current_value.get(key, {}) */ - if (unlikely(PyObject_SetItem(__pyx_v_current_value, __pyx_v_key, __pyx_v_value) < 0)) __PYX_ERR(1, 1394, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_v_current_value, __pyx_v_key, __pyx_v_value) < 0)) __PYX_ERR(1, 1494, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1395 + /* "dependency_injector/providers.pyx":1495 * if len(keys) == 0: * current_value[key] = value * break # <<<<<<<<<<<<<< @@ -28037,7 +30119,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set */ goto __pyx_L4_break; - /* "dependency_injector/providers.pyx":1393 + /* "dependency_injector/providers.pyx":1493 * while len(keys) > 0: * key = keys.pop(0) * if len(keys) == 0: # <<<<<<<<<<<<<< @@ -28046,16 +30128,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set */ } - /* "dependency_injector/providers.pyx":1396 + /* "dependency_injector/providers.pyx":1496 * current_value[key] = value * break * temp_value = current_value.get(key, {}) # <<<<<<<<<<<<<< * current_value[key] = temp_value * current_value = temp_value */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_current_value, __pyx_n_s_get); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1396, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_current_value, __pyx_n_s_get); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1496, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1396, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1496, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_6 = NULL; __pyx_t_7 = 0; @@ -28072,7 +30154,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_1)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_v_key, __pyx_t_3}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1396, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1496, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -28081,14 +30163,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_v_key, __pyx_t_3}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1396, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1496, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif { - __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1396, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1496, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; @@ -28099,7 +30181,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_7, __pyx_t_3); __pyx_t_3 = 0; - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_8, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1396, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_8, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1496, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } @@ -28107,16 +30189,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set __Pyx_XDECREF_SET(__pyx_v_temp_value, __pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1397 + /* "dependency_injector/providers.pyx":1497 * break * temp_value = current_value.get(key, {}) * current_value[key] = temp_value # <<<<<<<<<<<<<< * current_value = temp_value * */ - if (unlikely(PyObject_SetItem(__pyx_v_current_value, __pyx_v_key, __pyx_v_temp_value) < 0)) __PYX_ERR(1, 1397, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_v_current_value, __pyx_v_key, __pyx_v_temp_value) < 0)) __PYX_ERR(1, 1497, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1398 + /* "dependency_injector/providers.pyx":1498 * temp_value = current_value.get(key, {}) * current_value[key] = temp_value * current_value = temp_value # <<<<<<<<<<<<<< @@ -28128,7 +30210,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set } __pyx_L4_break:; - /* "dependency_injector/providers.pyx":1400 + /* "dependency_injector/providers.pyx":1500 * current_value = temp_value * * return self.override(original_value) # <<<<<<<<<<<<<< @@ -28136,7 +30218,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set * def override(self, provider): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1400, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1500, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -28150,14 +30232,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set } __pyx_t_2 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_8, __pyx_v_original_value) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_original_value); __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1400, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1500, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1376 + /* "dependency_injector/providers.pyx":1476 * return value * * def set(self, selector, value): # <<<<<<<<<<<<<< @@ -28185,7 +30267,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_14set return __pyx_r; } -/* "dependency_injector/providers.pyx":1402 +/* "dependency_injector/providers.pyx":1502 * return self.override(original_value) * * def override(self, provider): # <<<<<<<<<<<<<< @@ -28219,14 +30301,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_16ove int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/providers.pyx":1413 + /* "dependency_injector/providers.pyx":1513 * :rtype: :py:class:`OverridingContext` * """ * context = super().override(provider) # <<<<<<<<<<<<<< * self.reset_cache() * return context */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1413, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1513, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration)); @@ -28234,10 +30316,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_16ove __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1413, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1513, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1413, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1513, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -28252,20 +30334,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_16ove } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_provider); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1413, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1513, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_context = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1414 + /* "dependency_injector/providers.pyx":1514 * """ * context = super().override(provider) * self.reset_cache() # <<<<<<<<<<<<<< * return context * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_reset_cache); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1414, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_reset_cache); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1514, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -28279,12 +30361,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_16ove } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1414, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1514, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1415 + /* "dependency_injector/providers.pyx":1515 * context = super().override(provider) * self.reset_cache() * return context # <<<<<<<<<<<<<< @@ -28296,7 +30378,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_16ove __pyx_r = __pyx_v_context; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1402 + /* "dependency_injector/providers.pyx":1502 * return self.override(original_value) * * def override(self, provider): # <<<<<<<<<<<<<< @@ -28318,7 +30400,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_16ove return __pyx_r; } -/* "dependency_injector/providers.pyx":1417 +/* "dependency_injector/providers.pyx":1517 * return context * * def reset_last_overriding(self): # <<<<<<<<<<<<<< @@ -28351,14 +30433,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_18res int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_last_overriding", 0); - /* "dependency_injector/providers.pyx":1425 + /* "dependency_injector/providers.pyx":1525 * :rtype: None * """ * super().reset_last_overriding() # <<<<<<<<<<<<<< * self.reset_cache() * */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1425, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1525, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration)); @@ -28366,10 +30448,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_18res __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1425, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1525, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1425, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_reset_last_overriding); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1525, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -28384,19 +30466,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_18res } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1425, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1525, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1426 + /* "dependency_injector/providers.pyx":1526 * """ * super().reset_last_overriding() * self.reset_cache() # <<<<<<<<<<<<<< * * def reset_override(self): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_reset_cache); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1426, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_reset_cache); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1526, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -28410,12 +30492,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_18res } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1426, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1526, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1417 + /* "dependency_injector/providers.pyx":1517 * return context * * def reset_last_overriding(self): # <<<<<<<<<<<<<< @@ -28438,7 +30520,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_18res return __pyx_r; } -/* "dependency_injector/providers.pyx":1428 +/* "dependency_injector/providers.pyx":1528 * self.reset_cache() * * def reset_override(self): # <<<<<<<<<<<<<< @@ -28471,14 +30553,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_20res int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_override", 0); - /* "dependency_injector/providers.pyx":1433 + /* "dependency_injector/providers.pyx":1533 * :rtype: None * """ * super().reset_override() # <<<<<<<<<<<<<< * self.reset_cache() * */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1433, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration)); @@ -28486,10 +30568,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_20res __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1433, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_reset_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1433, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_reset_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -28504,19 +30586,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_20res } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1433, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1434 + /* "dependency_injector/providers.pyx":1534 * """ * super().reset_override() * self.reset_cache() # <<<<<<<<<<<<<< * * def reset_cache(self): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_reset_cache); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1434, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_reset_cache); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1534, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -28530,12 +30612,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_20res } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1434, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1534, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1428 + /* "dependency_injector/providers.pyx":1528 * self.reset_cache() * * def reset_override(self): # <<<<<<<<<<<<<< @@ -28558,7 +30640,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_20res return __pyx_r; } -/* "dependency_injector/providers.pyx":1436 +/* "dependency_injector/providers.pyx":1536 * self.reset_cache() * * def reset_cache(self): # <<<<<<<<<<<<<< @@ -28595,7 +30677,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_22res int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset_cache", 0); - /* "dependency_injector/providers.pyx":1441 + /* "dependency_injector/providers.pyx":1541 * :rtype: None * """ * for child in self.__children.values(): # <<<<<<<<<<<<<< @@ -28604,17 +30686,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_22res */ if (unlikely(__pyx_v_self->__pyx___children == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "values"); - __PYX_ERR(1, 1441, __pyx_L1_error) + __PYX_ERR(1, 1541, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_Values(__pyx_v_self->__pyx___children); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1441, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_Values(__pyx_v_self->__pyx___children); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1541, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; __pyx_t_4 = NULL; } else { - __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1441, __pyx_L1_error) + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1541, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1441, __pyx_L1_error) + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1541, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -28622,17 +30704,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_22res if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1441, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1541, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1441, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1541, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1441, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1541, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1441, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1541, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -28642,7 +30724,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_22res PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 1441, __pyx_L1_error) + else __PYX_ERR(1, 1541, __pyx_L1_error) } break; } @@ -28651,14 +30733,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_22res __Pyx_XDECREF_SET(__pyx_v_child, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1442 + /* "dependency_injector/providers.pyx":1542 * """ * for child in self.__children.values(): * child.reset_cache() # <<<<<<<<<<<<<< * * def update(self, value): */ - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_child, __pyx_n_s_reset_cache); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1442, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_child, __pyx_n_s_reset_cache); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1542, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { @@ -28672,12 +30754,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_22res } __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1442, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1542, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1441 + /* "dependency_injector/providers.pyx":1541 * :rtype: None * """ * for child in self.__children.values(): # <<<<<<<<<<<<<< @@ -28687,7 +30769,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_22res } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1436 + /* "dependency_injector/providers.pyx":1536 * self.reset_cache() * * def reset_cache(self): # <<<<<<<<<<<<<< @@ -28712,7 +30794,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_22res return __pyx_r; } -/* "dependency_injector/providers.pyx":1444 +/* "dependency_injector/providers.pyx":1544 * child.reset_cache() * * def update(self, value): # <<<<<<<<<<<<<< @@ -28745,14 +30827,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_24upd int __pyx_clineno = 0; __Pyx_RefNannySetupContext("update", 0); - /* "dependency_injector/providers.pyx":1456 + /* "dependency_injector/providers.pyx":1556 * :rtype: None * """ * self.override(value) # <<<<<<<<<<<<<< * * def from_ini(self, filepath): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1456, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1556, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -28766,12 +30848,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_24upd } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_value) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_value); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1456, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1556, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1444 + /* "dependency_injector/providers.pyx":1544 * child.reset_cache() * * def update(self, value): # <<<<<<<<<<<<<< @@ -28794,7 +30876,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_24upd return __pyx_r; } -/* "dependency_injector/providers.pyx":1458 +/* "dependency_injector/providers.pyx":1558 * self.override(value) * * def from_ini(self, filepath): # <<<<<<<<<<<<<< @@ -28839,14 +30921,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro int __pyx_clineno = 0; __Pyx_RefNannySetupContext("from_ini", 0); - /* "dependency_injector/providers.pyx":1468 + /* "dependency_injector/providers.pyx":1568 * :rtype: None * """ * parser = _parse_ini_file(filepath) # <<<<<<<<<<<<<< * * config = {} */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_parse_ini_file); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1468, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_parse_ini_file); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1568, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { @@ -28860,32 +30942,32 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_filepath) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_filepath); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1468, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1568, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_parser = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1470 + /* "dependency_injector/providers.pyx":1570 * parser = _parse_ini_file(filepath) * * config = {} # <<<<<<<<<<<<<< * for section in parser.sections(): * config[section] = dict(parser.items(section)) */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1470, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1570, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_config = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1471 + /* "dependency_injector/providers.pyx":1571 * * config = {} * for section in parser.sections(): # <<<<<<<<<<<<<< * config[section] = dict(parser.items(section)) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_sections); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1471, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_sections); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1571, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -28899,16 +30981,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1471, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1571, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_4 = 0; __pyx_t_5 = NULL; } else { - __pyx_t_4 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1471, __pyx_L1_error) + __pyx_t_4 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1571, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_5 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1471, __pyx_L1_error) + __pyx_t_5 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1571, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -28916,17 +30998,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 1471, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 1571, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1471, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1571, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 1471, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 1571, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1471, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1571, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -28936,7 +31018,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 1471, __pyx_L1_error) + else __PYX_ERR(1, 1571, __pyx_L1_error) } break; } @@ -28945,14 +31027,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro __Pyx_XDECREF_SET(__pyx_v_section, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1472 + /* "dependency_injector/providers.pyx":1572 * config = {} * for section in parser.sections(): * config[section] = dict(parser.items(section)) # <<<<<<<<<<<<<< * * current_config = self.__call__() */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_items); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1472, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser, __pyx_n_s_items); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1572, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -28966,16 +31048,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro } __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_6, __pyx_v_section) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_section); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1472, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1572, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1472, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyDict_Type)), __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1572, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(PyDict_SetItem(__pyx_v_config, __pyx_v_section, __pyx_t_3) < 0)) __PYX_ERR(1, 1472, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_config, __pyx_v_section, __pyx_t_3) < 0)) __PYX_ERR(1, 1572, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1471 + /* "dependency_injector/providers.pyx":1571 * * config = {} * for section in parser.sections(): # <<<<<<<<<<<<<< @@ -28985,14 +31067,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1474 + /* "dependency_injector/providers.pyx":1574 * config[section] = dict(parser.items(section)) * * current_config = self.__call__() # <<<<<<<<<<<<<< * if not current_config: * current_config = {} */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1474, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1574, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_1 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -29006,36 +31088,36 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro } __pyx_t_2 = (__pyx_t_1) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_1) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1474, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1574, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_v_current_config = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1475 + /* "dependency_injector/providers.pyx":1575 * * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< * current_config = {} * self.override(merge_dicts(current_config, config)) */ - __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 1475, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 1575, __pyx_L1_error) __pyx_t_8 = ((!__pyx_t_7) != 0); if (__pyx_t_8) { - /* "dependency_injector/providers.pyx":1476 + /* "dependency_injector/providers.pyx":1576 * current_config = self.__call__() * if not current_config: * current_config = {} # <<<<<<<<<<<<<< * self.override(merge_dicts(current_config, config)) * */ - __pyx_t_2 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1476, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1576, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF_SET(__pyx_v_current_config, __pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1475 + /* "dependency_injector/providers.pyx":1575 * * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< @@ -29044,16 +31126,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro */ } - /* "dependency_injector/providers.pyx":1477 + /* "dependency_injector/providers.pyx":1577 * if not current_config: * current_config = {} * self.override(merge_dicts(current_config, config)) # <<<<<<<<<<<<<< * * def from_yaml(self, filepath): */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1477, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1577, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1477, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1577, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_9 = NULL; __pyx_t_10 = 0; @@ -29070,7 +31152,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_v_current_config, __pyx_v_config}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1477, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1577, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -29078,13 +31160,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_v_current_config, __pyx_v_config}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1477, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1577, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_11 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 1477, __pyx_L1_error) + __pyx_t_11 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 1577, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_11); if (__pyx_t_9) { __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_9); __pyx_t_9 = NULL; @@ -29095,7 +31177,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro __Pyx_INCREF(__pyx_v_config); __Pyx_GIVEREF(__pyx_v_config); PyTuple_SET_ITEM(__pyx_t_11, 1+__pyx_t_10, __pyx_v_config); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_11, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1477, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_11, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1577, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } @@ -29113,12 +31195,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro __pyx_t_2 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_6, __pyx_t_1) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_1); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1477, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1577, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1458 + /* "dependency_injector/providers.pyx":1558 * self.override(value) * * def from_ini(self, filepath): # <<<<<<<<<<<<<< @@ -29148,7 +31230,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_26fro return __pyx_r; } -/* "dependency_injector/providers.pyx":1479 +/* "dependency_injector/providers.pyx":1579 * self.override(merge_dicts(current_config, config)) * * def from_yaml(self, filepath): # <<<<<<<<<<<<<< @@ -29198,28 +31280,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro int __pyx_clineno = 0; __Pyx_RefNannySetupContext("from_yaml", 0); - /* "dependency_injector/providers.pyx":1489 + /* "dependency_injector/providers.pyx":1589 * :rtype: None * """ * if yaml is None: # <<<<<<<<<<<<<< * raise Error( * 'Unable to load yaml configuration - PyYAML is not installed. ' */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1489, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1589, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = (__pyx_t_1 == Py_None); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = (__pyx_t_2 != 0); if (unlikely(__pyx_t_3)) { - /* "dependency_injector/providers.pyx":1490 + /* "dependency_injector/providers.pyx":1590 * """ * if yaml is None: * raise Error( # <<<<<<<<<<<<<< * 'Unable to load yaml configuration - PyYAML is not installed. ' * 'Install PyYAML or install Dependency Injector with yaml extras: ' */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1490, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1590, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { @@ -29233,14 +31315,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro } __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_kp_s_Unable_to_load_yaml_configuratio) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_kp_s_Unable_to_load_yaml_configuratio); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1490, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1590, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 1490, __pyx_L1_error) + __PYX_ERR(1, 1590, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1489 + /* "dependency_injector/providers.pyx":1589 * :rtype: None * """ * if yaml is None: # <<<<<<<<<<<<<< @@ -29249,7 +31331,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro */ } - /* "dependency_injector/providers.pyx":1496 + /* "dependency_injector/providers.pyx":1596 * ) * * try: # <<<<<<<<<<<<<< @@ -29265,7 +31347,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __Pyx_XGOTREF(__pyx_t_8); /*try:*/ { - /* "dependency_injector/providers.pyx":1497 + /* "dependency_injector/providers.pyx":1597 * * try: * with open(filepath) as opened_file: # <<<<<<<<<<<<<< @@ -29273,11 +31355,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro * except IOError: */ /*with:*/ { - __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_open, __pyx_v_filepath); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1497, __pyx_L4_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_open, __pyx_v_filepath); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1597, __pyx_L4_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_9 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1497, __pyx_L4_error) + __pyx_t_9 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1597, __pyx_L4_error) __Pyx_GOTREF(__pyx_t_9); - __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1497, __pyx_L10_error) + __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1597, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_10 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { @@ -29291,7 +31373,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro } __pyx_t_4 = (__pyx_t_10) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_10) : __Pyx_PyObject_CallNoArg(__pyx_t_5); __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1497, __pyx_L10_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1597, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = __pyx_t_4; @@ -29309,21 +31391,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __pyx_v_opened_file = __pyx_t_5; __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1498 + /* "dependency_injector/providers.pyx":1598 * try: * with open(filepath) as opened_file: * config = yaml.load(opened_file, yaml.Loader) # <<<<<<<<<<<<<< * except IOError: * return */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1498, __pyx_L14_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1598, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_load); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1498, __pyx_L14_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_load); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1598, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1498, __pyx_L14_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1598, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_Loader); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1498, __pyx_L14_error) + __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_Loader); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1598, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = NULL; @@ -29341,7 +31423,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_1, __pyx_v_opened_file, __pyx_t_10}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1498, __pyx_L14_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1598, __pyx_L14_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; @@ -29350,14 +31432,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_1, __pyx_v_opened_file, __pyx_t_10}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1498, __pyx_L14_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1598, __pyx_L14_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } else #endif { - __pyx_t_15 = PyTuple_New(2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1498, __pyx_L14_error) + __pyx_t_15 = PyTuple_New(2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1598, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_15); if (__pyx_t_1) { __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_1); __pyx_t_1 = NULL; @@ -29368,7 +31450,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __Pyx_GIVEREF(__pyx_t_10); PyTuple_SET_ITEM(__pyx_t_15, 1+__pyx_t_14, __pyx_t_10); __pyx_t_10 = 0; - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_15, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1498, __pyx_L14_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_15, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1598, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } @@ -29376,7 +31458,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __pyx_v_config = __pyx_t_5; __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1497 + /* "dependency_injector/providers.pyx":1597 * * try: * with open(filepath) as opened_file: # <<<<<<<<<<<<<< @@ -29396,20 +31478,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; /*except:*/ { __Pyx_AddTraceback("dependency_injector.providers.Configuration.from_yaml", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 1497, __pyx_L16_except_error) + if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 1597, __pyx_L16_except_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_15); - __pyx_t_10 = PyTuple_Pack(3, __pyx_t_5, __pyx_t_4, __pyx_t_15); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1497, __pyx_L16_except_error) + __pyx_t_10 = PyTuple_Pack(3, __pyx_t_5, __pyx_t_4, __pyx_t_15); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1597, __pyx_L16_except_error) __Pyx_GOTREF(__pyx_t_10); __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; - if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 1497, __pyx_L16_except_error) + if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 1597, __pyx_L16_except_error) __Pyx_GOTREF(__pyx_t_16); __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_16); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; - if (__pyx_t_3 < 0) __PYX_ERR(1, 1497, __pyx_L16_except_error) + if (__pyx_t_3 < 0) __PYX_ERR(1, 1597, __pyx_L16_except_error) __pyx_t_2 = ((!(__pyx_t_3 != 0)) != 0); if (__pyx_t_2) { __Pyx_GIVEREF(__pyx_t_5); @@ -29417,7 +31499,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestoreWithState(__pyx_t_5, __pyx_t_4, __pyx_t_15); __pyx_t_5 = 0; __pyx_t_4 = 0; __pyx_t_15 = 0; - __PYX_ERR(1, 1497, __pyx_L16_except_error) + __PYX_ERR(1, 1597, __pyx_L16_except_error) } __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -29443,7 +31525,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro if (__pyx_t_9) { __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 1497, __pyx_L4_error) + if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 1597, __pyx_L4_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } @@ -29458,7 +31540,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __pyx_L23:; } - /* "dependency_injector/providers.pyx":1496 + /* "dependency_injector/providers.pyx":1596 * ) * * try: # <<<<<<<<<<<<<< @@ -29477,7 +31559,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1499 + /* "dependency_injector/providers.pyx":1599 * with open(filepath) as opened_file: * config = yaml.load(opened_file, yaml.Loader) * except IOError: # <<<<<<<<<<<<<< @@ -29487,12 +31569,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __pyx_t_14 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_IOError); if (__pyx_t_14) { __Pyx_AddTraceback("dependency_injector.providers.Configuration.from_yaml", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_15, &__pyx_t_4, &__pyx_t_5) < 0) __PYX_ERR(1, 1499, __pyx_L6_except_error) + if (__Pyx_GetException(&__pyx_t_15, &__pyx_t_4, &__pyx_t_5) < 0) __PYX_ERR(1, 1599, __pyx_L6_except_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_5); - /* "dependency_injector/providers.pyx":1500 + /* "dependency_injector/providers.pyx":1600 * config = yaml.load(opened_file, yaml.Loader) * except IOError: * return # <<<<<<<<<<<<<< @@ -29509,7 +31591,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro goto __pyx_L6_except_error; __pyx_L6_except_error:; - /* "dependency_injector/providers.pyx":1496 + /* "dependency_injector/providers.pyx":1596 * ) * * try: # <<<<<<<<<<<<<< @@ -29530,14 +31612,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __pyx_L9_try_end:; } - /* "dependency_injector/providers.pyx":1502 + /* "dependency_injector/providers.pyx":1602 * return * * current_config = self.__call__() # <<<<<<<<<<<<<< * if not current_config: * current_config = {} */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1502, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1602, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_15 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -29551,36 +31633,36 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro } __pyx_t_5 = (__pyx_t_15) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_15) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1502, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1602, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_current_config = __pyx_t_5; __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1503 + /* "dependency_injector/providers.pyx":1603 * * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< * current_config = {} * self.override(merge_dicts(current_config, config)) */ - __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 1503, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 1603, __pyx_L1_error) __pyx_t_3 = ((!__pyx_t_2) != 0); if (__pyx_t_3) { - /* "dependency_injector/providers.pyx":1504 + /* "dependency_injector/providers.pyx":1604 * current_config = self.__call__() * if not current_config: * current_config = {} # <<<<<<<<<<<<<< * self.override(merge_dicts(current_config, config)) * */ - __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1504, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1604, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF_SET(__pyx_v_current_config, __pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1503 + /* "dependency_injector/providers.pyx":1603 * * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< @@ -29589,18 +31671,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro */ } - /* "dependency_injector/providers.pyx":1505 + /* "dependency_injector/providers.pyx":1605 * if not current_config: * current_config = {} * self.override(merge_dicts(current_config, config)) # <<<<<<<<<<<<<< * * def from_dict(self, options): */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1505, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1605, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __Pyx_GetModuleGlobalName(__pyx_t_10, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1505, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_10, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1605, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); - if (unlikely(!__pyx_v_config)) { __Pyx_RaiseUnboundLocalError("config"); __PYX_ERR(1, 1505, __pyx_L1_error) } + if (unlikely(!__pyx_v_config)) { __Pyx_RaiseUnboundLocalError("config"); __PYX_ERR(1, 1605, __pyx_L1_error) } __pyx_t_1 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_10))) { @@ -29616,7 +31698,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_10)) { PyObject *__pyx_temp[3] = {__pyx_t_1, __pyx_v_current_config, __pyx_v_config}; - __pyx_t_15 = __Pyx_PyFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1505, __pyx_L1_error) + __pyx_t_15 = __Pyx_PyFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1605, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GOTREF(__pyx_t_15); } else @@ -29624,13 +31706,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_10)) { PyObject *__pyx_temp[3] = {__pyx_t_1, __pyx_v_current_config, __pyx_v_config}; - __pyx_t_15 = __Pyx_PyCFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1505, __pyx_L1_error) + __pyx_t_15 = __Pyx_PyCFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1605, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GOTREF(__pyx_t_15); } else #endif { - __pyx_t_17 = PyTuple_New(2+__pyx_t_14); if (unlikely(!__pyx_t_17)) __PYX_ERR(1, 1505, __pyx_L1_error) + __pyx_t_17 = PyTuple_New(2+__pyx_t_14); if (unlikely(!__pyx_t_17)) __PYX_ERR(1, 1605, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_17); if (__pyx_t_1) { __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_17, 0, __pyx_t_1); __pyx_t_1 = NULL; @@ -29641,7 +31723,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __Pyx_INCREF(__pyx_v_config); __Pyx_GIVEREF(__pyx_v_config); PyTuple_SET_ITEM(__pyx_t_17, 1+__pyx_t_14, __pyx_v_config); - __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_t_17, NULL); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1505, __pyx_L1_error) + __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_t_17, NULL); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 1605, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0; } @@ -29659,12 +31741,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro __pyx_t_5 = (__pyx_t_10) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_10, __pyx_t_15) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_15); __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1505, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1605, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":1479 + /* "dependency_injector/providers.pyx":1579 * self.override(merge_dicts(current_config, config)) * * def from_yaml(self, filepath): # <<<<<<<<<<<<<< @@ -29693,7 +31775,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_28fro return __pyx_r; } -/* "dependency_injector/providers.pyx":1507 +/* "dependency_injector/providers.pyx":1607 * self.override(merge_dicts(current_config, config)) * * def from_dict(self, options): # <<<<<<<<<<<<<< @@ -29733,14 +31815,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_30fro int __pyx_clineno = 0; __Pyx_RefNannySetupContext("from_dict", 0); - /* "dependency_injector/providers.pyx":1517 + /* "dependency_injector/providers.pyx":1617 * :rtype: None * """ * current_config = self.__call__() # <<<<<<<<<<<<<< * if not current_config: * current_config = {} */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1517, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1617, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -29754,36 +31836,36 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_30fro } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1517, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1617, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_current_config = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1518 + /* "dependency_injector/providers.pyx":1618 * """ * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< * current_config = {} * self.override(merge_dicts(current_config, options)) */ - __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(1, 1518, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_current_config); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(1, 1618, __pyx_L1_error) __pyx_t_5 = ((!__pyx_t_4) != 0); if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":1519 + /* "dependency_injector/providers.pyx":1619 * current_config = self.__call__() * if not current_config: * current_config = {} # <<<<<<<<<<<<<< * self.override(merge_dicts(current_config, options)) * */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1519, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1619, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF_SET(__pyx_v_current_config, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1518 + /* "dependency_injector/providers.pyx":1618 * """ * current_config = self.__call__() * if not current_config: # <<<<<<<<<<<<<< @@ -29792,16 +31874,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_30fro */ } - /* "dependency_injector/providers.pyx":1520 + /* "dependency_injector/providers.pyx":1620 * if not current_config: * current_config = {} * self.override(merge_dicts(current_config, options)) # <<<<<<<<<<<<<< * * def from_env(self, name, default=None): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1520, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1620, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1520, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1620, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_8 = 0; @@ -29818,7 +31900,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_30fro #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_current_config, __pyx_v_options}; - __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1520, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1620, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_3); } else @@ -29826,13 +31908,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_30fro #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_current_config, __pyx_v_options}; - __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1520, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1620, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_3); } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1520, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1620, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -29843,7 +31925,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_30fro __Pyx_INCREF(__pyx_v_options); __Pyx_GIVEREF(__pyx_v_options); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, __pyx_v_options); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1520, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1620, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } @@ -29861,12 +31943,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_30fro __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_6, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1520, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1620, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1507 + /* "dependency_injector/providers.pyx":1607 * self.override(merge_dicts(current_config, config)) * * def from_dict(self, options): # <<<<<<<<<<<<<< @@ -29893,7 +31975,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_30fro return __pyx_r; } -/* "dependency_injector/providers.pyx":1522 +/* "dependency_injector/providers.pyx":1622 * self.override(merge_dicts(current_config, options)) * * def from_env(self, name, default=None): # <<<<<<<<<<<<<< @@ -29941,7 +32023,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_13Configuration_33fro } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "from_env") < 0)) __PYX_ERR(1, 1522, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "from_env") < 0)) __PYX_ERR(1, 1622, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -29957,7 +32039,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_13Configuration_33fro } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("from_env", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1522, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("from_env", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1622, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Configuration.from_env", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -29984,16 +32066,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_32fro int __pyx_clineno = 0; __Pyx_RefNannySetupContext("from_env", 0); - /* "dependency_injector/providers.pyx":1533 + /* "dependency_injector/providers.pyx":1633 * :rtype: None * """ * value = os.getenv(name, default) # <<<<<<<<<<<<<< * self.override(value) * */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_os); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1533, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_os); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1633, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_getenv); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1533, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_getenv); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1633, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -30011,7 +32093,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_32fro #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_2, __pyx_v_name, __pyx_v_default}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 2+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1533, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 2+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1633, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -30019,13 +32101,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_32fro #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_2, __pyx_v_name, __pyx_v_default}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 2+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1533, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 2+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1633, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_5 = PyTuple_New(2+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1533, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(2+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1633, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (__pyx_t_2) { __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_2); __pyx_t_2 = NULL; @@ -30036,7 +32118,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_32fro __Pyx_INCREF(__pyx_v_default); __Pyx_GIVEREF(__pyx_v_default); PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_4, __pyx_v_default); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1533, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1633, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } @@ -30044,14 +32126,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_32fro __pyx_v_value = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1534 + /* "dependency_injector/providers.pyx":1634 * """ * value = os.getenv(name, default) * self.override(value) # <<<<<<<<<<<<<< * * */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1534, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_override); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1634, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -30065,12 +32147,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_32fro } __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_5, __pyx_v_value) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_value); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1534, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1634, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1522 + /* "dependency_injector/providers.pyx":1622 * self.override(merge_dicts(current_config, options)) * * def from_env(self, name, default=None): # <<<<<<<<<<<<<< @@ -30121,9 +32203,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_34__r PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -30134,52 +32216,57 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_34__r /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__children, self.__last_overriding, self.__name, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(5); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx___children); __Pyx_GIVEREF(__pyx_v_self->__pyx___children); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->__pyx___children); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->__pyx___children); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx___name); __Pyx_GIVEREF(__pyx_v_self->__pyx___name); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx___name); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx___name); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_1, 4, __pyx_v_self->__pyx_base.__pyx___provides); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 5, __pyx_v_self->__pyx_base.__pyx___provides); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__children, self.__last_overriding, self.__name, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__children, self.__last_overriding, self.__name, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -30188,16 +32275,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_34__r * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -30209,7 +32296,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_34__r __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__children, self.__last_overriding, self.__name, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__children, self.__last_overriding, self.__name, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -30223,42 +32310,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_34__r * else: * use_setstate = self.__children is not None or self.__last_overriding is not None or self.__name is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Configuration, (type(self), 0xa7663cf, None), state + * return __pyx_unpickle_Configuration, (type(self), 0x3460d23, None), state */ /*else*/ { - __pyx_t_2 = (__pyx_v_self->__pyx___children != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx___children != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx___name != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx___name != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -30266,44 +32353,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_34__r * else: * use_setstate = self.__children is not None or self.__last_overriding is not None or self.__name is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Configuration, (type(self), 0xa7663cf, None), state + * return __pyx_unpickle_Configuration, (type(self), 0x3460d23, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__children is not None or self.__last_overriding is not None or self.__name is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_Configuration, (type(self), 0xa7663cf, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Configuration, (type(self), 0x3460d23, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Configuration, (type(self), 0xa7663cf, state) + * return __pyx_unpickle_Configuration, (type(self), 0x3460d23, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Configuration); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Configuration); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_175530959); - __Pyx_GIVEREF(__pyx_int_175530959); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_175530959); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_54922531); + __Pyx_GIVEREF(__pyx_int_54922531); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_54922531); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -30312,15 +32399,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_34__r * else: * use_setstate = self.__children is not None or self.__last_overriding is not None or self.__name is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Configuration, (type(self), 0xa7663cf, None), state + * return __pyx_unpickle_Configuration, (type(self), 0x3460d23, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Configuration, (type(self), 0xa7663cf, None), state + * return __pyx_unpickle_Configuration, (type(self), 0x3460d23, None), state * else: - * return __pyx_unpickle_Configuration, (type(self), 0xa7663cf, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Configuration, (type(self), 0x3460d23, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Configuration__set_state(self, __pyx_state) */ @@ -30328,27 +32415,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_34__r __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_Configuration); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_175530959); - __Pyx_GIVEREF(__pyx_int_175530959); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_175530959); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_54922531); + __Pyx_GIVEREF(__pyx_int_54922531); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_54922531); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -30361,7 +32448,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_34__r /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.Configuration.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -30375,7 +32462,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_34__r /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Configuration, (type(self), 0xa7663cf, state) + * return __pyx_unpickle_Configuration, (type(self), 0x3460d23, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Configuration__set_state(self, __pyx_state) */ @@ -30403,7 +32490,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_36__s __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Configuration, (type(self), 0xa7663cf, state) + * return __pyx_unpickle_Configuration, (type(self), 0x3460d23, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Configuration__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -30414,7 +32501,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_36__s /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Configuration, (type(self), 0xa7663cf, state) + * return __pyx_unpickle_Configuration, (type(self), 0x3460d23, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Configuration__set_state(self, __pyx_state) */ @@ -30432,7 +32519,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13Configuration_36__s return __pyx_r; } -/* "dependency_injector/providers.pyx":1590 +/* "dependency_injector/providers.pyx":1690 * provided_type = None * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -30489,7 +32576,7 @@ static int __pyx_pw_19dependency_injector_9providers_7Factory_1__init__(PyObject } if (unlikely(kw_args > 0)) { const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 1590, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 1690, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { goto __pyx_L5_argtuple_error; @@ -30500,7 +32587,7 @@ static int __pyx_pw_19dependency_injector_9providers_7Factory_1__init__(PyObject } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1590, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1690, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; @@ -30537,19 +32624,19 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":1596 + /* "dependency_injector/providers.pyx":1696 * :type provides: type * """ * if (self.__class__.provided_type and # <<<<<<<<<<<<<< * not issubclass(provides, self.__class__.provided_type)): * raise Error('{0} can provide only {1} instances'.format( */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1596, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1696, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1596, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1696, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(1, 1596, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(1, 1696, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (__pyx_t_4) { } else { @@ -30557,25 +32644,25 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ goto __pyx_L4_bool_binop_done; } - /* "dependency_injector/providers.pyx":1597 + /* "dependency_injector/providers.pyx":1697 * """ * if (self.__class__.provided_type and * not issubclass(provides, self.__class__.provided_type)): # <<<<<<<<<<<<<< * raise Error('{0} can provide only {1} instances'.format( * self.__class__, self.__class__.provided_type)) */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1597, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1697, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1597, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1697, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_4 = PyObject_IsSubclass(__pyx_v_provides, __pyx_t_2); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(1, 1597, __pyx_L1_error) + __pyx_t_4 = PyObject_IsSubclass(__pyx_v_provides, __pyx_t_2); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(1, 1697, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_5 = ((!(__pyx_t_4 != 0)) != 0); __pyx_t_1 = __pyx_t_5; __pyx_L4_bool_binop_done:; - /* "dependency_injector/providers.pyx":1596 + /* "dependency_injector/providers.pyx":1696 * :type provides: type * """ * if (self.__class__.provided_type and # <<<<<<<<<<<<<< @@ -30584,30 +32671,30 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ */ if (unlikely(__pyx_t_1)) { - /* "dependency_injector/providers.pyx":1598 + /* "dependency_injector/providers.pyx":1698 * if (self.__class__.provided_type and * not issubclass(provides, self.__class__.provided_type)): * raise Error('{0} can provide only {1} instances'.format( # <<<<<<<<<<<<<< * self.__class__, self.__class__.provided_type)) * */ - __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_Error); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1598, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_Error); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1698, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_provide_only_1_instances, __pyx_n_s_format); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1598, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_provide_only_1_instances, __pyx_n_s_format); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1698, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - /* "dependency_injector/providers.pyx":1599 + /* "dependency_injector/providers.pyx":1699 * not issubclass(provides, self.__class__.provided_type)): * raise Error('{0} can provide only {1} instances'.format( * self.__class__, self.__class__.provided_type)) # <<<<<<<<<<<<<< * * self.__instantiator = Callable(provides, *args, **kwargs) */ - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1599, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1699, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1599, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1699, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); - __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1599, __pyx_L1_error) + __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1699, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __pyx_t_9 = NULL; @@ -30625,7 +32712,7 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_t_8, __pyx_t_10}; - __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1598, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1698, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; @@ -30635,7 +32722,7 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_t_8, __pyx_t_10}; - __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1598, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1698, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; @@ -30643,7 +32730,7 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ } else #endif { - __pyx_t_12 = PyTuple_New(2+__pyx_t_11); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 1598, __pyx_L1_error) + __pyx_t_12 = PyTuple_New(2+__pyx_t_11); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 1698, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_12); if (__pyx_t_9) { __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_t_9); __pyx_t_9 = NULL; @@ -30654,7 +32741,7 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ PyTuple_SET_ITEM(__pyx_t_12, 1+__pyx_t_11, __pyx_t_10); __pyx_t_8 = 0; __pyx_t_10 = 0; - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_12, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1598, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_12, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1698, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } @@ -30672,14 +32759,14 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ __pyx_t_2 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_7, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1598, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1698, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __PYX_ERR(1, 1598, __pyx_L1_error) + __PYX_ERR(1, 1698, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1596 + /* "dependency_injector/providers.pyx":1696 * :type provides: type * """ * if (self.__class__.provided_type and # <<<<<<<<<<<<<< @@ -30688,22 +32775,22 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ */ } - /* "dependency_injector/providers.pyx":1601 + /* "dependency_injector/providers.pyx":1701 * self.__class__, self.__class__.provided_type)) * * self.__instantiator = Callable(provides, *args, **kwargs) # <<<<<<<<<<<<<< * * self.__attributes = tuple() */ - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1601, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1701, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_provides); __Pyx_GIVEREF(__pyx_v_provides); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_provides); - __pyx_t_3 = PyNumber_Add(__pyx_t_2, __pyx_v_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1601, __pyx_L1_error) + __pyx_t_3 = PyNumber_Add(__pyx_t_2, __pyx_v_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1701, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable), __pyx_t_3, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1601, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Callable), __pyx_t_3, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1701, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GIVEREF(__pyx_t_2); @@ -30712,14 +32799,14 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ __pyx_v_self->__pyx___instantiator = ((struct __pyx_obj_19dependency_injector_9providers_Callable *)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1603 + /* "dependency_injector/providers.pyx":1703 * self.__instantiator = Callable(provides, *args, **kwargs) * * self.__attributes = tuple() # <<<<<<<<<<<<<< * self.__attributes_len = 0 * */ - __pyx_t_2 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1603, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1703, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_2); __Pyx_GOTREF(__pyx_v_self->__pyx___attributes); @@ -30727,7 +32814,7 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ __pyx_v_self->__pyx___attributes = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1604 + /* "dependency_injector/providers.pyx":1704 * * self.__attributes = tuple() * self.__attributes_len = 0 # <<<<<<<<<<<<<< @@ -30736,14 +32823,14 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ */ __pyx_v_self->__pyx___attributes_len = 0; - /* "dependency_injector/providers.pyx":1606 + /* "dependency_injector/providers.pyx":1706 * self.__attributes_len = 0 * * super(Factory, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1606, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1706, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)); @@ -30751,10 +32838,10 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_3, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1606, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1706, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1606, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1706, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -30769,12 +32856,12 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ } __pyx_t_2 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1606, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1706, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1590 + /* "dependency_injector/providers.pyx":1690 * provided_type = None * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -30801,7 +32888,7 @@ static int __pyx_pf_19dependency_injector_9providers_7Factory___init__(struct __ return __pyx_r; } -/* "dependency_injector/providers.pyx":1608 +/* "dependency_injector/providers.pyx":1708 * super(Factory, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -30841,16 +32928,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_2__deepcopy_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":1610 + /* "dependency_injector/providers.pyx":1710 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1610, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1710, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1610, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1710, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -30865,13 +32952,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_2__deepcopy_ __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1610, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1710, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1611 + /* "dependency_injector/providers.pyx":1711 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -30882,7 +32969,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_2__deepcopy_ __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":1612 + /* "dependency_injector/providers.pyx":1712 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -30894,7 +32981,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_2__deepcopy_ __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1611 + /* "dependency_injector/providers.pyx":1711 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -30903,19 +32990,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_2__deepcopy_ */ } - /* "dependency_injector/providers.pyx":1614 + /* "dependency_injector/providers.pyx":1714 * return copied * * cls = self.cls # <<<<<<<<<<<<<< * if isinstance(cls, Provider): * cls = deepcopy(cls, memo) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_cls); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1614, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_cls); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1714, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_cls = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1615 + /* "dependency_injector/providers.pyx":1715 * * cls = self.cls * if isinstance(cls, Provider): # <<<<<<<<<<<<<< @@ -30926,22 +33013,22 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_2__deepcopy_ __pyx_t_5 = (__pyx_t_6 != 0); if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":1616 + /* "dependency_injector/providers.pyx":1716 * cls = self.cls * if isinstance(cls, Provider): * cls = deepcopy(cls, memo) # <<<<<<<<<<<<<< * * copied = self.__class__(cls, */ - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1616, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1716, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_v_cls, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1616, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_v_cls, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1716, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF_SET(__pyx_v_cls, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1615 + /* "dependency_injector/providers.pyx":1715 * * cls = self.cls * if isinstance(cls, Provider): # <<<<<<<<<<<<<< @@ -30950,89 +33037,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_2__deepcopy_ */ } - /* "dependency_injector/providers.pyx":1618 + /* "dependency_injector/providers.pyx":1718 * cls = deepcopy(cls, memo) * * copied = self.__class__(cls, # <<<<<<<<<<<<<< * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1618, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1718, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1618, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1718, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_cls); __Pyx_GIVEREF(__pyx_v_cls); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_cls); - /* "dependency_injector/providers.pyx":1619 + /* "dependency_injector/providers.pyx":1719 * * copied = self.__class__(cls, * *deepcopy(self.args, memo), # <<<<<<<<<<<<<< * **deepcopy(self.kwargs, memo)) * copied.set_attributes(**deepcopy(self.attributes, memo)) */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1619, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1719, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1619, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1719, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1619, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1719, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1618 + /* "dependency_injector/providers.pyx":1718 * cls = deepcopy(cls, memo) * * copied = self.__class__(cls, # <<<<<<<<<<<<<< * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) */ - __pyx_t_3 = __Pyx_PySequence_Tuple(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1618, __pyx_L1_error) + __pyx_t_3 = __Pyx_PySequence_Tuple(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1718, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = PyNumber_Add(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1618, __pyx_L1_error) + __pyx_t_4 = PyNumber_Add(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1718, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1620 + /* "dependency_injector/providers.pyx":1720 * copied = self.__class__(cls, * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) # <<<<<<<<<<<<<< * copied.set_attributes(**deepcopy(self.attributes, memo)) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1620, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1720, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1620, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1720, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1620, __pyx_L1_error) + __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1720, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (unlikely(__pyx_t_8 == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 1620, __pyx_L1_error) + __PYX_ERR(1, 1720, __pyx_L1_error) } if (likely(PyDict_CheckExact(__pyx_t_8))) { - __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1620, __pyx_L1_error) + __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1720, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { - __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1618, __pyx_L1_error) + __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1718, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } - /* "dependency_injector/providers.pyx":1618 + /* "dependency_injector/providers.pyx":1718 * cls = deepcopy(cls, memo) * * copied = self.__class__(cls, # <<<<<<<<<<<<<< * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) */ - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1618, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1718, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -31040,54 +33127,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_2__deepcopy_ __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":1621 + /* "dependency_injector/providers.pyx":1721 * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) * copied.set_attributes(**deepcopy(self.attributes, memo)) # <<<<<<<<<<<<<< * * self._copy_overridings(copied, memo) */ - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_copied, __pyx_n_s_set_attributes); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1621, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_copied, __pyx_n_s_set_attributes); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1721, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_attributes); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1621, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_attributes); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1721, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1621, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1721, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_4, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1621, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_4, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1721, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 1621, __pyx_L1_error) + __PYX_ERR(1, 1721, __pyx_L1_error) } if (likely(PyDict_CheckExact(__pyx_t_1))) { - __pyx_t_3 = PyDict_Copy(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1621, __pyx_L1_error) + __pyx_t_3 = PyDict_Copy(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1721, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { - __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1621, __pyx_L1_error) + __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1721, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1621, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1721, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1623 + /* "dependency_injector/providers.pyx":1723 * copied.set_attributes(**deepcopy(self.attributes, memo)) * * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 1623, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1623, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 1723, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1723, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_Factory *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":1625 + /* "dependency_injector/providers.pyx":1725 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -31099,7 +33186,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_2__deepcopy_ __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1608 + /* "dependency_injector/providers.pyx":1708 * super(Factory, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -31124,7 +33211,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_2__deepcopy_ return __pyx_r; } -/* "dependency_injector/providers.pyx":1627 +/* "dependency_injector/providers.pyx":1727 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -31159,7 +33246,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_4__str__(str int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":1632 + /* "dependency_injector/providers.pyx":1732 * :rtype: str * """ * return represent_provider(provider=self, # <<<<<<<<<<<<<< @@ -31168,31 +33255,31 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_4__str__(str */ __Pyx_XDECREF(__pyx_r); - /* "dependency_injector/providers.pyx":1633 + /* "dependency_injector/providers.pyx":1733 * """ * return represent_provider(provider=self, * provides=self.__instantiator.provides) # <<<<<<<<<<<<<< * * @property */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_provides); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1633, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_provides); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1733, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":1632 + /* "dependency_injector/providers.pyx":1732 * :rtype: str * """ * return represent_provider(provider=self, # <<<<<<<<<<<<<< * provides=self.__instantiator.provides) * */ - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1632, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1732, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1627 + /* "dependency_injector/providers.pyx":1727 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -31212,7 +33299,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_4__str__(str return __pyx_r; } -/* "dependency_injector/providers.pyx":1636 +/* "dependency_injector/providers.pyx":1736 * * @property * def cls(self): # <<<<<<<<<<<<<< @@ -31242,7 +33329,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_3cls___get__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":1638 + /* "dependency_injector/providers.pyx":1738 * def cls(self): * """Return provided type.""" * return self.provides # <<<<<<<<<<<<<< @@ -31250,13 +33337,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_3cls___get__ * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provides); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1638, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provides); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1738, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1636 + /* "dependency_injector/providers.pyx":1736 * * @property * def cls(self): # <<<<<<<<<<<<<< @@ -31275,7 +33362,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_3cls___get__ return __pyx_r; } -/* "dependency_injector/providers.pyx":1641 +/* "dependency_injector/providers.pyx":1741 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -31305,7 +33392,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_8provides___ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":1643 + /* "dependency_injector/providers.pyx":1743 * def provides(self): * """Return provided type.""" * return self.__instantiator.provides # <<<<<<<<<<<<<< @@ -31313,13 +33400,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_8provides___ * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_provides); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1643, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_provides); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1743, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1641 + /* "dependency_injector/providers.pyx":1741 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -31338,7 +33425,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_8provides___ return __pyx_r; } -/* "dependency_injector/providers.pyx":1646 +/* "dependency_injector/providers.pyx":1746 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -31368,7 +33455,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_4args___get_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":1648 + /* "dependency_injector/providers.pyx":1748 * def args(self): * """Return positional argument injections.""" * return self.__instantiator.args # <<<<<<<<<<<<<< @@ -31376,13 +33463,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_4args___get_ * def add_args(self, *args): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1648, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1748, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1646 + /* "dependency_injector/providers.pyx":1746 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -31401,7 +33488,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_4args___get_ return __pyx_r; } -/* "dependency_injector/providers.pyx":1650 +/* "dependency_injector/providers.pyx":1750 * return self.__instantiator.args * * def add_args(self, *args): # <<<<<<<<<<<<<< @@ -31438,21 +33525,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_6add_args(st int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_args", 0); - /* "dependency_injector/providers.pyx":1655 + /* "dependency_injector/providers.pyx":1755 * :return: Reference ``self`` * """ * self.__instantiator.add_args(*args) # <<<<<<<<<<<<<< * return self * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_add_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1655, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_add_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1755, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1655, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1755, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1656 + /* "dependency_injector/providers.pyx":1756 * """ * self.__instantiator.add_args(*args) * return self # <<<<<<<<<<<<<< @@ -31464,7 +33551,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_6add_args(st __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1650 + /* "dependency_injector/providers.pyx":1750 * return self.__instantiator.args * * def add_args(self, *args): # <<<<<<<<<<<<<< @@ -31484,7 +33571,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_6add_args(st return __pyx_r; } -/* "dependency_injector/providers.pyx":1658 +/* "dependency_injector/providers.pyx":1758 * return self * * def set_args(self, *args): # <<<<<<<<<<<<<< @@ -31521,21 +33608,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_8set_args(st int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_args", 0); - /* "dependency_injector/providers.pyx":1665 + /* "dependency_injector/providers.pyx":1765 * :return: Reference ``self`` * """ * self.__instantiator.set_args(*args) # <<<<<<<<<<<<<< * return self * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_set_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1665, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_set_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1765, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1665, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1765, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1666 + /* "dependency_injector/providers.pyx":1766 * """ * self.__instantiator.set_args(*args) * return self # <<<<<<<<<<<<<< @@ -31547,7 +33634,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_8set_args(st __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1658 + /* "dependency_injector/providers.pyx":1758 * return self * * def set_args(self, *args): # <<<<<<<<<<<<<< @@ -31567,7 +33654,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_8set_args(st return __pyx_r; } -/* "dependency_injector/providers.pyx":1668 +/* "dependency_injector/providers.pyx":1768 * return self * * def clear_args(self): # <<<<<<<<<<<<<< @@ -31600,14 +33687,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_10clear_args int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_args", 0); - /* "dependency_injector/providers.pyx":1673 + /* "dependency_injector/providers.pyx":1773 * :return: Reference ``self`` * """ * self.__instantiator.clear_args() # <<<<<<<<<<<<<< * return self * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_clear_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1673, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_clear_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1773, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -31621,12 +33708,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_10clear_args } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1673, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1773, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1674 + /* "dependency_injector/providers.pyx":1774 * """ * self.__instantiator.clear_args() * return self # <<<<<<<<<<<<<< @@ -31638,7 +33725,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_10clear_args __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1668 + /* "dependency_injector/providers.pyx":1768 * return self * * def clear_args(self): # <<<<<<<<<<<<<< @@ -31659,7 +33746,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_10clear_args return __pyx_r; } -/* "dependency_injector/providers.pyx":1677 +/* "dependency_injector/providers.pyx":1777 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -31689,7 +33776,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_6kwargs___ge int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":1679 + /* "dependency_injector/providers.pyx":1779 * def kwargs(self): * """Return keyword argument injections.""" * return self.__instantiator.kwargs # <<<<<<<<<<<<<< @@ -31697,13 +33784,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_6kwargs___ge * def add_kwargs(self, **kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1679, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1779, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1677 + /* "dependency_injector/providers.pyx":1777 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -31722,7 +33809,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_6kwargs___ge return __pyx_r; } -/* "dependency_injector/providers.pyx":1681 +/* "dependency_injector/providers.pyx":1781 * return self.__instantiator.kwargs * * def add_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -31765,21 +33852,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_12add_kwargs int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_kwargs", 0); - /* "dependency_injector/providers.pyx":1686 + /* "dependency_injector/providers.pyx":1786 * :return: Reference ``self`` * """ * self.__instantiator.add_kwargs(**kwargs) # <<<<<<<<<<<<<< * return self * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_add_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1686, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_add_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1786, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1686, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1786, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1687 + /* "dependency_injector/providers.pyx":1787 * """ * self.__instantiator.add_kwargs(**kwargs) * return self # <<<<<<<<<<<<<< @@ -31791,7 +33878,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_12add_kwargs __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1681 + /* "dependency_injector/providers.pyx":1781 * return self.__instantiator.kwargs * * def add_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -31811,7 +33898,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_12add_kwargs return __pyx_r; } -/* "dependency_injector/providers.pyx":1689 +/* "dependency_injector/providers.pyx":1789 * return self * * def set_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -31854,21 +33941,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_14set_kwargs int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_kwargs", 0); - /* "dependency_injector/providers.pyx":1696 + /* "dependency_injector/providers.pyx":1796 * :return: Reference ``self`` * """ * self.__instantiator.set_kwargs(**kwargs) # <<<<<<<<<<<<<< * return self * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_set_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1696, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_set_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1796, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1696, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1796, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1697 + /* "dependency_injector/providers.pyx":1797 * """ * self.__instantiator.set_kwargs(**kwargs) * return self # <<<<<<<<<<<<<< @@ -31880,7 +33967,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_14set_kwargs __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1689 + /* "dependency_injector/providers.pyx":1789 * return self * * def set_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -31900,7 +33987,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_14set_kwargs return __pyx_r; } -/* "dependency_injector/providers.pyx":1699 +/* "dependency_injector/providers.pyx":1799 * return self * * def clear_kwargs(self): # <<<<<<<<<<<<<< @@ -31933,14 +34020,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_16clear_kwar int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_kwargs", 0); - /* "dependency_injector/providers.pyx":1704 + /* "dependency_injector/providers.pyx":1804 * :return: Reference ``self`` * """ * self.__instantiator.clear_kwargs() # <<<<<<<<<<<<<< * return self * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_clear_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1704, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_clear_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1804, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -31954,12 +34041,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_16clear_kwar } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1704, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1804, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1705 + /* "dependency_injector/providers.pyx":1805 * """ * self.__instantiator.clear_kwargs() * return self # <<<<<<<<<<<<<< @@ -31971,7 +34058,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_16clear_kwar __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1699 + /* "dependency_injector/providers.pyx":1799 * return self * * def clear_kwargs(self): # <<<<<<<<<<<<<< @@ -31992,7 +34079,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_16clear_kwar return __pyx_r; } -/* "dependency_injector/providers.pyx":1708 +/* "dependency_injector/providers.pyx":1808 * * @property * def attributes(self): # <<<<<<<<<<<<<< @@ -32028,19 +34115,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_10attributes int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":1714 + /* "dependency_injector/providers.pyx":1814 * cdef dict attributes * * attributes = dict() # <<<<<<<<<<<<<< * for index in range(self.__attributes_len): * attribute = self.__attributes[index] */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1714, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1814, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_attributes = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1715 + /* "dependency_injector/providers.pyx":1815 * * attributes = dict() * for index in range(self.__attributes_len): # <<<<<<<<<<<<<< @@ -32052,7 +34139,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_10attributes for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_index = __pyx_t_4; - /* "dependency_injector/providers.pyx":1716 + /* "dependency_injector/providers.pyx":1816 * attributes = dict() * for index in range(self.__attributes_len): * attribute = self.__attributes[index] # <<<<<<<<<<<<<< @@ -32061,15 +34148,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_10attributes */ if (unlikely(__pyx_v_self->__pyx___attributes == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 1716, __pyx_L1_error) + __PYX_ERR(1, 1816, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___attributes, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1716, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___attributes, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1816, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_NamedInjection))))) __PYX_ERR(1, 1716, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_NamedInjection))))) __PYX_ERR(1, 1816, __pyx_L1_error) __Pyx_XDECREF_SET(__pyx_v_attribute, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1717 + /* "dependency_injector/providers.pyx":1817 * for index in range(self.__attributes_len): * attribute = self.__attributes[index] * attributes[attribute.__name] = attribute.__value # <<<<<<<<<<<<<< @@ -32078,11 +34165,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_10attributes */ __pyx_t_1 = __pyx_v_attribute->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_1); - if (unlikely(PyDict_SetItem(__pyx_v_attributes, __pyx_v_attribute->__pyx___name, __pyx_t_1) < 0)) __PYX_ERR(1, 1717, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_attributes, __pyx_v_attribute->__pyx___name, __pyx_t_1) < 0)) __PYX_ERR(1, 1817, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - /* "dependency_injector/providers.pyx":1718 + /* "dependency_injector/providers.pyx":1818 * attribute = self.__attributes[index] * attributes[attribute.__name] = attribute.__value * return attributes # <<<<<<<<<<<<<< @@ -32094,7 +34181,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_10attributes __pyx_r = __pyx_v_attributes; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1708 + /* "dependency_injector/providers.pyx":1808 * * @property * def attributes(self): # <<<<<<<<<<<<<< @@ -32115,7 +34202,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_10attributes return __pyx_r; } -/* "dependency_injector/providers.pyx":1720 +/* "dependency_injector/providers.pyx":1820 * return attributes * * def add_attributes(self, **kwargs): # <<<<<<<<<<<<<< @@ -32155,16 +34242,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_18add_attrib int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_attributes", 0); - /* "dependency_injector/providers.pyx":1725 + /* "dependency_injector/providers.pyx":1825 * :return: Reference ``self`` * """ * self.__attributes += parse_named_injections(kwargs) # <<<<<<<<<<<<<< * self.__attributes_len = len(self.__attributes) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1725, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1825, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___attributes, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1725, __pyx_L1_error) + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___attributes, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1825, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GIVEREF(__pyx_t_2); @@ -32173,7 +34260,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_18add_attrib __pyx_v_self->__pyx___attributes = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1726 + /* "dependency_injector/providers.pyx":1826 * """ * self.__attributes += parse_named_injections(kwargs) * self.__attributes_len = len(self.__attributes) # <<<<<<<<<<<<<< @@ -32184,13 +34271,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_18add_attrib __Pyx_INCREF(__pyx_t_2); if (unlikely(__pyx_t_2 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 1726, __pyx_L1_error) + __PYX_ERR(1, 1826, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1726, __pyx_L1_error) + __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1826, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_self->__pyx___attributes_len = __pyx_t_3; - /* "dependency_injector/providers.pyx":1727 + /* "dependency_injector/providers.pyx":1827 * self.__attributes += parse_named_injections(kwargs) * self.__attributes_len = len(self.__attributes) * return self # <<<<<<<<<<<<<< @@ -32202,7 +34289,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_18add_attrib __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1720 + /* "dependency_injector/providers.pyx":1820 * return attributes * * def add_attributes(self, **kwargs): # <<<<<<<<<<<<<< @@ -32222,7 +34309,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_18add_attrib return __pyx_r; } -/* "dependency_injector/providers.pyx":1729 +/* "dependency_injector/providers.pyx":1829 * return self * * def set_attributes(self, **kwargs): # <<<<<<<<<<<<<< @@ -32261,14 +34348,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_20set_attrib int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_attributes", 0); - /* "dependency_injector/providers.pyx":1736 + /* "dependency_injector/providers.pyx":1836 * :return: Reference ``self`` * """ * self.__attributes = parse_named_injections(kwargs) # <<<<<<<<<<<<<< * self.__attributes_len = len(self.__attributes) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1736, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1836, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___attributes); @@ -32276,7 +34363,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_20set_attrib __pyx_v_self->__pyx___attributes = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1737 + /* "dependency_injector/providers.pyx":1837 * """ * self.__attributes = parse_named_injections(kwargs) * self.__attributes_len = len(self.__attributes) # <<<<<<<<<<<<<< @@ -32287,13 +34374,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_20set_attrib __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 1737, __pyx_L1_error) + __PYX_ERR(1, 1837, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1737, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1837, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___attributes_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":1738 + /* "dependency_injector/providers.pyx":1838 * self.__attributes = parse_named_injections(kwargs) * self.__attributes_len = len(self.__attributes) * return self # <<<<<<<<<<<<<< @@ -32305,7 +34392,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_20set_attrib __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1729 + /* "dependency_injector/providers.pyx":1829 * return self * * def set_attributes(self, **kwargs): # <<<<<<<<<<<<<< @@ -32324,7 +34411,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_20set_attrib return __pyx_r; } -/* "dependency_injector/providers.pyx":1740 +/* "dependency_injector/providers.pyx":1840 * return self * * def clear_attributes(self): # <<<<<<<<<<<<<< @@ -32356,14 +34443,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_22clear_attr int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_attributes", 0); - /* "dependency_injector/providers.pyx":1745 + /* "dependency_injector/providers.pyx":1845 * :return: Reference ``self`` * """ * self.__attributes = tuple() # <<<<<<<<<<<<<< * self.__attributes_len = len(self.__attributes) * return self */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1745, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1845, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___attributes); @@ -32371,7 +34458,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_22clear_attr __pyx_v_self->__pyx___attributes = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1746 + /* "dependency_injector/providers.pyx":1846 * """ * self.__attributes = tuple() * self.__attributes_len = len(self.__attributes) # <<<<<<<<<<<<<< @@ -32382,13 +34469,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_22clear_attr __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 1746, __pyx_L1_error) + __PYX_ERR(1, 1846, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1746, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 1846, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___attributes_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":1747 + /* "dependency_injector/providers.pyx":1847 * self.__attributes = tuple() * self.__attributes_len = len(self.__attributes) * return self # <<<<<<<<<<<<<< @@ -32400,7 +34487,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_22clear_attr __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1740 + /* "dependency_injector/providers.pyx":1840 * return self * * def clear_attributes(self): # <<<<<<<<<<<<<< @@ -32419,7 +34506,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_22clear_attr return __pyx_r; } -/* "dependency_injector/providers.pyx":1749 +/* "dependency_injector/providers.pyx":1849 * return self * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -32450,7 +34537,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_7Factory__provide(stru if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1749, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1849, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_7Factory_25_provide)) { __Pyx_XDECREF(__pyx_r); @@ -32470,7 +34557,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_7Factory__provide(stru #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1749, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1849, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -32478,13 +34565,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_7Factory__provide(stru #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1749, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1849, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1749, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1849, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -32495,7 +34582,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_7Factory__provide(stru __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1749, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1849, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -32518,7 +34605,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_7Factory__provide(stru #endif } - /* "dependency_injector/providers.pyx":1751 + /* "dependency_injector/providers.pyx":1851 * cpdef object _provide(self, tuple args, dict kwargs): * """Return new instance.""" * return __factory_call(self, args, kwargs) # <<<<<<<<<<<<<< @@ -32526,13 +34613,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_7Factory__provide(stru * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___factory_call(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1751, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___factory_call(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1851, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1749 + /* "dependency_injector/providers.pyx":1849 * return self * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -32590,11 +34677,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_7Factory_25_provide(P case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 1749, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 1849, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 1749, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 1849, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -32607,14 +34694,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_7Factory_25_provide(P } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1749, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1849, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Factory._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 1749, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 1749, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 1849, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 1849, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_7Factory_24_provide(((struct __pyx_obj_19dependency_injector_9providers_Factory *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -32635,7 +34722,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_24_provide(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_7Factory__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1749, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_7Factory__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1849, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -32679,10 +34766,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_26__reduce_c __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; - int __pyx_t_3; + PyObject *__pyx_t_3 = NULL; int __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -32691,54 +34778,59 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_26__reduce_c /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___attributes_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___attributes_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(6); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx___attributes); __Pyx_GIVEREF(__pyx_v_self->__pyx___attributes); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_self->__pyx___attributes); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_self->__pyx___attributes); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_3, 3, ((PyObject *)__pyx_v_self->__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_2, 3, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx___overridden); __pyx_t_1 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_3); + __pyx_t_3 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_v__dict = __pyx_t_2; - __pyx_t_2 = 0; + __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_v__dict = __pyx_t_3; + __pyx_t_3 = 0; /* "(tree fragment)":7 - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_3 = (__pyx_v__dict != Py_None); - __pyx_t_4 = (__pyx_t_3 != 0); - if (__pyx_t_4) { + __pyx_t_4 = (__pyx_v__dict != Py_None); + __pyx_t_5 = (__pyx_t_4 != 0); + if (__pyx_t_5) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -32747,16 +34839,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_26__reduce_c * use_setstate = True * else: */ - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); - __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); - __pyx_t_1 = 0; + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); + __pyx_t_2 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -32768,7 +34860,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_26__reduce_c __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -32782,35 +34874,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_26__reduce_c * else: * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Factory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_Factory, (type(self), 0x7545337, None), state */ /*else*/ { - __pyx_t_3 = (__pyx_v_self->__pyx___attributes != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_3 != 0); - if (!__pyx_t_5) { + __pyx_t_4 = (__pyx_v_self->__pyx___attributes != ((PyObject*)Py_None)); + __pyx_t_6 = (__pyx_t_4 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_4 = __pyx_t_5; + __pyx_t_5 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx___instantiator) != Py_None); - __pyx_t_3 = (__pyx_t_5 != 0); - if (!__pyx_t_3) { + __pyx_t_6 = (((PyObject *)__pyx_v_self->__pyx___instantiator) != Py_None); + __pyx_t_4 = (__pyx_t_6 != 0); + if (!__pyx_t_4) { } else { - __pyx_t_4 = __pyx_t_3; + __pyx_t_5 = __pyx_t_4; goto __pyx_L4_bool_binop_done; } - __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_3 != 0); - if (!__pyx_t_5) { + __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_6 = (__pyx_t_4 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_4 = __pyx_t_5; + __pyx_t_5 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_3 = (__pyx_t_5 != 0); - __pyx_t_4 = __pyx_t_3; + __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_4 = (__pyx_t_6 != 0); + __pyx_t_5 = __pyx_t_4; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_4; + __pyx_v_use_setstate = __pyx_t_5; } __pyx_L3:; @@ -32818,89 +34910,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_26__reduce_c * else: * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Factory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_Factory, (type(self), 0x7545337, None), state * else: */ - __pyx_t_4 = (__pyx_v_use_setstate != 0); - if (__pyx_t_4) { + __pyx_t_5 = (__pyx_v_use_setstate != 0); + if (__pyx_t_5) { /* "(tree fragment)":13 * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: - * return __pyx_unpickle_Factory, (type(self), 0xa73b866, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Factory, (type(self), 0x7545337, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Factory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_Factory, (type(self), 0x7545337, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Factory); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_Factory); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_175356006); - __Pyx_GIVEREF(__pyx_int_175356006); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_175356006); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_122966839); + __Pyx_GIVEREF(__pyx_int_122966839); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_122966839); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); - __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); + __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_1 = 0; + PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); __pyx_t_2 = 0; - __pyx_r = __pyx_t_6; - __pyx_t_6 = 0; + __pyx_t_3 = 0; + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Factory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_Factory, (type(self), 0x7545337, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Factory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_Factory, (type(self), 0x7545337, None), state * else: - * return __pyx_unpickle_Factory, (type(self), 0xa73b866, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Factory, (type(self), 0x7545337, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Factory__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_Factory); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Factory); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_175356006); - __Pyx_GIVEREF(__pyx_int_175356006); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_175356006); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_122966839); + __Pyx_GIVEREF(__pyx_int_122966839); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_122966839); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); - __pyx_t_6 = 0; - __pyx_t_2 = 0; - __pyx_r = __pyx_t_1; + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); __pyx_t_1 = 0; + __pyx_t_3 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; } @@ -32914,7 +35006,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_26__reduce_c __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); - __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("dependency_injector.providers.Factory.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -32927,7 +35019,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_26__reduce_c /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Factory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_Factory, (type(self), 0x7545337, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Factory__set_state(self, __pyx_state) */ @@ -32955,7 +35047,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_28__setstate __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Factory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_Factory, (type(self), 0x7545337, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Factory__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -32966,7 +35058,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_7Factory_28__setstate /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Factory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_Factory, (type(self), 0x7545337, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Factory__set_state(self, __pyx_state) */ @@ -33011,10 +35103,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory___ __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; - int __pyx_t_3; + PyObject *__pyx_t_3 = NULL; int __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -33023,54 +35115,59 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory___ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___attributes_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___attributes_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(6); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___attributes); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___attributes); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_self->__pyx_base.__pyx___attributes); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_self->__pyx_base.__pyx___attributes); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_3, 3, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_2, 3, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __pyx_t_1 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_3); + __pyx_t_3 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_v__dict = __pyx_t_2; - __pyx_t_2 = 0; + __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_v__dict = __pyx_t_3; + __pyx_t_3 = 0; /* "(tree fragment)":7 - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_3 = (__pyx_v__dict != Py_None); - __pyx_t_4 = (__pyx_t_3 != 0); - if (__pyx_t_4) { + __pyx_t_4 = (__pyx_v__dict != Py_None); + __pyx_t_5 = (__pyx_t_4 != 0); + if (__pyx_t_5) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -33079,16 +35176,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory___ * use_setstate = True * else: */ - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); - __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); - __pyx_t_1 = 0; + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); + __pyx_t_2 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -33100,7 +35197,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory___ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -33114,35 +35211,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory___ * else: * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_DelegatedFactory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_DelegatedFactory, (type(self), 0x7545337, None), state */ /*else*/ { - __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___attributes != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_3 != 0); - if (!__pyx_t_5) { + __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___attributes != ((PyObject*)Py_None)); + __pyx_t_6 = (__pyx_t_4 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_4 = __pyx_t_5; + __pyx_t_5 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); - __pyx_t_3 = (__pyx_t_5 != 0); - if (!__pyx_t_3) { + __pyx_t_6 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); + __pyx_t_4 = (__pyx_t_6 != 0); + if (!__pyx_t_4) { } else { - __pyx_t_4 = __pyx_t_3; + __pyx_t_5 = __pyx_t_4; goto __pyx_L4_bool_binop_done; } - __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_3 != 0); - if (!__pyx_t_5) { + __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_6 = (__pyx_t_4 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_4 = __pyx_t_5; + __pyx_t_5 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_3 = (__pyx_t_5 != 0); - __pyx_t_4 = __pyx_t_3; + __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_4 = (__pyx_t_6 != 0); + __pyx_t_5 = __pyx_t_4; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_4; + __pyx_v_use_setstate = __pyx_t_5; } __pyx_L3:; @@ -33150,89 +35247,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory___ * else: * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedFactory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_DelegatedFactory, (type(self), 0x7545337, None), state * else: */ - __pyx_t_4 = (__pyx_v_use_setstate != 0); - if (__pyx_t_4) { + __pyx_t_5 = (__pyx_v_use_setstate != 0); + if (__pyx_t_5) { /* "(tree fragment)":13 * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: - * return __pyx_unpickle_DelegatedFactory, (type(self), 0xa73b866, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedFactory, (type(self), 0x7545337, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_DelegatedFactory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_DelegatedFactory, (type(self), 0x7545337, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_DelegatedFactory); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_DelegatedFactory); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_175356006); - __Pyx_GIVEREF(__pyx_int_175356006); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_175356006); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_122966839); + __Pyx_GIVEREF(__pyx_int_122966839); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_122966839); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); - __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); + __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_1 = 0; + PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); __pyx_t_2 = 0; - __pyx_r = __pyx_t_6; - __pyx_t_6 = 0; + __pyx_t_3 = 0; + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedFactory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_DelegatedFactory, (type(self), 0x7545337, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_DelegatedFactory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_DelegatedFactory, (type(self), 0x7545337, None), state * else: - * return __pyx_unpickle_DelegatedFactory, (type(self), 0xa73b866, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedFactory, (type(self), 0x7545337, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedFactory__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_DelegatedFactory); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_DelegatedFactory); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_175356006); - __Pyx_GIVEREF(__pyx_int_175356006); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_175356006); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_122966839); + __Pyx_GIVEREF(__pyx_int_122966839); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_122966839); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); - __pyx_t_6 = 0; - __pyx_t_2 = 0; - __pyx_r = __pyx_t_1; + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); __pyx_t_1 = 0; + __pyx_t_3 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; } @@ -33246,7 +35343,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory___ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); - __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("dependency_injector.providers.DelegatedFactory.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -33259,7 +35356,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory___ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedFactory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_DelegatedFactory, (type(self), 0x7545337, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedFactory__set_state(self, __pyx_state) */ @@ -33287,7 +35384,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory_2_ __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_DelegatedFactory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_DelegatedFactory, (type(self), 0x7545337, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedFactory__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -33298,7 +35395,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory_2_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedFactory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_DelegatedFactory, (type(self), 0x7545337, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedFactory__set_state(self, __pyx_state) */ @@ -33316,7 +35413,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16DelegatedFactory_2_ return __pyx_r; } -/* "dependency_injector/providers.pyx":1786 +/* "dependency_injector/providers.pyx":1886 * """ * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -33369,27 +35466,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory___c int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__call__", 0); - /* "dependency_injector/providers.pyx":1791 + /* "dependency_injector/providers.pyx":1891 * Callable interface implementation. * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) */ __pyx_t_1 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) == Py_None); __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":1792 + /* "dependency_injector/providers.pyx":1892 * """ * if self.__last_overriding is None: * raise Error('{0} must be overridden before calling'.format(self)) # <<<<<<<<<<<<<< - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) * */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1792, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1892, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1792, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1892, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -33403,7 +35500,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory___c } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, ((PyObject *)__pyx_v_self)) : __Pyx_PyObject_CallOneArg(__pyx_t_6, ((PyObject *)__pyx_v_self)); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1792, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1892, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -33419,37 +35516,52 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory___c __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1792, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1892, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 1792, __pyx_L1_error) + __PYX_ERR(1, 1892, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1791 + /* "dependency_injector/providers.pyx":1891 * Callable interface implementation. * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) */ } - /* "dependency_injector/providers.pyx":1793 + /* "dependency_injector/providers.pyx":1893 * if self.__last_overriding is None: * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) # <<<<<<<<<<<<<< + * return super().__call__(*args, **kwargs) # <<<<<<<<<<<<<< * * def override(self, provider): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1793, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1893, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_r = __pyx_t_3; - __pyx_t_3 = 0; + __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractFactory)); + __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractFactory)); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractFactory)); + __Pyx_INCREF(((PyObject *)__pyx_v_self)); + __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); + PyTuple_SET_ITEM(__pyx_t_3, 1, ((PyObject *)__pyx_v_self)); + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1893, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_call); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1893, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1893, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_r = __pyx_t_4; + __pyx_t_4 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1786 + /* "dependency_injector/providers.pyx":1886 * """ * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -33472,8 +35584,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory___c return __pyx_r; } -/* "dependency_injector/providers.pyx":1795 - * return self.__last_overriding(*args, **kwargs) +/* "dependency_injector/providers.pyx":1895 + * return super().__call__(*args, **kwargs) * * def override(self, provider): # <<<<<<<<<<<<<< * """Override provider with another provider. @@ -33511,7 +35623,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/providers.pyx":1806 + /* "dependency_injector/providers.pyx":1906 * :rtype: :py:class:`OverridingContext` * """ * if not isinstance(provider, Factory): # <<<<<<<<<<<<<< @@ -33522,24 +35634,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov __pyx_t_2 = ((!(__pyx_t_1 != 0)) != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":1807 + /* "dependency_injector/providers.pyx":1907 * """ * if not isinstance(provider, Factory): * raise Error('{0} must be overridden only by ' # <<<<<<<<<<<<<< * '{1} providers'.format(self, Factory)) * return super(AbstractFactory, self).override(provider) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1807, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1907, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/providers.pyx":1808 + /* "dependency_injector/providers.pyx":1908 * if not isinstance(provider, Factory): * raise Error('{0} must be overridden only by ' * '{1} providers'.format(self, Factory)) # <<<<<<<<<<<<<< * return super(AbstractFactory, self).override(provider) * */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_only_by_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1808, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_only_by_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1908, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_8 = 0; @@ -33556,7 +35668,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, ((PyObject *)__pyx_v_self), ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1808, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1908, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else @@ -33564,13 +35676,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, ((PyObject *)__pyx_v_self), ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1808, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1908, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1808, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1908, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -33581,7 +35693,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1808, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1908, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } @@ -33599,14 +35711,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1807, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1907, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 1807, __pyx_L1_error) + __PYX_ERR(1, 1907, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1806 + /* "dependency_injector/providers.pyx":1906 * :rtype: :py:class:`OverridingContext` * """ * if not isinstance(provider, Factory): # <<<<<<<<<<<<<< @@ -33615,7 +35727,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov */ } - /* "dependency_injector/providers.pyx":1809 + /* "dependency_injector/providers.pyx":1909 * raise Error('{0} must be overridden only by ' * '{1} providers'.format(self, Factory)) * return super(AbstractFactory, self).override(provider) # <<<<<<<<<<<<<< @@ -33623,7 +35735,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov * cpdef object _provide(self, tuple args, dict kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1809, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1909, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractFactory)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractFactory)); @@ -33631,10 +35743,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1809, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1909, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1809, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1909, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -33649,15 +35761,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_provider); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1809, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1909, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1795 - * return self.__last_overriding(*args, **kwargs) + /* "dependency_injector/providers.pyx":1895 + * return super().__call__(*args, **kwargs) * * def override(self, provider): # <<<<<<<<<<<<<< * """Override provider with another provider. @@ -33680,7 +35792,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_2ov return __pyx_r; } -/* "dependency_injector/providers.pyx":1811 +/* "dependency_injector/providers.pyx":1911 * return super(AbstractFactory, self).override(provider) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -33711,7 +35823,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AbstractFactory__pro if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1811, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1911, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_15AbstractFactory_5_provide)) { __Pyx_XDECREF(__pyx_r); @@ -33731,7 +35843,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AbstractFactory__pro #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1811, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1911, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -33739,13 +35851,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AbstractFactory__pro #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1811, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1911, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1811, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1911, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -33756,7 +35868,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AbstractFactory__pro __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1811, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1911, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -33779,20 +35891,20 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AbstractFactory__pro #endif } - /* "dependency_injector/providers.pyx":1813 + /* "dependency_injector/providers.pyx":1913 * cpdef object _provide(self, tuple args, dict kwargs): * """Return result of provided callable's call.""" * raise NotImplementedError('Abstract provider forward providing logic ' # <<<<<<<<<<<<<< * 'to overriding provider') * */ - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_tuple__6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1813, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_tuple__6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1913, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 1813, __pyx_L1_error) + __PYX_ERR(1, 1913, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1811 + /* "dependency_injector/providers.pyx":1911 * return super(AbstractFactory, self).override(provider) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -33850,11 +35962,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_15AbstractFactory_5_p case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 1811, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 1911, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 1811, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 1911, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -33867,14 +35979,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_15AbstractFactory_5_p } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1811, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1911, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.AbstractFactory._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 1811, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 1811, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 1911, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 1911, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_15AbstractFactory_4_provide(((struct __pyx_obj_19dependency_injector_9providers_AbstractFactory *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -33895,7 +36007,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_4_p int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_15AbstractFactory__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1811, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_15AbstractFactory__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1911, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -33939,10 +36051,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_6__ __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; - int __pyx_t_3; + PyObject *__pyx_t_3 = NULL; int __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -33951,54 +36063,59 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_6__ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___attributes_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___attributes_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(6); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___attributes); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___attributes); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_self->__pyx_base.__pyx___attributes); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_self->__pyx_base.__pyx___attributes); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_3, 3, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_2, 3, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __pyx_t_1 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_3); + __pyx_t_3 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_v__dict = __pyx_t_2; - __pyx_t_2 = 0; + __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_v__dict = __pyx_t_3; + __pyx_t_3 = 0; /* "(tree fragment)":7 - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_3 = (__pyx_v__dict != Py_None); - __pyx_t_4 = (__pyx_t_3 != 0); - if (__pyx_t_4) { + __pyx_t_4 = (__pyx_v__dict != Py_None); + __pyx_t_5 = (__pyx_t_4 != 0); + if (__pyx_t_5) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -34007,16 +36124,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_6__ * use_setstate = True * else: */ - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); - __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); - __pyx_t_1 = 0; + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); + __pyx_t_2 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -34028,7 +36145,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_6__ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__attributes, self.__attributes_len, self.__instantiator, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -34042,35 +36159,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_6__ * else: * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_AbstractFactory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_AbstractFactory, (type(self), 0x7545337, None), state */ /*else*/ { - __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___attributes != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_3 != 0); - if (!__pyx_t_5) { + __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___attributes != ((PyObject*)Py_None)); + __pyx_t_6 = (__pyx_t_4 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_4 = __pyx_t_5; + __pyx_t_5 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); - __pyx_t_3 = (__pyx_t_5 != 0); - if (!__pyx_t_3) { + __pyx_t_6 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); + __pyx_t_4 = (__pyx_t_6 != 0); + if (!__pyx_t_4) { } else { - __pyx_t_4 = __pyx_t_3; + __pyx_t_5 = __pyx_t_4; goto __pyx_L4_bool_binop_done; } - __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_3 != 0); - if (!__pyx_t_5) { + __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_6 = (__pyx_t_4 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_4 = __pyx_t_5; + __pyx_t_5 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_3 = (__pyx_t_5 != 0); - __pyx_t_4 = __pyx_t_3; + __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_4 = (__pyx_t_6 != 0); + __pyx_t_5 = __pyx_t_4; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_4; + __pyx_v_use_setstate = __pyx_t_5; } __pyx_L3:; @@ -34078,89 +36195,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_6__ * else: * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_AbstractFactory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_AbstractFactory, (type(self), 0x7545337, None), state * else: */ - __pyx_t_4 = (__pyx_v_use_setstate != 0); - if (__pyx_t_4) { + __pyx_t_5 = (__pyx_v_use_setstate != 0); + if (__pyx_t_5) { /* "(tree fragment)":13 * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: - * return __pyx_unpickle_AbstractFactory, (type(self), 0xa73b866, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_AbstractFactory, (type(self), 0x7545337, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_AbstractFactory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_AbstractFactory, (type(self), 0x7545337, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_AbstractFactory); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_AbstractFactory); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_175356006); - __Pyx_GIVEREF(__pyx_int_175356006); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_175356006); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_122966839); + __Pyx_GIVEREF(__pyx_int_122966839); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_122966839); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); - __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); + __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_1 = 0; + PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); __pyx_t_2 = 0; - __pyx_r = __pyx_t_6; - __pyx_t_6 = 0; + __pyx_t_3 = 0; + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__attributes is not None or self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_AbstractFactory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_AbstractFactory, (type(self), 0x7545337, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_AbstractFactory, (type(self), 0xa73b866, None), state + * return __pyx_unpickle_AbstractFactory, (type(self), 0x7545337, None), state * else: - * return __pyx_unpickle_AbstractFactory, (type(self), 0xa73b866, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_AbstractFactory, (type(self), 0x7545337, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_AbstractFactory__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_AbstractFactory); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_AbstractFactory); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_175356006); - __Pyx_GIVEREF(__pyx_int_175356006); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_175356006); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_122966839); + __Pyx_GIVEREF(__pyx_int_122966839); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_122966839); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); - __pyx_t_6 = 0; - __pyx_t_2 = 0; - __pyx_r = __pyx_t_1; + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); __pyx_t_1 = 0; + __pyx_t_3 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; } @@ -34174,7 +36291,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_6__ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); - __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("dependency_injector.providers.AbstractFactory.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -34187,7 +36304,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_6__ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_AbstractFactory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_AbstractFactory, (type(self), 0x7545337, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractFactory__set_state(self, __pyx_state) */ @@ -34215,7 +36332,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_8__ __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_AbstractFactory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_AbstractFactory, (type(self), 0x7545337, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_AbstractFactory__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -34226,7 +36343,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_8__ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_AbstractFactory, (type(self), 0xa73b866, state) + * return __pyx_unpickle_AbstractFactory, (type(self), 0x7545337, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractFactory__set_state(self, __pyx_state) */ @@ -34244,7 +36361,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AbstractFactory_8__ return __pyx_r; } -/* "dependency_injector/providers.pyx":1827 +/* "dependency_injector/providers.pyx":1927 * """ * * def __init__(self, factory): # <<<<<<<<<<<<<< @@ -34285,7 +36402,7 @@ static int __pyx_pw_19dependency_injector_9providers_15FactoryDelegate_1__init__ else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 1827, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 1927, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -34296,7 +36413,7 @@ static int __pyx_pw_19dependency_injector_9providers_15FactoryDelegate_1__init__ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1827, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1927, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.FactoryDelegate.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -34327,7 +36444,7 @@ static int __pyx_pf_19dependency_injector_9providers_15FactoryDelegate___init__( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":1833 + /* "dependency_injector/providers.pyx":1933 * :type factory: object * """ * if isinstance(factory, Factory) is False: # <<<<<<<<<<<<<< @@ -34338,26 +36455,26 @@ static int __pyx_pf_19dependency_injector_9providers_15FactoryDelegate___init__( __pyx_t_2 = ((__pyx_t_1 == 0) != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":1834 + /* "dependency_injector/providers.pyx":1934 * """ * if isinstance(factory, Factory) is False: * raise Error('{0} can wrap only {1} providers'.format( # <<<<<<<<<<<<<< * self.__class__, Factory)) * super(FactoryDelegate, self).__init__(factory) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1834, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1934, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_wrap_only_1_providers, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1834, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_wrap_only_1_providers, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1934, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - /* "dependency_injector/providers.pyx":1835 + /* "dependency_injector/providers.pyx":1935 * if isinstance(factory, Factory) is False: * raise Error('{0} can wrap only {1} providers'.format( * self.__class__, Factory)) # <<<<<<<<<<<<<< * super(FactoryDelegate, self).__init__(factory) * */ - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1835, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1935, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_9 = 0; @@ -34374,7 +36491,7 @@ static int __pyx_pf_19dependency_injector_9providers_15FactoryDelegate___init__( #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1834, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1934, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; @@ -34383,14 +36500,14 @@ static int __pyx_pf_19dependency_injector_9providers_15FactoryDelegate___init__( #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1834, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1934, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { - __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1834, __pyx_L1_error) + __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1934, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_8); __pyx_t_8 = NULL; @@ -34401,7 +36518,7 @@ static int __pyx_pf_19dependency_injector_9providers_15FactoryDelegate___init__( __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)); PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_9, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory)); __pyx_t_7 = 0; - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1834, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1934, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } @@ -34419,14 +36536,14 @@ static int __pyx_pf_19dependency_injector_9providers_15FactoryDelegate___init__( __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1834, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1934, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 1834, __pyx_L1_error) + __PYX_ERR(1, 1934, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1833 + /* "dependency_injector/providers.pyx":1933 * :type factory: object * """ * if isinstance(factory, Factory) is False: # <<<<<<<<<<<<<< @@ -34435,14 +36552,14 @@ static int __pyx_pf_19dependency_injector_9providers_15FactoryDelegate___init__( */ } - /* "dependency_injector/providers.pyx":1836 + /* "dependency_injector/providers.pyx":1936 * raise Error('{0} can wrap only {1} providers'.format( * self.__class__, Factory)) * super(FactoryDelegate, self).__init__(factory) # <<<<<<<<<<<<<< * * */ - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1836, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1936, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_FactoryDelegate)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_FactoryDelegate)); @@ -34450,10 +36567,10 @@ static int __pyx_pf_19dependency_injector_9providers_15FactoryDelegate___init__( __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1836, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1936, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1836, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1936, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -34468,12 +36585,12 @@ static int __pyx_pf_19dependency_injector_9providers_15FactoryDelegate___init__( } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_factory) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_factory); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1836, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1936, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1827 + /* "dependency_injector/providers.pyx":1927 * """ * * def __init__(self, factory): # <<<<<<<<<<<<<< @@ -34525,9 +36642,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -34538,46 +36655,51 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx___provides); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___provides); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -34586,16 +36708,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -34607,7 +36729,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -34621,28 +36743,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_FactoryDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_FactoryDelegate, (type(self), 0x328787b, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -34650,44 +36772,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_FactoryDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_FactoryDelegate, (type(self), 0x328787b, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_FactoryDelegate, (type(self), 0x3f4a3b6, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_FactoryDelegate, (type(self), 0x328787b, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_FactoryDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_FactoryDelegate, (type(self), 0x328787b, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_FactoryDelegate); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_FactoryDelegate); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -34696,15 +36818,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_FactoryDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_FactoryDelegate, (type(self), 0x328787b, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_FactoryDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_FactoryDelegate, (type(self), 0x328787b, None), state * else: - * return __pyx_unpickle_FactoryDelegate, (type(self), 0x3f4a3b6, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_FactoryDelegate, (type(self), 0x328787b, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_FactoryDelegate__set_state(self, __pyx_state) */ @@ -34712,27 +36834,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_FactoryDelegate); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -34745,7 +36867,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.FactoryDelegate.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -34759,7 +36881,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_2__ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_FactoryDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_FactoryDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_FactoryDelegate__set_state(self, __pyx_state) */ @@ -34787,7 +36909,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_4__ __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_FactoryDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_FactoryDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_FactoryDelegate__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -34798,7 +36920,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_4__ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_FactoryDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_FactoryDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_FactoryDelegate__set_state(self, __pyx_state) */ @@ -34816,7 +36938,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15FactoryDelegate_4__ return __pyx_r; } -/* "dependency_injector/providers.pyx":1855 +/* "dependency_injector/providers.pyx":1955 * __IS_DELEGATED__ = True * * def __init__(self, **factories): # <<<<<<<<<<<<<< @@ -34870,22 +36992,22 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":1861 + /* "dependency_injector/providers.pyx":1961 * :type factories: dict[str, :py:class:`Factory`] * """ * for factory in factories.values(): # <<<<<<<<<<<<<< * if isinstance(factory, Factory) is False: * raise Error( */ - __pyx_t_1 = __Pyx_PyDict_Values(__pyx_v_factories); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1861, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_Values(__pyx_v_factories); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1961, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; __pyx_t_4 = NULL; } else { - __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1861, __pyx_L1_error) + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1961, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1861, __pyx_L1_error) + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1961, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -34893,17 +37015,17 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1861, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1961, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1861, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1961, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1861, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 1961, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1861, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1961, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -34913,7 +37035,7 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 1861, __pyx_L1_error) + else __PYX_ERR(1, 1961, __pyx_L1_error) } break; } @@ -34922,7 +37044,7 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ __Pyx_XDECREF_SET(__pyx_v_factory, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1862 + /* "dependency_injector/providers.pyx":1962 * """ * for factory in factories.values(): * if isinstance(factory, Factory) is False: # <<<<<<<<<<<<<< @@ -34933,26 +37055,26 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ __pyx_t_6 = ((__pyx_t_5 == 0) != 0); if (unlikely(__pyx_t_6)) { - /* "dependency_injector/providers.pyx":1863 + /* "dependency_injector/providers.pyx":1963 * for factory in factories.values(): * if isinstance(factory, Factory) is False: * raise Error( # <<<<<<<<<<<<<< * '{0} can aggregate only instances of {1}, given - {2}' * .format(self.__class__, Factory, factory)) */ - __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_Error); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1863, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_Error); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1963, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - /* "dependency_injector/providers.pyx":1865 + /* "dependency_injector/providers.pyx":1965 * raise Error( * '{0} can aggregate only instances of {1}, given - {2}' * .format(self.__class__, Factory, factory)) # <<<<<<<<<<<<<< * self.__factories = factories * super(FactoryAggregate, self).__init__() */ - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_aggregate_only_instances, __pyx_n_s_format); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1865, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_aggregate_only_instances, __pyx_n_s_format); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1965, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); - __pyx_t_10 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1865, __pyx_L1_error) + __pyx_t_10 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1965, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); __pyx_t_11 = NULL; __pyx_t_12 = 0; @@ -34969,7 +37091,7 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[4] = {__pyx_t_11, __pyx_t_10, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory), __pyx_v_factory}; - __pyx_t_8 = __Pyx_PyFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_12, 3+__pyx_t_12); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1865, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_12, 3+__pyx_t_12); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1965, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; @@ -34978,14 +37100,14 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[4] = {__pyx_t_11, __pyx_t_10, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory), __pyx_v_factory}; - __pyx_t_8 = __Pyx_PyCFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_12, 3+__pyx_t_12); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1865, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyCFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_12, 3+__pyx_t_12); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1965, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } else #endif { - __pyx_t_13 = PyTuple_New(3+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 1865, __pyx_L1_error) + __pyx_t_13 = PyTuple_New(3+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 1965, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); if (__pyx_t_11) { __Pyx_GIVEREF(__pyx_t_11); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_11); __pyx_t_11 = NULL; @@ -34999,7 +37121,7 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ __Pyx_GIVEREF(__pyx_v_factory); PyTuple_SET_ITEM(__pyx_t_13, 2+__pyx_t_12, __pyx_v_factory); __pyx_t_10 = 0; - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_13, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1865, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_13, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1965, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } @@ -35017,14 +37139,14 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_9, __pyx_t_8) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1863, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1963, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 1863, __pyx_L1_error) + __PYX_ERR(1, 1963, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1862 + /* "dependency_injector/providers.pyx":1962 * """ * for factory in factories.values(): * if isinstance(factory, Factory) is False: # <<<<<<<<<<<<<< @@ -35033,7 +37155,7 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ */ } - /* "dependency_injector/providers.pyx":1861 + /* "dependency_injector/providers.pyx":1961 * :type factories: dict[str, :py:class:`Factory`] * """ * for factory in factories.values(): # <<<<<<<<<<<<<< @@ -35043,7 +37165,7 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1866 + /* "dependency_injector/providers.pyx":1966 * '{0} can aggregate only instances of {1}, given - {2}' * .format(self.__class__, Factory, factory)) * self.__factories = factories # <<<<<<<<<<<<<< @@ -35056,14 +37178,14 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ __Pyx_DECREF(__pyx_v_self->__pyx___factories); __pyx_v_self->__pyx___factories = __pyx_v_factories; - /* "dependency_injector/providers.pyx":1867 + /* "dependency_injector/providers.pyx":1967 * .format(self.__class__, Factory, factory)) * self.__factories = factories * super(FactoryAggregate, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1867, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1967, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_FactoryAggregate)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_FactoryAggregate)); @@ -35071,10 +37193,10 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_7 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1867, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1967, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1867, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1967, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_7 = NULL; @@ -35089,12 +37211,12 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ } __pyx_t_2 = (__pyx_t_7) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_7) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1867, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1967, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1855 + /* "dependency_injector/providers.pyx":1955 * __IS_DELEGATED__ = True * * def __init__(self, **factories): # <<<<<<<<<<<<<< @@ -35122,7 +37244,7 @@ static int __pyx_pf_19dependency_injector_9providers_16FactoryAggregate___init__ return __pyx_r; } -/* "dependency_injector/providers.pyx":1869 +/* "dependency_injector/providers.pyx":1969 * super(FactoryAggregate, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -35160,16 +37282,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_2_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":1873 + /* "dependency_injector/providers.pyx":1973 * cdef FactoryAggregate copied * * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1873, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1973, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1873, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1973, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -35184,14 +37306,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_2_ __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1873, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1973, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_FactoryAggregate))))) __PYX_ERR(1, 1873, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_FactoryAggregate))))) __PYX_ERR(1, 1973, __pyx_L1_error) __pyx_v_copied = ((struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1874 + /* "dependency_injector/providers.pyx":1974 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -35202,7 +37324,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_2_ __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":1875 + /* "dependency_injector/providers.pyx":1975 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -35214,7 +37336,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_2_ __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1874 + /* "dependency_injector/providers.pyx":1974 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -35223,14 +37345,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_2_ */ } - /* "dependency_injector/providers.pyx":1877 + /* "dependency_injector/providers.pyx":1977 * return copied * * copied = self.__class__() # <<<<<<<<<<<<<< * copied.__factories = deepcopy(self.__factories, memo) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1877, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1977, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -35244,14 +37366,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_2_ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1877, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1977, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_FactoryAggregate))))) __PYX_ERR(1, 1877, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_FactoryAggregate))))) __PYX_ERR(1, 1977, __pyx_L1_error) __Pyx_DECREF_SET(__pyx_v_copied, ((struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1878 + /* "dependency_injector/providers.pyx":1978 * * copied = self.__class__() * copied.__factories = deepcopy(self.__factories, memo) # <<<<<<<<<<<<<< @@ -35260,42 +37382,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_2_ */ __pyx_t_1 = __pyx_v_self->__pyx___factories; __Pyx_INCREF(__pyx_t_1); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1878, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1978, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1878, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1978, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (!(likely(PyDict_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_2)->tp_name), 0))) __PYX_ERR(1, 1878, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_2)->tp_name), 0))) __PYX_ERR(1, 1978, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_2); __Pyx_GOTREF(__pyx_v_copied->__pyx___factories); __Pyx_DECREF(__pyx_v_copied->__pyx___factories); __pyx_v_copied->__pyx___factories = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1880 + /* "dependency_injector/providers.pyx":1980 * copied.__factories = deepcopy(self.__factories, memo) * * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1880, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1980, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":1882 + /* "dependency_injector/providers.pyx":1982 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< * - * def __call__(self, factory_name, *args, **kwargs): + * def __getattr__(self, factory_name): */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(((PyObject *)__pyx_v_copied)); __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1869 + /* "dependency_injector/providers.pyx":1969 * super(FactoryAggregate, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -35318,165 +37440,32 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_2_ return __pyx_r; } -/* "dependency_injector/providers.pyx":1884 +/* "dependency_injector/providers.pyx":1984 * return copied * - * def __call__(self, factory_name, *args, **kwargs): # <<<<<<<<<<<<<< - * """Create new object using factory with provided name. - * - */ - -/* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_5__call__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static char __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_4__call__[] = "Create new object using factory with provided name.\n\n Callable interface implementation.\n "; -#if CYTHON_COMPILING_IN_CPYTHON -struct wrapperbase __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_4__call__; -#endif -static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_5__call__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { - PyObject *__pyx_v_factory_name = 0; - PyObject *__pyx_v_args = 0; - PyObject *__pyx_v_kwargs = 0; - int __pyx_lineno = 0; - const char *__pyx_filename = NULL; - int __pyx_clineno = 0; - PyObject *__pyx_r = 0; - __Pyx_RefNannyDeclarations - __Pyx_RefNannySetupContext("__call__ (wrapper)", 0); - __pyx_v_kwargs = PyDict_New(); if (unlikely(!__pyx_v_kwargs)) return NULL; - __Pyx_GOTREF(__pyx_v_kwargs); - if (PyTuple_GET_SIZE(__pyx_args) > 1) { - __pyx_v_args = PyTuple_GetSlice(__pyx_args, 1, PyTuple_GET_SIZE(__pyx_args)); - if (unlikely(!__pyx_v_args)) { - __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; - __Pyx_RefNannyFinishContext(); - return NULL; - } - __Pyx_GOTREF(__pyx_v_args); - } else { - __pyx_v_args = __pyx_empty_tuple; __Pyx_INCREF(__pyx_empty_tuple); - } - { - static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_factory_name,0}; - PyObject* values[1] = {0}; - if (unlikely(__pyx_kwds)) { - Py_ssize_t kw_args; - const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); - switch (pos_args) { - default: - case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); - CYTHON_FALLTHROUGH; - case 0: break; - } - kw_args = PyDict_Size(__pyx_kwds); - switch (pos_args) { - case 0: - if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_factory_name)) != 0)) kw_args--; - else goto __pyx_L5_argtuple_error; - } - if (unlikely(kw_args > 0)) { - const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__call__") < 0)) __PYX_ERR(1, 1884, __pyx_L3_error) - } - } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { - goto __pyx_L5_argtuple_error; - } else { - values[0] = PyTuple_GET_ITEM(__pyx_args, 0); - } - __pyx_v_factory_name = values[0]; - } - goto __pyx_L4_argument_unpacking_done; - __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__call__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1884, __pyx_L3_error) - __pyx_L3_error:; - __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; - __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; - __Pyx_AddTraceback("dependency_injector.providers.FactoryAggregate.__call__", __pyx_clineno, __pyx_lineno, __pyx_filename); - __Pyx_RefNannyFinishContext(); - return NULL; - __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_16FactoryAggregate_4__call__(((struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self), __pyx_v_factory_name, __pyx_v_args, __pyx_v_kwargs); - - /* function exit code */ - __Pyx_XDECREF(__pyx_v_args); - __Pyx_XDECREF(__pyx_v_kwargs); - __Pyx_RefNannyFinishContext(); - return __pyx_r; -} - -static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_4__call__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_factory_name, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs) { - PyObject *__pyx_r = NULL; - __Pyx_RefNannyDeclarations - PyObject *__pyx_t_1 = NULL; - PyObject *__pyx_t_2 = NULL; - int __pyx_lineno = 0; - const char *__pyx_filename = NULL; - int __pyx_clineno = 0; - __Pyx_RefNannySetupContext("__call__", 0); - - /* "dependency_injector/providers.pyx":1889 - * Callable interface implementation. - * """ - * return self.__get_factory(factory_name)(*args, **kwargs) # <<<<<<<<<<<<<< - * - * def __getattr__(self, factory_name): - */ - __Pyx_XDECREF(__pyx_r); - if (!(likely(PyString_CheckExact(__pyx_v_factory_name))||((__pyx_v_factory_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_v_factory_name)->tp_name), 0))) __PYX_ERR(1, 1889, __pyx_L1_error) - __pyx_t_1 = ((PyObject *)((struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx___get_factory(__pyx_v_self, ((PyObject*)__pyx_v_factory_name))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1889, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1889, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_r = __pyx_t_2; - __pyx_t_2 = 0; - goto __pyx_L0; - - /* "dependency_injector/providers.pyx":1884 - * return copied - * - * def __call__(self, factory_name, *args, **kwargs): # <<<<<<<<<<<<<< - * """Create new object using factory with provided name. - * - */ - - /* function exit code */ - __pyx_L1_error:; - __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_2); - __Pyx_AddTraceback("dependency_injector.providers.FactoryAggregate.__call__", __pyx_clineno, __pyx_lineno, __pyx_filename); - __pyx_r = NULL; - __pyx_L0:; - __Pyx_XGIVEREF(__pyx_r); - __Pyx_RefNannyFinishContext(); - return __pyx_r; -} - -/* "dependency_injector/providers.pyx":1891 - * return self.__get_factory(factory_name)(*args, **kwargs) - * * def __getattr__(self, factory_name): # <<<<<<<<<<<<<< * """Return aggregated factory.""" * return self.__get_factory(factory_name) */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_7__getattr__(PyObject *__pyx_v_self, PyObject *__pyx_v_factory_name); /*proto*/ -static char __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_6__getattr__[] = "Return aggregated factory."; +static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_5__getattr__(PyObject *__pyx_v_self, PyObject *__pyx_v_factory_name); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_4__getattr__[] = "Return aggregated factory."; #if CYTHON_COMPILING_IN_CPYTHON -struct wrapperbase __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_6__getattr__; +struct wrapperbase __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_4__getattr__; #endif -static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_7__getattr__(PyObject *__pyx_v_self, PyObject *__pyx_v_factory_name) { +static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_5__getattr__(PyObject *__pyx_v_self, PyObject *__pyx_v_factory_name) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__getattr__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_16FactoryAggregate_6__getattr__(((struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self), ((PyObject *)__pyx_v_factory_name)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_16FactoryAggregate_4__getattr__(((struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self), ((PyObject *)__pyx_v_factory_name)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_6__getattr__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_factory_name) { +static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_4__getattr__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_factory_name) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -35485,7 +37474,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_6_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getattr__", 0); - /* "dependency_injector/providers.pyx":1893 + /* "dependency_injector/providers.pyx":1986 * def __getattr__(self, factory_name): * """Return aggregated factory.""" * return self.__get_factory(factory_name) # <<<<<<<<<<<<<< @@ -35493,15 +37482,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_6_ * def __str__(self): */ __Pyx_XDECREF(__pyx_r); - if (!(likely(PyString_CheckExact(__pyx_v_factory_name))||((__pyx_v_factory_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_v_factory_name)->tp_name), 0))) __PYX_ERR(1, 1893, __pyx_L1_error) - __pyx_t_1 = ((PyObject *)((struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx___get_factory(__pyx_v_self, ((PyObject*)__pyx_v_factory_name))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1893, __pyx_L1_error) + if (!(likely(PyString_CheckExact(__pyx_v_factory_name))||((__pyx_v_factory_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_v_factory_name)->tp_name), 0))) __PYX_ERR(1, 1986, __pyx_L1_error) + __pyx_t_1 = ((PyObject *)((struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx___get_factory(__pyx_v_self, ((PyObject*)__pyx_v_factory_name))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1986, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1891 - * return self.__get_factory(factory_name)(*args, **kwargs) + /* "dependency_injector/providers.pyx":1984 + * return copied * * def __getattr__(self, factory_name): # <<<<<<<<<<<<<< * """Return aggregated factory.""" @@ -35519,7 +37508,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_6_ return __pyx_r; } -/* "dependency_injector/providers.pyx":1895 +/* "dependency_injector/providers.pyx":1988 * return self.__get_factory(factory_name) * * def __str__(self): # <<<<<<<<<<<<<< @@ -35528,23 +37517,23 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_6_ */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_9__str__(PyObject *__pyx_v_self); /*proto*/ -static char __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_8__str__[] = "Return string representation of provider.\n\n :rtype: str\n "; +static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_7__str__(PyObject *__pyx_v_self); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_6__str__[] = "Return string representation of provider.\n\n :rtype: str\n "; #if CYTHON_COMPILING_IN_CPYTHON -struct wrapperbase __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_8__str__; +struct wrapperbase __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_6__str__; #endif -static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_9__str__(PyObject *__pyx_v_self) { +static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_7__str__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__str__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_16FactoryAggregate_8__str__(((struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_16FactoryAggregate_6__str__(((struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_8__str__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self) { +static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_6__str__(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -35554,7 +37543,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_8_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":1900 + /* "dependency_injector/providers.pyx":1993 * :rtype: str * """ * return represent_provider(provider=self, provides=self.factories) # <<<<<<<<<<<<<< @@ -35562,16 +37551,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_8_ * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_factories); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1900, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_factories); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1993, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1900, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1993, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1895 + /* "dependency_injector/providers.pyx":1988 * return self.__get_factory(factory_name) * * def __str__(self): # <<<<<<<<<<<<<< @@ -35591,7 +37580,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_8_ return __pyx_r; } -/* "dependency_injector/providers.pyx":1903 +/* "dependency_injector/providers.pyx":1996 * * @property * def factories(self): # <<<<<<<<<<<<<< @@ -35617,7 +37606,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_9f __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":1905 + /* "dependency_injector/providers.pyx":1998 * def factories(self): * """Return dictionary of factories, read-only.""" * return self.__factories # <<<<<<<<<<<<<< @@ -35629,7 +37618,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_9f __pyx_r = __pyx_v_self->__pyx___factories; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1903 + /* "dependency_injector/providers.pyx":1996 * * @property * def factories(self): # <<<<<<<<<<<<<< @@ -35644,7 +37633,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_9f return __pyx_r; } -/* "dependency_injector/providers.pyx":1907 +/* "dependency_injector/providers.pyx":2000 * return self.__factories * * def override(self, _): # <<<<<<<<<<<<<< @@ -35653,20 +37642,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_9f */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_11override(PyObject *__pyx_v_self, PyObject *__pyx_v__); /*proto*/ -static char __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_10override[] = "Override provider with another provider.\n\n :raise: :py:exc:`dependency_injector.errors.Error`\n\n :return: Overriding context.\n :rtype: :py:class:`OverridingContext`\n "; -static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_11override(PyObject *__pyx_v_self, PyObject *__pyx_v__) { +static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_9override(PyObject *__pyx_v_self, PyObject *__pyx_v__); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_8override[] = "Override provider with another provider.\n\n :raise: :py:exc:`dependency_injector.errors.Error`\n\n :return: Overriding context.\n :rtype: :py:class:`OverridingContext`\n "; +static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_9override(PyObject *__pyx_v_self, PyObject *__pyx_v__) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("override (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_16FactoryAggregate_10override(((struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self), ((PyObject *)__pyx_v__)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_16FactoryAggregate_8override(((struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self), ((PyObject *)__pyx_v__)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_10override(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v__) { +static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_8override(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v__) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -35680,26 +37669,26 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_10 int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/providers.pyx":1915 + /* "dependency_injector/providers.pyx":2008 * :rtype: :py:class:`OverridingContext` * """ * raise Error( # <<<<<<<<<<<<<< * '{0} providers could not be overridden'.format(self.__class__)) * */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1915, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2008, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - /* "dependency_injector/providers.pyx":1916 + /* "dependency_injector/providers.pyx":2009 * """ * raise Error( * '{0} providers could not be overridden'.format(self.__class__)) # <<<<<<<<<<<<<< * - * cdef Factory __get_factory(self, str factory_name): + * cpdef object _provide(self, tuple args, dict kwargs): */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_providers_could_not_be_overri, __pyx_n_s_format); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1916, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_providers_could_not_be_overri, __pyx_n_s_format); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2009, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1916, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2009, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -35714,7 +37703,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_10 __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1916, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2009, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; @@ -35730,14 +37719,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_10 __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1915, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2008, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 1915, __pyx_L1_error) + __PYX_ERR(1, 2008, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1907 + /* "dependency_injector/providers.pyx":2000 * return self.__factories * * def override(self, _): # <<<<<<<<<<<<<< @@ -35760,9 +37749,472 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_10 return __pyx_r; } -/* "dependency_injector/providers.pyx":1918 +/* "dependency_injector/providers.pyx":2011 * '{0} providers could not be overridden'.format(self.__class__)) * + * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< + * try: + * factory_name = args[0] + */ + +static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_11_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_f_19dependency_injector_9providers_16FactoryAggregate__provide(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch) { + PyObject *__pyx_v_factory_name = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + int __pyx_t_5; + PyObject *__pyx_t_6 = NULL; + PyObject *__pyx_t_7 = NULL; + PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; + PyObject *__pyx_t_10 = NULL; + PyObject *__pyx_t_11 = NULL; + PyObject *__pyx_t_12 = NULL; + PyObject *__pyx_t_13 = NULL; + PyObject *__pyx_t_14 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_provide", 0); + __Pyx_INCREF(__pyx_v_args); + /* Check if called by wrapper */ + if (unlikely(__pyx_skip_dispatch)) ; + /* Check if overridden in Python */ + else if (unlikely((Py_TYPE(((PyObject *)__pyx_v_self))->tp_dictoffset != 0) || (Py_TYPE(((PyObject *)__pyx_v_self))->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)))) { + #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_PYTYPE_LOOKUP && CYTHON_USE_TYPE_SLOTS + static PY_UINT64_T __pyx_tp_dict_version = __PYX_DICT_VERSION_INIT, __pyx_obj_dict_version = __PYX_DICT_VERSION_INIT; + if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { + PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); + #endif + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2011, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_11_provide)) { + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_t_1); + __pyx_t_3 = __pyx_t_1; __pyx_t_4 = NULL; + __pyx_t_5 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + __pyx_t_5 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_3)) { + PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2011, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_GOTREF(__pyx_t_2); + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { + PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2011, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_GOTREF(__pyx_t_2); + } else + #endif + { + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2011, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + if (__pyx_t_4) { + __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; + } + __Pyx_INCREF(__pyx_v_args); + __Pyx_GIVEREF(__pyx_v_args); + PyTuple_SET_ITEM(__pyx_t_6, 0+__pyx_t_5, __pyx_v_args); + __Pyx_INCREF(__pyx_v_kwargs); + __Pyx_GIVEREF(__pyx_v_kwargs); + PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2011, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + goto __pyx_L0; + } + #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_PYTYPE_LOOKUP && CYTHON_USE_TYPE_SLOTS + __pyx_tp_dict_version = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); + __pyx_obj_dict_version = __Pyx_get_object_dict_version(((PyObject *)__pyx_v_self)); + if (unlikely(__pyx_type_dict_guard != __pyx_tp_dict_version)) { + __pyx_tp_dict_version = __pyx_obj_dict_version = __PYX_DICT_VERSION_INIT; + } + #endif + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_PYTYPE_LOOKUP && CYTHON_USE_TYPE_SLOTS + } + #endif + } + + /* "dependency_injector/providers.pyx":2012 + * + * cpdef object _provide(self, tuple args, dict kwargs): + * try: # <<<<<<<<<<<<<< + * factory_name = args[0] + * except IndexError: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_7, &__pyx_t_8, &__pyx_t_9); + __Pyx_XGOTREF(__pyx_t_7); + __Pyx_XGOTREF(__pyx_t_8); + __Pyx_XGOTREF(__pyx_t_9); + /*try:*/ { + + /* "dependency_injector/providers.pyx":2013 + * cpdef object _provide(self, tuple args, dict kwargs): + * try: + * factory_name = args[0] # <<<<<<<<<<<<<< + * except IndexError: + * try: + */ + if (unlikely(__pyx_v_args == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(1, 2013, __pyx_L3_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_args, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2013, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_factory_name = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":2012 + * + * cpdef object _provide(self, tuple args, dict kwargs): + * try: # <<<<<<<<<<<<<< + * factory_name = args[0] + * except IndexError: + */ + } + + /* "dependency_injector/providers.pyx":2020 + * raise TypeError('Factory missing 1 required positional argument: \'factory_name\'') + * else: + * args = args[1:] # <<<<<<<<<<<<<< + * + * return self.__get_factory(factory_name)(*args, **kwargs) + */ + /*else:*/ { + if (unlikely(__pyx_v_args == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(1, 2020, __pyx_L5_except_error) + } + __pyx_t_1 = __Pyx_PyTuple_GetSlice(__pyx_v_args, 1, PY_SSIZE_T_MAX); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2020, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF_SET(__pyx_v_args, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; + } + __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + goto __pyx_L8_try_end; + __pyx_L3_error:; + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + + /* "dependency_injector/providers.pyx":2014 + * try: + * factory_name = args[0] + * except IndexError: # <<<<<<<<<<<<<< + * try: + * factory_name = kwargs.pop('factory_name') + */ + __pyx_t_5 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_IndexError); + if (__pyx_t_5) { + __Pyx_AddTraceback("dependency_injector.providers.FactoryAggregate._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3) < 0) __PYX_ERR(1, 2014, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GOTREF(__pyx_t_3); + + /* "dependency_injector/providers.pyx":2015 + * factory_name = args[0] + * except IndexError: + * try: # <<<<<<<<<<<<<< + * factory_name = kwargs.pop('factory_name') + * except KeyError: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_10, &__pyx_t_11, &__pyx_t_12); + __Pyx_XGOTREF(__pyx_t_10); + __Pyx_XGOTREF(__pyx_t_11); + __Pyx_XGOTREF(__pyx_t_12); + /*try:*/ { + + /* "dependency_injector/providers.pyx":2016 + * except IndexError: + * try: + * factory_name = kwargs.pop('factory_name') # <<<<<<<<<<<<<< + * except KeyError: + * raise TypeError('Factory missing 1 required positional argument: \'factory_name\'') + */ + if (unlikely(__pyx_v_kwargs == Py_None)) { + PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "pop"); + __PYX_ERR(1, 2016, __pyx_L11_error) + } + __pyx_t_6 = __Pyx_PyDict_Pop(__pyx_v_kwargs, __pyx_n_s_factory_name, ((PyObject *)NULL)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2016, __pyx_L11_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_XDECREF_SET(__pyx_v_factory_name, __pyx_t_6); + __pyx_t_6 = 0; + + /* "dependency_injector/providers.pyx":2015 + * factory_name = args[0] + * except IndexError: + * try: # <<<<<<<<<<<<<< + * factory_name = kwargs.pop('factory_name') + * except KeyError: + */ + } + __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; + __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; + __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; + goto __pyx_L18_try_end; + __pyx_L11_error:; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + + /* "dependency_injector/providers.pyx":2017 + * try: + * factory_name = kwargs.pop('factory_name') + * except KeyError: # <<<<<<<<<<<<<< + * raise TypeError('Factory missing 1 required positional argument: \'factory_name\'') + * else: + */ + __pyx_t_5 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_KeyError); + if (__pyx_t_5) { + __Pyx_AddTraceback("dependency_injector.providers.FactoryAggregate._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_13) < 0) __PYX_ERR(1, 2017, __pyx_L13_except_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_GOTREF(__pyx_t_4); + __Pyx_GOTREF(__pyx_t_13); + + /* "dependency_injector/providers.pyx":2018 + * factory_name = kwargs.pop('factory_name') + * except KeyError: + * raise TypeError('Factory missing 1 required positional argument: \'factory_name\'') # <<<<<<<<<<<<<< + * else: + * args = args[1:] + */ + __pyx_t_14 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__8, NULL); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 2018, __pyx_L13_except_error) + __Pyx_GOTREF(__pyx_t_14); + __Pyx_Raise(__pyx_t_14, 0, 0, 0); + __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; + __PYX_ERR(1, 2018, __pyx_L13_except_error) + } + goto __pyx_L13_except_error; + __pyx_L13_except_error:; + + /* "dependency_injector/providers.pyx":2015 + * factory_name = args[0] + * except IndexError: + * try: # <<<<<<<<<<<<<< + * factory_name = kwargs.pop('factory_name') + * except KeyError: + */ + __Pyx_XGIVEREF(__pyx_t_10); + __Pyx_XGIVEREF(__pyx_t_11); + __Pyx_XGIVEREF(__pyx_t_12); + __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_11, __pyx_t_12); + goto __pyx_L5_except_error; + __pyx_L18_try_end:; + } + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + goto __pyx_L4_exception_handled; + } + goto __pyx_L5_except_error; + __pyx_L5_except_error:; + + /* "dependency_injector/providers.pyx":2012 + * + * cpdef object _provide(self, tuple args, dict kwargs): + * try: # <<<<<<<<<<<<<< + * factory_name = args[0] + * except IndexError: + */ + __Pyx_XGIVEREF(__pyx_t_7); + __Pyx_XGIVEREF(__pyx_t_8); + __Pyx_XGIVEREF(__pyx_t_9); + __Pyx_ExceptionReset(__pyx_t_7, __pyx_t_8, __pyx_t_9); + goto __pyx_L1_error; + __pyx_L4_exception_handled:; + __Pyx_XGIVEREF(__pyx_t_7); + __Pyx_XGIVEREF(__pyx_t_8); + __Pyx_XGIVEREF(__pyx_t_9); + __Pyx_ExceptionReset(__pyx_t_7, __pyx_t_8, __pyx_t_9); + __pyx_L8_try_end:; + } + + /* "dependency_injector/providers.pyx":2022 + * args = args[1:] + * + * return self.__get_factory(factory_name)(*args, **kwargs) # <<<<<<<<<<<<<< + * + * cdef Factory __get_factory(self, str factory_name): + */ + __Pyx_XDECREF(__pyx_r); + if (!(likely(PyString_CheckExact(__pyx_v_factory_name))||((__pyx_v_factory_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_v_factory_name)->tp_name), 0))) __PYX_ERR(1, 2022, __pyx_L1_error) + __pyx_t_3 = ((PyObject *)((struct __pyx_vtabstruct_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx___get_factory(__pyx_v_self, ((PyObject*)__pyx_v_factory_name))); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2022, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + if (unlikely(__pyx_v_args == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); + __PYX_ERR(1, 2022, __pyx_L1_error) + } + if (unlikely(__pyx_v_kwargs == Py_None)) { + PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); + __PYX_ERR(1, 2022, __pyx_L1_error) + } + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2022, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":2011 + * '{0} providers could not be overridden'.format(self.__class__)) + * + * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< + * try: + * factory_name = args[0] + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_13); + __Pyx_XDECREF(__pyx_t_14); + __Pyx_AddTraceback("dependency_injector.providers.FactoryAggregate._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = 0; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_factory_name); + __Pyx_XDECREF(__pyx_v_args); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_11_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_11_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_args = 0; + PyObject *__pyx_v_kwargs = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_provide (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_args,&__pyx_n_s_kwargs,0}; + PyObject* values[2] = {0,0}; + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_args)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + CYTHON_FALLTHROUGH; + case 1: + if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; + else { + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2011, __pyx_L3_error) + } + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2011, __pyx_L3_error) + } + } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { + goto __pyx_L5_argtuple_error; + } else { + values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + } + __pyx_v_args = ((PyObject*)values[0]); + __pyx_v_kwargs = ((PyObject*)values[1]); + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2011, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.FactoryAggregate._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2011, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2011, __pyx_L1_error) + __pyx_r = __pyx_pf_19dependency_injector_9providers_16FactoryAggregate_10_provide(((struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); + + /* function exit code */ + goto __pyx_L0; + __pyx_L1_error:; + __pyx_r = NULL; + __pyx_L0:; + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_10_provide(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_provide", 0); + __Pyx_XDECREF(__pyx_r); + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_16FactoryAggregate__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2011, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_AddTraceback("dependency_injector.providers.FactoryAggregate._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":2024 + * return self.__get_factory(factory_name)(*args, **kwargs) + * * cdef Factory __get_factory(self, str factory_name): # <<<<<<<<<<<<<< * if factory_name not in self.__factories: * raise NoSuchProviderError( @@ -35785,7 +38237,7 @@ static struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_f_19depe int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get_factory", 0); - /* "dependency_injector/providers.pyx":1919 + /* "dependency_injector/providers.pyx":2025 * * cdef Factory __get_factory(self, str factory_name): * if factory_name not in self.__factories: # <<<<<<<<<<<<<< @@ -35794,33 +38246,33 @@ static struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_f_19depe */ if (unlikely(__pyx_v_self->__pyx___factories == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 1919, __pyx_L1_error) + __PYX_ERR(1, 2025, __pyx_L1_error) } - __pyx_t_1 = (__Pyx_PyDict_ContainsTF(__pyx_v_factory_name, __pyx_v_self->__pyx___factories, Py_NE)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 1919, __pyx_L1_error) + __pyx_t_1 = (__Pyx_PyDict_ContainsTF(__pyx_v_factory_name, __pyx_v_self->__pyx___factories, Py_NE)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 2025, __pyx_L1_error) __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":1920 + /* "dependency_injector/providers.pyx":2026 * cdef Factory __get_factory(self, str factory_name): * if factory_name not in self.__factories: * raise NoSuchProviderError( # <<<<<<<<<<<<<< * '{0} does not contain factory with name {1}'.format( * self, factory_name)) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_NoSuchProviderError); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1920, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_NoSuchProviderError); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2026, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/providers.pyx":1921 + /* "dependency_injector/providers.pyx":2027 * if factory_name not in self.__factories: * raise NoSuchProviderError( * '{0} does not contain factory with name {1}'.format( # <<<<<<<<<<<<<< * self, factory_name)) * return self.__factories[factory_name] */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_does_not_contain_factory_with, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1921, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_does_not_contain_factory_with, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2027, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - /* "dependency_injector/providers.pyx":1922 + /* "dependency_injector/providers.pyx":2028 * raise NoSuchProviderError( * '{0} does not contain factory with name {1}'.format( * self, factory_name)) # <<<<<<<<<<<<<< @@ -35842,7 +38294,7 @@ static struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_f_19depe #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, ((PyObject *)__pyx_v_self), __pyx_v_factory_name}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1921, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2027, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else @@ -35850,13 +38302,13 @@ static struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_f_19depe #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, ((PyObject *)__pyx_v_self), __pyx_v_factory_name}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1921, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2027, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1921, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2027, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -35867,7 +38319,7 @@ static struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_f_19depe __Pyx_INCREF(__pyx_v_factory_name); __Pyx_GIVEREF(__pyx_v_factory_name); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, __pyx_v_factory_name); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 1921, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2027, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } @@ -35885,14 +38337,14 @@ static struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_f_19depe __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1920, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2026, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 1920, __pyx_L1_error) + __PYX_ERR(1, 2026, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1919 + /* "dependency_injector/providers.pyx":2025 * * cdef Factory __get_factory(self, str factory_name): * if factory_name not in self.__factories: # <<<<<<<<<<<<<< @@ -35901,7 +38353,7 @@ static struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_f_19depe */ } - /* "dependency_injector/providers.pyx":1923 + /* "dependency_injector/providers.pyx":2029 * '{0} does not contain factory with name {1}'.format( * self, factory_name)) * return self.__factories[factory_name] # <<<<<<<<<<<<<< @@ -35911,17 +38363,17 @@ static struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_f_19depe __Pyx_XDECREF(((PyObject *)__pyx_r)); if (unlikely(__pyx_v_self->__pyx___factories == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 1923, __pyx_L1_error) + __PYX_ERR(1, 2029, __pyx_L1_error) } - __pyx_t_3 = __Pyx_PyDict_GetItem(__pyx_v_self->__pyx___factories, __pyx_v_factory_name); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1923, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_GetItem(__pyx_v_self->__pyx___factories, __pyx_v_factory_name); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2029, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)((struct __pyx_obj_19dependency_injector_9providers_Factory *)__pyx_t_3))); __pyx_r = ((struct __pyx_obj_19dependency_injector_9providers_Factory *)__pyx_t_3); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1918 - * '{0} providers could not be overridden'.format(self.__class__)) + /* "dependency_injector/providers.pyx":2024 + * return self.__get_factory(factory_name)(*args, **kwargs) * * cdef Factory __get_factory(self, str factory_name): # <<<<<<<<<<<<<< * if factory_name not in self.__factories: @@ -35970,9 +38422,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12 PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -35983,46 +38435,51 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12 /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__factories, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__factories, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx___factories); __Pyx_GIVEREF(__pyx_v_self->__pyx___factories); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->__pyx___factories); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->__pyx___factories); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx___overridden); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___overridden); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__factories, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__factories, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__factories, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__factories, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -36031,16 +38488,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12 * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -36052,7 +38509,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12 __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__factories, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__factories, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -36066,28 +38523,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12 * else: * use_setstate = self.__factories is not None or self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa6696fd, None), state + * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa264cf2, None), state */ /*else*/ { - __pyx_t_2 = (__pyx_v_self->__pyx___factories != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx___factories != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -36095,44 +38552,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12 * else: * use_setstate = self.__factories is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa6696fd, None), state + * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa264cf2, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__factories is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: - * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa6696fd, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa264cf2, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa6696fd, state) + * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa264cf2, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_FactoryAggregate); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_FactoryAggregate); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_174495485); - __Pyx_GIVEREF(__pyx_int_174495485); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_174495485); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_170282226); + __Pyx_GIVEREF(__pyx_int_170282226); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_170282226); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -36141,15 +38598,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12 * else: * use_setstate = self.__factories is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa6696fd, None), state + * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa264cf2, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa6696fd, None), state + * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa264cf2, None), state * else: - * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa6696fd, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa264cf2, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_FactoryAggregate__set_state(self, __pyx_state) */ @@ -36157,27 +38614,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12 __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_FactoryAggregate); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_174495485); - __Pyx_GIVEREF(__pyx_int_174495485); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_174495485); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_170282226); + __Pyx_GIVEREF(__pyx_int_170282226); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_170282226); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -36190,7 +38647,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12 /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.FactoryAggregate.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -36204,7 +38661,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_12 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa6696fd, state) + * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa264cf2, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_FactoryAggregate__set_state(self, __pyx_state) */ @@ -36232,7 +38689,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_14 __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa6696fd, state) + * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa264cf2, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_FactoryAggregate__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -36243,7 +38700,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_14 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa6696fd, state) + * return __pyx_unpickle_FactoryAggregate, (type(self), 0xa264cf2, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_FactoryAggregate__set_state(self, __pyx_state) */ @@ -36261,7 +38718,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16FactoryAggregate_14 return __pyx_r; } -/* "dependency_injector/providers.pyx":1931 +/* "dependency_injector/providers.pyx":2037 * provided_type = None * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -36318,7 +38775,7 @@ static int __pyx_pw_19dependency_injector_9providers_13BaseSingleton_1__init__(P } if (unlikely(kw_args > 0)) { const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 1931, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 2037, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { goto __pyx_L5_argtuple_error; @@ -36329,7 +38786,7 @@ static int __pyx_pw_19dependency_injector_9providers_13BaseSingleton_1__init__(P } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1931, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2037, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; @@ -36366,19 +38823,19 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":1937 + /* "dependency_injector/providers.pyx":2043 * :type provides: type * """ * if (self.__class__.provided_type and # <<<<<<<<<<<<<< * not issubclass(provides, self.__class__.provided_type)): * raise Error('{0} can provide only {1} instances'.format( */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1937, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2043, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1937, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2043, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(1, 1937, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(1, 2043, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (__pyx_t_4) { } else { @@ -36386,25 +38843,25 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st goto __pyx_L4_bool_binop_done; } - /* "dependency_injector/providers.pyx":1938 + /* "dependency_injector/providers.pyx":2044 * """ * if (self.__class__.provided_type and * not issubclass(provides, self.__class__.provided_type)): # <<<<<<<<<<<<<< * raise Error('{0} can provide only {1} instances'.format( * self.__class__, self.__class__.provided_type)) */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1938, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2044, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1938, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2044, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_4 = PyObject_IsSubclass(__pyx_v_provides, __pyx_t_2); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(1, 1938, __pyx_L1_error) + __pyx_t_4 = PyObject_IsSubclass(__pyx_v_provides, __pyx_t_2); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(1, 2044, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_5 = ((!(__pyx_t_4 != 0)) != 0); __pyx_t_1 = __pyx_t_5; __pyx_L4_bool_binop_done:; - /* "dependency_injector/providers.pyx":1937 + /* "dependency_injector/providers.pyx":2043 * :type provides: type * """ * if (self.__class__.provided_type and # <<<<<<<<<<<<<< @@ -36413,30 +38870,30 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st */ if (unlikely(__pyx_t_1)) { - /* "dependency_injector/providers.pyx":1939 + /* "dependency_injector/providers.pyx":2045 * if (self.__class__.provided_type and * not issubclass(provides, self.__class__.provided_type)): * raise Error('{0} can provide only {1} instances'.format( # <<<<<<<<<<<<<< * self.__class__, self.__class__.provided_type)) * */ - __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_Error); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1939, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_Error); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2045, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_provide_only_1_instances, __pyx_n_s_format); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1939, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_provide_only_1_instances, __pyx_n_s_format); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 2045, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - /* "dependency_injector/providers.pyx":1940 + /* "dependency_injector/providers.pyx":2046 * not issubclass(provides, self.__class__.provided_type)): * raise Error('{0} can provide only {1} instances'.format( * self.__class__, self.__class__.provided_type)) # <<<<<<<<<<<<<< * * self.__instantiator = Factory(provides, *args, **kwargs) */ - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1940, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2046, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 1940, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2046, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); - __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 1940, __pyx_L1_error) + __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_provided_type); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 2046, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __pyx_t_9 = NULL; @@ -36454,7 +38911,7 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_t_8, __pyx_t_10}; - __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1939, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2045, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; @@ -36464,7 +38921,7 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_t_8, __pyx_t_10}; - __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1939, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2045, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; @@ -36472,7 +38929,7 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st } else #endif { - __pyx_t_12 = PyTuple_New(2+__pyx_t_11); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 1939, __pyx_L1_error) + __pyx_t_12 = PyTuple_New(2+__pyx_t_11); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 2045, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_12); if (__pyx_t_9) { __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_t_9); __pyx_t_9 = NULL; @@ -36483,7 +38940,7 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st PyTuple_SET_ITEM(__pyx_t_12, 1+__pyx_t_11, __pyx_t_10); __pyx_t_8 = 0; __pyx_t_10 = 0; - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_12, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1939, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_12, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2045, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } @@ -36501,14 +38958,14 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st __pyx_t_2 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_7, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1939, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2045, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __PYX_ERR(1, 1939, __pyx_L1_error) + __PYX_ERR(1, 2045, __pyx_L1_error) - /* "dependency_injector/providers.pyx":1937 + /* "dependency_injector/providers.pyx":2043 * :type provides: type * """ * if (self.__class__.provided_type and # <<<<<<<<<<<<<< @@ -36517,22 +38974,22 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st */ } - /* "dependency_injector/providers.pyx":1942 + /* "dependency_injector/providers.pyx":2048 * self.__class__, self.__class__.provided_type)) * * self.__instantiator = Factory(provides, *args, **kwargs) # <<<<<<<<<<<<<< * * super(BaseSingleton, self).__init__() */ - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1942, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2048, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_provides); __Pyx_GIVEREF(__pyx_v_provides); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_provides); - __pyx_t_3 = PyNumber_Add(__pyx_t_2, __pyx_v_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1942, __pyx_L1_error) + __pyx_t_3 = PyNumber_Add(__pyx_t_2, __pyx_v_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2048, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory), __pyx_t_3, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1942, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory), __pyx_t_3, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2048, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GIVEREF(__pyx_t_2); @@ -36541,14 +38998,14 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st __pyx_v_self->__pyx___instantiator = ((struct __pyx_obj_19dependency_injector_9providers_Factory *)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1944 + /* "dependency_injector/providers.pyx":2050 * self.__instantiator = Factory(provides, *args, **kwargs) * * super(BaseSingleton, self).__init__() # <<<<<<<<<<<<<< * * def __str__(self): */ - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1944, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2050, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)); @@ -36556,10 +39013,10 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_3, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 1944, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2050, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1944, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2050, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -36574,12 +39031,12 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st } __pyx_t_2 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1944, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2050, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1931 + /* "dependency_injector/providers.pyx":2037 * provided_type = None * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -36606,7 +39063,7 @@ static int __pyx_pf_19dependency_injector_9providers_13BaseSingleton___init__(st return __pyx_r; } -/* "dependency_injector/providers.pyx":1946 +/* "dependency_injector/providers.pyx":2052 * super(BaseSingleton, self).__init__() * * def __str__(self): # <<<<<<<<<<<<<< @@ -36641,7 +39098,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_2__st int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":1951 + /* "dependency_injector/providers.pyx":2057 * :rtype: str * """ * return represent_provider(provider=self, # <<<<<<<<<<<<<< @@ -36650,31 +39107,31 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_2__st */ __Pyx_XDECREF(__pyx_r); - /* "dependency_injector/providers.pyx":1952 + /* "dependency_injector/providers.pyx":2058 * """ * return represent_provider(provider=self, * provides=self.__instantiator.cls) # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_cls); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1952, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_cls); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2058, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":1951 + /* "dependency_injector/providers.pyx":2057 * :rtype: str * """ * return represent_provider(provider=self, # <<<<<<<<<<<<<< * provides=self.__instantiator.cls) * */ - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1951, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2057, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1946 + /* "dependency_injector/providers.pyx":2052 * super(BaseSingleton, self).__init__() * * def __str__(self): # <<<<<<<<<<<<<< @@ -36694,7 +39151,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_2__st return __pyx_r; } -/* "dependency_injector/providers.pyx":1954 +/* "dependency_injector/providers.pyx":2060 * provides=self.__instantiator.cls) * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -36734,16 +39191,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4__de int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":1956 + /* "dependency_injector/providers.pyx":2062 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1956, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2062, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1956, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2062, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -36758,13 +39215,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4__de __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1956, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2062, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1957 + /* "dependency_injector/providers.pyx":2063 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -36775,7 +39232,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4__de __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":1958 + /* "dependency_injector/providers.pyx":2064 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -36787,7 +39244,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4__de __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1957 + /* "dependency_injector/providers.pyx":2063 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -36796,19 +39253,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4__de */ } - /* "dependency_injector/providers.pyx":1960 + /* "dependency_injector/providers.pyx":2066 * return copied * * cls = self.cls # <<<<<<<<<<<<<< * if isinstance(cls, Provider): * cls = deepcopy(cls, memo) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_cls); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1960, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_cls); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2066, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_cls = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1961 + /* "dependency_injector/providers.pyx":2067 * * cls = self.cls * if isinstance(cls, Provider): # <<<<<<<<<<<<<< @@ -36819,22 +39276,22 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4__de __pyx_t_5 = (__pyx_t_6 != 0); if (__pyx_t_5) { - /* "dependency_injector/providers.pyx":1962 + /* "dependency_injector/providers.pyx":2068 * cls = self.cls * if isinstance(cls, Provider): * cls = deepcopy(cls, memo) # <<<<<<<<<<<<<< * * copied = self.__class__(cls, */ - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1962, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2068, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_v_cls, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1962, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_v_cls, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2068, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF_SET(__pyx_v_cls, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1961 + /* "dependency_injector/providers.pyx":2067 * * cls = self.cls * if isinstance(cls, Provider): # <<<<<<<<<<<<<< @@ -36843,89 +39300,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4__de */ } - /* "dependency_injector/providers.pyx":1964 + /* "dependency_injector/providers.pyx":2070 * cls = deepcopy(cls, memo) * * copied = self.__class__(cls, # <<<<<<<<<<<<<< * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1964, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2070, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1964, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2070, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_cls); __Pyx_GIVEREF(__pyx_v_cls); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_cls); - /* "dependency_injector/providers.pyx":1965 + /* "dependency_injector/providers.pyx":2071 * * copied = self.__class__(cls, * *deepcopy(self.args, memo), # <<<<<<<<<<<<<< * **deepcopy(self.kwargs, memo)) * copied.set_attributes(**deepcopy(self.attributes, memo)) */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1965, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2071, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1965, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2071, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1965, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2071, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1964 + /* "dependency_injector/providers.pyx":2070 * cls = deepcopy(cls, memo) * * copied = self.__class__(cls, # <<<<<<<<<<<<<< * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) */ - __pyx_t_3 = __Pyx_PySequence_Tuple(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1964, __pyx_L1_error) + __pyx_t_3 = __Pyx_PySequence_Tuple(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2070, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = PyNumber_Add(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1964, __pyx_L1_error) + __pyx_t_4 = PyNumber_Add(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2070, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":1966 + /* "dependency_injector/providers.pyx":2072 * copied = self.__class__(cls, * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) # <<<<<<<<<<<<<< * copied.set_attributes(**deepcopy(self.attributes, memo)) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1966, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2072, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1966, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2072, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1966, __pyx_L1_error) + __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2072, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (unlikely(__pyx_t_8 == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 1966, __pyx_L1_error) + __PYX_ERR(1, 2072, __pyx_L1_error) } if (likely(PyDict_CheckExact(__pyx_t_8))) { - __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1966, __pyx_L1_error) + __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2072, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { - __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1964, __pyx_L1_error) + __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2070, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } - /* "dependency_injector/providers.pyx":1964 + /* "dependency_injector/providers.pyx":2070 * cls = deepcopy(cls, memo) * * copied = self.__class__(cls, # <<<<<<<<<<<<<< * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) */ - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1964, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2070, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -36933,54 +39390,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4__de __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":1967 + /* "dependency_injector/providers.pyx":2073 * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo)) * copied.set_attributes(**deepcopy(self.attributes, memo)) # <<<<<<<<<<<<<< * * self._copy_overridings(copied, memo) */ - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_copied, __pyx_n_s_set_attributes); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1967, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_copied, __pyx_n_s_set_attributes); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2073, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_attributes); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1967, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_attributes); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2073, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1967, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2073, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_4, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1967, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_4, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2073, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 1967, __pyx_L1_error) + __PYX_ERR(1, 2073, __pyx_L1_error) } if (likely(PyDict_CheckExact(__pyx_t_1))) { - __pyx_t_3 = PyDict_Copy(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1967, __pyx_L1_error) + __pyx_t_3 = PyDict_Copy(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2073, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { - __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1967, __pyx_L1_error) + __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2073, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1967, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2073, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1969 + /* "dependency_injector/providers.pyx":2075 * copied.set_attributes(**deepcopy(self.attributes, memo)) * * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 1969, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 1969, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 2075, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2075, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_BaseSingleton *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":1971 + /* "dependency_injector/providers.pyx":2077 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -36992,7 +39449,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4__de __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1954 + /* "dependency_injector/providers.pyx":2060 * provides=self.__instantiator.cls) * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -37017,7 +39474,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4__de return __pyx_r; } -/* "dependency_injector/providers.pyx":1974 +/* "dependency_injector/providers.pyx":2080 * * @property * def cls(self): # <<<<<<<<<<<<<< @@ -37047,7 +39504,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_3cls_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":1976 + /* "dependency_injector/providers.pyx":2082 * def cls(self): * """Return provided type.""" * return self.__instantiator.cls # <<<<<<<<<<<<<< @@ -37055,13 +39512,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_3cls_ * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_cls); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1976, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_cls); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2082, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1974 + /* "dependency_injector/providers.pyx":2080 * * @property * def cls(self): # <<<<<<<<<<<<<< @@ -37080,7 +39537,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_3cls_ return __pyx_r; } -/* "dependency_injector/providers.pyx":1979 +/* "dependency_injector/providers.pyx":2085 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -37110,7 +39567,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4args int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":1981 + /* "dependency_injector/providers.pyx":2087 * def args(self): * """Return positional argument injections.""" * return self.__instantiator.args # <<<<<<<<<<<<<< @@ -37118,13 +39575,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4args * def add_args(self, *args): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1981, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2087, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":1979 + /* "dependency_injector/providers.pyx":2085 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -37143,7 +39600,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_4args return __pyx_r; } -/* "dependency_injector/providers.pyx":1983 +/* "dependency_injector/providers.pyx":2089 * return self.__instantiator.args * * def add_args(self, *args): # <<<<<<<<<<<<<< @@ -37180,21 +39637,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_6add_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_args", 0); - /* "dependency_injector/providers.pyx":1988 + /* "dependency_injector/providers.pyx":2094 * :return: Reference ``self`` * """ * self.__instantiator.add_args(*args) # <<<<<<<<<<<<<< * return self * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_add_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1988, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_add_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2094, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1988, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2094, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1989 + /* "dependency_injector/providers.pyx":2095 * """ * self.__instantiator.add_args(*args) * return self # <<<<<<<<<<<<<< @@ -37206,7 +39663,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_6add_ __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1983 + /* "dependency_injector/providers.pyx":2089 * return self.__instantiator.args * * def add_args(self, *args): # <<<<<<<<<<<<<< @@ -37226,7 +39683,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_6add_ return __pyx_r; } -/* "dependency_injector/providers.pyx":1991 +/* "dependency_injector/providers.pyx":2097 * return self * * def set_args(self, *args): # <<<<<<<<<<<<<< @@ -37263,21 +39720,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_8set_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_args", 0); - /* "dependency_injector/providers.pyx":1998 + /* "dependency_injector/providers.pyx":2104 * :return: Reference ``self`` * """ * self.__instantiator.set_args(*args) # <<<<<<<<<<<<<< * return self * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_set_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1998, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_set_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2104, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1998, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2104, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":1999 + /* "dependency_injector/providers.pyx":2105 * """ * self.__instantiator.set_args(*args) * return self # <<<<<<<<<<<<<< @@ -37289,7 +39746,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_8set_ __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":1991 + /* "dependency_injector/providers.pyx":2097 * return self * * def set_args(self, *args): # <<<<<<<<<<<<<< @@ -37309,7 +39766,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_8set_ return __pyx_r; } -/* "dependency_injector/providers.pyx":2001 +/* "dependency_injector/providers.pyx":2107 * return self * * def clear_args(self): # <<<<<<<<<<<<<< @@ -37342,14 +39799,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_10cle int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_args", 0); - /* "dependency_injector/providers.pyx":2006 + /* "dependency_injector/providers.pyx":2112 * :return: Reference ``self`` * """ * self.__instantiator.clear_args() # <<<<<<<<<<<<<< * return self * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_clear_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2006, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_clear_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2112, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -37363,12 +39820,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_10cle } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2006, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2112, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2007 + /* "dependency_injector/providers.pyx":2113 * """ * self.__instantiator.clear_args() * return self # <<<<<<<<<<<<<< @@ -37380,7 +39837,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_10cle __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2001 + /* "dependency_injector/providers.pyx":2107 * return self * * def clear_args(self): # <<<<<<<<<<<<<< @@ -37401,7 +39858,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_10cle return __pyx_r; } -/* "dependency_injector/providers.pyx":2010 +/* "dependency_injector/providers.pyx":2116 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -37431,7 +39888,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_6kwar int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":2012 + /* "dependency_injector/providers.pyx":2118 * def kwargs(self): * """Return keyword argument injections.""" * return self.__instantiator.kwargs # <<<<<<<<<<<<<< @@ -37439,13 +39896,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_6kwar * def add_kwargs(self, **kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2012, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2118, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2010 + /* "dependency_injector/providers.pyx":2116 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -37464,7 +39921,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_6kwar return __pyx_r; } -/* "dependency_injector/providers.pyx":2014 +/* "dependency_injector/providers.pyx":2120 * return self.__instantiator.kwargs * * def add_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -37507,21 +39964,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_12add int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_kwargs", 0); - /* "dependency_injector/providers.pyx":2019 + /* "dependency_injector/providers.pyx":2125 * :return: Reference ``self`` * """ * self.__instantiator.add_kwargs(**kwargs) # <<<<<<<<<<<<<< * return self * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_add_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2019, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_add_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2125, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2019, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2125, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2020 + /* "dependency_injector/providers.pyx":2126 * """ * self.__instantiator.add_kwargs(**kwargs) * return self # <<<<<<<<<<<<<< @@ -37533,7 +39990,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_12add __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2014 + /* "dependency_injector/providers.pyx":2120 * return self.__instantiator.kwargs * * def add_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -37553,7 +40010,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_12add return __pyx_r; } -/* "dependency_injector/providers.pyx":2022 +/* "dependency_injector/providers.pyx":2128 * return self * * def set_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -37596,21 +40053,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_14set int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_kwargs", 0); - /* "dependency_injector/providers.pyx":2029 + /* "dependency_injector/providers.pyx":2135 * :return: Reference ``self`` * """ * self.__instantiator.set_kwargs(**kwargs) # <<<<<<<<<<<<<< * return self * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_set_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2029, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_set_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2135, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2029, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2135, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2030 + /* "dependency_injector/providers.pyx":2136 * """ * self.__instantiator.set_kwargs(**kwargs) * return self # <<<<<<<<<<<<<< @@ -37622,7 +40079,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_14set __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2022 + /* "dependency_injector/providers.pyx":2128 * return self * * def set_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -37642,7 +40099,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_14set return __pyx_r; } -/* "dependency_injector/providers.pyx":2032 +/* "dependency_injector/providers.pyx":2138 * return self * * def clear_kwargs(self): # <<<<<<<<<<<<<< @@ -37675,14 +40132,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_16cle int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_kwargs", 0); - /* "dependency_injector/providers.pyx":2037 + /* "dependency_injector/providers.pyx":2143 * :return: Reference ``self`` * """ * self.__instantiator.clear_kwargs() # <<<<<<<<<<<<<< * return self * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_clear_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2037, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_clear_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2143, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -37696,12 +40153,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_16cle } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2037, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2143, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2038 + /* "dependency_injector/providers.pyx":2144 * """ * self.__instantiator.clear_kwargs() * return self # <<<<<<<<<<<<<< @@ -37713,7 +40170,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_16cle __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2032 + /* "dependency_injector/providers.pyx":2138 * return self * * def clear_kwargs(self): # <<<<<<<<<<<<<< @@ -37734,7 +40191,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_16cle return __pyx_r; } -/* "dependency_injector/providers.pyx":2041 +/* "dependency_injector/providers.pyx":2147 * * @property * def attributes(self): # <<<<<<<<<<<<<< @@ -37764,7 +40221,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_10att int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":2043 + /* "dependency_injector/providers.pyx":2149 * def attributes(self): * """Return attribute injections.""" * return self.__instantiator.attributes # <<<<<<<<<<<<<< @@ -37772,13 +40229,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_10att * def add_attributes(self, **kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_attributes); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2043, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_attributes); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2149, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2041 + /* "dependency_injector/providers.pyx":2147 * * @property * def attributes(self): # <<<<<<<<<<<<<< @@ -37797,7 +40254,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_10att return __pyx_r; } -/* "dependency_injector/providers.pyx":2045 +/* "dependency_injector/providers.pyx":2151 * return self.__instantiator.attributes * * def add_attributes(self, **kwargs): # <<<<<<<<<<<<<< @@ -37840,21 +40297,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_18add int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_attributes", 0); - /* "dependency_injector/providers.pyx":2050 + /* "dependency_injector/providers.pyx":2156 * :return: Reference ``self`` * """ * self.__instantiator.add_attributes(**kwargs) # <<<<<<<<<<<<<< * return self * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_add_attributes); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2050, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_add_attributes); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2156, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2050, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2156, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2051 + /* "dependency_injector/providers.pyx":2157 * """ * self.__instantiator.add_attributes(**kwargs) * return self # <<<<<<<<<<<<<< @@ -37866,7 +40323,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_18add __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2045 + /* "dependency_injector/providers.pyx":2151 * return self.__instantiator.attributes * * def add_attributes(self, **kwargs): # <<<<<<<<<<<<<< @@ -37886,7 +40343,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_18add return __pyx_r; } -/* "dependency_injector/providers.pyx":2053 +/* "dependency_injector/providers.pyx":2159 * return self * * def set_attributes(self, **kwargs): # <<<<<<<<<<<<<< @@ -37929,21 +40386,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_20set int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_attributes", 0); - /* "dependency_injector/providers.pyx":2060 + /* "dependency_injector/providers.pyx":2166 * :return: Reference ``self`` * """ * self.__instantiator.set_attributes(**kwargs) # <<<<<<<<<<<<<< * return self * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_set_attributes); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2060, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_set_attributes); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2166, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2060, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2166, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2061 + /* "dependency_injector/providers.pyx":2167 * """ * self.__instantiator.set_attributes(**kwargs) * return self # <<<<<<<<<<<<<< @@ -37955,7 +40412,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_20set __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2053 + /* "dependency_injector/providers.pyx":2159 * return self * * def set_attributes(self, **kwargs): # <<<<<<<<<<<<<< @@ -37975,7 +40432,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_20set return __pyx_r; } -/* "dependency_injector/providers.pyx":2063 +/* "dependency_injector/providers.pyx":2169 * return self * * def clear_attributes(self): # <<<<<<<<<<<<<< @@ -38008,14 +40465,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_22cle int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_attributes", 0); - /* "dependency_injector/providers.pyx":2068 + /* "dependency_injector/providers.pyx":2174 * :return: Reference ``self`` * """ * self.__instantiator.clear_attributes() # <<<<<<<<<<<<<< * return self * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_clear_attributes); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2068, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx___instantiator), __pyx_n_s_clear_attributes); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2174, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -38029,12 +40486,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_22cle } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2068, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2174, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2069 + /* "dependency_injector/providers.pyx":2175 * """ * self.__instantiator.clear_attributes() * return self # <<<<<<<<<<<<<< @@ -38046,7 +40503,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_22cle __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2063 + /* "dependency_injector/providers.pyx":2169 * return self * * def clear_attributes(self): # <<<<<<<<<<<<<< @@ -38067,7 +40524,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_22cle return __pyx_r; } -/* "dependency_injector/providers.pyx":2071 +/* "dependency_injector/providers.pyx":2177 * return self * * def reset(self): # <<<<<<<<<<<<<< @@ -38098,20 +40555,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_24res int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset", 0); - /* "dependency_injector/providers.pyx":2076 + /* "dependency_injector/providers.pyx":2182 * :rtype: None * """ * raise NotImplementedError() # <<<<<<<<<<<<<< * - * + * def _async_init_instance(self, future_result, result): */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_builtin_NotImplementedError); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2076, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_builtin_NotImplementedError); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2182, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 2076, __pyx_L1_error) + __PYX_ERR(1, 2182, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2071 + /* "dependency_injector/providers.pyx":2177 * return self * * def reset(self): # <<<<<<<<<<<<<< @@ -38129,6 +40586,310 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_24res return __pyx_r; } +/* "dependency_injector/providers.pyx":2184 + * raise NotImplementedError() + * + * def _async_init_instance(self, future_result, result): # <<<<<<<<<<<<<< + * try: + * instance = result.result() + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_13BaseSingleton_27_async_init_instance(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_13BaseSingleton_27_async_init_instance(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_future_result = 0; + PyObject *__pyx_v_result = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_async_init_instance (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_future_result,&__pyx_n_s_result,0}; + PyObject* values[2] = {0,0}; + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future_result)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + CYTHON_FALLTHROUGH; + case 1: + if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_result)) != 0)) kw_args--; + else { + __Pyx_RaiseArgtupleInvalid("_async_init_instance", 1, 2, 2, 1); __PYX_ERR(1, 2184, __pyx_L3_error) + } + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_async_init_instance") < 0)) __PYX_ERR(1, 2184, __pyx_L3_error) + } + } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { + goto __pyx_L5_argtuple_error; + } else { + values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + } + __pyx_v_future_result = values[0]; + __pyx_v_result = values[1]; + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_async_init_instance", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2184, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.BaseSingleton._async_init_instance", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + __pyx_r = __pyx_pf_19dependency_injector_9providers_13BaseSingleton_26_async_init_instance(((struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *)__pyx_v_self), __pyx_v_future_result, __pyx_v_result); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_26_async_init_instance(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_result) { + PyObject *__pyx_v_instance = NULL; + PyObject *__pyx_v_exception = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; + PyObject *__pyx_t_10 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_async_init_instance", 0); + + /* "dependency_injector/providers.pyx":2185 + * + * def _async_init_instance(self, future_result, result): + * try: # <<<<<<<<<<<<<< + * instance = result.result() + * except Exception as exception: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); + __Pyx_XGOTREF(__pyx_t_1); + __Pyx_XGOTREF(__pyx_t_2); + __Pyx_XGOTREF(__pyx_t_3); + /*try:*/ { + + /* "dependency_injector/providers.pyx":2186 + * def _async_init_instance(self, future_result, result): + * try: + * instance = result.result() # <<<<<<<<<<<<<< + * except Exception as exception: + * self.__storage = None + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_result, __pyx_n_s_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2186, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2186, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_instance = __pyx_t_4; + __pyx_t_4 = 0; + + /* "dependency_injector/providers.pyx":2185 + * + * def _async_init_instance(self, future_result, result): + * try: # <<<<<<<<<<<<<< + * instance = result.result() + * except Exception as exception: + */ + } + + /* "dependency_injector/providers.pyx":2191 + * future_result.set_exception(exception) + * else: + * self.__storage = instance # <<<<<<<<<<<<<< + * future_result.set_result(instance) + * + */ + /*else:*/ { + __Pyx_INCREF(__pyx_v_instance); + __Pyx_GIVEREF(__pyx_v_instance); + __Pyx_GOTREF(__pyx_v_self->__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx___storage); + __pyx_v_self->__pyx___storage = __pyx_v_instance; + + /* "dependency_injector/providers.pyx":2192 + * else: + * self.__storage = instance + * future_result.set_result(instance) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2192, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2192, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + } + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + goto __pyx_L8_try_end; + __pyx_L3_error:; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + + /* "dependency_injector/providers.pyx":2187 + * try: + * instance = result.result() + * except Exception as exception: # <<<<<<<<<<<<<< + * self.__storage = None + * future_result.set_exception(exception) + */ + __pyx_t_7 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0]))); + if (__pyx_t_7) { + __Pyx_AddTraceback("dependency_injector.providers.BaseSingleton._async_init_instance", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_5, &__pyx_t_6) < 0) __PYX_ERR(1, 2187, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_GOTREF(__pyx_t_5); + __Pyx_GOTREF(__pyx_t_6); + __Pyx_INCREF(__pyx_t_5); + __pyx_v_exception = __pyx_t_5; + + /* "dependency_injector/providers.pyx":2188 + * instance = result.result() + * except Exception as exception: + * self.__storage = None # <<<<<<<<<<<<<< + * future_result.set_exception(exception) + * else: + */ + __Pyx_INCREF(Py_None); + __Pyx_GIVEREF(Py_None); + __Pyx_GOTREF(__pyx_v_self->__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx___storage); + __pyx_v_self->__pyx___storage = Py_None; + + /* "dependency_injector/providers.pyx":2189 + * except Exception as exception: + * self.__storage = None + * future_result.set_exception(exception) # <<<<<<<<<<<<<< + * else: + * self.__storage = instance + */ + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_exception); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2189, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_9); + __pyx_t_10 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_9))) { + __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_9); + if (likely(__pyx_t_10)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9); + __Pyx_INCREF(__pyx_t_10); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_9, function); + } + } + __pyx_t_8 = (__pyx_t_10) ? __Pyx_PyObject_Call2Args(__pyx_t_9, __pyx_t_10, __pyx_v_exception) : __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_exception); + __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; + if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2189, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + goto __pyx_L4_exception_handled; + } + goto __pyx_L5_except_error; + __pyx_L5_except_error:; + + /* "dependency_injector/providers.pyx":2185 + * + * def _async_init_instance(self, future_result, result): + * try: # <<<<<<<<<<<<<< + * instance = result.result() + * except Exception as exception: + */ + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L1_error; + __pyx_L4_exception_handled:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + __pyx_L8_try_end:; + } + + /* "dependency_injector/providers.pyx":2184 + * raise NotImplementedError() + * + * def _async_init_instance(self, future_result, result): # <<<<<<<<<<<<<< + * try: + * instance = result.result() + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); + __Pyx_XDECREF(__pyx_t_10); + __Pyx_AddTraceback("dependency_injector.providers.BaseSingleton._async_init_instance", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_exception); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + /* "(tree fragment)":1 * def __reduce_cython__(self): # <<<<<<<<<<<<<< * cdef tuple state @@ -38136,28 +40897,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_24res */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_13BaseSingleton_27__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_13BaseSingleton_27__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { +static PyObject *__pyx_pw_19dependency_injector_9providers_13BaseSingleton_29__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_13BaseSingleton_29__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_13BaseSingleton_26__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *)__pyx_v_self)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_13BaseSingleton_28__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_26__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self) { +static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_28__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self) { PyObject *__pyx_v_state = 0; PyObject *__pyx_v__dict = 0; int __pyx_v_use_setstate; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -38168,46 +40929,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_26__r /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx___overridden); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___overridden); + __Pyx_INCREF(__pyx_v_self->__pyx___storage); + __Pyx_GIVEREF(__pyx_v_self->__pyx___storage); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx___storage); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -38216,28 +40985,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_26__r * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: * state += (_dict,) * use_setstate = True # <<<<<<<<<<<<<< * else: - * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None + * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None */ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -38249,92 +41018,99 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_26__r /* "(tree fragment)":11 * use_setstate = True * else: - * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< + * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_BaseSingleton, (type(self), 0x0c49df0, None), state + * return __pyx_unpickle_BaseSingleton, (type(self), 0xce4d239, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx___instantiator) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx___instantiator) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); + if (!__pyx_t_5) { + } else { + __pyx_t_4 = __pyx_t_5; + goto __pyx_L4_bool_binop_done; + } + __pyx_t_5 = (__pyx_v_self->__pyx___storage != Py_None); + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; /* "(tree fragment)":12 * else: - * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None + * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_BaseSingleton, (type(self), 0x0c49df0, None), state + * return __pyx_unpickle_BaseSingleton, (type(self), 0xce4d239, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 - * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None + * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: - * return __pyx_unpickle_BaseSingleton, (type(self), 0x0c49df0, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_BaseSingleton, (type(self), 0xce4d239, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_BaseSingleton, (type(self), 0x0c49df0, state) + * return __pyx_unpickle_BaseSingleton, (type(self), 0xce4d239, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_BaseSingleton); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_BaseSingleton); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_12885488); - __Pyx_GIVEREF(__pyx_int_12885488); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_12885488); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: - * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None + * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_BaseSingleton, (type(self), 0x0c49df0, None), state + * return __pyx_unpickle_BaseSingleton, (type(self), 0xce4d239, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_BaseSingleton, (type(self), 0x0c49df0, None), state + * return __pyx_unpickle_BaseSingleton, (type(self), 0xce4d239, None), state * else: - * return __pyx_unpickle_BaseSingleton, (type(self), 0x0c49df0, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_BaseSingleton, (type(self), 0xce4d239, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_BaseSingleton__set_state(self, __pyx_state) */ @@ -38342,27 +41118,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_26__r __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_BaseSingleton); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_12885488); - __Pyx_GIVEREF(__pyx_int_12885488); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_12885488); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -38375,7 +41151,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_26__r /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.BaseSingleton.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -38389,25 +41165,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_26__r /* "(tree fragment)":16 * else: - * return __pyx_unpickle_BaseSingleton, (type(self), 0x0c49df0, state) + * return __pyx_unpickle_BaseSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_BaseSingleton__set_state(self, __pyx_state) */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_13BaseSingleton_29__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_13BaseSingleton_29__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pw_19dependency_injector_9providers_13BaseSingleton_31__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_13BaseSingleton_31__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_13BaseSingleton_28__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_13BaseSingleton_30__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_28__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_30__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -38417,7 +41193,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_28__s __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_BaseSingleton, (type(self), 0x0c49df0, state) + * return __pyx_unpickle_BaseSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_BaseSingleton__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -38428,7 +41204,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_28__s /* "(tree fragment)":16 * else: - * return __pyx_unpickle_BaseSingleton, (type(self), 0x0c49df0, state) + * return __pyx_unpickle_BaseSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_BaseSingleton__set_state(self, __pyx_state) */ @@ -38446,7 +41222,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_13BaseSingleton_28__s return __pyx_r; } -/* "dependency_injector/providers.pyx":2111 +/* "dependency_injector/providers.pyx":2227 * """ * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -38503,7 +41279,7 @@ static int __pyx_pw_19dependency_injector_9providers_9Singleton_1__init__(PyObje } if (unlikely(kw_args > 0)) { const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 2111, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 2227, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { goto __pyx_L5_argtuple_error; @@ -38514,7 +41290,7 @@ static int __pyx_pw_19dependency_injector_9providers_9Singleton_1__init__(PyObje } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2111, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2227, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; @@ -38542,7 +41318,7 @@ static int __pyx_pf_19dependency_injector_9providers_9Singleton___init__(struct int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":2117 + /* "dependency_injector/providers.pyx":2233 * :type provides: type * """ * self.__storage = None # <<<<<<<<<<<<<< @@ -38551,18 +41327,18 @@ static int __pyx_pf_19dependency_injector_9providers_9Singleton___init__(struct */ __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - __Pyx_GOTREF(__pyx_v_self->__pyx___storage); - __Pyx_DECREF(__pyx_v_self->__pyx___storage); - __pyx_v_self->__pyx___storage = Py_None; + __Pyx_GOTREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___storage); + __pyx_v_self->__pyx_base.__pyx___storage = Py_None; - /* "dependency_injector/providers.pyx":2118 + /* "dependency_injector/providers.pyx":2234 * """ * self.__storage = None * super(Singleton, self).__init__(provides, *args, **kwargs) # <<<<<<<<<<<<<< * * def reset(self): */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2118, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2234, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Singleton)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Singleton)); @@ -38570,27 +41346,27 @@ static int __pyx_pf_19dependency_injector_9providers_9Singleton___init__(struct __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2118, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2234, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2118, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2234, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2118, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2234, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_provides); __Pyx_GIVEREF(__pyx_v_provides); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_provides); - __pyx_t_3 = PyNumber_Add(__pyx_t_2, __pyx_v_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2118, __pyx_L1_error) + __pyx_t_3 = PyNumber_Add(__pyx_t_2, __pyx_v_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2234, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2118, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2234, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2111 + /* "dependency_injector/providers.pyx":2227 * """ * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -38612,7 +41388,7 @@ static int __pyx_pf_19dependency_injector_9providers_9Singleton___init__(struct return __pyx_r; } -/* "dependency_injector/providers.pyx":2120 +/* "dependency_injector/providers.pyx":2236 * super(Singleton, self).__init__(provides, *args, **kwargs) * * def reset(self): # <<<<<<<<<<<<<< @@ -38637,22 +41413,99 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_9Singleton_3reset(PyO static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_2reset(struct __pyx_obj_19dependency_injector_9providers_Singleton *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_t_2; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset", 0); - /* "dependency_injector/providers.pyx":2125 + /* "dependency_injector/providers.pyx":2241 * :rtype: None * """ + * if __isawaitable(self.__storage): # <<<<<<<<<<<<<< + * asyncio.ensure_future(self.__storage).cancel() + * self.__storage = None + */ + __pyx_t_1 = __pyx_v_self->__pyx_base.__pyx___storage; + __Pyx_INCREF(__pyx_t_1); + __pyx_t_2 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_t_1) != 0); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":2242 + * """ + * if __isawaitable(self.__storage): + * asyncio.ensure_future(self.__storage).cancel() # <<<<<<<<<<<<<< + * self.__storage = None + * + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2242, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2242, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_v_self->__pyx_base.__pyx___storage) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2242, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_cancel); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2242, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2242, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":2241 + * :rtype: None + * """ + * if __isawaitable(self.__storage): # <<<<<<<<<<<<<< + * asyncio.ensure_future(self.__storage).cancel() + * self.__storage = None + */ + } + + /* "dependency_injector/providers.pyx":2243 + * if __isawaitable(self.__storage): + * asyncio.ensure_future(self.__storage).cancel() * self.__storage = None # <<<<<<<<<<<<<< * * cpdef object _provide(self, tuple args, dict kwargs): */ __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - __Pyx_GOTREF(__pyx_v_self->__pyx___storage); - __Pyx_DECREF(__pyx_v_self->__pyx___storage); - __pyx_v_self->__pyx___storage = Py_None; + __Pyx_GOTREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___storage); + __pyx_v_self->__pyx_base.__pyx___storage = Py_None; - /* "dependency_injector/providers.pyx":2120 + /* "dependency_injector/providers.pyx":2236 * super(Singleton, self).__init__(provides, *args, **kwargs) * * def reset(self): # <<<<<<<<<<<<<< @@ -38662,12 +41515,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_2reset(str /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_AddTraceback("dependency_injector.providers.Singleton.reset", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "dependency_injector/providers.pyx":2127 +/* "dependency_injector/providers.pyx":2245 * self.__storage = None * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -38677,6 +41539,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_2reset(str static PyObject *__pyx_pw_19dependency_injector_9providers_9Singleton_5_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_9Singleton__provide(struct __pyx_obj_19dependency_injector_9providers_Singleton *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch) { + PyObject *__pyx_v_instance = NULL; + PyObject *__pyx_v_future_result = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -38687,6 +41551,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Singleton__provide(st PyObject *__pyx_t_6 = NULL; int __pyx_t_7; int __pyx_t_8; + PyObject *__pyx_t_9 = NULL; + PyObject *__pyx_t_10 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -38700,7 +41566,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Singleton__provide(st if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2127, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_9Singleton_5_provide)) { __Pyx_XDECREF(__pyx_r); @@ -38720,7 +41586,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Singleton__provide(st #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2127, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2245, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -38728,13 +41594,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Singleton__provide(st #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2127, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2245, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2127, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -38745,7 +41611,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Singleton__provide(st __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2127, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -38768,73 +41634,252 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Singleton__provide(st #endif } - /* "dependency_injector/providers.pyx":2129 + /* "dependency_injector/providers.pyx":2247 * cpdef object _provide(self, tuple args, dict kwargs): * """Return single instance.""" * if self.__storage is None: # <<<<<<<<<<<<<< - * self.__storage = __factory_call(self.__instantiator, - * args, kwargs) + * instance = __factory_call(self.__instantiator, args, kwargs) + * */ - __pyx_t_7 = (__pyx_v_self->__pyx___storage == Py_None); + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx___storage == Py_None); __pyx_t_8 = (__pyx_t_7 != 0); if (__pyx_t_8) { - /* "dependency_injector/providers.pyx":2130 + /* "dependency_injector/providers.pyx":2248 * """Return single instance.""" * if self.__storage is None: - * self.__storage = __factory_call(self.__instantiator, # <<<<<<<<<<<<<< - * args, kwargs) - * return self.__storage + * instance = __factory_call(self.__instantiator, args, kwargs) # <<<<<<<<<<<<<< + * + * if __isawaitable(instance): */ __pyx_t_1 = ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator); __Pyx_INCREF(__pyx_t_1); - - /* "dependency_injector/providers.pyx":2131 - * if self.__storage is None: - * self.__storage = __factory_call(self.__instantiator, - * args, kwargs) # <<<<<<<<<<<<<< - * return self.__storage - * - */ - __pyx_t_2 = __pyx_f_19dependency_injector_9providers___factory_call(((struct __pyx_obj_19dependency_injector_9providers_Factory *)__pyx_t_1), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2130, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers___factory_call(((struct __pyx_obj_19dependency_injector_9providers_Factory *)__pyx_t_1), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2248, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - - /* "dependency_injector/providers.pyx":2130 - * """Return single instance.""" - * if self.__storage is None: - * self.__storage = __factory_call(self.__instantiator, # <<<<<<<<<<<<<< - * args, kwargs) - * return self.__storage - */ - __Pyx_GIVEREF(__pyx_t_2); - __Pyx_GOTREF(__pyx_v_self->__pyx___storage); - __Pyx_DECREF(__pyx_v_self->__pyx___storage); - __pyx_v_self->__pyx___storage = __pyx_t_2; + __pyx_v_instance = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2129 + /* "dependency_injector/providers.pyx":2250 + * instance = __factory_call(self.__instantiator, args, kwargs) + * + * if __isawaitable(instance): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) + */ + __pyx_t_8 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_instance) != 0); + if (__pyx_t_8) { + + /* "dependency_injector/providers.pyx":2251 + * + * if __isawaitable(instance): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * instance = asyncio.ensure_future(instance) + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + */ + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2251, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_Future); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2251, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_1 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_1 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_1)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_1); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_2 = (__pyx_t_1) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_1) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2251, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_future_result = __pyx_t_2; + __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2252 + * if __isawaitable(instance): + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) # <<<<<<<<<<<<<< + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + * self.__storage = future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2252, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2252, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_1, function); + } + } + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_3, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2252, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF_SET(__pyx_v_instance, __pyx_t_2); + __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2253 + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) # <<<<<<<<<<<<<< + * self.__storage = future_result + * return future_result + */ + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_instance, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2253, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_functools); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2253, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_partial); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2253, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_async_init_instance); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2253, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_9 = NULL; + __pyx_t_5 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_9); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + __pyx_t_5 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_4)) { + PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_t_6, __pyx_v_future_result}; + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2253, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { + PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_t_6, __pyx_v_future_result}; + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2253, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + { + __pyx_t_10 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 2253, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_10); + if (__pyx_t_9) { + __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_9); __pyx_t_9 = NULL; + } + __Pyx_GIVEREF(__pyx_t_6); + PyTuple_SET_ITEM(__pyx_t_10, 0+__pyx_t_5, __pyx_t_6); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_5, __pyx_v_future_result); + __pyx_t_6 = 0; + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_10, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2253, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; + } + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_1, function); + } + } + __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2253, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2254 + * instance = asyncio.ensure_future(instance) + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + * self.__storage = future_result # <<<<<<<<<<<<<< + * return future_result + * + */ + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + __Pyx_GOTREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___storage); + __pyx_v_self->__pyx_base.__pyx___storage = __pyx_v_future_result; + + /* "dependency_injector/providers.pyx":2255 + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + * self.__storage = future_result + * return future_result # <<<<<<<<<<<<<< + * + * self.__storage = instance + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":2250 + * instance = __factory_call(self.__instantiator, args, kwargs) + * + * if __isawaitable(instance): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) + */ + } + + /* "dependency_injector/providers.pyx":2257 + * return future_result + * + * self.__storage = instance # <<<<<<<<<<<<<< + * + * return self.__storage + */ + __Pyx_INCREF(__pyx_v_instance); + __Pyx_GIVEREF(__pyx_v_instance); + __Pyx_GOTREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___storage); + __pyx_v_self->__pyx_base.__pyx___storage = __pyx_v_instance; + + /* "dependency_injector/providers.pyx":2247 * cpdef object _provide(self, tuple args, dict kwargs): * """Return single instance.""" * if self.__storage is None: # <<<<<<<<<<<<<< - * self.__storage = __factory_call(self.__instantiator, - * args, kwargs) + * instance = __factory_call(self.__instantiator, args, kwargs) + * */ } - /* "dependency_injector/providers.pyx":2132 - * self.__storage = __factory_call(self.__instantiator, - * args, kwargs) + /* "dependency_injector/providers.pyx":2259 + * self.__storage = instance + * * return self.__storage # <<<<<<<<<<<<<< * * */ __Pyx_XDECREF(__pyx_r); - __Pyx_INCREF(__pyx_v_self->__pyx___storage); - __pyx_r = __pyx_v_self->__pyx___storage; + __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___storage); + __pyx_r = __pyx_v_self->__pyx_base.__pyx___storage; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2127 + /* "dependency_injector/providers.pyx":2245 * self.__storage = None * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -38849,9 +41894,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Singleton__provide(st __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_9); + __Pyx_XDECREF(__pyx_t_10); __Pyx_AddTraceback("dependency_injector.providers.Singleton._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; + __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_future_result); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; @@ -38892,11 +41941,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_9Singleton_5_provide( case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2127, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2245, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2127, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2245, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -38909,14 +41958,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_9Singleton_5_provide( } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2127, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2245, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Singleton._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2127, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2127, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2245, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2245, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_9Singleton_4_provide(((struct __pyx_obj_19dependency_injector_9providers_Singleton *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -38937,7 +41986,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_4_provide( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_9Singleton__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2127, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_9Singleton__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -38980,9 +42029,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_6__reduce_ PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -38993,49 +42042,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_6__reduce_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - __Pyx_INCREF(__pyx_v_self->__pyx___storage); - __Pyx_GIVEREF(__pyx_v_self->__pyx___storage); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx___storage); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___storage); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx___storage); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -39044,16 +42098,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_6__reduce_ * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -39065,7 +42119,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_6__reduce_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -39079,35 +42133,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_6__reduce_ * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Singleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_Singleton, (type(self), 0xce4d239, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx___storage != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - __pyx_t_3 = __pyx_t_2; + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___storage != Py_None); + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -39115,44 +42169,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_6__reduce_ * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Singleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_Singleton, (type(self), 0xce4d239, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: - * return __pyx_unpickle_Singleton, (type(self), 0x76eb8a2, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Singleton, (type(self), 0xce4d239, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Singleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_Singleton, (type(self), 0xce4d239, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Singleton); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Singleton); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_124696738); - __Pyx_GIVEREF(__pyx_int_124696738); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_124696738); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -39161,15 +42215,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_6__reduce_ * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Singleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_Singleton, (type(self), 0xce4d239, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Singleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_Singleton, (type(self), 0xce4d239, None), state * else: - * return __pyx_unpickle_Singleton, (type(self), 0x76eb8a2, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Singleton, (type(self), 0xce4d239, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Singleton__set_state(self, __pyx_state) */ @@ -39177,27 +42231,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_6__reduce_ __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_Singleton); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_124696738); - __Pyx_GIVEREF(__pyx_int_124696738); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_124696738); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -39210,7 +42264,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_6__reduce_ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.Singleton.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -39224,7 +42278,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_6__reduce_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Singleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_Singleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Singleton__set_state(self, __pyx_state) */ @@ -39252,7 +42306,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_8__setstat __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Singleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_Singleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Singleton__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -39263,7 +42317,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Singleton_8__setstat /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Singleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_Singleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Singleton__set_state(self, __pyx_state) */ @@ -39307,9 +42361,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -39320,49 +42374,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); - __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___storage); - __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___storage); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx_base.__pyx___storage); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); + __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___storage); + __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___storage); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx_base.__pyx___storage); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -39371,16 +42430,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -39392,7 +42451,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -39406,35 +42465,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_DelegatedSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_DelegatedSingleton, (type(self), 0xce4d239, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___storage != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - __pyx_t_3 = __pyx_t_2; + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___storage != Py_None); + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -39442,44 +42501,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_DelegatedSingleton, (type(self), 0xce4d239, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: - * return __pyx_unpickle_DelegatedSingleton, (type(self), 0x76eb8a2, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedSingleton, (type(self), 0xce4d239, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_DelegatedSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_DelegatedSingleton, (type(self), 0xce4d239, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_DelegatedSingleto); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_DelegatedSingleto); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_124696738); - __Pyx_GIVEREF(__pyx_int_124696738); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_124696738); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -39488,15 +42547,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_DelegatedSingleton, (type(self), 0xce4d239, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_DelegatedSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_DelegatedSingleton, (type(self), 0xce4d239, None), state * else: - * return __pyx_unpickle_DelegatedSingleton, (type(self), 0x76eb8a2, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedSingleton, (type(self), 0xce4d239, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedSingleton__set_state(self, __pyx_state) */ @@ -39504,27 +42563,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_DelegatedSingleto); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_124696738); - __Pyx_GIVEREF(__pyx_int_124696738); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_124696738); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -39537,7 +42596,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.DelegatedSingleton.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -39551,7 +42610,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_DelegatedSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedSingleton__set_state(self, __pyx_state) */ @@ -39579,7 +42638,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_DelegatedSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_DelegatedSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedSingleton__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -39590,7 +42649,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_DelegatedSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedSingleton__set_state(self, __pyx_state) */ @@ -39608,7 +42667,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18DelegatedSingleton_ return __pyx_r; } -/* "dependency_injector/providers.pyx":2166 +/* "dependency_injector/providers.pyx":2293 * """ * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -39665,7 +42724,7 @@ static int __pyx_pw_19dependency_injector_9providers_19ThreadSafeSingleton_1__in } if (unlikely(kw_args > 0)) { const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 2166, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 2293, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { goto __pyx_L5_argtuple_error; @@ -39676,7 +42735,7 @@ static int __pyx_pw_19dependency_injector_9providers_19ThreadSafeSingleton_1__in } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2166, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2293, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; @@ -39704,7 +42763,7 @@ static int __pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton___ini int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":2172 + /* "dependency_injector/providers.pyx":2299 * :type provides: type * """ * self.__storage = None # <<<<<<<<<<<<<< @@ -39713,20 +42772,20 @@ static int __pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton___ini */ __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - __Pyx_GOTREF(__pyx_v_self->__pyx___storage); - __Pyx_DECREF(__pyx_v_self->__pyx___storage); - __pyx_v_self->__pyx___storage = Py_None; + __Pyx_GOTREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___storage); + __pyx_v_self->__pyx_base.__pyx___storage = Py_None; - /* "dependency_injector/providers.pyx":2173 + /* "dependency_injector/providers.pyx":2300 * """ * self.__storage = None * self.__storage_lock = self.__class__.storage_lock # <<<<<<<<<<<<<< * super(ThreadSafeSingleton, self).__init__(provides, *args, **kwargs) * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2173, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2300, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_storage_lock); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2173, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_storage_lock); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2300, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GIVEREF(__pyx_t_2); @@ -39735,14 +42794,14 @@ static int __pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton___ini __pyx_v_self->__pyx___storage_lock = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2174 + /* "dependency_injector/providers.pyx":2301 * self.__storage = None * self.__storage_lock = self.__class__.storage_lock * super(ThreadSafeSingleton, self).__init__(provides, *args, **kwargs) # <<<<<<<<<<<<<< * * def reset(self): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2174, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton)); @@ -39750,27 +42809,27 @@ static int __pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton___ini __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2174, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2174, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2174, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_v_provides); __Pyx_GIVEREF(__pyx_v_provides); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_provides); - __pyx_t_3 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2174, __pyx_L1_error) + __pyx_t_3 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_3, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2174, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_3, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2166 + /* "dependency_injector/providers.pyx":2293 * """ * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -39792,7 +42851,7 @@ static int __pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton___ini return __pyx_r; } -/* "dependency_injector/providers.pyx":2176 +/* "dependency_injector/providers.pyx":2303 * super(ThreadSafeSingleton, self).__init__(provides, *args, **kwargs) * * def reset(self): # <<<<<<<<<<<<<< @@ -39824,22 +42883,26 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; + int __pyx_t_8; + PyObject *__pyx_t_9 = NULL; + PyObject *__pyx_t_10 = NULL; + int __pyx_t_11; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset", 0); - /* "dependency_injector/providers.pyx":2181 + /* "dependency_injector/providers.pyx":2308 * :rtype: None * """ * with self.__storage_lock: # <<<<<<<<<<<<<< - * self.__storage = None - * + * if __isawaitable(self.__storage): + * asyncio.ensure_future(self.__storage).cancel() */ /*with:*/ { - __pyx_t_1 = __Pyx_PyObject_LookupSpecial(__pyx_v_self->__pyx___storage_lock, __pyx_n_s_exit); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2181, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_LookupSpecial(__pyx_v_self->__pyx___storage_lock, __pyx_n_s_exit); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_PyObject_LookupSpecial(__pyx_v_self->__pyx___storage_lock, __pyx_n_s_enter); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2181, __pyx_L3_error) + __pyx_t_3 = __Pyx_PyObject_LookupSpecial(__pyx_v_self->__pyx___storage_lock, __pyx_n_s_enter); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2308, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -39853,36 +42916,161 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2181, __pyx_L3_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2308, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /*try:*/ { { - (void)__pyx_t_5; (void)__pyx_t_6; (void)__pyx_t_7; /* mark used */ + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7); + __Pyx_XGOTREF(__pyx_t_5); + __Pyx_XGOTREF(__pyx_t_6); + __Pyx_XGOTREF(__pyx_t_7); /*try:*/ { - /* "dependency_injector/providers.pyx":2182 + /* "dependency_injector/providers.pyx":2309 * """ * with self.__storage_lock: - * self.__storage = None # <<<<<<<<<<<<<< - * - * cpdef object _provide(self, tuple args, dict kwargs): + * if __isawaitable(self.__storage): # <<<<<<<<<<<<<< + * asyncio.ensure_future(self.__storage).cancel() + * self.__storage = None */ - __Pyx_INCREF(Py_None); - __Pyx_GIVEREF(Py_None); - __Pyx_GOTREF(__pyx_v_self->__pyx___storage); - __Pyx_DECREF(__pyx_v_self->__pyx___storage); - __pyx_v_self->__pyx___storage = Py_None; + __pyx_t_2 = __pyx_v_self->__pyx_base.__pyx___storage; + __Pyx_INCREF(__pyx_t_2); + __pyx_t_8 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_t_2) != 0); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + if (__pyx_t_8) { - /* "dependency_injector/providers.pyx":2181 - * :rtype: None - * """ - * with self.__storage_lock: # <<<<<<<<<<<<<< + /* "dependency_injector/providers.pyx":2310 + * with self.__storage_lock: + * if __isawaitable(self.__storage): + * asyncio.ensure_future(self.__storage).cancel() # <<<<<<<<<<<<<< * self.__storage = None * + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2310, __pyx_L7_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2310, __pyx_L7_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_9))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_9); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_9, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_9, __pyx_t_4, __pyx_v_self->__pyx_base.__pyx___storage) : __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2310, __pyx_L7_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_cancel); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2310, __pyx_L7_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_9))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_9, function); + } + } + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_9); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2310, __pyx_L7_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2309 + * """ + * with self.__storage_lock: + * if __isawaitable(self.__storage): # <<<<<<<<<<<<<< + * asyncio.ensure_future(self.__storage).cancel() + * self.__storage = None + */ + } + + /* "dependency_injector/providers.pyx":2311 + * if __isawaitable(self.__storage): + * asyncio.ensure_future(self.__storage).cancel() + * self.__storage = None # <<<<<<<<<<<<<< + * + * + */ + __Pyx_INCREF(Py_None); + __Pyx_GIVEREF(Py_None); + __Pyx_GOTREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___storage); + __pyx_v_self->__pyx_base.__pyx___storage = Py_None; + + /* "dependency_injector/providers.pyx":2308 + * :rtype: None + * """ + * with self.__storage_lock: # <<<<<<<<<<<<<< + * if __isawaitable(self.__storage): + * asyncio.ensure_future(self.__storage).cancel() */ } + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; + goto __pyx_L12_try_end; + __pyx_L7_error:; + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + /*except:*/ { + __Pyx_AddTraceback("dependency_injector.providers.ThreadSafeSingleton.reset", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_2, &__pyx_t_9, &__pyx_t_3) < 0) __PYX_ERR(1, 2308, __pyx_L9_except_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GOTREF(__pyx_t_9); + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_Pack(3, __pyx_t_2, __pyx_t_9, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2308, __pyx_L9_except_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_10 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 2308, __pyx_L9_except_error) + __Pyx_GOTREF(__pyx_t_10); + __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_10); + __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; + if (__pyx_t_8 < 0) __PYX_ERR(1, 2308, __pyx_L9_except_error) + __pyx_t_11 = ((!(__pyx_t_8 != 0)) != 0); + if (__pyx_t_11) { + __Pyx_GIVEREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_9); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ErrRestoreWithState(__pyx_t_2, __pyx_t_9, __pyx_t_3); + __pyx_t_2 = 0; __pyx_t_9 = 0; __pyx_t_3 = 0; + __PYX_ERR(1, 2308, __pyx_L9_except_error) + } + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + goto __pyx_L8_exception_handled; + } + __pyx_L9_except_error:; + __Pyx_XGIVEREF(__pyx_t_5); + __Pyx_XGIVEREF(__pyx_t_6); + __Pyx_XGIVEREF(__pyx_t_7); + __Pyx_ExceptionReset(__pyx_t_5, __pyx_t_6, __pyx_t_7); + goto __pyx_L1_error; + __pyx_L8_exception_handled:; + __Pyx_XGIVEREF(__pyx_t_5); + __Pyx_XGIVEREF(__pyx_t_6); + __Pyx_XGIVEREF(__pyx_t_7); + __Pyx_ExceptionReset(__pyx_t_5, __pyx_t_6, __pyx_t_7); + __pyx_L12_try_end:; } } /*finally:*/ { @@ -39890,7 +43078,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton if (__pyx_t_1) { __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 2181, __pyx_L1_error) + if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 2308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } @@ -39898,14 +43086,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton } __pyx_L6:; } - goto __pyx_L13; + goto __pyx_L17; __pyx_L3_error:; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; goto __pyx_L1_error; - __pyx_L13:; + __pyx_L17:; } - /* "dependency_injector/providers.pyx":2176 + /* "dependency_injector/providers.pyx":2303 * super(ThreadSafeSingleton, self).__init__(provides, *args, **kwargs) * * def reset(self): # <<<<<<<<<<<<<< @@ -39920,6 +43108,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.ThreadSafeSingleton.reset", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -39928,17 +43117,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton return __pyx_r; } -/* "dependency_injector/providers.pyx":2184 - * self.__storage = None +/* "dependency_injector/providers.pyx":2314 + * * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * """Return single instance.""" - * storage = self.__storage + * instance = self.__storage */ static PyObject *__pyx_pw_19dependency_injector_9providers_19ThreadSafeSingleton_5_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton__provide(struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch) { - PyObject *__pyx_v_storage = NULL; + PyObject *__pyx_v_instance = NULL; + PyObject *__pyx_v_future_result = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -39954,6 +43144,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; + PyObject *__pyx_t_14 = NULL; + PyObject *__pyx_t_15 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -39967,7 +43159,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2184, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_19ThreadSafeSingleton_5_provide)) { __Pyx_XDECREF(__pyx_r); @@ -39987,7 +43179,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2184, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2314, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -39995,13 +43187,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2184, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2314, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2184, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -40012,7 +43204,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2184, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -40035,40 +43227,40 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ #endif } - /* "dependency_injector/providers.pyx":2186 + /* "dependency_injector/providers.pyx":2316 * cpdef object _provide(self, tuple args, dict kwargs): * """Return single instance.""" - * storage = self.__storage # <<<<<<<<<<<<<< - * if storage is None: - * with self.__storage_lock: + * instance = self.__storage # <<<<<<<<<<<<<< + * + * if instance is None: */ - __pyx_t_1 = __pyx_v_self->__pyx___storage; + __pyx_t_1 = __pyx_v_self->__pyx_base.__pyx___storage; __Pyx_INCREF(__pyx_t_1); - __pyx_v_storage = __pyx_t_1; + __pyx_v_instance = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2187 - * """Return single instance.""" - * storage = self.__storage - * if storage is None: # <<<<<<<<<<<<<< + /* "dependency_injector/providers.pyx":2318 + * instance = self.__storage + * + * if instance is None: # <<<<<<<<<<<<<< * with self.__storage_lock: * if self.__storage is None: */ - __pyx_t_7 = (__pyx_v_storage == Py_None); + __pyx_t_7 = (__pyx_v_instance == Py_None); __pyx_t_8 = (__pyx_t_7 != 0); if (__pyx_t_8) { - /* "dependency_injector/providers.pyx":2188 - * storage = self.__storage - * if storage is None: + /* "dependency_injector/providers.pyx":2319 + * + * if instance is None: * with self.__storage_lock: # <<<<<<<<<<<<<< * if self.__storage is None: - * self.__storage = __factory_call(self.__instantiator, + * instance = __factory_call(self.__instantiator, args, kwargs) */ /*with:*/ { - __pyx_t_9 = __Pyx_PyObject_LookupSpecial(__pyx_v_self->__pyx___storage_lock, __pyx_n_s_exit); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2188, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_LookupSpecial(__pyx_v_self->__pyx___storage_lock, __pyx_n_s_exit); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2319, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); - __pyx_t_2 = __Pyx_PyObject_LookupSpecial(__pyx_v_self->__pyx___storage_lock, __pyx_n_s_enter); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2188, __pyx_L4_error) + __pyx_t_2 = __Pyx_PyObject_LookupSpecial(__pyx_v_self->__pyx___storage_lock, __pyx_n_s_enter); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2319, __pyx_L4_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -40082,7 +43274,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2188, __pyx_L4_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2319, __pyx_L4_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -40096,78 +43288,245 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ __Pyx_XGOTREF(__pyx_t_12); /*try:*/ { - /* "dependency_injector/providers.pyx":2189 - * if storage is None: + /* "dependency_injector/providers.pyx":2320 + * if instance is None: * with self.__storage_lock: * if self.__storage is None: # <<<<<<<<<<<<<< - * self.__storage = __factory_call(self.__instantiator, - * args, kwargs) + * instance = __factory_call(self.__instantiator, args, kwargs) + * */ - __pyx_t_8 = (__pyx_v_self->__pyx___storage == Py_None); + __pyx_t_8 = (__pyx_v_self->__pyx_base.__pyx___storage == Py_None); __pyx_t_7 = (__pyx_t_8 != 0); if (__pyx_t_7) { - /* "dependency_injector/providers.pyx":2190 + /* "dependency_injector/providers.pyx":2321 * with self.__storage_lock: * if self.__storage is None: - * self.__storage = __factory_call(self.__instantiator, # <<<<<<<<<<<<<< - * args, kwargs) - * storage = self.__storage + * instance = __factory_call(self.__instantiator, args, kwargs) # <<<<<<<<<<<<<< + * + * if __isawaitable(instance): */ __pyx_t_1 = ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator); __Pyx_INCREF(__pyx_t_1); - - /* "dependency_injector/providers.pyx":2191 - * if self.__storage is None: - * self.__storage = __factory_call(self.__instantiator, - * args, kwargs) # <<<<<<<<<<<<<< - * storage = self.__storage - * return storage - */ - __pyx_t_2 = __pyx_f_19dependency_injector_9providers___factory_call(((struct __pyx_obj_19dependency_injector_9providers_Factory *)__pyx_t_1), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2190, __pyx_L8_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers___factory_call(((struct __pyx_obj_19dependency_injector_9providers_Factory *)__pyx_t_1), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2321, __pyx_L8_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - - /* "dependency_injector/providers.pyx":2190 - * with self.__storage_lock: - * if self.__storage is None: - * self.__storage = __factory_call(self.__instantiator, # <<<<<<<<<<<<<< - * args, kwargs) - * storage = self.__storage - */ - __Pyx_GIVEREF(__pyx_t_2); - __Pyx_GOTREF(__pyx_v_self->__pyx___storage); - __Pyx_DECREF(__pyx_v_self->__pyx___storage); - __pyx_v_self->__pyx___storage = __pyx_t_2; + __Pyx_DECREF_SET(__pyx_v_instance, __pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2189 - * if storage is None: + /* "dependency_injector/providers.pyx":2323 + * instance = __factory_call(self.__instantiator, args, kwargs) + * + * if __isawaitable(instance): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) + */ + __pyx_t_7 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_instance) != 0); + if (__pyx_t_7) { + + /* "dependency_injector/providers.pyx":2324 + * + * if __isawaitable(instance): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * instance = asyncio.ensure_future(instance) + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + */ + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2324, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_Future); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2324, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_1 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_1 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_1)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_1); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_2 = (__pyx_t_1) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_1) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2324, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_future_result = __pyx_t_2; + __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2325 + * if __isawaitable(instance): + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) # <<<<<<<<<<<<<< + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + * self.__storage = future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2325, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2325, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_1, function); + } + } + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_3, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2325, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF_SET(__pyx_v_instance, __pyx_t_2); + __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2326 + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) # <<<<<<<<<<<<<< + * self.__storage = future_result + * return future_result + */ + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_instance, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2326, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_functools); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2326, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_partial); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2326, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_async_init_instance); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2326, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_13 = NULL; + __pyx_t_5 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_13)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_13); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + __pyx_t_5 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_4)) { + PyObject *__pyx_temp[3] = {__pyx_t_13, __pyx_t_6, __pyx_v_future_result}; + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2326, __pyx_L8_error) + __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { + PyObject *__pyx_temp[3] = {__pyx_t_13, __pyx_t_6, __pyx_v_future_result}; + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2326, __pyx_L8_error) + __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + { + __pyx_t_14 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 2326, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_14); + if (__pyx_t_13) { + __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_13); __pyx_t_13 = NULL; + } + __Pyx_GIVEREF(__pyx_t_6); + PyTuple_SET_ITEM(__pyx_t_14, 0+__pyx_t_5, __pyx_t_6); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_14, 1+__pyx_t_5, __pyx_v_future_result); + __pyx_t_6 = 0; + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_14, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2326, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; + } + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_1, function); + } + } + __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2326, __pyx_L8_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2327 + * instance = asyncio.ensure_future(instance) + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + * self.__storage = future_result # <<<<<<<<<<<<<< + * return future_result + * + */ + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + __Pyx_GOTREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___storage); + __pyx_v_self->__pyx_base.__pyx___storage = __pyx_v_future_result; + + /* "dependency_injector/providers.pyx":2328 + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + * self.__storage = future_result + * return future_result # <<<<<<<<<<<<<< + * + * self.__storage = instance + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L12_try_return; + + /* "dependency_injector/providers.pyx":2323 + * instance = __factory_call(self.__instantiator, args, kwargs) + * + * if __isawaitable(instance): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) + */ + } + + /* "dependency_injector/providers.pyx":2330 + * return future_result + * + * self.__storage = instance # <<<<<<<<<<<<<< + * + * return instance + */ + __Pyx_INCREF(__pyx_v_instance); + __Pyx_GIVEREF(__pyx_v_instance); + __Pyx_GOTREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___storage); + __pyx_v_self->__pyx_base.__pyx___storage = __pyx_v_instance; + + /* "dependency_injector/providers.pyx":2320 + * if instance is None: * with self.__storage_lock: * if self.__storage is None: # <<<<<<<<<<<<<< - * self.__storage = __factory_call(self.__instantiator, - * args, kwargs) + * instance = __factory_call(self.__instantiator, args, kwargs) + * */ } - /* "dependency_injector/providers.pyx":2192 - * self.__storage = __factory_call(self.__instantiator, - * args, kwargs) - * storage = self.__storage # <<<<<<<<<<<<<< - * return storage + /* "dependency_injector/providers.pyx":2319 * - */ - __pyx_t_2 = __pyx_v_self->__pyx___storage; - __Pyx_INCREF(__pyx_t_2); - __Pyx_DECREF_SET(__pyx_v_storage, __pyx_t_2); - __pyx_t_2 = 0; - - /* "dependency_injector/providers.pyx":2188 - * storage = self.__storage - * if storage is None: + * if instance is None: * with self.__storage_lock: # <<<<<<<<<<<<<< * if self.__storage is None: - * self.__storage = __factory_call(self.__instantiator, + * instance = __factory_call(self.__instantiator, args, kwargs) */ } __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; @@ -40176,26 +43535,28 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ goto __pyx_L13_try_end; __pyx_L8_error:; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; + __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; /*except:*/ { __Pyx_AddTraceback("dependency_injector.providers.ThreadSafeSingleton._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_2, &__pyx_t_1, &__pyx_t_3) < 0) __PYX_ERR(1, 2188, __pyx_L10_except_error) + if (__Pyx_GetException(&__pyx_t_2, &__pyx_t_1, &__pyx_t_3) < 0) __PYX_ERR(1, 2319, __pyx_L10_except_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_3); - __pyx_t_6 = PyTuple_Pack(3, __pyx_t_2, __pyx_t_1, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2188, __pyx_L10_except_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_6, NULL); + __pyx_t_4 = PyTuple_Pack(3, __pyx_t_2, __pyx_t_1, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2319, __pyx_L10_except_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_4, NULL); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 2188, __pyx_L10_except_error) - __Pyx_GOTREF(__pyx_t_13); - __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_t_13); - __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; - if (__pyx_t_7 < 0) __PYX_ERR(1, 2188, __pyx_L10_except_error) + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 2319, __pyx_L10_except_error) + __Pyx_GOTREF(__pyx_t_15); + __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_t_15); + __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; + if (__pyx_t_7 < 0) __PYX_ERR(1, 2319, __pyx_L10_except_error) __pyx_t_8 = ((!(__pyx_t_7 != 0)) != 0); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_2); @@ -40203,7 +43564,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ErrRestoreWithState(__pyx_t_2, __pyx_t_1, __pyx_t_3); __pyx_t_2 = 0; __pyx_t_1 = 0; __pyx_t_3 = 0; - __PYX_ERR(1, 2188, __pyx_L10_except_error) + __PYX_ERR(1, 2319, __pyx_L10_except_error) } __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -40216,6 +43577,12 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ __Pyx_XGIVEREF(__pyx_t_12); __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_11, __pyx_t_12); goto __pyx_L1_error; + __pyx_L12_try_return:; + __Pyx_XGIVEREF(__pyx_t_10); + __Pyx_XGIVEREF(__pyx_t_11); + __Pyx_XGIVEREF(__pyx_t_12); + __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_11, __pyx_t_12); + goto __pyx_L5_return; __pyx_L9_exception_handled:; __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); @@ -40229,48 +43596,62 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ if (__pyx_t_9) { __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 2188, __pyx_L1_error) + if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 2319, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } goto __pyx_L7; } + __pyx_L5_return: { + __pyx_t_12 = __pyx_r; + __pyx_r = 0; + if (__pyx_t_9) { + __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_tuple__2, NULL); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 2319, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_11); + __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; + } + __pyx_r = __pyx_t_12; + __pyx_t_12 = 0; + goto __pyx_L0; + } __pyx_L7:; } - goto __pyx_L18; + goto __pyx_L19; __pyx_L4_error:; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; goto __pyx_L1_error; - __pyx_L18:; + __pyx_L19:; } - /* "dependency_injector/providers.pyx":2187 - * """Return single instance.""" - * storage = self.__storage - * if storage is None: # <<<<<<<<<<<<<< + /* "dependency_injector/providers.pyx":2318 + * instance = self.__storage + * + * if instance is None: # <<<<<<<<<<<<<< * with self.__storage_lock: * if self.__storage is None: */ } - /* "dependency_injector/providers.pyx":2193 - * args, kwargs) - * storage = self.__storage - * return storage # <<<<<<<<<<<<<< + /* "dependency_injector/providers.pyx":2332 + * self.__storage = instance + * + * return instance # <<<<<<<<<<<<<< * * */ __Pyx_XDECREF(__pyx_r); - __Pyx_INCREF(__pyx_v_storage); - __pyx_r = __pyx_v_storage; + __Pyx_INCREF(__pyx_v_instance); + __pyx_r = __pyx_v_instance; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2184 - * self.__storage = None + /* "dependency_injector/providers.pyx":2314 + * * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * """Return single instance.""" - * storage = self.__storage + * instance = self.__storage */ /* function exit code */ @@ -40280,10 +43661,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton_ __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_13); + __Pyx_XDECREF(__pyx_t_14); __Pyx_AddTraceback("dependency_injector.providers.ThreadSafeSingleton._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; - __Pyx_XDECREF(__pyx_v_storage); + __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_future_result); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; @@ -40324,11 +43708,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19ThreadSafeSingleton case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2184, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2314, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2184, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2314, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -40341,14 +43725,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19ThreadSafeSingleton } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2184, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2314, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ThreadSafeSingleton._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2184, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2184, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2314, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2314, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton_4_provide(((struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -40369,7 +43753,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2184, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -40412,9 +43796,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -40425,52 +43809,57 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(5); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - __Pyx_INCREF(__pyx_v_self->__pyx___storage); - __Pyx_GIVEREF(__pyx_v_self->__pyx___storage); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx___storage); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___storage); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx___storage); __Pyx_INCREF(__pyx_v_self->__pyx___storage_lock); __Pyx_GIVEREF(__pyx_v_self->__pyx___storage_lock); - PyTuple_SET_ITEM(__pyx_t_1, 4, __pyx_v_self->__pyx___storage_lock); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 5, __pyx_v_self->__pyx___storage_lock); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -40479,16 +43868,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -40500,7 +43889,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -40514,42 +43903,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None or self.__storage_lock is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0xa5833ef, None), state + * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0x2a56a3c, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx___storage != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___storage != Py_None); + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx___storage_lock != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx___storage_lock != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -40557,44 +43946,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None or self.__storage_lock is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0xa5833ef, None), state + * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0x2a56a3c, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None or self.__storage_lock is not None * if use_setstate: - * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0xa5833ef, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0x2a56a3c, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0xa5833ef, state) + * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0x2a56a3c, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_ThreadSafeSinglet); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_ThreadSafeSinglet); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_173552623); - __Pyx_GIVEREF(__pyx_int_173552623); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_173552623); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_44395068); + __Pyx_GIVEREF(__pyx_int_44395068); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_44395068); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -40603,15 +43992,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None or self.__storage_lock is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0xa5833ef, None), state + * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0x2a56a3c, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0xa5833ef, None), state + * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0x2a56a3c, None), state * else: - * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0xa5833ef, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0x2a56a3c, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ThreadSafeSingleton__set_state(self, __pyx_state) */ @@ -40619,27 +44008,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_ThreadSafeSinglet); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_173552623); - __Pyx_GIVEREF(__pyx_int_173552623); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_173552623); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_44395068); + __Pyx_GIVEREF(__pyx_int_44395068); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_44395068); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -40652,7 +44041,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.ThreadSafeSingleton.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -40666,7 +44055,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0xa5833ef, state) + * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0x2a56a3c, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ThreadSafeSingleton__set_state(self, __pyx_state) */ @@ -40694,7 +44083,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0xa5833ef, state) + * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0x2a56a3c, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ThreadSafeSingleton__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -40705,7 +44094,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19ThreadSafeSingleton /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0xa5833ef, state) + * return __pyx_unpickle_ThreadSafeSingleton, (type(self), 0x2a56a3c, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ThreadSafeSingleton__set_state(self, __pyx_state) */ @@ -40749,9 +44138,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -40762,52 +44151,57 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(5); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); - __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___storage); - __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___storage); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx_base.__pyx___storage); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); + __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___storage); + __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___storage); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx_base.__pyx___storage); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___storage_lock); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___storage_lock); - PyTuple_SET_ITEM(__pyx_t_1, 4, __pyx_v_self->__pyx_base.__pyx___storage_lock); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 5, __pyx_v_self->__pyx_base.__pyx___storage_lock); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -40816,16 +44210,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -40837,7 +44231,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage, self.__storage_lock) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -40851,42 +44245,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None or self.__storage_lock is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0xa5833ef, None), state + * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0x2a56a3c, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___storage != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___storage != Py_None); + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___storage_lock != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___storage_lock != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -40894,44 +44288,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None or self.__storage_lock is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0xa5833ef, None), state + * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0x2a56a3c, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None or self.__storage_lock is not None * if use_setstate: - * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0xa5833ef, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0x2a56a3c, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0xa5833ef, state) + * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0x2a56a3c, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_DelegatedThreadSa); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_DelegatedThreadSa); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_173552623); - __Pyx_GIVEREF(__pyx_int_173552623); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_173552623); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_44395068); + __Pyx_GIVEREF(__pyx_int_44395068); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_44395068); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -40940,15 +44334,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None or self.__storage_lock is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0xa5833ef, None), state + * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0x2a56a3c, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0xa5833ef, None), state + * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0x2a56a3c, None), state * else: - * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0xa5833ef, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0x2a56a3c, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedThreadSafeSingleton__set_state(self, __pyx_state) */ @@ -40956,27 +44350,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_DelegatedThreadSa); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_173552623); - __Pyx_GIVEREF(__pyx_int_173552623); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_173552623); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_44395068); + __Pyx_GIVEREF(__pyx_int_44395068); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_44395068); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -40989,7 +44383,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.DelegatedThreadSafeSingleton.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -41003,7 +44397,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0xa5833ef, state) + * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0x2a56a3c, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedThreadSafeSingleton__set_state(self, __pyx_state) */ @@ -41031,7 +44425,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0xa5833ef, state) + * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0x2a56a3c, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedThreadSafeSingleton__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -41042,7 +44436,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0xa5833ef, state) + * return __pyx_unpickle_DelegatedThreadSafeSingleton, (type(self), 0x2a56a3c, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedThreadSafeSingleton__set_state(self, __pyx_state) */ @@ -41060,7 +44454,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_28DelegatedThreadSafe return __pyx_r; } -/* "dependency_injector/providers.pyx":2237 +/* "dependency_injector/providers.pyx":2376 * """ * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -41117,7 +44511,7 @@ static int __pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_1__i } if (unlikely(kw_args > 0)) { const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 2237, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 2376, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { goto __pyx_L5_argtuple_error; @@ -41128,7 +44522,7 @@ static int __pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_1__i } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2237, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2376, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; @@ -41156,16 +44550,16 @@ static int __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton___in int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":2243 + /* "dependency_injector/providers.pyx":2382 * :type provides: type * """ * self.__storage = threading.local() # <<<<<<<<<<<<<< * super(ThreadLocalSingleton, self).__init__(provides, *args, **kwargs) * */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_threading); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2243, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_threading); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2382, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_local); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2243, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_local); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2382, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -41180,23 +44574,23 @@ static int __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton___in } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2243, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2382, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GIVEREF(__pyx_t_1); - __Pyx_GOTREF(__pyx_v_self->__pyx___storage); - __Pyx_DECREF(__pyx_v_self->__pyx___storage); - __pyx_v_self->__pyx___storage = __pyx_t_1; + __Pyx_GOTREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___storage); + __pyx_v_self->__pyx_base.__pyx___storage = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2244 + /* "dependency_injector/providers.pyx":2383 * """ * self.__storage = threading.local() * super(ThreadLocalSingleton, self).__init__(provides, *args, **kwargs) # <<<<<<<<<<<<<< * * def reset(self): */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2244, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ThreadLocalSingleton)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ThreadLocalSingleton)); @@ -41204,27 +44598,27 @@ static int __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton___in __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2244, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2244, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2244, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v_provides); __Pyx_GIVEREF(__pyx_v_provides); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_provides); - __pyx_t_2 = PyNumber_Add(__pyx_t_3, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2244, __pyx_L1_error) + __pyx_t_2 = PyNumber_Add(__pyx_t_3, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2244, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2237 + /* "dependency_injector/providers.pyx":2376 * """ * * def __init__(self, provides, *args, **kwargs): # <<<<<<<<<<<<<< @@ -41246,7 +44640,7 @@ static int __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton___in return __pyx_r; } -/* "dependency_injector/providers.pyx":2246 +/* "dependency_injector/providers.pyx":2385 * super(ThreadLocalSingleton, self).__init__(provides, *args, **kwargs) * * def reset(self): # <<<<<<<<<<<<<< @@ -41271,21 +44665,99 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleto static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_2reset(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_t_2; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset", 0); - /* "dependency_injector/providers.pyx":2251 + /* "dependency_injector/providers.pyx":2390 * :rtype: None * """ + * if __isawaitable(self.__storage.instance): # <<<<<<<<<<<<<< + * asyncio.ensure_future(self.__storage.instance).cancel() + * del self.__storage.instance + */ + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->__pyx_base.__pyx___storage, __pyx_n_s_instance); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2390, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_t_1) != 0); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":2391 + * """ + * if __isawaitable(self.__storage.instance): + * asyncio.ensure_future(self.__storage.instance).cancel() # <<<<<<<<<<<<<< + * del self.__storage.instance + * + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2391, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2391, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->__pyx_base.__pyx___storage, __pyx_n_s_instance); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2391, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2391, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_cancel); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2391, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2391, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":2390 + * :rtype: None + * """ + * if __isawaitable(self.__storage.instance): # <<<<<<<<<<<<<< + * asyncio.ensure_future(self.__storage.instance).cancel() + * del self.__storage.instance + */ + } + + /* "dependency_injector/providers.pyx":2392 + * if __isawaitable(self.__storage.instance): + * asyncio.ensure_future(self.__storage.instance).cancel() * del self.__storage.instance # <<<<<<<<<<<<<< * * cpdef object _provide(self, tuple args, dict kwargs): */ - if (__Pyx_PyObject_DelAttrStr(__pyx_v_self->__pyx___storage, __pyx_n_s_instance) < 0) __PYX_ERR(1, 2251, __pyx_L1_error) + if (__Pyx_PyObject_DelAttrStr(__pyx_v_self->__pyx_base.__pyx___storage, __pyx_n_s_instance) < 0) __PYX_ERR(1, 2392, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2246 + /* "dependency_injector/providers.pyx":2385 * super(ThreadLocalSingleton, self).__init__(provides, *args, **kwargs) * * def reset(self): # <<<<<<<<<<<<<< @@ -41297,6 +44769,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.ThreadLocalSingleton.reset", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -41305,7 +44782,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto return __pyx_r; } -/* "dependency_injector/providers.pyx":2253 +/* "dependency_injector/providers.pyx":2394 * del self.__storage.instance * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -41316,6 +44793,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_5_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton__provide(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch) { PyObject *__pyx_v_instance = 0; + PyObject *__pyx_v_future_result = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -41327,9 +44805,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; - PyObject *__pyx_t_10 = NULL; + int __pyx_t_10; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; + PyObject *__pyx_t_13 = NULL; + PyObject *__pyx_t_14 = NULL; + PyObject *__pyx_t_15 = NULL; + PyObject *__pyx_t_16 = NULL; + PyObject *__pyx_t_17 = NULL; + PyObject *__pyx_t_18 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -41343,7 +44827,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2253, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2394, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_5_provide)) { __Pyx_XDECREF(__pyx_r); @@ -41363,7 +44847,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2253, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2394, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -41371,13 +44855,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2253, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2394, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2253, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2394, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -41388,7 +44872,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2253, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2394, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -41411,7 +44895,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton #endif } - /* "dependency_injector/providers.pyx":2257 + /* "dependency_injector/providers.pyx":2398 * cdef object instance * * try: # <<<<<<<<<<<<<< @@ -41428,19 +44912,19 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton __Pyx_XGOTREF(__pyx_t_9); /*try:*/ { - /* "dependency_injector/providers.pyx":2258 + /* "dependency_injector/providers.pyx":2399 * * try: * instance = self.__storage.instance # <<<<<<<<<<<<<< * except AttributeError: * instance = __factory_call(self.__instantiator, args, kwargs) */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->__pyx___storage, __pyx_n_s_instance); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2258, __pyx_L6_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->__pyx_base.__pyx___storage, __pyx_n_s_instance); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2399, __pyx_L6_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_instance = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2257 + /* "dependency_injector/providers.pyx":2398 * cdef object instance * * try: # <<<<<<<<<<<<<< @@ -41459,44 +44943,228 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":2259 + /* "dependency_injector/providers.pyx":2400 * try: * instance = self.__storage.instance * except AttributeError: # <<<<<<<<<<<<<< * instance = __factory_call(self.__instantiator, args, kwargs) - * self.__storage.instance = instance + * */ __pyx_t_5 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_AttributeError); if (__pyx_t_5) { __Pyx_AddTraceback("dependency_injector.providers.ThreadLocalSingleton._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3) < 0) __PYX_ERR(1, 2259, __pyx_L8_except_error) + if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3) < 0) __PYX_ERR(1, 2400, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_2); __Pyx_GOTREF(__pyx_t_3); - /* "dependency_injector/providers.pyx":2260 + /* "dependency_injector/providers.pyx":2401 * instance = self.__storage.instance * except AttributeError: * instance = __factory_call(self.__instantiator, args, kwargs) # <<<<<<<<<<<<<< - * self.__storage.instance = instance - * finally: + * + * if __isawaitable(instance): */ __pyx_t_6 = ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator); __Pyx_INCREF(__pyx_t_6); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers___factory_call(((struct __pyx_obj_19dependency_injector_9providers_Factory *)__pyx_t_6), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2260, __pyx_L8_except_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers___factory_call(((struct __pyx_obj_19dependency_injector_9providers_Factory *)__pyx_t_6), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2401, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF_SET(__pyx_v_instance, __pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":2261 - * except AttributeError: + /* "dependency_injector/providers.pyx":2403 * instance = __factory_call(self.__instantiator, args, kwargs) + * + * if __isawaitable(instance): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) + */ + __pyx_t_10 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_instance) != 0); + if (__pyx_t_10) { + + /* "dependency_injector/providers.pyx":2404 + * + * if __isawaitable(instance): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * instance = asyncio.ensure_future(instance) + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + */ + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2404, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_11 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_Future); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 2404, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_11); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_11))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_11); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_11); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_11, function); + } + } + __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_11, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_11); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2404, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; + __pyx_v_future_result = __pyx_t_4; + __pyx_t_4 = 0; + + /* "dependency_injector/providers.pyx":2405 + * if __isawaitable(instance): + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) # <<<<<<<<<<<<<< + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + * self.__storage.instance = future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_11, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 2405, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_11); + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_11, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2405, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; + __pyx_t_11 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { + __pyx_t_11 = PyMethod_GET_SELF(__pyx_t_6); + if (likely(__pyx_t_11)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); + __Pyx_INCREF(__pyx_t_11); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_6, function); + } + } + __pyx_t_4 = (__pyx_t_11) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_11, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2405, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF_SET(__pyx_v_instance, __pyx_t_4); + __pyx_t_4 = 0; + + /* "dependency_injector/providers.pyx":2406 + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) # <<<<<<<<<<<<<< + * self.__storage.instance = future_result + * return future_result + */ + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_instance, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2406, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_GetModuleGlobalName(__pyx_t_12, __pyx_n_s_functools); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 2406, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_12); + __pyx_t_13 = __Pyx_PyObject_GetAttrStr(__pyx_t_12, __pyx_n_s_partial); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 2406, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_13); + __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; + __pyx_t_12 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_async_init_instance); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 2406, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_12); + __pyx_t_14 = NULL; + __pyx_t_5 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_13))) { + __pyx_t_14 = PyMethod_GET_SELF(__pyx_t_13); + if (likely(__pyx_t_14)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_13); + __Pyx_INCREF(__pyx_t_14); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_13, function); + __pyx_t_5 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_13)) { + PyObject *__pyx_temp[3] = {__pyx_t_14, __pyx_t_12, __pyx_v_future_result}; + __pyx_t_11 = __Pyx_PyFunction_FastCall(__pyx_t_13, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 2406, __pyx_L8_except_error) + __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; + __Pyx_GOTREF(__pyx_t_11); + __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_13)) { + PyObject *__pyx_temp[3] = {__pyx_t_14, __pyx_t_12, __pyx_v_future_result}; + __pyx_t_11 = __Pyx_PyCFunction_FastCall(__pyx_t_13, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 2406, __pyx_L8_except_error) + __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; + __Pyx_GOTREF(__pyx_t_11); + __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; + } else + #endif + { + __pyx_t_15 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 2406, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_15); + if (__pyx_t_14) { + __Pyx_GIVEREF(__pyx_t_14); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_14); __pyx_t_14 = NULL; + } + __Pyx_GIVEREF(__pyx_t_12); + PyTuple_SET_ITEM(__pyx_t_15, 0+__pyx_t_5, __pyx_t_12); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_15, 1+__pyx_t_5, __pyx_v_future_result); + __pyx_t_12 = 0; + __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_13, __pyx_t_15, NULL); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 2406, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_11); + __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; + } + __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; + __pyx_t_13 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { + __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_6); + if (likely(__pyx_t_13)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); + __Pyx_INCREF(__pyx_t_13); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_6, function); + } + } + __pyx_t_4 = (__pyx_t_13) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_13, __pyx_t_11) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_11); + __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; + __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2406, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + + /* "dependency_injector/providers.pyx":2407 + * instance = asyncio.ensure_future(instance) + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + * self.__storage.instance = future_result # <<<<<<<<<<<<<< + * return future_result + * + */ + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self->__pyx_base.__pyx___storage, __pyx_n_s_instance, __pyx_v_future_result) < 0) __PYX_ERR(1, 2407, __pyx_L8_except_error) + + /* "dependency_injector/providers.pyx":2408 + * instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + * self.__storage.instance = future_result + * return future_result # <<<<<<<<<<<<<< + * + * self.__storage.instance = instance + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + goto __pyx_L9_except_return; + + /* "dependency_injector/providers.pyx":2403 + * instance = __factory_call(self.__instantiator, args, kwargs) + * + * if __isawaitable(instance): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * instance = asyncio.ensure_future(instance) + */ + } + + /* "dependency_injector/providers.pyx":2410 + * return future_result + * * self.__storage.instance = instance # <<<<<<<<<<<<<< * finally: * return instance */ - if (__Pyx_PyObject_SetAttrStr(__pyx_v_self->__pyx___storage, __pyx_n_s_instance, __pyx_v_instance) < 0) __PYX_ERR(1, 2261, __pyx_L8_except_error) + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self->__pyx_base.__pyx___storage, __pyx_n_s_instance, __pyx_v_instance) < 0) __PYX_ERR(1, 2410, __pyx_L8_except_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -41505,7 +45173,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton goto __pyx_L8_except_error; __pyx_L8_except_error:; - /* "dependency_injector/providers.pyx":2257 + /* "dependency_injector/providers.pyx":2398 * cdef object instance * * try: # <<<<<<<<<<<<<< @@ -41517,6 +45185,12 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton __Pyx_XGIVEREF(__pyx_t_9); __Pyx_ExceptionReset(__pyx_t_7, __pyx_t_8, __pyx_t_9); goto __pyx_L4_error; + __pyx_L9_except_return:; + __Pyx_XGIVEREF(__pyx_t_7); + __Pyx_XGIVEREF(__pyx_t_8); + __Pyx_XGIVEREF(__pyx_t_9); + __Pyx_ExceptionReset(__pyx_t_7, __pyx_t_8, __pyx_t_9); + goto __pyx_L3_return; __pyx_L7_exception_handled:; __Pyx_XGIVEREF(__pyx_t_7); __Pyx_XGIVEREF(__pyx_t_8); @@ -41526,12 +45200,12 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton } } - /* "dependency_injector/providers.pyx":2263 + /* "dependency_injector/providers.pyx":2412 * self.__storage.instance = instance * finally: * return instance # <<<<<<<<<<<<<< * - * + * def _async_init_instance(self, future_result, result): */ /*finally:*/ { /*normal exit:*/{ @@ -41544,55 +45218,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton /*exception exit:*/{ __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign - __pyx_t_9 = 0; __pyx_t_8 = 0; __pyx_t_7 = 0; __pyx_t_10 = 0; __pyx_t_11 = 0; __pyx_t_12 = 0; + __pyx_t_9 = 0; __pyx_t_8 = 0; __pyx_t_7 = 0; __pyx_t_16 = 0; __pyx_t_17 = 0; __pyx_t_18 = 0; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; + __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; + __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; + __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; + __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_10, &__pyx_t_11, &__pyx_t_12); + if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_16, &__pyx_t_17, &__pyx_t_18); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_9, &__pyx_t_8, &__pyx_t_7) < 0)) __Pyx_ErrFetch(&__pyx_t_9, &__pyx_t_8, &__pyx_t_7); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_8); __Pyx_XGOTREF(__pyx_t_7); - __Pyx_XGOTREF(__pyx_t_10); - __Pyx_XGOTREF(__pyx_t_11); - __Pyx_XGOTREF(__pyx_t_12); + __Pyx_XGOTREF(__pyx_t_16); + __Pyx_XGOTREF(__pyx_t_17); + __Pyx_XGOTREF(__pyx_t_18); { __Pyx_XDECREF(__pyx_r); - if (unlikely(!__pyx_v_instance)) { __Pyx_RaiseUnboundLocalError("instance"); __PYX_ERR(1, 2263, __pyx_L15_error) } + if (unlikely(!__pyx_v_instance)) { __Pyx_RaiseUnboundLocalError("instance"); __PYX_ERR(1, 2412, __pyx_L16_error) } __Pyx_INCREF(__pyx_v_instance); __pyx_r = __pyx_v_instance; - goto __pyx_L14_return; + goto __pyx_L15_return; } - __pyx_L14_return:; + __pyx_L15_return:; if (PY_MAJOR_VERSION >= 3) { - __Pyx_XGIVEREF(__pyx_t_10); - __Pyx_XGIVEREF(__pyx_t_11); - __Pyx_XGIVEREF(__pyx_t_12); - __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_11, __pyx_t_12); + __Pyx_XGIVEREF(__pyx_t_16); + __Pyx_XGIVEREF(__pyx_t_17); + __Pyx_XGIVEREF(__pyx_t_18); + __Pyx_ExceptionReset(__pyx_t_16, __pyx_t_17, __pyx_t_18); } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - __pyx_t_10 = 0; __pyx_t_11 = 0; __pyx_t_12 = 0; + __pyx_t_16 = 0; __pyx_t_17 = 0; __pyx_t_18 = 0; goto __pyx_L0; - __pyx_L15_error:; + __pyx_L16_error:; if (PY_MAJOR_VERSION >= 3) { - __Pyx_XGIVEREF(__pyx_t_10); - __Pyx_XGIVEREF(__pyx_t_11); - __Pyx_XGIVEREF(__pyx_t_12); - __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_11, __pyx_t_12); + __Pyx_XGIVEREF(__pyx_t_16); + __Pyx_XGIVEREF(__pyx_t_17); + __Pyx_XGIVEREF(__pyx_t_18); + __Pyx_ExceptionReset(__pyx_t_16, __pyx_t_17, __pyx_t_18); } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - __pyx_t_10 = 0; __pyx_t_11 = 0; __pyx_t_12 = 0; + __pyx_t_16 = 0; __pyx_t_17 = 0; __pyx_t_18 = 0; goto __pyx_L1_error; } + __pyx_L3_return: { + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_instance); + __pyx_r = __pyx_v_instance; + goto __pyx_L0; + } } - /* "dependency_injector/providers.pyx":2253 + /* "dependency_injector/providers.pyx":2394 * del self.__storage.instance * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -41607,10 +45292,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_11); + __Pyx_XDECREF(__pyx_t_12); + __Pyx_XDECREF(__pyx_t_13); + __Pyx_XDECREF(__pyx_t_14); + __Pyx_XDECREF(__pyx_t_15); __Pyx_AddTraceback("dependency_injector.providers.ThreadLocalSingleton._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_future_result); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; @@ -41651,11 +45342,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleto case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2253, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2394, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2253, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2394, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -41668,14 +45359,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleto } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2253, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2394, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ThreadLocalSingleton._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2253, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2253, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2394, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2394, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_4_provide(((struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -41696,7 +45387,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2253, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2394, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -41713,6 +45404,302 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto return __pyx_r; } +/* "dependency_injector/providers.pyx":2414 + * return instance + * + * def _async_init_instance(self, future_result, result): # <<<<<<<<<<<<<< + * try: + * instance = result.result() + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_7_async_init_instance(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_7_async_init_instance(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_future_result = 0; + PyObject *__pyx_v_result = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_async_init_instance (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_future_result,&__pyx_n_s_result,0}; + PyObject* values[2] = {0,0}; + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future_result)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + CYTHON_FALLTHROUGH; + case 1: + if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_result)) != 0)) kw_args--; + else { + __Pyx_RaiseArgtupleInvalid("_async_init_instance", 1, 2, 2, 1); __PYX_ERR(1, 2414, __pyx_L3_error) + } + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_async_init_instance") < 0)) __PYX_ERR(1, 2414, __pyx_L3_error) + } + } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { + goto __pyx_L5_argtuple_error; + } else { + values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + } + __pyx_v_future_result = values[0]; + __pyx_v_result = values[1]; + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_async_init_instance", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2414, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.ThreadLocalSingleton._async_init_instance", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + __pyx_r = __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_6_async_init_instance(((struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *)__pyx_v_self), __pyx_v_future_result, __pyx_v_result); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_6_async_init_instance(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_result) { + PyObject *__pyx_v_instance = NULL; + PyObject *__pyx_v_exception = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; + PyObject *__pyx_t_10 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_async_init_instance", 0); + + /* "dependency_injector/providers.pyx":2415 + * + * def _async_init_instance(self, future_result, result): + * try: # <<<<<<<<<<<<<< + * instance = result.result() + * except Exception as exception: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); + __Pyx_XGOTREF(__pyx_t_1); + __Pyx_XGOTREF(__pyx_t_2); + __Pyx_XGOTREF(__pyx_t_3); + /*try:*/ { + + /* "dependency_injector/providers.pyx":2416 + * def _async_init_instance(self, future_result, result): + * try: + * instance = result.result() # <<<<<<<<<<<<<< + * except Exception as exception: + * del self.__storage.instance + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_result, __pyx_n_s_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2416, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2416, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_instance = __pyx_t_4; + __pyx_t_4 = 0; + + /* "dependency_injector/providers.pyx":2415 + * + * def _async_init_instance(self, future_result, result): + * try: # <<<<<<<<<<<<<< + * instance = result.result() + * except Exception as exception: + */ + } + + /* "dependency_injector/providers.pyx":2421 + * future_result.set_exception(exception) + * else: + * self.__storage.instance = instance # <<<<<<<<<<<<<< + * future_result.set_result(instance) + * + */ + /*else:*/ { + if (__Pyx_PyObject_SetAttrStr(__pyx_v_self->__pyx_base.__pyx___storage, __pyx_n_s_instance, __pyx_v_instance) < 0) __PYX_ERR(1, 2421, __pyx_L5_except_error) + + /* "dependency_injector/providers.pyx":2422 + * else: + * self.__storage.instance = instance + * future_result.set_result(instance) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2422, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2422, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + } + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + goto __pyx_L8_try_end; + __pyx_L3_error:; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + + /* "dependency_injector/providers.pyx":2417 + * try: + * instance = result.result() + * except Exception as exception: # <<<<<<<<<<<<<< + * del self.__storage.instance + * future_result.set_exception(exception) + */ + __pyx_t_7 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0]))); + if (__pyx_t_7) { + __Pyx_AddTraceback("dependency_injector.providers.ThreadLocalSingleton._async_init_instance", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_5, &__pyx_t_6) < 0) __PYX_ERR(1, 2417, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_GOTREF(__pyx_t_5); + __Pyx_GOTREF(__pyx_t_6); + __Pyx_INCREF(__pyx_t_5); + __pyx_v_exception = __pyx_t_5; + + /* "dependency_injector/providers.pyx":2418 + * instance = result.result() + * except Exception as exception: + * del self.__storage.instance # <<<<<<<<<<<<<< + * future_result.set_exception(exception) + * else: + */ + if (__Pyx_PyObject_DelAttrStr(__pyx_v_self->__pyx_base.__pyx___storage, __pyx_n_s_instance) < 0) __PYX_ERR(1, 2418, __pyx_L5_except_error) + + /* "dependency_injector/providers.pyx":2419 + * except Exception as exception: + * del self.__storage.instance + * future_result.set_exception(exception) # <<<<<<<<<<<<<< + * else: + * self.__storage.instance = instance + */ + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_exception); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2419, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_9); + __pyx_t_10 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_9))) { + __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_9); + if (likely(__pyx_t_10)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9); + __Pyx_INCREF(__pyx_t_10); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_9, function); + } + } + __pyx_t_8 = (__pyx_t_10) ? __Pyx_PyObject_Call2Args(__pyx_t_9, __pyx_t_10, __pyx_v_exception) : __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_exception); + __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; + if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2419, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + goto __pyx_L4_exception_handled; + } + goto __pyx_L5_except_error; + __pyx_L5_except_error:; + + /* "dependency_injector/providers.pyx":2415 + * + * def _async_init_instance(self, future_result, result): + * try: # <<<<<<<<<<<<<< + * instance = result.result() + * except Exception as exception: + */ + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L1_error; + __pyx_L4_exception_handled:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + __pyx_L8_try_end:; + } + + /* "dependency_injector/providers.pyx":2414 + * return instance + * + * def _async_init_instance(self, future_result, result): # <<<<<<<<<<<<<< + * try: + * instance = result.result() + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); + __Pyx_XDECREF(__pyx_t_10); + __Pyx_AddTraceback("dependency_injector.providers.ThreadLocalSingleton._async_init_instance", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_exception); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + /* "(tree fragment)":1 * def __reduce_cython__(self): # <<<<<<<<<<<<<< * cdef tuple state @@ -41720,28 +45707,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_7__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_7__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { +static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_9__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_9__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_6__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *)__pyx_v_self)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_8__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_6__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self) { +static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_8__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self) { PyObject *__pyx_v_state = 0; PyObject *__pyx_v__dict = 0; int __pyx_v_use_setstate; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -41752,49 +45739,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - __Pyx_INCREF(__pyx_v_self->__pyx___storage); - __Pyx_GIVEREF(__pyx_v_self->__pyx___storage); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx___storage); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___storage); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx___storage); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -41803,16 +45795,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -41824,7 +45816,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -41838,35 +45830,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0xce4d239, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx___storage != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - __pyx_t_3 = __pyx_t_2; + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___storage != Py_None); + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -41874,44 +45866,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0xce4d239, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: - * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0x76eb8a2, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0xce4d239, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0xce4d239, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_ThreadLocalSingle); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_ThreadLocalSingle); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_124696738); - __Pyx_GIVEREF(__pyx_int_124696738); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_124696738); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -41920,15 +45912,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0xce4d239, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0xce4d239, None), state * else: - * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0x76eb8a2, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0xce4d239, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ThreadLocalSingleton__set_state(self, __pyx_state) */ @@ -41936,27 +45928,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_ThreadLocalSingle); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_124696738); - __Pyx_GIVEREF(__pyx_int_124696738); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_124696738); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -41969,7 +45961,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.ThreadLocalSingleton.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -41983,25 +45975,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ThreadLocalSingleton__set_state(self, __pyx_state) */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_9__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_9__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_11__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_11__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_8__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_10__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_8__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleton_10__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -42011,7 +46003,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ThreadLocalSingleton__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -42022,7 +46014,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20ThreadLocalSingleto /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_ThreadLocalSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ThreadLocalSingleton__set_state(self, __pyx_state) */ @@ -42066,9 +46058,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -42079,49 +46071,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); - __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___storage); - __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___storage); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx_base.__pyx___storage); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden); + __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___storage); + __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___storage); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx_base.__pyx___storage); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -42130,16 +46127,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -42151,7 +46148,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -42165,35 +46162,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0xce4d239, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___instantiator) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___storage != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - __pyx_t_3 = __pyx_t_2; + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___storage != Py_None); + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -42201,44 +46198,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0xce4d239, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: - * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0x76eb8a2, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0xce4d239, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0xce4d239, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_DelegatedThreadLo); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_DelegatedThreadLo); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_124696738); - __Pyx_GIVEREF(__pyx_int_124696738); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_124696738); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -42247,15 +46244,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca * else: * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0xce4d239, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0x76eb8a2, None), state + * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0xce4d239, None), state * else: - * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0x76eb8a2, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0xce4d239, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedThreadLocalSingleton__set_state(self, __pyx_state) */ @@ -42263,27 +46260,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_DelegatedThreadLo); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_124696738); - __Pyx_GIVEREF(__pyx_int_124696738); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_124696738); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -42296,7 +46293,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.DelegatedThreadLocalSingleton.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -42310,7 +46307,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedThreadLocalSingleton__set_state(self, __pyx_state) */ @@ -42338,7 +46335,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_DelegatedThreadLocalSingleton__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -42349,7 +46346,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca /* "(tree fragment)":16 * else: - * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0x76eb8a2, state) + * return __pyx_unpickle_DelegatedThreadLocalSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedThreadLocalSingleton__set_state(self, __pyx_state) */ @@ -42367,7 +46364,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29DelegatedThreadLoca return __pyx_r; } -/* "dependency_injector/providers.pyx":2298 +/* "dependency_injector/providers.pyx":2457 * """ * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -42420,27 +46417,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__call__", 0); - /* "dependency_injector/providers.pyx":2303 + /* "dependency_injector/providers.pyx":2462 * Callable interface implementation. * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) */ __pyx_t_1 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) == Py_None); __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":2304 + /* "dependency_injector/providers.pyx":2463 * """ * if self.__last_overriding is None: * raise Error('{0} must be overridden before calling'.format(self)) # <<<<<<<<<<<<<< - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) * */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2304, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2463, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2304, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2463, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -42454,7 +46451,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton__ } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, ((PyObject *)__pyx_v_self)) : __Pyx_PyObject_CallOneArg(__pyx_t_6, ((PyObject *)__pyx_v_self)); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2304, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2463, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -42470,37 +46467,52 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton__ __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2304, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2463, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 2304, __pyx_L1_error) + __PYX_ERR(1, 2463, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2303 + /* "dependency_injector/providers.pyx":2462 * Callable interface implementation. * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) + * return super().__call__(*args, **kwargs) */ } - /* "dependency_injector/providers.pyx":2305 + /* "dependency_injector/providers.pyx":2464 * if self.__last_overriding is None: * raise Error('{0} must be overridden before calling'.format(self)) - * return self.__last_overriding(*args, **kwargs) # <<<<<<<<<<<<<< + * return super().__call__(*args, **kwargs) # <<<<<<<<<<<<<< * * def override(self, provider): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2305, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2464, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_r = __pyx_t_3; - __pyx_t_3 = 0; + __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractSingleton)); + __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractSingleton)); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractSingleton)); + __Pyx_INCREF(((PyObject *)__pyx_v_self)); + __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); + PyTuple_SET_ITEM(__pyx_t_3, 1, ((PyObject *)__pyx_v_self)); + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_call); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_r = __pyx_t_4; + __pyx_t_4 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2298 + /* "dependency_injector/providers.pyx":2457 * """ * * def __call__(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -42523,8 +46535,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton__ return __pyx_r; } -/* "dependency_injector/providers.pyx":2307 - * return self.__last_overriding(*args, **kwargs) +/* "dependency_injector/providers.pyx":2466 + * return super().__call__(*args, **kwargs) * * def override(self, provider): # <<<<<<<<<<<<<< * """Override provider with another provider. @@ -42562,7 +46574,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/providers.pyx":2318 + /* "dependency_injector/providers.pyx":2477 * :rtype: :py:class:`OverridingContext` * """ * if not isinstance(provider, BaseSingleton): # <<<<<<<<<<<<<< @@ -42573,24 +46585,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 __pyx_t_2 = ((!(__pyx_t_1 != 0)) != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":2319 + /* "dependency_injector/providers.pyx":2478 * """ * if not isinstance(provider, BaseSingleton): * raise Error('{0} must be overridden only by ' # <<<<<<<<<<<<<< * '{1} providers'.format(self, BaseSingleton)) * return super(AbstractSingleton, self).override(provider) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2319, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2478, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "dependency_injector/providers.pyx":2320 + /* "dependency_injector/providers.pyx":2479 * if not isinstance(provider, BaseSingleton): * raise Error('{0} must be overridden only by ' * '{1} providers'.format(self, BaseSingleton)) # <<<<<<<<<<<<<< * return super(AbstractSingleton, self).override(provider) * */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_only_by_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2320, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_only_by_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_8 = 0; @@ -42607,7 +46619,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, ((PyObject *)__pyx_v_self), ((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2320, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2479, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else @@ -42615,13 +46627,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, ((PyObject *)__pyx_v_self), ((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2320, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2479, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2320, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -42632,7 +46644,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2320, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } @@ -42650,14 +46662,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2319, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2478, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 2319, __pyx_L1_error) + __PYX_ERR(1, 2478, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2318 + /* "dependency_injector/providers.pyx":2477 * :rtype: :py:class:`OverridingContext` * """ * if not isinstance(provider, BaseSingleton): # <<<<<<<<<<<<<< @@ -42666,7 +46678,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 */ } - /* "dependency_injector/providers.pyx":2321 + /* "dependency_injector/providers.pyx":2480 * raise Error('{0} must be overridden only by ' * '{1} providers'.format(self, BaseSingleton)) * return super(AbstractSingleton, self).override(provider) # <<<<<<<<<<<<<< @@ -42674,7 +46686,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 * def reset(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2321, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2480, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractSingleton)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AbstractSingleton)); @@ -42682,10 +46694,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2321, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2480, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2321, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_override); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2480, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -42700,15 +46712,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_provider) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_provider); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2321, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2480, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2307 - * return self.__last_overriding(*args, **kwargs) + /* "dependency_injector/providers.pyx":2466 + * return super().__call__(*args, **kwargs) * * def override(self, provider): # <<<<<<<<<<<<<< * """Override provider with another provider. @@ -42731,7 +46743,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_2 return __pyx_r; } -/* "dependency_injector/providers.pyx":2323 +/* "dependency_injector/providers.pyx":2482 * return super(AbstractSingleton, self).override(provider) * * def reset(self): # <<<<<<<<<<<<<< @@ -42768,7 +46780,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_4 int __pyx_clineno = 0; __Pyx_RefNannySetupContext("reset", 0); - /* "dependency_injector/providers.pyx":2328 + /* "dependency_injector/providers.pyx":2487 * :rtype: None * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< @@ -42779,16 +46791,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_4 __pyx_t_2 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":2329 + /* "dependency_injector/providers.pyx":2488 * """ * if self.__last_overriding is None: * raise Error('{0} must be overridden before calling'.format(self)) # <<<<<<<<<<<<<< * return self.__last_overriding.reset() * */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2329, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2329, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -42802,7 +46814,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_4 } __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, ((PyObject *)__pyx_v_self)) : __Pyx_PyObject_CallOneArg(__pyx_t_6, ((PyObject *)__pyx_v_self)); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2329, __pyx_L1_error) + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -42818,14 +46830,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_4 __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2329, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 2329, __pyx_L1_error) + __PYX_ERR(1, 2488, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2328 + /* "dependency_injector/providers.pyx":2487 * :rtype: None * """ * if self.__last_overriding is None: # <<<<<<<<<<<<<< @@ -42834,7 +46846,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_4 */ } - /* "dependency_injector/providers.pyx":2330 + /* "dependency_injector/providers.pyx":2489 * if self.__last_overriding is None: * raise Error('{0} must be overridden before calling'.format(self)) * return self.__last_overriding.reset() # <<<<<<<<<<<<<< @@ -42842,7 +46854,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_4 * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding), __pyx_n_s_reset); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2330, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding), __pyx_n_s_reset); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2489, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -42856,14 +46868,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_4 } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2330, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2489, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2323 + /* "dependency_injector/providers.pyx":2482 * return super(AbstractSingleton, self).override(provider) * * def reset(self): # <<<<<<<<<<<<<< @@ -42912,9 +46924,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_6 PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -42925,46 +46937,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_6 /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator)); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___storage); + __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___storage); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx___storage); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -42973,28 +46993,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_6 * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: * state += (_dict,) * use_setstate = True # <<<<<<<<<<<<<< * else: - * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None + * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None */ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__instantiator, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__instantiator, self.__last_overriding, self.__overridden, self.__storage) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -43006,92 +47026,99 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_6 /* "(tree fragment)":11 * use_setstate = True * else: - * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< + * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_AbstractSingleton, (type(self), 0x0c49df0, None), state + * return __pyx_unpickle_AbstractSingleton, (type(self), 0xce4d239, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___instantiator) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); + if (!__pyx_t_5) { + } else { + __pyx_t_4 = __pyx_t_5; + goto __pyx_L4_bool_binop_done; + } + __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___storage != Py_None); + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; /* "(tree fragment)":12 * else: - * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None + * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_AbstractSingleton, (type(self), 0x0c49df0, None), state + * return __pyx_unpickle_AbstractSingleton, (type(self), 0xce4d239, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 - * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None + * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: - * return __pyx_unpickle_AbstractSingleton, (type(self), 0x0c49df0, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_AbstractSingleton, (type(self), 0xce4d239, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_AbstractSingleton, (type(self), 0x0c49df0, state) + * return __pyx_unpickle_AbstractSingleton, (type(self), 0xce4d239, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_AbstractSingleton); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_AbstractSingleton); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_12885488); - __Pyx_GIVEREF(__pyx_int_12885488); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_12885488); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: - * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None + * use_setstate = self.__instantiator is not None or self.__last_overriding is not None or self.__overridden is not None or self.__storage is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_AbstractSingleton, (type(self), 0x0c49df0, None), state + * return __pyx_unpickle_AbstractSingleton, (type(self), 0xce4d239, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_AbstractSingleton, (type(self), 0x0c49df0, None), state + * return __pyx_unpickle_AbstractSingleton, (type(self), 0xce4d239, None), state * else: - * return __pyx_unpickle_AbstractSingleton, (type(self), 0x0c49df0, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_AbstractSingleton, (type(self), 0xce4d239, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_AbstractSingleton__set_state(self, __pyx_state) */ @@ -43099,27 +47126,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_6 __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_AbstractSingleton); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_12885488); - __Pyx_GIVEREF(__pyx_int_12885488); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_12885488); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_216322617); + __Pyx_GIVEREF(__pyx_int_216322617); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_216322617); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -43132,7 +47159,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_6 /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.AbstractSingleton.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -43146,7 +47173,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_6 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_AbstractSingleton, (type(self), 0x0c49df0, state) + * return __pyx_unpickle_AbstractSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractSingleton__set_state(self, __pyx_state) */ @@ -43174,7 +47201,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_8 __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_AbstractSingleton, (type(self), 0x0c49df0, state) + * return __pyx_unpickle_AbstractSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_AbstractSingleton__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -43185,7 +47212,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_8 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_AbstractSingleton, (type(self), 0x0c49df0, state) + * return __pyx_unpickle_AbstractSingleton, (type(self), 0xce4d239, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractSingleton__set_state(self, __pyx_state) */ @@ -43203,7 +47230,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17AbstractSingleton_8 return __pyx_r; } -/* "dependency_injector/providers.pyx":2343 +/* "dependency_injector/providers.pyx":2502 * """ * * def __init__(self, singleton): # <<<<<<<<<<<<<< @@ -43244,7 +47271,7 @@ static int __pyx_pw_19dependency_injector_9providers_17SingletonDelegate_1__init else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 2343, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 2502, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -43255,7 +47282,7 @@ static int __pyx_pw_19dependency_injector_9providers_17SingletonDelegate_1__init } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2343, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2502, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.SingletonDelegate.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -43286,7 +47313,7 @@ static int __pyx_pf_19dependency_injector_9providers_17SingletonDelegate___init_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":2349 + /* "dependency_injector/providers.pyx":2508 * :type singleton: py:class:`BaseSingleton` * """ * if isinstance(singleton, BaseSingleton) is False: # <<<<<<<<<<<<<< @@ -43297,26 +47324,26 @@ static int __pyx_pf_19dependency_injector_9providers_17SingletonDelegate___init_ __pyx_t_2 = ((__pyx_t_1 == 0) != 0); if (unlikely(__pyx_t_2)) { - /* "dependency_injector/providers.pyx":2350 + /* "dependency_injector/providers.pyx":2509 * """ * if isinstance(singleton, BaseSingleton) is False: * raise Error('{0} can wrap only {1} providers'.format( # <<<<<<<<<<<<<< * self.__class__, BaseSingleton)) * super(SingletonDelegate, self).__init__(singleton) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2350, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_Error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2509, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_wrap_only_1_providers, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2350, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_can_wrap_only_1_providers, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2509, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - /* "dependency_injector/providers.pyx":2351 + /* "dependency_injector/providers.pyx":2510 * if isinstance(singleton, BaseSingleton) is False: * raise Error('{0} can wrap only {1} providers'.format( * self.__class__, BaseSingleton)) # <<<<<<<<<<<<<< * super(SingletonDelegate, self).__init__(singleton) * */ - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 2351, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 2510, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_9 = 0; @@ -43333,7 +47360,7 @@ static int __pyx_pf_19dependency_injector_9providers_17SingletonDelegate___init_ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)}; - __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2350, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2509, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; @@ -43342,14 +47369,14 @@ static int __pyx_pf_19dependency_injector_9providers_17SingletonDelegate___init_ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)}; - __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2350, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2509, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { - __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 2350, __pyx_L1_error) + __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 2509, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_8); __pyx_t_8 = NULL; @@ -43360,7 +47387,7 @@ static int __pyx_pf_19dependency_injector_9providers_17SingletonDelegate___init_ __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)); PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_9, ((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton)); __pyx_t_7 = 0; - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2350, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2509, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } @@ -43378,14 +47405,14 @@ static int __pyx_pf_19dependency_injector_9providers_17SingletonDelegate___init_ __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2350, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2509, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 2350, __pyx_L1_error) + __PYX_ERR(1, 2509, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2349 + /* "dependency_injector/providers.pyx":2508 * :type singleton: py:class:`BaseSingleton` * """ * if isinstance(singleton, BaseSingleton) is False: # <<<<<<<<<<<<<< @@ -43394,14 +47421,14 @@ static int __pyx_pf_19dependency_injector_9providers_17SingletonDelegate___init_ */ } - /* "dependency_injector/providers.pyx":2352 + /* "dependency_injector/providers.pyx":2511 * raise Error('{0} can wrap only {1} providers'.format( * self.__class__, BaseSingleton)) * super(SingletonDelegate, self).__init__(singleton) # <<<<<<<<<<<<<< * * */ - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2352, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2511, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_SingletonDelegate)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_SingletonDelegate)); @@ -43409,10 +47436,10 @@ static int __pyx_pf_19dependency_injector_9providers_17SingletonDelegate___init_ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2352, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2511, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2352, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2511, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -43427,12 +47454,12 @@ static int __pyx_pf_19dependency_injector_9providers_17SingletonDelegate___init_ } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_singleton) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_singleton); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2352, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2511, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2343 + /* "dependency_injector/providers.pyx":2502 * """ * * def __init__(self, singleton): # <<<<<<<<<<<<<< @@ -43484,9 +47511,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_2 PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -43497,46 +47524,51 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_2 /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___provides); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___provides); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx___provides); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___provides); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -43545,16 +47577,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_2 * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -43566,7 +47598,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_2 __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provides) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provides) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -43580,28 +47612,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_2 * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_SingletonDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_SingletonDelegate, (type(self), 0x328787b, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___provides != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -43609,44 +47641,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_2 * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_SingletonDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_SingletonDelegate, (type(self), 0x328787b, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: - * return __pyx_unpickle_SingletonDelegate, (type(self), 0x3f4a3b6, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_SingletonDelegate, (type(self), 0x328787b, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_SingletonDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_SingletonDelegate, (type(self), 0x328787b, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_SingletonDelegate); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_SingletonDelegate); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -43655,15 +47687,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_2 * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provides is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_SingletonDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_SingletonDelegate, (type(self), 0x328787b, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_SingletonDelegate, (type(self), 0x3f4a3b6, None), state + * return __pyx_unpickle_SingletonDelegate, (type(self), 0x328787b, None), state * else: - * return __pyx_unpickle_SingletonDelegate, (type(self), 0x3f4a3b6, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_SingletonDelegate, (type(self), 0x328787b, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_SingletonDelegate__set_state(self, __pyx_state) */ @@ -43671,27 +47703,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_2 __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_SingletonDelegate); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_66364342); - __Pyx_GIVEREF(__pyx_int_66364342); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_66364342); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_52983931); + __Pyx_GIVEREF(__pyx_int_52983931); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_52983931); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -43704,7 +47736,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_2 /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.SingletonDelegate.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -43718,7 +47750,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_2 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_SingletonDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_SingletonDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_SingletonDelegate__set_state(self, __pyx_state) */ @@ -43746,7 +47778,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_4 __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_SingletonDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_SingletonDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_SingletonDelegate__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -43757,7 +47789,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_4 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_SingletonDelegate, (type(self), 0x3f4a3b6, state) + * return __pyx_unpickle_SingletonDelegate, (type(self), 0x328787b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_SingletonDelegate__set_state(self, __pyx_state) */ @@ -43775,7 +47807,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_17SingletonDelegate_4 return __pyx_r; } -/* "dependency_injector/providers.pyx":2385 +/* "dependency_injector/providers.pyx":2544 * """ * * def __init__(self, *args): # <<<<<<<<<<<<<< @@ -43816,14 +47848,14 @@ static int __pyx_pf_19dependency_injector_9providers_4List___init__(struct __pyx int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":2387 + /* "dependency_injector/providers.pyx":2546 * def __init__(self, *args): * """Initializer.""" * self.__args = tuple() # <<<<<<<<<<<<<< * self.__args_len = 0 * self.set_args(*args) */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2387, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2546, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___args); @@ -43831,7 +47863,7 @@ static int __pyx_pf_19dependency_injector_9providers_4List___init__(struct __pyx __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2388 + /* "dependency_injector/providers.pyx":2547 * """Initializer.""" * self.__args = tuple() * self.__args_len = 0 # <<<<<<<<<<<<<< @@ -43840,28 +47872,28 @@ static int __pyx_pf_19dependency_injector_9providers_4List___init__(struct __pyx */ __pyx_v_self->__pyx___args_len = 0; - /* "dependency_injector/providers.pyx":2389 + /* "dependency_injector/providers.pyx":2548 * self.__args = tuple() * self.__args_len = 0 * self.set_args(*args) # <<<<<<<<<<<<<< * super(List, self).__init__() * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_set_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2389, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_set_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2548, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2389, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2548, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2390 + /* "dependency_injector/providers.pyx":2549 * self.__args_len = 0 * self.set_args(*args) * super(List, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2390, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2549, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_List)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_List)); @@ -43869,10 +47901,10 @@ static int __pyx_pf_19dependency_injector_9providers_4List___init__(struct __pyx __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2390, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2549, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2390, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2549, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -43887,12 +47919,12 @@ static int __pyx_pf_19dependency_injector_9providers_4List___init__(struct __pyx } __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2390, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2549, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2385 + /* "dependency_injector/providers.pyx":2544 * """ * * def __init__(self, *args): # <<<<<<<<<<<<<< @@ -43914,7 +47946,7 @@ static int __pyx_pf_19dependency_injector_9providers_4List___init__(struct __pyx return __pyx_r; } -/* "dependency_injector/providers.pyx":2392 +/* "dependency_injector/providers.pyx":2551 * super(List, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -43952,16 +47984,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_2__deepcopy__(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":2394 + /* "dependency_injector/providers.pyx":2553 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2394, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2553, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2394, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2553, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -43976,13 +48008,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_2__deepcopy__(s __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2394, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2553, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2395 + /* "dependency_injector/providers.pyx":2554 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -43993,7 +48025,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_2__deepcopy__(s __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":2396 + /* "dependency_injector/providers.pyx":2555 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -44005,7 +48037,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_2__deepcopy__(s __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2395 + /* "dependency_injector/providers.pyx":2554 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -44014,45 +48046,45 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_2__deepcopy__(s */ } - /* "dependency_injector/providers.pyx":2398 + /* "dependency_injector/providers.pyx":2557 * return copied * * copied = self.__class__(*deepcopy(self.args, memo)) # <<<<<<<<<<<<<< * self._copy_overridings(copied, memo) * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2398, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2557, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2398, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2557, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2398, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2557, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_3 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2398, __pyx_L1_error) + __pyx_t_3 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2557, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PySequence_Tuple(__pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2398, __pyx_L1_error) + __pyx_t_2 = __Pyx_PySequence_Tuple(__pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2557, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2398, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2557, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2399 + /* "dependency_injector/providers.pyx":2558 * * copied = self.__class__(*deepcopy(self.args, memo)) * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 2399, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2399, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 2558, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2558, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_List *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":2401 + /* "dependency_injector/providers.pyx":2560 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -44064,7 +48096,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_2__deepcopy__(s __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2392 + /* "dependency_injector/providers.pyx":2551 * super(List, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -44087,7 +48119,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_2__deepcopy__(s return __pyx_r; } -/* "dependency_injector/providers.pyx":2403 +/* "dependency_injector/providers.pyx":2562 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -44122,7 +48154,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_4__str__(struct int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":2408 + /* "dependency_injector/providers.pyx":2567 * :rtype: str * """ * return represent_provider(provider=self, provides=list(self.args)) # <<<<<<<<<<<<<< @@ -44130,19 +48162,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_4__str__(struct * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2408, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2567, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PySequence_List(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2408, __pyx_L1_error) + __pyx_t_2 = PySequence_List(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2567, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_2, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2408, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_2, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2567, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2403 + /* "dependency_injector/providers.pyx":2562 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -44162,7 +48194,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_4__str__(struct return __pyx_r; } -/* "dependency_injector/providers.pyx":2411 +/* "dependency_injector/providers.pyx":2570 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -44199,19 +48231,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_4args___get__(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":2417 + /* "dependency_injector/providers.pyx":2576 * cdef list args * * args = list() # <<<<<<<<<<<<<< * for index in range(self.__args_len): * arg = self.__args[index] */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2417, __pyx_L1_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2576, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2418 + /* "dependency_injector/providers.pyx":2577 * * args = list() * for index in range(self.__args_len): # <<<<<<<<<<<<<< @@ -44223,7 +48255,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_4args___get__(s for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_index = __pyx_t_4; - /* "dependency_injector/providers.pyx":2419 + /* "dependency_injector/providers.pyx":2578 * args = list() * for index in range(self.__args_len): * arg = self.__args[index] # <<<<<<<<<<<<<< @@ -44232,15 +48264,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_4args___get__(s */ if (unlikely(__pyx_v_self->__pyx___args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 2419, __pyx_L1_error) + __PYX_ERR(1, 2578, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___args, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2419, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___args, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2578, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_PositionalInjection))))) __PYX_ERR(1, 2419, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_PositionalInjection))))) __PYX_ERR(1, 2578, __pyx_L1_error) __Pyx_XDECREF_SET(__pyx_v_arg, ((struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2420 + /* "dependency_injector/providers.pyx":2579 * for index in range(self.__args_len): * arg = self.__args[index] * args.append(arg.__value) # <<<<<<<<<<<<<< @@ -44249,11 +48281,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_4args___get__(s */ __pyx_t_1 = __pyx_v_arg->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_1); - __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_args, __pyx_t_1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 2420, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_args, __pyx_t_1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 2579, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - /* "dependency_injector/providers.pyx":2421 + /* "dependency_injector/providers.pyx":2580 * arg = self.__args[index] * args.append(arg.__value) * return tuple(args) # <<<<<<<<<<<<<< @@ -44261,13 +48293,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_4args___get__(s * def add_args(self, *args): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyList_AsTuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2421, __pyx_L1_error) + __pyx_t_1 = PyList_AsTuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2580, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2411 + /* "dependency_injector/providers.pyx":2570 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -44288,7 +48320,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_4args___get__(s return __pyx_r; } -/* "dependency_injector/providers.pyx":2423 +/* "dependency_injector/providers.pyx":2582 * return tuple(args) * * def add_args(self, *args): # <<<<<<<<<<<<<< @@ -44326,16 +48358,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_6add_args(struc int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_args", 0); - /* "dependency_injector/providers.pyx":2428 + /* "dependency_injector/providers.pyx":2587 * :return: Reference ``self`` * """ * self.__args += parse_positional_injections(args) # <<<<<<<<<<<<<< * self.__args_len = len(self.__args) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2428, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2587, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___args, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2428, __pyx_L1_error) + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___args, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2587, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GIVEREF(__pyx_t_2); @@ -44344,7 +48376,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_6add_args(struc __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2429 + /* "dependency_injector/providers.pyx":2588 * """ * self.__args += parse_positional_injections(args) * self.__args_len = len(self.__args) # <<<<<<<<<<<<<< @@ -44355,13 +48387,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_6add_args(struc __Pyx_INCREF(__pyx_t_2); if (unlikely(__pyx_t_2 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2429, __pyx_L1_error) + __PYX_ERR(1, 2588, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2429, __pyx_L1_error) + __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2588, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_self->__pyx___args_len = __pyx_t_3; - /* "dependency_injector/providers.pyx":2430 + /* "dependency_injector/providers.pyx":2589 * self.__args += parse_positional_injections(args) * self.__args_len = len(self.__args) * return self # <<<<<<<<<<<<<< @@ -44373,7 +48405,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_6add_args(struc __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2423 + /* "dependency_injector/providers.pyx":2582 * return tuple(args) * * def add_args(self, *args): # <<<<<<<<<<<<<< @@ -44393,7 +48425,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_6add_args(struc return __pyx_r; } -/* "dependency_injector/providers.pyx":2432 +/* "dependency_injector/providers.pyx":2591 * return self * * def set_args(self, *args): # <<<<<<<<<<<<<< @@ -44430,14 +48462,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_8set_args(struc int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_args", 0); - /* "dependency_injector/providers.pyx":2439 + /* "dependency_injector/providers.pyx":2598 * :return: Reference ``self`` * """ * self.__args = parse_positional_injections(args) # <<<<<<<<<<<<<< * self.__args_len = len(self.__args) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2439, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2598, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___args); @@ -44445,7 +48477,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_8set_args(struc __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2440 + /* "dependency_injector/providers.pyx":2599 * """ * self.__args = parse_positional_injections(args) * self.__args_len = len(self.__args) # <<<<<<<<<<<<<< @@ -44456,13 +48488,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_8set_args(struc __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2440, __pyx_L1_error) + __PYX_ERR(1, 2599, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2440, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2599, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___args_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":2441 + /* "dependency_injector/providers.pyx":2600 * self.__args = parse_positional_injections(args) * self.__args_len = len(self.__args) * return self # <<<<<<<<<<<<<< @@ -44474,7 +48506,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_8set_args(struc __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2432 + /* "dependency_injector/providers.pyx":2591 * return self * * def set_args(self, *args): # <<<<<<<<<<<<<< @@ -44493,7 +48525,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_8set_args(struc return __pyx_r; } -/* "dependency_injector/providers.pyx":2443 +/* "dependency_injector/providers.pyx":2602 * return self * * def clear_args(self): # <<<<<<<<<<<<<< @@ -44525,14 +48557,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_10clear_args(st int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_args", 0); - /* "dependency_injector/providers.pyx":2448 + /* "dependency_injector/providers.pyx":2607 * :return: Reference ``self`` * """ * self.__args = tuple() # <<<<<<<<<<<<<< * self.__args_len = len(self.__args) * return self */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2448, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2607, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___args); @@ -44540,7 +48572,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_10clear_args(st __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2449 + /* "dependency_injector/providers.pyx":2608 * """ * self.__args = tuple() * self.__args_len = len(self.__args) # <<<<<<<<<<<<<< @@ -44551,13 +48583,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_10clear_args(st __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2449, __pyx_L1_error) + __PYX_ERR(1, 2608, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2449, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2608, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___args_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":2450 + /* "dependency_injector/providers.pyx":2609 * self.__args = tuple() * self.__args_len = len(self.__args) * return self # <<<<<<<<<<<<<< @@ -44569,7 +48601,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_10clear_args(st __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2443 + /* "dependency_injector/providers.pyx":2602 * return self * * def clear_args(self): # <<<<<<<<<<<<<< @@ -44588,7 +48620,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_10clear_args(st return __pyx_r; } -/* "dependency_injector/providers.pyx":2452 +/* "dependency_injector/providers.pyx":2611 * return self * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -44619,7 +48651,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4List__provide(struct if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2452, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2611, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_4List_13_provide)) { __Pyx_XDECREF(__pyx_r); @@ -44639,7 +48671,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4List__provide(struct #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2452, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2611, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -44647,13 +48679,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4List__provide(struct #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2452, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2611, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2452, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2611, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -44664,7 +48696,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4List__provide(struct __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2452, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2611, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -44687,7 +48719,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4List__provide(struct #endif } - /* "dependency_injector/providers.pyx":2454 + /* "dependency_injector/providers.pyx":2613 * cpdef object _provide(self, tuple args, dict kwargs): * """Return result of provided callable's call.""" * return list(__provide_positional_args(args, self.__args, self.__args_len)) # <<<<<<<<<<<<<< @@ -44697,17 +48729,17 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4List__provide(struct __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __pyx_v_self->__pyx___args; __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers___provide_positional_args(__pyx_v_args, ((PyObject*)__pyx_t_1), __pyx_v_self->__pyx___args_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2454, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers___provide_positional_args(__pyx_v_args, ((PyObject*)__pyx_t_1), __pyx_v_self->__pyx___args_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2613, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PySequence_List(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2454, __pyx_L1_error) + __pyx_t_1 = PySequence_List(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2613, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2452 + /* "dependency_injector/providers.pyx":2611 * return self * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -44765,11 +48797,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_4List_13_provide(PyOb case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2452, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2611, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2452, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2611, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -44782,14 +48814,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_4List_13_provide(PyOb } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2452, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2611, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.List._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2452, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2452, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2611, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2611, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_4List_12_provide(((struct __pyx_obj_19dependency_injector_9providers_List *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -44810,7 +48842,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_12_provide(stru int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_4List__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2452, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_4List__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2611, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -44854,10 +48886,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_14__reduce_cyth __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; - int __pyx_t_3; + PyObject *__pyx_t_3 = NULL; int __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -44866,51 +48898,56 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_14__reduce_cyth /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__args, self.__args_len, self.__async_mode, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(5); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v_self->__pyx___args); __Pyx_GIVEREF(__pyx_v_self->__pyx___args); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_self->__pyx___args); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->__pyx___args); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_3, 3, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_3, 4, __pyx_v_self->__pyx_base.__pyx___overridden); __pyx_t_1 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_3); + __pyx_t_3 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__last_overriding, self.__overridden) + * state = (self.__args, self.__args_len, self.__async_mode, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_v__dict = __pyx_t_2; - __pyx_t_2 = 0; + __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_v__dict = __pyx_t_3; + __pyx_t_3 = 0; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__last_overriding, self.__overridden) + * state = (self.__args, self.__args_len, self.__async_mode, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_3 = (__pyx_v__dict != Py_None); - __pyx_t_4 = (__pyx_t_3 != 0); - if (__pyx_t_4) { + __pyx_t_4 = (__pyx_v__dict != Py_None); + __pyx_t_5 = (__pyx_t_4 != 0); + if (__pyx_t_5) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -44919,16 +48956,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_14__reduce_cyth * use_setstate = True * else: */ - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); - __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); - __pyx_t_1 = 0; + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); + __pyx_t_2 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -44940,7 +48977,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_14__reduce_cyth __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__last_overriding, self.__overridden) + * state = (self.__args, self.__args_len, self.__async_mode, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -44954,28 +48991,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_14__reduce_cyth * else: * use_setstate = self.__args is not None or self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_List, (type(self), 0x631cff7, None), state + * return __pyx_unpickle_List, (type(self), 0x42b6146, None), state */ /*else*/ { - __pyx_t_3 = (__pyx_v_self->__pyx___args != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_3 != 0); - if (!__pyx_t_5) { + __pyx_t_4 = (__pyx_v_self->__pyx___args != ((PyObject*)Py_None)); + __pyx_t_6 = (__pyx_t_4 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_4 = __pyx_t_5; + __pyx_t_5 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_3 = (__pyx_t_5 != 0); - if (!__pyx_t_3) { + __pyx_t_6 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_4 = (__pyx_t_6 != 0); + if (!__pyx_t_4) { } else { - __pyx_t_4 = __pyx_t_3; + __pyx_t_5 = __pyx_t_4; goto __pyx_L4_bool_binop_done; } - __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_3 != 0); - __pyx_t_4 = __pyx_t_5; + __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_6 = (__pyx_t_4 != 0); + __pyx_t_5 = __pyx_t_6; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_4; + __pyx_v_use_setstate = __pyx_t_5; } __pyx_L3:; @@ -44983,89 +49020,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_14__reduce_cyth * else: * use_setstate = self.__args is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_List, (type(self), 0x631cff7, None), state + * return __pyx_unpickle_List, (type(self), 0x42b6146, None), state * else: */ - __pyx_t_4 = (__pyx_v_use_setstate != 0); - if (__pyx_t_4) { + __pyx_t_5 = (__pyx_v_use_setstate != 0); + if (__pyx_t_5) { /* "(tree fragment)":13 * use_setstate = self.__args is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: - * return __pyx_unpickle_List, (type(self), 0x631cff7, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_List, (type(self), 0x42b6146, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_List, (type(self), 0x631cff7, state) + * return __pyx_unpickle_List, (type(self), 0x42b6146, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_List); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_List); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_103927799); - __Pyx_GIVEREF(__pyx_int_103927799); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_103927799); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_69951814); + __Pyx_GIVEREF(__pyx_int_69951814); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_69951814); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); - __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); + __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_1 = 0; + PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); __pyx_t_2 = 0; - __pyx_r = __pyx_t_6; - __pyx_t_6 = 0; + __pyx_t_3 = 0; + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__args is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_List, (type(self), 0x631cff7, None), state + * return __pyx_unpickle_List, (type(self), 0x42b6146, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_List, (type(self), 0x631cff7, None), state + * return __pyx_unpickle_List, (type(self), 0x42b6146, None), state * else: - * return __pyx_unpickle_List, (type(self), 0x631cff7, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_List, (type(self), 0x42b6146, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_List__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_List); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_List); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_103927799); - __Pyx_GIVEREF(__pyx_int_103927799); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_103927799); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_69951814); + __Pyx_GIVEREF(__pyx_int_69951814); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_69951814); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); - __pyx_t_6 = 0; - __pyx_t_2 = 0; - __pyx_r = __pyx_t_1; + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); __pyx_t_1 = 0; + __pyx_t_3 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; } @@ -45079,7 +49116,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_14__reduce_cyth __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); - __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("dependency_injector.providers.List.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -45092,7 +49129,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_14__reduce_cyth /* "(tree fragment)":16 * else: - * return __pyx_unpickle_List, (type(self), 0x631cff7, state) + * return __pyx_unpickle_List, (type(self), 0x42b6146, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_List__set_state(self, __pyx_state) */ @@ -45120,7 +49157,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_16__setstate_cy __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_List, (type(self), 0x631cff7, state) + * return __pyx_unpickle_List, (type(self), 0x42b6146, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_List__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -45131,7 +49168,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_16__setstate_cy /* "(tree fragment)":16 * else: - * return __pyx_unpickle_List, (type(self), 0x631cff7, state) + * return __pyx_unpickle_List, (type(self), 0x42b6146, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_List__set_state(self, __pyx_state) */ @@ -45149,7 +49186,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4List_16__setstate_cy return __pyx_r; } -/* "dependency_injector/providers.pyx":2487 +/* "dependency_injector/providers.pyx":2646 * """ * * def __init__(self, dict_=None, **kwargs): # <<<<<<<<<<<<<< @@ -45196,7 +49233,7 @@ static int __pyx_pw_19dependency_injector_9providers_4Dict_1__init__(PyObject *_ } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 2487, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 2646, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -45210,7 +49247,7 @@ static int __pyx_pw_19dependency_injector_9providers_4Dict_1__init__(PyObject *_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2487, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2646, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; __Pyx_AddTraceback("dependency_injector.providers.Dict.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); @@ -45236,14 +49273,14 @@ static int __pyx_pf_19dependency_injector_9providers_4Dict___init__(struct __pyx int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":2489 + /* "dependency_injector/providers.pyx":2648 * def __init__(self, dict_=None, **kwargs): * """Initializer.""" * self.__kwargs = tuple() # <<<<<<<<<<<<<< * self.__kwargs_len = 0 * self.add_kwargs(dict_, **kwargs) */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2489, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2648, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___kwargs); @@ -45251,7 +49288,7 @@ static int __pyx_pf_19dependency_injector_9providers_4Dict___init__(struct __pyx __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2490 + /* "dependency_injector/providers.pyx":2649 * """Initializer.""" * self.__kwargs = tuple() * self.__kwargs_len = 0 # <<<<<<<<<<<<<< @@ -45260,34 +49297,34 @@ static int __pyx_pf_19dependency_injector_9providers_4Dict___init__(struct __pyx */ __pyx_v_self->__pyx___kwargs_len = 0; - /* "dependency_injector/providers.pyx":2491 + /* "dependency_injector/providers.pyx":2650 * self.__kwargs = tuple() * self.__kwargs_len = 0 * self.add_kwargs(dict_, **kwargs) # <<<<<<<<<<<<<< * super(Dict, self).__init__() * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_add_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2491, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_add_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2650, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2491, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2650, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_dict_); __Pyx_GIVEREF(__pyx_v_dict_); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_dict_); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2491, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2650, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2492 + /* "dependency_injector/providers.pyx":2651 * self.__kwargs_len = 0 * self.add_kwargs(dict_, **kwargs) * super(Dict, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2492, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2651, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Dict)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Dict)); @@ -45295,10 +49332,10 @@ static int __pyx_pf_19dependency_injector_9providers_4Dict___init__(struct __pyx __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2492, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2651, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2492, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2651, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = NULL; @@ -45313,12 +49350,12 @@ static int __pyx_pf_19dependency_injector_9providers_4Dict___init__(struct __pyx } __pyx_t_3 = (__pyx_t_1) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_1) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2492, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2651, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2487 + /* "dependency_injector/providers.pyx":2646 * """ * * def __init__(self, dict_=None, **kwargs): # <<<<<<<<<<<<<< @@ -45340,7 +49377,7 @@ static int __pyx_pf_19dependency_injector_9providers_4Dict___init__(struct __pyx return __pyx_r; } -/* "dependency_injector/providers.pyx":2494 +/* "dependency_injector/providers.pyx":2653 * super(Dict, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -45378,16 +49415,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_2__deepcopy__(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":2496 + /* "dependency_injector/providers.pyx":2655 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2496, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2496, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -45402,13 +49439,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_2__deepcopy__(s __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2496, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2497 + /* "dependency_injector/providers.pyx":2656 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -45419,7 +49456,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_2__deepcopy__(s __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":2498 + /* "dependency_injector/providers.pyx":2657 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -45431,7 +49468,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_2__deepcopy__(s __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2497 + /* "dependency_injector/providers.pyx":2656 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -45440,21 +49477,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_2__deepcopy__(s */ } - /* "dependency_injector/providers.pyx":2500 + /* "dependency_injector/providers.pyx":2659 * return copied * * copied = self.__class__(deepcopy(self.kwargs, memo)) # <<<<<<<<<<<<<< * self._copy_overridings(copied, memo) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2500, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2659, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2500, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2659, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2500, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2659, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2500, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2659, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -45470,24 +49507,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_2__deepcopy__(s __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2500, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2659, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2501 + /* "dependency_injector/providers.pyx":2660 * * copied = self.__class__(deepcopy(self.kwargs, memo)) * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 2501, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2501, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 2660, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2660, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_Dict *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":2503 + /* "dependency_injector/providers.pyx":2662 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -45499,7 +49536,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_2__deepcopy__(s __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2494 + /* "dependency_injector/providers.pyx":2653 * super(Dict, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -45522,7 +49559,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_2__deepcopy__(s return __pyx_r; } -/* "dependency_injector/providers.pyx":2505 +/* "dependency_injector/providers.pyx":2664 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -45557,7 +49594,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_4__str__(struct int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__str__", 0); - /* "dependency_injector/providers.pyx":2510 + /* "dependency_injector/providers.pyx":2669 * :rtype: str * """ * return represent_provider(provider=self, provides=self.kwargs) # <<<<<<<<<<<<<< @@ -45565,16 +49602,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_4__str__(struct * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2510, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2669, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2510, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_represent_provider(((PyObject *)__pyx_v_self), __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2669, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2505 + /* "dependency_injector/providers.pyx":2664 * return copied * * def __str__(self): # <<<<<<<<<<<<<< @@ -45594,7 +49631,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_4__str__(struct return __pyx_r; } -/* "dependency_injector/providers.pyx":2513 +/* "dependency_injector/providers.pyx":2672 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -45630,19 +49667,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6kwargs___get__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":2519 + /* "dependency_injector/providers.pyx":2678 * cdef dict kwargs * * kwargs = dict() # <<<<<<<<<<<<<< * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2519, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2678, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2520 + /* "dependency_injector/providers.pyx":2679 * * kwargs = dict() * for index in range(self.__kwargs_len): # <<<<<<<<<<<<<< @@ -45654,7 +49691,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6kwargs___get__ for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_index = __pyx_t_4; - /* "dependency_injector/providers.pyx":2521 + /* "dependency_injector/providers.pyx":2680 * kwargs = dict() * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] # <<<<<<<<<<<<<< @@ -45663,15 +49700,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6kwargs___get__ */ if (unlikely(__pyx_v_self->__pyx___kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 2521, __pyx_L1_error) + __PYX_ERR(1, 2680, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___kwargs, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2521, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___kwargs, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2680, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_NamedInjection))))) __PYX_ERR(1, 2521, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_NamedInjection))))) __PYX_ERR(1, 2680, __pyx_L1_error) __Pyx_XDECREF_SET(__pyx_v_kwarg, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2522 + /* "dependency_injector/providers.pyx":2681 * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] * kwargs[kwarg.__name] = kwarg.__value # <<<<<<<<<<<<<< @@ -45680,11 +49717,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6kwargs___get__ */ __pyx_t_1 = __pyx_v_kwarg->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_1); - if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_kwarg->__pyx___name, __pyx_t_1) < 0)) __PYX_ERR(1, 2522, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_kwarg->__pyx___name, __pyx_t_1) < 0)) __PYX_ERR(1, 2681, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - /* "dependency_injector/providers.pyx":2523 + /* "dependency_injector/providers.pyx":2682 * kwarg = self.__kwargs[index] * kwargs[kwarg.__name] = kwarg.__value * return kwargs # <<<<<<<<<<<<<< @@ -45696,7 +49733,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6kwargs___get__ __pyx_r = __pyx_v_kwargs; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2513 + /* "dependency_injector/providers.pyx":2672 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -45717,7 +49754,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6kwargs___get__ return __pyx_r; } -/* "dependency_injector/providers.pyx":2525 +/* "dependency_injector/providers.pyx":2684 * return kwargs * * def add_kwargs(self, dict_=None, **kwargs): # <<<<<<<<<<<<<< @@ -45761,7 +49798,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_4Dict_7add_kwargs(PyO } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, pos_args, "add_kwargs") < 0)) __PYX_ERR(1, 2525, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, pos_args, "add_kwargs") < 0)) __PYX_ERR(1, 2684, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -45775,7 +49812,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_4Dict_7add_kwargs(PyO } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("add_kwargs", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2525, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("add_kwargs", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2684, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; __Pyx_AddTraceback("dependency_injector.providers.Dict.add_kwargs", __pyx_clineno, __pyx_lineno, __pyx_filename); @@ -45804,7 +49841,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6add_kwargs(str __Pyx_RefNannySetupContext("add_kwargs", 0); __Pyx_INCREF(__pyx_v_dict_); - /* "dependency_injector/providers.pyx":2530 + /* "dependency_injector/providers.pyx":2689 * :return: Reference ``self`` * """ * if dict_ is None: # <<<<<<<<<<<<<< @@ -45815,19 +49852,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6add_kwargs(str __pyx_t_2 = (__pyx_t_1 != 0); if (__pyx_t_2) { - /* "dependency_injector/providers.pyx":2531 + /* "dependency_injector/providers.pyx":2690 * """ * if dict_ is None: * dict_ = {} # <<<<<<<<<<<<<< * * self.__kwargs += parse_named_injections(dict_) */ - __pyx_t_3 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2531, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2690, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF_SET(__pyx_v_dict_, __pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2530 + /* "dependency_injector/providers.pyx":2689 * :return: Reference ``self`` * """ * if dict_ is None: # <<<<<<<<<<<<<< @@ -45836,17 +49873,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6add_kwargs(str */ } - /* "dependency_injector/providers.pyx":2533 + /* "dependency_injector/providers.pyx":2692 * dict_ = {} * * self.__kwargs += parse_named_injections(dict_) # <<<<<<<<<<<<<< * self.__kwargs += parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) */ - if (!(likely(PyDict_CheckExact(__pyx_v_dict_))||((__pyx_v_dict_) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_dict_)->tp_name), 0))) __PYX_ERR(1, 2533, __pyx_L1_error) - __pyx_t_3 = __pyx_f_19dependency_injector_9providers_parse_named_injections(((PyObject*)__pyx_v_dict_), 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2533, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_dict_))||((__pyx_v_dict_) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_dict_)->tp_name), 0))) __PYX_ERR(1, 2692, __pyx_L1_error) + __pyx_t_3 = __pyx_f_19dependency_injector_9providers_parse_named_injections(((PyObject*)__pyx_v_dict_), 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2692, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___kwargs, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2533, __pyx_L1_error) + __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___kwargs, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2692, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GIVEREF(__pyx_t_4); @@ -45855,16 +49892,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6add_kwargs(str __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":2534 + /* "dependency_injector/providers.pyx":2693 * * self.__kwargs += parse_named_injections(dict_) * self.__kwargs += parse_named_injections(kwargs) # <<<<<<<<<<<<<< * self.__kwargs_len = len(self.__kwargs) * */ - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2534, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2693, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___kwargs, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2534, __pyx_L1_error) + __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___kwargs, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2693, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GIVEREF(__pyx_t_3); @@ -45873,7 +49910,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6add_kwargs(str __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2535 + /* "dependency_injector/providers.pyx":2694 * self.__kwargs += parse_named_injections(dict_) * self.__kwargs += parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) # <<<<<<<<<<<<<< @@ -45884,13 +49921,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6add_kwargs(str __Pyx_INCREF(__pyx_t_3); if (unlikely(__pyx_t_3 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2535, __pyx_L1_error) + __PYX_ERR(1, 2694, __pyx_L1_error) } - __pyx_t_5 = PyTuple_GET_SIZE(__pyx_t_3); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2535, __pyx_L1_error) + __pyx_t_5 = PyTuple_GET_SIZE(__pyx_t_3); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2694, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_v_self->__pyx___kwargs_len = __pyx_t_5; - /* "dependency_injector/providers.pyx":2537 + /* "dependency_injector/providers.pyx":2696 * self.__kwargs_len = len(self.__kwargs) * * return self # <<<<<<<<<<<<<< @@ -45902,7 +49939,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6add_kwargs(str __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2525 + /* "dependency_injector/providers.pyx":2684 * return kwargs * * def add_kwargs(self, dict_=None, **kwargs): # <<<<<<<<<<<<<< @@ -45923,7 +49960,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_6add_kwargs(str return __pyx_r; } -/* "dependency_injector/providers.pyx":2539 +/* "dependency_injector/providers.pyx":2698 * return self * * def set_kwargs(self, dict_=None, **kwargs): # <<<<<<<<<<<<<< @@ -45967,7 +50004,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_4Dict_9set_kwargs(PyO } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, pos_args, "set_kwargs") < 0)) __PYX_ERR(1, 2539, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, pos_args, "set_kwargs") < 0)) __PYX_ERR(1, 2698, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -45981,7 +50018,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_4Dict_9set_kwargs(PyO } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("set_kwargs", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2539, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("set_kwargs", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2698, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; __Pyx_AddTraceback("dependency_injector.providers.Dict.set_kwargs", __pyx_clineno, __pyx_lineno, __pyx_filename); @@ -46010,7 +50047,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_8set_kwargs(str __Pyx_RefNannySetupContext("set_kwargs", 0); __Pyx_INCREF(__pyx_v_dict_); - /* "dependency_injector/providers.pyx":2546 + /* "dependency_injector/providers.pyx":2705 * :return: Reference ``self`` * """ * if dict_ is None: # <<<<<<<<<<<<<< @@ -46021,19 +50058,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_8set_kwargs(str __pyx_t_2 = (__pyx_t_1 != 0); if (__pyx_t_2) { - /* "dependency_injector/providers.pyx":2547 + /* "dependency_injector/providers.pyx":2706 * """ * if dict_ is None: * dict_ = {} # <<<<<<<<<<<<<< * * self.__kwargs = parse_named_injections(dict_) */ - __pyx_t_3 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2547, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2706, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF_SET(__pyx_v_dict_, __pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2546 + /* "dependency_injector/providers.pyx":2705 * :return: Reference ``self`` * """ * if dict_ is None: # <<<<<<<<<<<<<< @@ -46042,15 +50079,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_8set_kwargs(str */ } - /* "dependency_injector/providers.pyx":2549 + /* "dependency_injector/providers.pyx":2708 * dict_ = {} * * self.__kwargs = parse_named_injections(dict_) # <<<<<<<<<<<<<< * self.__kwargs += parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) */ - if (!(likely(PyDict_CheckExact(__pyx_v_dict_))||((__pyx_v_dict_) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_dict_)->tp_name), 0))) __PYX_ERR(1, 2549, __pyx_L1_error) - __pyx_t_3 = __pyx_f_19dependency_injector_9providers_parse_named_injections(((PyObject*)__pyx_v_dict_), 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2549, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_dict_))||((__pyx_v_dict_) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_dict_)->tp_name), 0))) __PYX_ERR(1, 2708, __pyx_L1_error) + __pyx_t_3 = __pyx_f_19dependency_injector_9providers_parse_named_injections(((PyObject*)__pyx_v_dict_), 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2708, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_3); __Pyx_GOTREF(__pyx_v_self->__pyx___kwargs); @@ -46058,16 +50095,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_8set_kwargs(str __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2550 + /* "dependency_injector/providers.pyx":2709 * * self.__kwargs = parse_named_injections(dict_) * self.__kwargs += parse_named_injections(kwargs) # <<<<<<<<<<<<<< * self.__kwargs_len = len(self.__kwargs) * */ - __pyx_t_3 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2550, __pyx_L1_error) + __pyx_t_3 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2709, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___kwargs, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2550, __pyx_L1_error) + __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___kwargs, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2709, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GIVEREF(__pyx_t_4); @@ -46076,7 +50113,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_8set_kwargs(str __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":2551 + /* "dependency_injector/providers.pyx":2710 * self.__kwargs = parse_named_injections(dict_) * self.__kwargs += parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) # <<<<<<<<<<<<<< @@ -46087,13 +50124,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_8set_kwargs(str __Pyx_INCREF(__pyx_t_4); if (unlikely(__pyx_t_4 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2551, __pyx_L1_error) + __PYX_ERR(1, 2710, __pyx_L1_error) } - __pyx_t_5 = PyTuple_GET_SIZE(__pyx_t_4); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2551, __pyx_L1_error) + __pyx_t_5 = PyTuple_GET_SIZE(__pyx_t_4); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2710, __pyx_L1_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_self->__pyx___kwargs_len = __pyx_t_5; - /* "dependency_injector/providers.pyx":2553 + /* "dependency_injector/providers.pyx":2712 * self.__kwargs_len = len(self.__kwargs) * * return self # <<<<<<<<<<<<<< @@ -46105,7 +50142,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_8set_kwargs(str __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2539 + /* "dependency_injector/providers.pyx":2698 * return self * * def set_kwargs(self, dict_=None, **kwargs): # <<<<<<<<<<<<<< @@ -46126,7 +50163,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_8set_kwargs(str return __pyx_r; } -/* "dependency_injector/providers.pyx":2555 +/* "dependency_injector/providers.pyx":2714 * return self * * def clear_kwargs(self): # <<<<<<<<<<<<<< @@ -46158,14 +50195,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_10clear_kwargs( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_kwargs", 0); - /* "dependency_injector/providers.pyx":2560 + /* "dependency_injector/providers.pyx":2719 * :return: Reference ``self`` * """ * self.__kwargs = tuple() # <<<<<<<<<<<<<< * self.__kwargs_len = len(self.__kwargs) * return self */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2560, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2719, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___kwargs); @@ -46173,7 +50210,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_10clear_kwargs( __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2561 + /* "dependency_injector/providers.pyx":2720 * """ * self.__kwargs = tuple() * self.__kwargs_len = len(self.__kwargs) # <<<<<<<<<<<<<< @@ -46184,13 +50221,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_10clear_kwargs( __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2561, __pyx_L1_error) + __PYX_ERR(1, 2720, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2561, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2720, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___kwargs_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":2562 + /* "dependency_injector/providers.pyx":2721 * self.__kwargs = tuple() * self.__kwargs_len = len(self.__kwargs) * return self # <<<<<<<<<<<<<< @@ -46202,7 +50239,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_10clear_kwargs( __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2555 + /* "dependency_injector/providers.pyx":2714 * return self * * def clear_kwargs(self): # <<<<<<<<<<<<<< @@ -46221,7 +50258,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_10clear_kwargs( return __pyx_r; } -/* "dependency_injector/providers.pyx":2564 +/* "dependency_injector/providers.pyx":2723 * return self * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -46252,7 +50289,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4Dict__provide(struct if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2564, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2723, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_4Dict_13_provide)) { __Pyx_XDECREF(__pyx_r); @@ -46272,7 +50309,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4Dict__provide(struct #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2564, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2723, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -46280,13 +50317,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4Dict__provide(struct #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2564, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2723, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2564, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2723, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -46297,7 +50334,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4Dict__provide(struct __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2564, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2723, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -46320,7 +50357,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4Dict__provide(struct #endif } - /* "dependency_injector/providers.pyx":2566 + /* "dependency_injector/providers.pyx":2725 * cpdef object _provide(self, tuple args, dict kwargs): * """Return result of provided callable's call.""" * return __provide_keyword_args(kwargs, self.__kwargs, self.__kwargs_len) # <<<<<<<<<<<<<< @@ -46330,14 +50367,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_4Dict__provide(struct __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __pyx_v_self->__pyx___kwargs; __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers___provide_keyword_args(__pyx_v_kwargs, ((PyObject*)__pyx_t_1), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2566, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers___provide_keyword_args(__pyx_v_kwargs, ((PyObject*)__pyx_t_1), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2725, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2564 + /* "dependency_injector/providers.pyx":2723 * return self * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -46395,11 +50432,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_4Dict_13_provide(PyOb case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2564, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2723, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2564, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2723, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -46412,14 +50449,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_4Dict_13_provide(PyOb } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2564, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2723, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Dict._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2564, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2564, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2723, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2723, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_4Dict_12_provide(((struct __pyx_obj_19dependency_injector_9providers_Dict *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -46440,7 +50477,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_12_provide(stru int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_4Dict__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2564, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_4Dict__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2723, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -46484,10 +50521,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_14__reduce_cyth __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; - int __pyx_t_3; + PyObject *__pyx_t_3 = NULL; int __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -46496,51 +50533,56 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_14__reduce_cyth /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(5); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx___kwargs); __Pyx_GIVEREF(__pyx_v_self->__pyx___kwargs); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_self->__pyx___kwargs); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_self->__pyx___kwargs); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_3, 3, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_3, 4, __pyx_v_self->__pyx_base.__pyx___overridden); __pyx_t_1 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_3); + __pyx_t_3 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_v__dict = __pyx_t_2; - __pyx_t_2 = 0; + __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_v__dict = __pyx_t_3; + __pyx_t_3 = 0; /* "(tree fragment)":7 - * state = (self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_3 = (__pyx_v__dict != Py_None); - __pyx_t_4 = (__pyx_t_3 != 0); - if (__pyx_t_4) { + __pyx_t_4 = (__pyx_v__dict != Py_None); + __pyx_t_5 = (__pyx_t_4 != 0); + if (__pyx_t_5) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -46549,16 +50591,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_14__reduce_cyth * use_setstate = True * else: */ - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); - __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); - __pyx_t_1 = 0; + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); + __pyx_t_2 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -46570,7 +50612,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_14__reduce_cyth __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden) + * state = (self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -46584,28 +50626,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_14__reduce_cyth * else: * use_setstate = self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Dict, (type(self), 0x97c970c, None), state + * return __pyx_unpickle_Dict, (type(self), 0xff73c9f, None), state */ /*else*/ { - __pyx_t_3 = (__pyx_v_self->__pyx___kwargs != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_3 != 0); - if (!__pyx_t_5) { + __pyx_t_4 = (__pyx_v_self->__pyx___kwargs != ((PyObject*)Py_None)); + __pyx_t_6 = (__pyx_t_4 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_4 = __pyx_t_5; + __pyx_t_5 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_3 = (__pyx_t_5 != 0); - if (!__pyx_t_3) { + __pyx_t_6 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_4 = (__pyx_t_6 != 0); + if (!__pyx_t_4) { } else { - __pyx_t_4 = __pyx_t_3; + __pyx_t_5 = __pyx_t_4; goto __pyx_L4_bool_binop_done; } - __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_3 != 0); - __pyx_t_4 = __pyx_t_5; + __pyx_t_4 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_6 = (__pyx_t_4 != 0); + __pyx_t_5 = __pyx_t_6; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_4; + __pyx_v_use_setstate = __pyx_t_5; } __pyx_L3:; @@ -46613,89 +50655,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_14__reduce_cyth * else: * use_setstate = self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Dict, (type(self), 0x97c970c, None), state + * return __pyx_unpickle_Dict, (type(self), 0xff73c9f, None), state * else: */ - __pyx_t_4 = (__pyx_v_use_setstate != 0); - if (__pyx_t_4) { + __pyx_t_5 = (__pyx_v_use_setstate != 0); + if (__pyx_t_5) { /* "(tree fragment)":13 * use_setstate = self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: - * return __pyx_unpickle_Dict, (type(self), 0x97c970c, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Dict, (type(self), 0xff73c9f, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Dict, (type(self), 0x97c970c, state) + * return __pyx_unpickle_Dict, (type(self), 0xff73c9f, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Dict); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_Dict); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_159160076); - __Pyx_GIVEREF(__pyx_int_159160076); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_159160076); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_267861151); + __Pyx_GIVEREF(__pyx_int_267861151); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_267861151); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); - __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); + __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_1 = 0; + PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); __pyx_t_2 = 0; - __pyx_r = __pyx_t_6; - __pyx_t_6 = 0; + __pyx_t_3 = 0; + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Dict, (type(self), 0x97c970c, None), state + * return __pyx_unpickle_Dict, (type(self), 0xff73c9f, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Dict, (type(self), 0x97c970c, None), state + * return __pyx_unpickle_Dict, (type(self), 0xff73c9f, None), state * else: - * return __pyx_unpickle_Dict, (type(self), 0x97c970c, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Dict, (type(self), 0xff73c9f, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Dict__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_Dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Dict); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_159160076); - __Pyx_GIVEREF(__pyx_int_159160076); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_159160076); + PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_267861151); + __Pyx_GIVEREF(__pyx_int_267861151); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_267861151); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); - __pyx_t_6 = 0; - __pyx_t_2 = 0; - __pyx_r = __pyx_t_1; + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); __pyx_t_1 = 0; + __pyx_t_3 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; } @@ -46709,7 +50751,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_14__reduce_cyth __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); - __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("dependency_injector.providers.Dict.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -46722,7 +50764,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_14__reduce_cyth /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Dict, (type(self), 0x97c970c, state) + * return __pyx_unpickle_Dict, (type(self), 0xff73c9f, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Dict__set_state(self, __pyx_state) */ @@ -46750,7 +50792,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_16__setstate_cy __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Dict, (type(self), 0x97c970c, state) + * return __pyx_unpickle_Dict, (type(self), 0xff73c9f, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Dict__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -46761,7 +50803,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_16__setstate_cy /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Dict, (type(self), 0x97c970c, state) + * return __pyx_unpickle_Dict, (type(self), 0xff73c9f, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Dict__set_state(self, __pyx_state) */ @@ -46779,7 +50821,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_4Dict_16__setstate_cy return __pyx_r; } -/* "dependency_injector/providers.pyx":2572 +/* "dependency_injector/providers.pyx":2731 * """Resource provider provides a component with initialization and shutdown.""" * * def __init__(self, initializer, *args, **kwargs): # <<<<<<<<<<<<<< @@ -46832,7 +50874,7 @@ static int __pyx_pw_19dependency_injector_9providers_8Resource_1__init__(PyObjec } if (unlikely(kw_args > 0)) { const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 2572, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 2731, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { goto __pyx_L5_argtuple_error; @@ -46843,7 +50885,7 @@ static int __pyx_pw_19dependency_injector_9providers_8Resource_1__init__(PyObjec } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2572, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2731, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; @@ -46871,7 +50913,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":2573 + /* "dependency_injector/providers.pyx":2732 * * def __init__(self, initializer, *args, **kwargs): * self.__initializer = initializer # <<<<<<<<<<<<<< @@ -46884,7 +50926,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ __Pyx_DECREF(__pyx_v_self->__pyx___initializer); __pyx_v_self->__pyx___initializer = __pyx_v_initializer; - /* "dependency_injector/providers.pyx":2574 + /* "dependency_injector/providers.pyx":2733 * def __init__(self, initializer, *args, **kwargs): * self.__initializer = initializer * self.__initialized = False # <<<<<<<<<<<<<< @@ -46893,7 +50935,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ */ __pyx_v_self->__pyx___initialized = 0; - /* "dependency_injector/providers.pyx":2575 + /* "dependency_injector/providers.pyx":2734 * self.__initializer = initializer * self.__initialized = False * self.__resource = None # <<<<<<<<<<<<<< @@ -46906,7 +50948,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ __Pyx_DECREF(__pyx_v_self->__pyx___resource); __pyx_v_self->__pyx___resource = Py_None; - /* "dependency_injector/providers.pyx":2576 + /* "dependency_injector/providers.pyx":2735 * self.__initialized = False * self.__resource = None * self.__shutdowner = None # <<<<<<<<<<<<<< @@ -46919,14 +50961,14 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ __Pyx_DECREF(__pyx_v_self->__pyx___shutdowner); __pyx_v_self->__pyx___shutdowner = Py_None; - /* "dependency_injector/providers.pyx":2578 + /* "dependency_injector/providers.pyx":2737 * self.__shutdowner = None * * self.__args = tuple() # <<<<<<<<<<<<<< * self.__args_len = 0 * self.set_args(*args) */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2578, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2737, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___args); @@ -46934,7 +50976,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2579 + /* "dependency_injector/providers.pyx":2738 * * self.__args = tuple() * self.__args_len = 0 # <<<<<<<<<<<<<< @@ -46943,28 +50985,28 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ */ __pyx_v_self->__pyx___args_len = 0; - /* "dependency_injector/providers.pyx":2580 + /* "dependency_injector/providers.pyx":2739 * self.__args = tuple() * self.__args_len = 0 * self.set_args(*args) # <<<<<<<<<<<<<< * * self.__kwargs = tuple() */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_set_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2580, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_set_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2739, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2580, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2739, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2582 + /* "dependency_injector/providers.pyx":2741 * self.set_args(*args) * * self.__kwargs = tuple() # <<<<<<<<<<<<<< * self.__kwargs_len = 0 * self.set_kwargs(**kwargs) */ - __pyx_t_2 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2582, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2741, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_2); __Pyx_GOTREF(__pyx_v_self->__pyx___kwargs); @@ -46972,7 +51014,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2583 + /* "dependency_injector/providers.pyx":2742 * * self.__kwargs = tuple() * self.__kwargs_len = 0 # <<<<<<<<<<<<<< @@ -46981,28 +51023,28 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ */ __pyx_v_self->__pyx___kwargs_len = 0; - /* "dependency_injector/providers.pyx":2584 + /* "dependency_injector/providers.pyx":2743 * self.__kwargs = tuple() * self.__kwargs_len = 0 * self.set_kwargs(**kwargs) # <<<<<<<<<<<<<< * * super().__init__() */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_set_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2584, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_set_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2743, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2584, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2743, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2586 + /* "dependency_injector/providers.pyx":2745 * self.set_kwargs(**kwargs) * * super().__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2586, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2745, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource)); @@ -47010,10 +51052,10 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2586, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2745, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2586, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2745, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -47028,12 +51070,12 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2586, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2745, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2572 + /* "dependency_injector/providers.pyx":2731 * """Resource provider provides a component with initialization and shutdown.""" * * def __init__(self, initializer, *args, **kwargs): # <<<<<<<<<<<<<< @@ -47055,7 +51097,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Resource___init__(struct _ return __pyx_r; } -/* "dependency_injector/providers.pyx":2588 +/* "dependency_injector/providers.pyx":2747 * super().__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -47094,16 +51136,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":2590 + /* "dependency_injector/providers.pyx":2749 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2590, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2749, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2590, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2749, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -47118,13 +51160,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2590, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2749, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2591 + /* "dependency_injector/providers.pyx":2750 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -47135,7 +51177,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":2592 + /* "dependency_injector/providers.pyx":2751 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -47147,7 +51189,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2591 + /* "dependency_injector/providers.pyx":2750 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -47156,7 +51198,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy */ } - /* "dependency_injector/providers.pyx":2594 + /* "dependency_injector/providers.pyx":2753 * return copied * * if self.__initialized: # <<<<<<<<<<<<<< @@ -47166,14 +51208,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy __pyx_t_6 = (__pyx_v_self->__pyx___initialized != 0); if (unlikely(__pyx_t_6)) { - /* "dependency_injector/providers.pyx":2595 + /* "dependency_injector/providers.pyx":2754 * * if self.__initialized: * raise Error('Can not copy initialized resource') # <<<<<<<<<<<<<< * * copied = self.__class__( */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2595, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2754, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { @@ -47187,14 +51229,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_kp_s_Can_not_copy_initialized_resourc) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_kp_s_Can_not_copy_initialized_resourc); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2595, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2754, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 2595, __pyx_L1_error) + __PYX_ERR(1, 2754, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2594 + /* "dependency_injector/providers.pyx":2753 * return copied * * if self.__initialized: # <<<<<<<<<<<<<< @@ -47203,97 +51245,97 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy */ } - /* "dependency_injector/providers.pyx":2597 + /* "dependency_injector/providers.pyx":2756 * raise Error('Can not copy initialized resource') * * copied = self.__class__( # <<<<<<<<<<<<<< * self.__initializer, * *deepcopy(self.args, memo), */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2597, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2756, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":2598 + /* "dependency_injector/providers.pyx":2757 * * copied = self.__class__( * self.__initializer, # <<<<<<<<<<<<<< * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo), */ - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2597, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2756, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_self->__pyx___initializer); __Pyx_GIVEREF(__pyx_v_self->__pyx___initializer); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_self->__pyx___initializer); - /* "dependency_injector/providers.pyx":2599 + /* "dependency_injector/providers.pyx":2758 * copied = self.__class__( * self.__initializer, * *deepcopy(self.args, memo), # <<<<<<<<<<<<<< * **deepcopy(self.kwargs, memo), * ) */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2599, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_args); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2758, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2599, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2758, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2599, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2758, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2597 + /* "dependency_injector/providers.pyx":2756 * raise Error('Can not copy initialized resource') * * copied = self.__class__( # <<<<<<<<<<<<<< * self.__initializer, * *deepcopy(self.args, memo), */ - __pyx_t_3 = __Pyx_PySequence_Tuple(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2597, __pyx_L1_error) + __pyx_t_3 = __Pyx_PySequence_Tuple(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2756, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = PyNumber_Add(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2597, __pyx_L1_error) + __pyx_t_4 = PyNumber_Add(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2756, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2600 + /* "dependency_injector/providers.pyx":2759 * self.__initializer, * *deepcopy(self.args, memo), * **deepcopy(self.kwargs, memo), # <<<<<<<<<<<<<< * ) * self._copy_overridings(copied, memo) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2600, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2759, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2600, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2759, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2600, __pyx_L1_error) + __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2759, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (unlikely(__pyx_t_8 == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 2600, __pyx_L1_error) + __PYX_ERR(1, 2759, __pyx_L1_error) } if (likely(PyDict_CheckExact(__pyx_t_8))) { - __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2600, __pyx_L1_error) + __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2759, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { - __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2597, __pyx_L1_error) + __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2756, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } - /* "dependency_injector/providers.pyx":2597 + /* "dependency_injector/providers.pyx":2756 * raise Error('Can not copy initialized resource') * * copied = self.__class__( # <<<<<<<<<<<<<< * self.__initializer, * *deepcopy(self.args, memo), */ - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2597, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2756, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -47301,18 +51343,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":2602 + /* "dependency_injector/providers.pyx":2761 * **deepcopy(self.kwargs, memo), * ) * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 2602, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2602, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 2761, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2761, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_Resource *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":2604 + /* "dependency_injector/providers.pyx":2763 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -47324,7 +51366,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2588 + /* "dependency_injector/providers.pyx":2747 * super().__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -47348,7 +51390,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_2__deepcopy return __pyx_r; } -/* "dependency_injector/providers.pyx":2606 +/* "dependency_injector/providers.pyx":2765 * return copied * * def __repr__(self): # <<<<<<<<<<<<<< @@ -47382,7 +51424,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4__repr__(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__repr__", 0); - /* "dependency_injector/providers.pyx":2607 + /* "dependency_injector/providers.pyx":2766 * * def __repr__(self): * return ( # <<<<<<<<<<<<<< @@ -47391,23 +51433,23 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4__repr__(s */ __Pyx_XDECREF(__pyx_r); - /* "dependency_injector/providers.pyx":2608 + /* "dependency_injector/providers.pyx":2767 * def __repr__(self): * return ( * f'{self.__class__.__name__}({self.__initializer}, ' # <<<<<<<<<<<<<< * f'initialized={self.__initialized})' * ) */ - __pyx_t_1 = PyTuple_New(6); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2608, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(6); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = 0; __pyx_t_3 = 127; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2608, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2608, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_t_5, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2608, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_t_5, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_3 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) > __pyx_t_3) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) : __pyx_t_3; @@ -47415,11 +51457,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4__repr__(s __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_4); __pyx_t_4 = 0; - __Pyx_INCREF(__pyx_kp_u__8); + __Pyx_INCREF(__pyx_kp_u__9); __pyx_t_2 += 1; - __Pyx_GIVEREF(__pyx_kp_u__8); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_kp_u__8); - __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_v_self->__pyx___initializer, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2608, __pyx_L1_error) + __Pyx_GIVEREF(__pyx_kp_u__9); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_kp_u__9); + __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_v_self->__pyx___initializer, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_3 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) > __pyx_t_3) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) : __pyx_t_3; __pyx_t_2 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_4); @@ -47431,39 +51473,39 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4__repr__(s __Pyx_GIVEREF(__pyx_kp_u_initialized); PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_kp_u_initialized); - /* "dependency_injector/providers.pyx":2609 + /* "dependency_injector/providers.pyx":2768 * return ( * f'{self.__class__.__name__}({self.__initializer}, ' * f'initialized={self.__initialized})' # <<<<<<<<<<<<<< * ) * */ - __pyx_t_4 = __Pyx_PyUnicode_FromBInt_int(__pyx_v_self->__pyx___initialized); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2609, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyUnicode_FromBInt_int(__pyx_v_self->__pyx___initialized); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2768, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_2 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 4, __pyx_t_4); __pyx_t_4 = 0; - __Pyx_INCREF(__pyx_kp_u__9); + __Pyx_INCREF(__pyx_kp_u__10); __pyx_t_2 += 1; - __Pyx_GIVEREF(__pyx_kp_u__9); - PyTuple_SET_ITEM(__pyx_t_1, 5, __pyx_kp_u__9); + __Pyx_GIVEREF(__pyx_kp_u__10); + PyTuple_SET_ITEM(__pyx_t_1, 5, __pyx_kp_u__10); - /* "dependency_injector/providers.pyx":2608 + /* "dependency_injector/providers.pyx":2767 * def __repr__(self): * return ( * f'{self.__class__.__name__}({self.__initializer}, ' # <<<<<<<<<<<<<< * f'initialized={self.__initialized})' * ) */ - __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 6, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2608, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 6, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2767, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_4; __pyx_t_4 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2606 + /* "dependency_injector/providers.pyx":2765 * return copied * * def __repr__(self): # <<<<<<<<<<<<<< @@ -47484,7 +51526,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4__repr__(s return __pyx_r; } -/* "dependency_injector/providers.pyx":2613 +/* "dependency_injector/providers.pyx":2772 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -47521,19 +51563,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4args___get int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":2619 + /* "dependency_injector/providers.pyx":2778 * cdef list args * * args = list() # <<<<<<<<<<<<<< * for index in range(self.__args_len): * arg = self.__args[index] */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2619, __pyx_L1_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2778, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2620 + /* "dependency_injector/providers.pyx":2779 * * args = list() * for index in range(self.__args_len): # <<<<<<<<<<<<<< @@ -47545,7 +51587,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4args___get for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_index = __pyx_t_4; - /* "dependency_injector/providers.pyx":2621 + /* "dependency_injector/providers.pyx":2780 * args = list() * for index in range(self.__args_len): * arg = self.__args[index] # <<<<<<<<<<<<<< @@ -47554,15 +51596,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4args___get */ if (unlikely(__pyx_v_self->__pyx___args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 2621, __pyx_L1_error) + __PYX_ERR(1, 2780, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___args, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2621, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___args, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2780, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_PositionalInjection))))) __PYX_ERR(1, 2621, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_PositionalInjection))))) __PYX_ERR(1, 2780, __pyx_L1_error) __Pyx_XDECREF_SET(__pyx_v_arg, ((struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2622 + /* "dependency_injector/providers.pyx":2781 * for index in range(self.__args_len): * arg = self.__args[index] * args.append(arg.__value) # <<<<<<<<<<<<<< @@ -47571,11 +51613,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4args___get */ __pyx_t_1 = __pyx_v_arg->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_1); - __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_args, __pyx_t_1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 2622, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_args, __pyx_t_1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 2781, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - /* "dependency_injector/providers.pyx":2623 + /* "dependency_injector/providers.pyx":2782 * arg = self.__args[index] * args.append(arg.__value) * return tuple(args) # <<<<<<<<<<<<<< @@ -47583,13 +51625,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4args___get * def add_args(self, *args): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyList_AsTuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2623, __pyx_L1_error) + __pyx_t_1 = PyList_AsTuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2782, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2613 + /* "dependency_injector/providers.pyx":2772 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -47610,7 +51652,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_4args___get return __pyx_r; } -/* "dependency_injector/providers.pyx":2625 +/* "dependency_injector/providers.pyx":2784 * return tuple(args) * * def add_args(self, *args): # <<<<<<<<<<<<<< @@ -47648,16 +51690,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6add_args(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_args", 0); - /* "dependency_injector/providers.pyx":2630 + /* "dependency_injector/providers.pyx":2789 * :return: Reference ``self`` * """ * self.__args += parse_positional_injections(args) # <<<<<<<<<<<<<< * self.__args_len = len(self.__args) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2630, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2789, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___args, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2630, __pyx_L1_error) + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___args, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2789, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GIVEREF(__pyx_t_2); @@ -47666,7 +51708,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6add_args(s __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2631 + /* "dependency_injector/providers.pyx":2790 * """ * self.__args += parse_positional_injections(args) * self.__args_len = len(self.__args) # <<<<<<<<<<<<<< @@ -47677,13 +51719,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6add_args(s __Pyx_INCREF(__pyx_t_2); if (unlikely(__pyx_t_2 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2631, __pyx_L1_error) + __PYX_ERR(1, 2790, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2631, __pyx_L1_error) + __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2790, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_self->__pyx___args_len = __pyx_t_3; - /* "dependency_injector/providers.pyx":2632 + /* "dependency_injector/providers.pyx":2791 * self.__args += parse_positional_injections(args) * self.__args_len = len(self.__args) * return self # <<<<<<<<<<<<<< @@ -47695,7 +51737,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6add_args(s __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2625 + /* "dependency_injector/providers.pyx":2784 * return tuple(args) * * def add_args(self, *args): # <<<<<<<<<<<<<< @@ -47715,7 +51757,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6add_args(s return __pyx_r; } -/* "dependency_injector/providers.pyx":2634 +/* "dependency_injector/providers.pyx":2793 * return self * * def set_args(self, *args): # <<<<<<<<<<<<<< @@ -47752,14 +51794,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_8set_args(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_args", 0); - /* "dependency_injector/providers.pyx":2641 + /* "dependency_injector/providers.pyx":2800 * :return: Reference ``self`` * """ * self.__args = parse_positional_injections(args) # <<<<<<<<<<<<<< * self.__args_len = len(self.__args) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2641, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2800, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___args); @@ -47767,7 +51809,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_8set_args(s __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2642 + /* "dependency_injector/providers.pyx":2801 * """ * self.__args = parse_positional_injections(args) * self.__args_len = len(self.__args) # <<<<<<<<<<<<<< @@ -47778,13 +51820,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_8set_args(s __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2642, __pyx_L1_error) + __PYX_ERR(1, 2801, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2642, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2801, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___args_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":2643 + /* "dependency_injector/providers.pyx":2802 * self.__args = parse_positional_injections(args) * self.__args_len = len(self.__args) * return self # <<<<<<<<<<<<<< @@ -47796,7 +51838,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_8set_args(s __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2634 + /* "dependency_injector/providers.pyx":2793 * return self * * def set_args(self, *args): # <<<<<<<<<<<<<< @@ -47815,7 +51857,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_8set_args(s return __pyx_r; } -/* "dependency_injector/providers.pyx":2645 +/* "dependency_injector/providers.pyx":2804 * return self * * def clear_args(self): # <<<<<<<<<<<<<< @@ -47847,14 +51889,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_10clear_arg int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_args", 0); - /* "dependency_injector/providers.pyx":2650 + /* "dependency_injector/providers.pyx":2809 * :return: Reference ``self`` * """ * self.__args = tuple() # <<<<<<<<<<<<<< * self.__args_len = len(self.__args) * return self */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2650, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2809, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___args); @@ -47862,7 +51904,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_10clear_arg __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2651 + /* "dependency_injector/providers.pyx":2810 * """ * self.__args = tuple() * self.__args_len = len(self.__args) # <<<<<<<<<<<<<< @@ -47873,13 +51915,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_10clear_arg __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2651, __pyx_L1_error) + __PYX_ERR(1, 2810, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2651, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2810, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___args_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":2652 + /* "dependency_injector/providers.pyx":2811 * self.__args = tuple() * self.__args_len = len(self.__args) * return self # <<<<<<<<<<<<<< @@ -47891,7 +51933,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_10clear_arg __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2645 + /* "dependency_injector/providers.pyx":2804 * return self * * def clear_args(self): # <<<<<<<<<<<<<< @@ -47910,7 +51952,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_10clear_arg return __pyx_r; } -/* "dependency_injector/providers.pyx":2655 +/* "dependency_injector/providers.pyx":2814 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -47946,19 +51988,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6kwargs___g int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":2661 + /* "dependency_injector/providers.pyx":2820 * cdef dict kwargs * * kwargs = dict() # <<<<<<<<<<<<<< * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2661, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2820, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2662 + /* "dependency_injector/providers.pyx":2821 * * kwargs = dict() * for index in range(self.__kwargs_len): # <<<<<<<<<<<<<< @@ -47970,7 +52012,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6kwargs___g for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_index = __pyx_t_4; - /* "dependency_injector/providers.pyx":2663 + /* "dependency_injector/providers.pyx":2822 * kwargs = dict() * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] # <<<<<<<<<<<<<< @@ -47979,15 +52021,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6kwargs___g */ if (unlikely(__pyx_v_self->__pyx___kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 2663, __pyx_L1_error) + __PYX_ERR(1, 2822, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___kwargs, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2663, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___kwargs, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2822, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_NamedInjection))))) __PYX_ERR(1, 2663, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_NamedInjection))))) __PYX_ERR(1, 2822, __pyx_L1_error) __Pyx_XDECREF_SET(__pyx_v_kwarg, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2664 + /* "dependency_injector/providers.pyx":2823 * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] * kwargs[kwarg.__name] = kwarg.__value # <<<<<<<<<<<<<< @@ -47996,11 +52038,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6kwargs___g */ __pyx_t_1 = __pyx_v_kwarg->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_1); - if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_kwarg->__pyx___name, __pyx_t_1) < 0)) __PYX_ERR(1, 2664, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_kwarg->__pyx___name, __pyx_t_1) < 0)) __PYX_ERR(1, 2823, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - /* "dependency_injector/providers.pyx":2665 + /* "dependency_injector/providers.pyx":2824 * kwarg = self.__kwargs[index] * kwargs[kwarg.__name] = kwarg.__value * return kwargs # <<<<<<<<<<<<<< @@ -48012,7 +52054,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6kwargs___g __pyx_r = __pyx_v_kwargs; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2655 + /* "dependency_injector/providers.pyx":2814 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -48033,7 +52075,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_6kwargs___g return __pyx_r; } -/* "dependency_injector/providers.pyx":2667 +/* "dependency_injector/providers.pyx":2826 * return kwargs * * def add_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -48073,16 +52115,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_12add_kwarg int __pyx_clineno = 0; __Pyx_RefNannySetupContext("add_kwargs", 0); - /* "dependency_injector/providers.pyx":2672 + /* "dependency_injector/providers.pyx":2831 * :return: Reference ``self`` * """ * self.__kwargs += parse_named_injections(kwargs) # <<<<<<<<<<<<<< * self.__kwargs_len = len(self.__kwargs) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2672, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2831, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___kwargs, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2672, __pyx_L1_error) + __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_self->__pyx___kwargs, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2831, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GIVEREF(__pyx_t_2); @@ -48091,7 +52133,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_12add_kwarg __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2673 + /* "dependency_injector/providers.pyx":2832 * """ * self.__kwargs += parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) # <<<<<<<<<<<<<< @@ -48102,13 +52144,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_12add_kwarg __Pyx_INCREF(__pyx_t_2); if (unlikely(__pyx_t_2 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2673, __pyx_L1_error) + __PYX_ERR(1, 2832, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2673, __pyx_L1_error) + __pyx_t_3 = PyTuple_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2832, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_self->__pyx___kwargs_len = __pyx_t_3; - /* "dependency_injector/providers.pyx":2674 + /* "dependency_injector/providers.pyx":2833 * self.__kwargs += parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) * return self # <<<<<<<<<<<<<< @@ -48120,7 +52162,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_12add_kwarg __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2667 + /* "dependency_injector/providers.pyx":2826 * return kwargs * * def add_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -48140,7 +52182,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_12add_kwarg return __pyx_r; } -/* "dependency_injector/providers.pyx":2676 +/* "dependency_injector/providers.pyx":2835 * return self * * def set_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -48179,14 +52221,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_14set_kwarg int __pyx_clineno = 0; __Pyx_RefNannySetupContext("set_kwargs", 0); - /* "dependency_injector/providers.pyx":2683 + /* "dependency_injector/providers.pyx":2842 * :return: Reference ``self`` * """ * self.__kwargs = parse_named_injections(kwargs) # <<<<<<<<<<<<<< * self.__kwargs_len = len(self.__kwargs) * return self */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2683, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2842, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___kwargs); @@ -48194,7 +52236,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_14set_kwarg __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2684 + /* "dependency_injector/providers.pyx":2843 * """ * self.__kwargs = parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) # <<<<<<<<<<<<<< @@ -48205,13 +52247,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_14set_kwarg __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2684, __pyx_L1_error) + __PYX_ERR(1, 2843, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2684, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2843, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___kwargs_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":2685 + /* "dependency_injector/providers.pyx":2844 * self.__kwargs = parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) * return self # <<<<<<<<<<<<<< @@ -48223,7 +52265,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_14set_kwarg __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2676 + /* "dependency_injector/providers.pyx":2835 * return self * * def set_kwargs(self, **kwargs): # <<<<<<<<<<<<<< @@ -48242,7 +52284,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_14set_kwarg return __pyx_r; } -/* "dependency_injector/providers.pyx":2687 +/* "dependency_injector/providers.pyx":2846 * return self * * def clear_kwargs(self): # <<<<<<<<<<<<<< @@ -48274,14 +52316,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_16clear_kwa int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_kwargs", 0); - /* "dependency_injector/providers.pyx":2692 + /* "dependency_injector/providers.pyx":2851 * :return: Reference ``self`` * """ * self.__kwargs = tuple() # <<<<<<<<<<<<<< * self.__kwargs_len = len(self.__kwargs) * return self */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2692, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)(&PyTuple_Type))); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2851, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___kwargs); @@ -48289,7 +52331,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_16clear_kwa __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2693 + /* "dependency_injector/providers.pyx":2852 * """ * self.__kwargs = tuple() * self.__kwargs_len = len(self.__kwargs) # <<<<<<<<<<<<<< @@ -48300,13 +52342,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_16clear_kwa __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 2693, __pyx_L1_error) + __PYX_ERR(1, 2852, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2693, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 2852, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___kwargs_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":2694 + /* "dependency_injector/providers.pyx":2853 * self.__kwargs = tuple() * self.__kwargs_len = len(self.__kwargs) * return self # <<<<<<<<<<<<<< @@ -48318,7 +52360,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_16clear_kwa __pyx_r = ((PyObject *)__pyx_v_self); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2687 + /* "dependency_injector/providers.pyx":2846 * return self * * def clear_kwargs(self): # <<<<<<<<<<<<<< @@ -48337,7 +52379,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_16clear_kwa return __pyx_r; } -/* "dependency_injector/providers.pyx":2697 +/* "dependency_injector/providers.pyx":2856 * * @property * def initialized(self): # <<<<<<<<<<<<<< @@ -48367,7 +52409,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_11initializ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":2699 + /* "dependency_injector/providers.pyx":2858 * def initialized(self): * """Check if resource is initialized.""" * return self.__initialized # <<<<<<<<<<<<<< @@ -48375,13 +52417,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_11initializ * def init(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_v_self->__pyx___initialized); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2699, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_v_self->__pyx___initialized); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2858, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2697 + /* "dependency_injector/providers.pyx":2856 * * @property * def initialized(self): # <<<<<<<<<<<<<< @@ -48400,7 +52442,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_11initializ return __pyx_r; } -/* "dependency_injector/providers.pyx":2701 +/* "dependency_injector/providers.pyx":2860 * return self.__initialized * * def init(self): # <<<<<<<<<<<<<< @@ -48433,7 +52475,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_18init(stru int __pyx_clineno = 0; __Pyx_RefNannySetupContext("init", 0); - /* "dependency_injector/providers.pyx":2703 + /* "dependency_injector/providers.pyx":2862 * def init(self): * """Initialize resource.""" * return self.__call__() # <<<<<<<<<<<<<< @@ -48441,7 +52483,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_18init(stru * def shutdown(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2703, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_call); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2862, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -48455,14 +52497,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_18init(stru } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2703, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2862, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2701 + /* "dependency_injector/providers.pyx":2860 * return self.__initialized * * def init(self): # <<<<<<<<<<<<<< @@ -48483,7 +52525,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_18init(stru return __pyx_r; } -/* "dependency_injector/providers.pyx":2705 +/* "dependency_injector/providers.pyx":2864 * return self.__call__() * * def shutdown(self): # <<<<<<<<<<<<<< @@ -48506,6 +52548,8 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_21shutdown( } static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_20shutdown(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self) { + PyObject *__pyx_v_result = NULL; + PyObject *__pyx_v_shutdown = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; @@ -48521,19 +52565,124 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_20shutdown( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("shutdown", 0); - /* "dependency_injector/providers.pyx":2707 + /* "dependency_injector/providers.pyx":2866 * def shutdown(self): * """Shutdown resource.""" * if not self.__initialized: # <<<<<<<<<<<<<< - * return - * + * if self.is_async_mode_enabled(): + * result = asyncio.Future() */ __pyx_t_1 = ((!(__pyx_v_self->__pyx___initialized != 0)) != 0); if (__pyx_t_1) { - /* "dependency_injector/providers.pyx":2708 + /* "dependency_injector/providers.pyx":2867 * """Shutdown resource.""" * if not self.__initialized: + * if self.is_async_mode_enabled(): # <<<<<<<<<<<<<< + * result = asyncio.Future() + * result.set_result(None) + */ + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_async_mode_enabled); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2867, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2867, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 2867, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + if (__pyx_t_1) { + + /* "dependency_injector/providers.pyx":2868 + * if not self.__initialized: + * if self.is_async_mode_enabled(): + * result = asyncio.Future() # <<<<<<<<<<<<<< + * result.set_result(None) + * return result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2868, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_Future); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2868, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2868, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_v_result = __pyx_t_2; + __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2869 + * if self.is_async_mode_enabled(): + * result = asyncio.Future() + * result.set_result(None) # <<<<<<<<<<<<<< + * return result + * return + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2869, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_3, Py_None) : __Pyx_PyObject_CallOneArg(__pyx_t_4, Py_None); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2869, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2870 + * result = asyncio.Future() + * result.set_result(None) + * return result # <<<<<<<<<<<<<< + * return + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_result); + __pyx_r = __pyx_v_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":2867 + * """Shutdown resource.""" + * if not self.__initialized: + * if self.is_async_mode_enabled(): # <<<<<<<<<<<<<< + * result = asyncio.Future() + * result.set_result(None) + */ + } + + /* "dependency_injector/providers.pyx":2871 + * result.set_result(None) + * return result * return # <<<<<<<<<<<<<< * * if self.__shutdowner: @@ -48542,129 +52691,207 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_20shutdown( __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2707 + /* "dependency_injector/providers.pyx":2866 * def shutdown(self): * """Shutdown resource.""" * if not self.__initialized: # <<<<<<<<<<<<<< - * return - * + * if self.is_async_mode_enabled(): + * result = asyncio.Future() */ } - /* "dependency_injector/providers.pyx":2710 + /* "dependency_injector/providers.pyx":2873 * return * * if self.__shutdowner: # <<<<<<<<<<<<<< * try: - * self.__shutdowner(self.__resource) + * shutdown = self.__shutdowner(self.__resource) */ - __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_self->__pyx___shutdowner); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 2710, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_self->__pyx___shutdowner); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 2873, __pyx_L1_error) if (__pyx_t_1) { - /* "dependency_injector/providers.pyx":2711 + /* "dependency_injector/providers.pyx":2874 * * if self.__shutdowner: * try: # <<<<<<<<<<<<<< - * self.__shutdowner(self.__resource) + * shutdown = self.__shutdowner(self.__resource) * except StopIteration: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign - __Pyx_ExceptionSave(&__pyx_t_2, &__pyx_t_3, &__pyx_t_4); - __Pyx_XGOTREF(__pyx_t_2); - __Pyx_XGOTREF(__pyx_t_3); - __Pyx_XGOTREF(__pyx_t_4); + __Pyx_ExceptionSave(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7); + __Pyx_XGOTREF(__pyx_t_5); + __Pyx_XGOTREF(__pyx_t_6); + __Pyx_XGOTREF(__pyx_t_7); /*try:*/ { - /* "dependency_injector/providers.pyx":2712 + /* "dependency_injector/providers.pyx":2875 * if self.__shutdowner: * try: - * self.__shutdowner(self.__resource) # <<<<<<<<<<<<<< + * shutdown = self.__shutdowner(self.__resource) # <<<<<<<<<<<<<< * except StopIteration: * pass */ __Pyx_INCREF(__pyx_v_self->__pyx___shutdowner); - __pyx_t_6 = __pyx_v_self->__pyx___shutdowner; __pyx_t_7 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { - __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); - if (likely(__pyx_t_7)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); - __Pyx_INCREF(__pyx_t_7); + __pyx_t_4 = __pyx_v_self->__pyx___shutdowner; __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_6, function); + __Pyx_DECREF_SET(__pyx_t_4, function); } } - __pyx_t_5 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, __pyx_v_self->__pyx___resource) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_self->__pyx___resource); - __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2712, __pyx_L5_error) - __Pyx_GOTREF(__pyx_t_5); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_3, __pyx_v_self->__pyx___resource) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_self->__pyx___resource); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2875, __pyx_L6_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_v_shutdown = __pyx_t_2; + __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2711 + /* "dependency_injector/providers.pyx":2874 * * if self.__shutdowner: * try: # <<<<<<<<<<<<<< - * self.__shutdowner(self.__resource) + * shutdown = self.__shutdowner(self.__resource) * except StopIteration: */ } - __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - goto __pyx_L10_try_end; - __pyx_L5_error:; + + /* "dependency_injector/providers.pyx":2879 + * pass + * else: + * if inspect.isawaitable(shutdown): # <<<<<<<<<<<<<< + * return self._create_shutdown_future(shutdown) + * + */ + /*else:*/ { + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_inspect); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2879, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_isawaitable); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2879, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_v_shutdown) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_shutdown); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2879, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 2879, __pyx_L8_except_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + if (__pyx_t_1) { + + /* "dependency_injector/providers.pyx":2880 + * else: + * if inspect.isawaitable(shutdown): + * return self._create_shutdown_future(shutdown) # <<<<<<<<<<<<<< + * + * self.__resource = None + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_create_shutdown_future); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2880, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_v_shutdown) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_shutdown); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2880, __pyx_L8_except_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; + goto __pyx_L9_except_return; + + /* "dependency_injector/providers.pyx":2879 + * pass + * else: + * if inspect.isawaitable(shutdown): # <<<<<<<<<<<<<< + * return self._create_shutdown_future(shutdown) + * + */ + } + } __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; + goto __pyx_L11_try_end; + __pyx_L6_error:; + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":2713 + /* "dependency_injector/providers.pyx":2876 * try: - * self.__shutdowner(self.__resource) + * shutdown = self.__shutdowner(self.__resource) * except StopIteration: # <<<<<<<<<<<<<< * pass - * + * else: */ __pyx_t_8 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_StopIteration); if (__pyx_t_8) { __Pyx_ErrRestore(0,0,0); - goto __pyx_L6_exception_handled; + goto __pyx_L7_exception_handled; } - goto __pyx_L7_except_error; - __pyx_L7_except_error:; + goto __pyx_L8_except_error; + __pyx_L8_except_error:; - /* "dependency_injector/providers.pyx":2711 + /* "dependency_injector/providers.pyx":2874 * * if self.__shutdowner: * try: # <<<<<<<<<<<<<< - * self.__shutdowner(self.__resource) + * shutdown = self.__shutdowner(self.__resource) * except StopIteration: */ - __Pyx_XGIVEREF(__pyx_t_2); - __Pyx_XGIVEREF(__pyx_t_3); - __Pyx_XGIVEREF(__pyx_t_4); - __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4); + __Pyx_XGIVEREF(__pyx_t_5); + __Pyx_XGIVEREF(__pyx_t_6); + __Pyx_XGIVEREF(__pyx_t_7); + __Pyx_ExceptionReset(__pyx_t_5, __pyx_t_6, __pyx_t_7); goto __pyx_L1_error; - __pyx_L6_exception_handled:; - __Pyx_XGIVEREF(__pyx_t_2); - __Pyx_XGIVEREF(__pyx_t_3); - __Pyx_XGIVEREF(__pyx_t_4); - __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4); - __pyx_L10_try_end:; + __pyx_L9_except_return:; + __Pyx_XGIVEREF(__pyx_t_5); + __Pyx_XGIVEREF(__pyx_t_6); + __Pyx_XGIVEREF(__pyx_t_7); + __Pyx_ExceptionReset(__pyx_t_5, __pyx_t_6, __pyx_t_7); + goto __pyx_L0; + __pyx_L7_exception_handled:; + __Pyx_XGIVEREF(__pyx_t_5); + __Pyx_XGIVEREF(__pyx_t_6); + __Pyx_XGIVEREF(__pyx_t_7); + __Pyx_ExceptionReset(__pyx_t_5, __pyx_t_6, __pyx_t_7); + __pyx_L11_try_end:; } - /* "dependency_injector/providers.pyx":2710 + /* "dependency_injector/providers.pyx":2873 * return * * if self.__shutdowner: # <<<<<<<<<<<<<< * try: - * self.__shutdowner(self.__resource) + * shutdown = self.__shutdowner(self.__resource) */ } - /* "dependency_injector/providers.pyx":2716 - * pass + /* "dependency_injector/providers.pyx":2882 + * return self._create_shutdown_future(shutdown) * * self.__resource = None # <<<<<<<<<<<<<< * self.__initialized = False @@ -48676,7 +52903,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_20shutdown( __Pyx_DECREF(__pyx_v_self->__pyx___resource); __pyx_v_self->__pyx___resource = Py_None; - /* "dependency_injector/providers.pyx":2717 + /* "dependency_injector/providers.pyx":2883 * * self.__resource = None * self.__initialized = False # <<<<<<<<<<<<<< @@ -48685,12 +52912,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_20shutdown( */ __pyx_v_self->__pyx___initialized = 0; - /* "dependency_injector/providers.pyx":2718 + /* "dependency_injector/providers.pyx":2884 * self.__resource = None * self.__initialized = False * self.__shutdowner = None # <<<<<<<<<<<<<< * - * cpdef object _provide(self, tuple args, dict kwargs): + * if self.is_async_mode_enabled(): */ __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); @@ -48698,7 +52925,112 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_20shutdown( __Pyx_DECREF(__pyx_v_self->__pyx___shutdowner); __pyx_v_self->__pyx___shutdowner = Py_None; - /* "dependency_injector/providers.pyx":2705 + /* "dependency_injector/providers.pyx":2886 + * self.__shutdowner = None + * + * if self.is_async_mode_enabled(): # <<<<<<<<<<<<<< + * result = asyncio.Future() + * result.set_result(None) + */ + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_async_mode_enabled); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2886, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2886, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 2886, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + if (__pyx_t_1) { + + /* "dependency_injector/providers.pyx":2887 + * + * if self.is_async_mode_enabled(): + * result = asyncio.Future() # <<<<<<<<<<<<<< + * result.set_result(None) + * return result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2887, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_Future); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2887, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2887, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_v_result = __pyx_t_2; + __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2888 + * if self.is_async_mode_enabled(): + * result = asyncio.Future() + * result.set_result(None) # <<<<<<<<<<<<<< + * return result + * + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2888, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_3, Py_None) : __Pyx_PyObject_CallOneArg(__pyx_t_4, Py_None); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2888, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":2889 + * result = asyncio.Future() + * result.set_result(None) + * return result # <<<<<<<<<<<<<< + * + * cpdef object _provide(self, tuple args, dict kwargs): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_result); + __pyx_r = __pyx_v_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":2886 + * self.__shutdowner = None + * + * if self.is_async_mode_enabled(): # <<<<<<<<<<<<<< + * result = asyncio.Future() + * result.set_result(None) + */ + } + + /* "dependency_injector/providers.pyx":2864 * return self.__call__() * * def shutdown(self): # <<<<<<<<<<<<<< @@ -48710,19 +53042,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_20shutdown( __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; - __Pyx_XDECREF(__pyx_t_5); - __Pyx_XDECREF(__pyx_t_6); - __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("dependency_injector.providers.Resource.shutdown", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; + __Pyx_XDECREF(__pyx_v_result); + __Pyx_XDECREF(__pyx_v_shutdown); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "dependency_injector/providers.pyx":2720 - * self.__shutdowner = None +/* "dependency_injector/providers.pyx":2891 + * return result * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * if self.__initialized: @@ -48732,6 +53066,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_20shutdown( static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_23_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch) { PyObject *__pyx_v_initializer = NULL; + PyObject *__pyx_v_async_init = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -48741,7 +53076,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_t_7; - int __pyx_t_8; + PyObject *__pyx_t_8 = NULL; + int __pyx_t_9; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -48755,7 +53091,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2720, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2891, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_8Resource_23_provide)) { __Pyx_XDECREF(__pyx_r); @@ -48775,7 +53111,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2720, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2891, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -48783,13 +53119,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2720, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2891, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2720, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2891, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -48800,7 +53136,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2720, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2891, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -48823,7 +53159,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str #endif } - /* "dependency_injector/providers.pyx":2721 + /* "dependency_injector/providers.pyx":2892 * * cpdef object _provide(self, tuple args, dict kwargs): * if self.__initialized: # <<<<<<<<<<<<<< @@ -48833,7 +53169,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str __pyx_t_7 = (__pyx_v_self->__pyx___initialized != 0); if (__pyx_t_7) { - /* "dependency_injector/providers.pyx":2722 + /* "dependency_injector/providers.pyx":2893 * cpdef object _provide(self, tuple args, dict kwargs): * if self.__initialized: * return self.__resource # <<<<<<<<<<<<<< @@ -48845,7 +53181,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str __pyx_r = __pyx_v_self->__pyx___resource; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2721 + /* "dependency_injector/providers.pyx":2892 * * cpdef object _provide(self, tuple args, dict kwargs): * if self.__initialized: # <<<<<<<<<<<<<< @@ -48854,14 +53190,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str */ } - /* "dependency_injector/providers.pyx":2724 + /* "dependency_injector/providers.pyx":2895 * return self.__resource * * if self._is_resource_subclass(self.__initializer): # <<<<<<<<<<<<<< * initializer = self.__initializer() * self.__resource = __call( */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_resource_subclass); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2724, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_resource_subclass); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2895, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -48875,14 +53211,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_self->__pyx___initializer) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_self->__pyx___initializer); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2724, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2895, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 2724, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 2895, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; if (__pyx_t_7) { - /* "dependency_injector/providers.pyx":2725 + /* "dependency_injector/providers.pyx":2896 * * if self._is_resource_subclass(self.__initializer): * initializer = self.__initializer() # <<<<<<<<<<<<<< @@ -48902,23 +53238,23 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2725, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2896, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_initializer = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2727 + /* "dependency_injector/providers.pyx":2898 * initializer = self.__initializer() * self.__resource = __call( * initializer.init, # <<<<<<<<<<<<<< * args, * self.__args, */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_init_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2727, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_init_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2898, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":2729 + /* "dependency_injector/providers.pyx":2900 * initializer.init, * args, * self.__args, # <<<<<<<<<<<<<< @@ -48928,7 +53264,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str __pyx_t_2 = __pyx_v_self->__pyx___args; __Pyx_INCREF(__pyx_t_2); - /* "dependency_injector/providers.pyx":2732 + /* "dependency_injector/providers.pyx":2903 * self.__args_len, * kwargs, * self.__kwargs, # <<<<<<<<<<<<<< @@ -48938,14 +53274,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str __pyx_t_3 = __pyx_v_self->__pyx___kwargs; __Pyx_INCREF(__pyx_t_3); - /* "dependency_injector/providers.pyx":2726 + /* "dependency_injector/providers.pyx":2897 * if self._is_resource_subclass(self.__initializer): * initializer = self.__initializer() * self.__resource = __call( # <<<<<<<<<<<<<< * initializer.init, * args, */ - __pyx_t_6 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_1, __pyx_v_args, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_3), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2726, __pyx_L1_error) + __pyx_t_6 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_1, __pyx_v_args, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_3), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2897, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -48956,14 +53292,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str __pyx_v_self->__pyx___resource = __pyx_t_6; __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":2735 + /* "dependency_injector/providers.pyx":2906 * self.__kwargs_len, * ) * self.__shutdowner = initializer.shutdown # <<<<<<<<<<<<<< - * elif inspect.isgeneratorfunction(self.__initializer): - * initializer = __call( + * elif self._is_async_resource_subclass(self.__initializer): + * initializer = self.__initializer() */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_shutdown); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2735, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_shutdown); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2906, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_6); __Pyx_GOTREF(__pyx_v_self->__pyx___shutdowner); @@ -48971,7 +53307,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str __pyx_v_self->__pyx___shutdowner = __pyx_t_6; __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":2724 + /* "dependency_injector/providers.pyx":2895 * return self.__resource * * if self._is_resource_subclass(self.__initializer): # <<<<<<<<<<<<<< @@ -48981,148 +53317,72 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str goto __pyx_L4; } - /* "dependency_injector/providers.pyx":2736 + /* "dependency_injector/providers.pyx":2907 * ) * self.__shutdowner = initializer.shutdown - * elif inspect.isgeneratorfunction(self.__initializer): # <<<<<<<<<<<<<< - * initializer = __call( - * self.__initializer, + * elif self._is_async_resource_subclass(self.__initializer): # <<<<<<<<<<<<<< + * initializer = self.__initializer() + * async_init = __call( */ - __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_inspect); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2736, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_is_async_resource_subclass); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2907, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_isgeneratorfunction); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2736, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = NULL; - if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { - __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); - if (likely(__pyx_t_3)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); - __Pyx_INCREF(__pyx_t_3); + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_2, function); + __Pyx_DECREF_SET(__pyx_t_3, function); } } - __pyx_t_6 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_self->__pyx___initializer) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_self->__pyx___initializer); - __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2736, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, __pyx_v_self->__pyx___initializer) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_self->__pyx___initializer); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2907, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 2736, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 2907, __pyx_L1_error) __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; if (__pyx_t_7) { - /* "dependency_injector/providers.pyx":2738 - * elif inspect.isgeneratorfunction(self.__initializer): - * initializer = __call( - * self.__initializer, # <<<<<<<<<<<<<< - * args, - * self.__args, - */ - __pyx_t_6 = __pyx_v_self->__pyx___initializer; - __Pyx_INCREF(__pyx_t_6); - - /* "dependency_injector/providers.pyx":2740 - * self.__initializer, - * args, - * self.__args, # <<<<<<<<<<<<<< - * self.__args_len, - * kwargs, - */ - __pyx_t_2 = __pyx_v_self->__pyx___args; - __Pyx_INCREF(__pyx_t_2); - - /* "dependency_injector/providers.pyx":2743 - * self.__args_len, - * kwargs, - * self.__kwargs, # <<<<<<<<<<<<<< - * self.__kwargs_len, - * ) - */ - __pyx_t_3 = __pyx_v_self->__pyx___kwargs; - __Pyx_INCREF(__pyx_t_3); - - /* "dependency_injector/providers.pyx":2737 + /* "dependency_injector/providers.pyx":2908 * self.__shutdowner = initializer.shutdown - * elif inspect.isgeneratorfunction(self.__initializer): - * initializer = __call( # <<<<<<<<<<<<<< - * self.__initializer, - * args, + * elif self._is_async_resource_subclass(self.__initializer): + * initializer = self.__initializer() # <<<<<<<<<<<<<< + * async_init = __call( + * initializer.init, */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_6, __pyx_v_args, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_3), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2737, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_INCREF(__pyx_v_self->__pyx___initializer); + __pyx_t_3 = __pyx_v_self->__pyx___initializer; __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_6 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2908, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_v_initializer = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_v_initializer = __pyx_t_6; + __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":2746 - * self.__kwargs_len, - * ) - * self.__resource = next(initializer) # <<<<<<<<<<<<<< - * self.__shutdowner = initializer.send - * elif callable(self.__initializer): - */ - __pyx_t_1 = __Pyx_PyIter_Next(__pyx_v_initializer); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2746, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_1); - __Pyx_GOTREF(__pyx_v_self->__pyx___resource); - __Pyx_DECREF(__pyx_v_self->__pyx___resource); - __pyx_v_self->__pyx___resource = __pyx_t_1; - __pyx_t_1 = 0; - - /* "dependency_injector/providers.pyx":2747 - * ) - * self.__resource = next(initializer) - * self.__shutdowner = initializer.send # <<<<<<<<<<<<<< - * elif callable(self.__initializer): - * self.__resource = __call( - */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_send); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2747, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_1); - __Pyx_GOTREF(__pyx_v_self->__pyx___shutdowner); - __Pyx_DECREF(__pyx_v_self->__pyx___shutdowner); - __pyx_v_self->__pyx___shutdowner = __pyx_t_1; - __pyx_t_1 = 0; - - /* "dependency_injector/providers.pyx":2736 - * ) - * self.__shutdowner = initializer.shutdown - * elif inspect.isgeneratorfunction(self.__initializer): # <<<<<<<<<<<<<< - * initializer = __call( - * self.__initializer, - */ - goto __pyx_L4; - } - - /* "dependency_injector/providers.pyx":2748 - * self.__resource = next(initializer) - * self.__shutdowner = initializer.send - * elif callable(self.__initializer): # <<<<<<<<<<<<<< - * self.__resource = __call( - * self.__initializer, - */ - __pyx_t_1 = __pyx_v_self->__pyx___initializer; - __Pyx_INCREF(__pyx_t_1); - __pyx_t_7 = __Pyx_PyCallable_Check(__pyx_t_1); if (unlikely(__pyx_t_7 == ((int)-1))) __PYX_ERR(1, 2748, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_8 = (__pyx_t_7 != 0); - if (likely(__pyx_t_8)) { - - /* "dependency_injector/providers.pyx":2750 - * elif callable(self.__initializer): - * self.__resource = __call( - * self.__initializer, # <<<<<<<<<<<<<< + /* "dependency_injector/providers.pyx":2910 + * initializer = self.__initializer() + * async_init = __call( + * initializer.init, # <<<<<<<<<<<<<< * args, * self.__args, */ - __pyx_t_1 = __pyx_v_self->__pyx___initializer; - __Pyx_INCREF(__pyx_t_1); + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_init_2); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2910, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); - /* "dependency_injector/providers.pyx":2752 - * self.__initializer, + /* "dependency_injector/providers.pyx":2912 + * initializer.init, * args, * self.__args, # <<<<<<<<<<<<<< * self.__args_len, @@ -49131,7 +53391,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str __pyx_t_3 = __pyx_v_self->__pyx___args; __Pyx_INCREF(__pyx_t_3); - /* "dependency_injector/providers.pyx":2755 + /* "dependency_injector/providers.pyx":2915 * self.__args_len, * kwargs, * self.__kwargs, # <<<<<<<<<<<<<< @@ -49141,27 +53401,576 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str __pyx_t_2 = __pyx_v_self->__pyx___kwargs; __Pyx_INCREF(__pyx_t_2); - /* "dependency_injector/providers.pyx":2749 + /* "dependency_injector/providers.pyx":2909 + * elif self._is_async_resource_subclass(self.__initializer): + * initializer = self.__initializer() + * async_init = __call( # <<<<<<<<<<<<<< + * initializer.init, + * args, + */ + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_6, __pyx_v_args, ((PyObject*)__pyx_t_3), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2909, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_async_init = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":2918 + * self.__kwargs_len, + * ) + * self.__initialized = True # <<<<<<<<<<<<<< + * return self._create_init_future(async_init, initializer.shutdown) + * elif inspect.isgeneratorfunction(self.__initializer): + */ + __pyx_v_self->__pyx___initialized = 1; + + /* "dependency_injector/providers.pyx":2919 + * ) + * self.__initialized = True + * return self._create_init_future(async_init, initializer.shutdown) # <<<<<<<<<<<<<< + * elif inspect.isgeneratorfunction(self.__initializer): + * initializer = __call( + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_create_init_future); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2919, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_shutdown); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2919, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_6 = NULL; + __pyx_t_5 = 0; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + __pyx_t_5 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_2)) { + PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_v_async_init, __pyx_t_3}; + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2919, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { + PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_v_async_init, __pyx_t_3}; + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2919, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + } else + #endif + { + __pyx_t_4 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2919, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + if (__pyx_t_6) { + __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); __pyx_t_6 = NULL; + } + __Pyx_INCREF(__pyx_v_async_init); + __Pyx_GIVEREF(__pyx_v_async_init); + PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_5, __pyx_v_async_init); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_5, __pyx_t_3); + __pyx_t_3 = 0; + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2919, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + } + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":2907 + * ) + * self.__shutdowner = initializer.shutdown + * elif self._is_async_resource_subclass(self.__initializer): # <<<<<<<<<<<<<< + * initializer = self.__initializer() + * async_init = __call( + */ + } + + /* "dependency_injector/providers.pyx":2920 + * self.__initialized = True + * return self._create_init_future(async_init, initializer.shutdown) + * elif inspect.isgeneratorfunction(self.__initializer): # <<<<<<<<<<<<<< + * initializer = __call( + * self.__initializer, + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_inspect); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2920, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_isgeneratorfunction); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2920, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_2, __pyx_v_self->__pyx___initializer) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_self->__pyx___initializer); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2920, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 2920, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + if (__pyx_t_7) { + + /* "dependency_injector/providers.pyx":2922 + * elif inspect.isgeneratorfunction(self.__initializer): + * initializer = __call( + * self.__initializer, # <<<<<<<<<<<<<< + * args, + * self.__args, + */ + __pyx_t_1 = __pyx_v_self->__pyx___initializer; + __Pyx_INCREF(__pyx_t_1); + + /* "dependency_injector/providers.pyx":2924 + * self.__initializer, + * args, + * self.__args, # <<<<<<<<<<<<<< + * self.__args_len, + * kwargs, + */ + __pyx_t_4 = __pyx_v_self->__pyx___args; + __Pyx_INCREF(__pyx_t_4); + + /* "dependency_injector/providers.pyx":2927 + * self.__args_len, + * kwargs, + * self.__kwargs, # <<<<<<<<<<<<<< + * self.__kwargs_len, + * ) + */ + __pyx_t_2 = __pyx_v_self->__pyx___kwargs; + __Pyx_INCREF(__pyx_t_2); + + /* "dependency_injector/providers.pyx":2921 + * return self._create_init_future(async_init, initializer.shutdown) + * elif inspect.isgeneratorfunction(self.__initializer): + * initializer = __call( # <<<<<<<<<<<<<< + * self.__initializer, + * args, + */ + __pyx_t_3 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_1, __pyx_v_args, ((PyObject*)__pyx_t_4), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2921, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_initializer = __pyx_t_3; + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":2930 + * self.__kwargs_len, + * ) + * self.__resource = next(initializer) # <<<<<<<<<<<<<< * self.__shutdowner = initializer.send + * elif iscoroutinefunction(self.__initializer): + */ + __pyx_t_3 = __Pyx_PyIter_Next(__pyx_v_initializer); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2930, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_3); + __Pyx_GOTREF(__pyx_v_self->__pyx___resource); + __Pyx_DECREF(__pyx_v_self->__pyx___resource); + __pyx_v_self->__pyx___resource = __pyx_t_3; + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":2931 + * ) + * self.__resource = next(initializer) + * self.__shutdowner = initializer.send # <<<<<<<<<<<<<< + * elif iscoroutinefunction(self.__initializer): + * initializer = __call( + */ + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_send); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2931, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_3); + __Pyx_GOTREF(__pyx_v_self->__pyx___shutdowner); + __Pyx_DECREF(__pyx_v_self->__pyx___shutdowner); + __pyx_v_self->__pyx___shutdowner = __pyx_t_3; + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":2920 + * self.__initialized = True + * return self._create_init_future(async_init, initializer.shutdown) + * elif inspect.isgeneratorfunction(self.__initializer): # <<<<<<<<<<<<<< + * initializer = __call( + * self.__initializer, + */ + goto __pyx_L4; + } + + /* "dependency_injector/providers.pyx":2932 + * self.__resource = next(initializer) + * self.__shutdowner = initializer.send + * elif iscoroutinefunction(self.__initializer): # <<<<<<<<<<<<<< + * initializer = __call( + * self.__initializer, + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_iscoroutinefunction); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2932, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_v_self->__pyx___initializer) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_self->__pyx___initializer); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2932, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 2932, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (__pyx_t_7) { + + /* "dependency_injector/providers.pyx":2934 + * elif iscoroutinefunction(self.__initializer): + * initializer = __call( + * self.__initializer, # <<<<<<<<<<<<<< + * args, + * self.__args, + */ + __pyx_t_3 = __pyx_v_self->__pyx___initializer; + __Pyx_INCREF(__pyx_t_3); + + /* "dependency_injector/providers.pyx":2936 + * self.__initializer, + * args, + * self.__args, # <<<<<<<<<<<<<< + * self.__args_len, + * kwargs, + */ + __pyx_t_2 = __pyx_v_self->__pyx___args; + __Pyx_INCREF(__pyx_t_2); + + /* "dependency_injector/providers.pyx":2939 + * self.__args_len, + * kwargs, + * self.__kwargs, # <<<<<<<<<<<<<< + * self.__kwargs_len, + * ) + */ + __pyx_t_4 = __pyx_v_self->__pyx___kwargs; + __Pyx_INCREF(__pyx_t_4); + + /* "dependency_injector/providers.pyx":2933 + * self.__shutdowner = initializer.send + * elif iscoroutinefunction(self.__initializer): + * initializer = __call( # <<<<<<<<<<<<<< + * self.__initializer, + * args, + */ + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_3, __pyx_v_args, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_4), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2933, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_v_initializer = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":2942 + * self.__kwargs_len, + * ) + * self.__initialized = True # <<<<<<<<<<<<<< + * return self._create_init_future(initializer) + * elif isasyncgenfunction(self.__initializer): + */ + __pyx_v_self->__pyx___initialized = 1; + + /* "dependency_injector/providers.pyx":2943 + * ) + * self.__initialized = True + * return self._create_init_future(initializer) # <<<<<<<<<<<<<< + * elif isasyncgenfunction(self.__initializer): + * initializer = __call( + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_create_init_future); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2943, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_2, __pyx_v_initializer) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_initializer); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2943, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":2932 + * self.__resource = next(initializer) + * self.__shutdowner = initializer.send + * elif iscoroutinefunction(self.__initializer): # <<<<<<<<<<<<<< + * initializer = __call( + * self.__initializer, + */ + } + + /* "dependency_injector/providers.pyx":2944 + * self.__initialized = True + * return self._create_init_future(initializer) + * elif isasyncgenfunction(self.__initializer): # <<<<<<<<<<<<<< + * initializer = __call( + * self.__initializer, + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_isasyncgenfunction); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2944, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_2, __pyx_v_self->__pyx___initializer) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_self->__pyx___initializer); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2944, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(1, 2944, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + if (__pyx_t_7) { + + /* "dependency_injector/providers.pyx":2946 + * elif isasyncgenfunction(self.__initializer): + * initializer = __call( + * self.__initializer, # <<<<<<<<<<<<<< + * args, + * self.__args, + */ + __pyx_t_1 = __pyx_v_self->__pyx___initializer; + __Pyx_INCREF(__pyx_t_1); + + /* "dependency_injector/providers.pyx":2948 + * self.__initializer, + * args, + * self.__args, # <<<<<<<<<<<<<< + * self.__args_len, + * kwargs, + */ + __pyx_t_4 = __pyx_v_self->__pyx___args; + __Pyx_INCREF(__pyx_t_4); + + /* "dependency_injector/providers.pyx":2951 + * self.__args_len, + * kwargs, + * self.__kwargs, # <<<<<<<<<<<<<< + * self.__kwargs_len, + * ) + */ + __pyx_t_2 = __pyx_v_self->__pyx___kwargs; + __Pyx_INCREF(__pyx_t_2); + + /* "dependency_injector/providers.pyx":2945 + * return self._create_init_future(initializer) + * elif isasyncgenfunction(self.__initializer): + * initializer = __call( # <<<<<<<<<<<<<< + * self.__initializer, + * args, + */ + __pyx_t_3 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_1, __pyx_v_args, ((PyObject*)__pyx_t_4), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2945, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_initializer = __pyx_t_3; + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":2954 + * self.__kwargs_len, + * ) + * self.__initialized = True # <<<<<<<<<<<<<< + * return self._create_init_future(initializer.__anext__(), initializer.asend) + * elif callable(self.__initializer): + */ + __pyx_v_self->__pyx___initialized = 1; + + /* "dependency_injector/providers.pyx":2955 + * ) + * self.__initialized = True + * return self._create_init_future(initializer.__anext__(), initializer.asend) # <<<<<<<<<<<<<< + * elif callable(self.__initializer): + * self.__resource = __call( + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_create_init_future); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2955, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_anext); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2955, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_1); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_1, function); + } + } + __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2955, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_asend); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2955, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_6 = NULL; + __pyx_t_5 = 0; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + __pyx_t_5 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_2)) { + PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_4, __pyx_t_1}; + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2955, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { + PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_4, __pyx_t_1}; + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2955, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + } else + #endif + { + __pyx_t_8 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2955, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + if (__pyx_t_6) { + __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; + } + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_5, __pyx_t_4); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_5, __pyx_t_1); + __pyx_t_4 = 0; + __pyx_t_1 = 0; + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2955, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + } + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_r = __pyx_t_3; + __pyx_t_3 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":2944 + * self.__initialized = True + * return self._create_init_future(initializer) + * elif isasyncgenfunction(self.__initializer): # <<<<<<<<<<<<<< + * initializer = __call( + * self.__initializer, + */ + } + + /* "dependency_injector/providers.pyx":2956 + * self.__initialized = True + * return self._create_init_future(initializer.__anext__(), initializer.asend) + * elif callable(self.__initializer): # <<<<<<<<<<<<<< + * self.__resource = __call( + * self.__initializer, + */ + __pyx_t_3 = __pyx_v_self->__pyx___initializer; + __Pyx_INCREF(__pyx_t_3); + __pyx_t_7 = __Pyx_PyCallable_Check(__pyx_t_3); if (unlikely(__pyx_t_7 == ((int)-1))) __PYX_ERR(1, 2956, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_9 = (__pyx_t_7 != 0); + if (likely(__pyx_t_9)) { + + /* "dependency_injector/providers.pyx":2958 + * elif callable(self.__initializer): + * self.__resource = __call( + * self.__initializer, # <<<<<<<<<<<<<< + * args, + * self.__args, + */ + __pyx_t_3 = __pyx_v_self->__pyx___initializer; + __Pyx_INCREF(__pyx_t_3); + + /* "dependency_injector/providers.pyx":2960 + * self.__initializer, + * args, + * self.__args, # <<<<<<<<<<<<<< + * self.__args_len, + * kwargs, + */ + __pyx_t_2 = __pyx_v_self->__pyx___args; + __Pyx_INCREF(__pyx_t_2); + + /* "dependency_injector/providers.pyx":2963 + * self.__args_len, + * kwargs, + * self.__kwargs, # <<<<<<<<<<<<<< + * self.__kwargs_len, + * ) + */ + __pyx_t_8 = __pyx_v_self->__pyx___kwargs; + __Pyx_INCREF(__pyx_t_8); + + /* "dependency_injector/providers.pyx":2957 + * return self._create_init_future(initializer.__anext__(), initializer.asend) * elif callable(self.__initializer): * self.__resource = __call( # <<<<<<<<<<<<<< * self.__initializer, * args, */ - __pyx_t_6 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_1, __pyx_v_args, ((PyObject*)__pyx_t_3), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2749, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_3, __pyx_v_args, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_8), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2957, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_GIVEREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___resource); __Pyx_DECREF(__pyx_v_self->__pyx___resource); - __pyx_v_self->__pyx___resource = __pyx_t_6; - __pyx_t_6 = 0; + __pyx_v_self->__pyx___resource = __pyx_t_1; + __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2748 - * self.__resource = next(initializer) - * self.__shutdowner = initializer.send + /* "dependency_injector/providers.pyx":2956 + * self.__initialized = True + * return self._create_init_future(initializer.__anext__(), initializer.asend) * elif callable(self.__initializer): # <<<<<<<<<<<<<< * self.__resource = __call( * self.__initializer, @@ -49169,7 +53978,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str goto __pyx_L4; } - /* "dependency_injector/providers.pyx":2759 + /* "dependency_injector/providers.pyx":2967 * ) * else: * raise Error('Unknown type of resource initializer') # <<<<<<<<<<<<<< @@ -49177,30 +53986,30 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str * self.__initialized = True */ /*else*/ { - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2759, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = NULL; - if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { - __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); - if (likely(__pyx_t_3)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); - __Pyx_INCREF(__pyx_t_3); + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_Error); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2967, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_2, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_6 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_kp_s_Unknown_type_of_resource_initial) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_kp_s_Unknown_type_of_resource_initial); - __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2759, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_Raise(__pyx_t_6, 0, 0, 0); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - __PYX_ERR(1, 2759, __pyx_L1_error) + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_2, __pyx_kp_s_Unknown_type_of_resource_initial) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_kp_s_Unknown_type_of_resource_initial); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2967, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_Raise(__pyx_t_1, 0, 0, 0); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __PYX_ERR(1, 2967, __pyx_L1_error) } __pyx_L4:; - /* "dependency_injector/providers.pyx":2761 + /* "dependency_injector/providers.pyx":2969 * raise Error('Unknown type of resource initializer') * * self.__initialized = True # <<<<<<<<<<<<<< @@ -49209,20 +54018,20 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str */ __pyx_v_self->__pyx___initialized = 1; - /* "dependency_injector/providers.pyx":2762 + /* "dependency_injector/providers.pyx":2970 * * self.__initialized = True * return self.__resource # <<<<<<<<<<<<<< * - * @staticmethod + * def _create_init_future(self, future, shutdowner=None): */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_self->__pyx___resource); __pyx_r = __pyx_v_self->__pyx___resource; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2720 - * self.__shutdowner = None + /* "dependency_injector/providers.pyx":2891 + * return result * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * if self.__initialized: @@ -49236,10 +54045,12 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Resource__provide(str __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_8); __Pyx_AddTraceback("dependency_injector.providers.Resource._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_initializer); + __Pyx_XDECREF(__pyx_v_async_init); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; @@ -49279,11 +54090,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_23_provide( case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2720, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2891, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2720, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2891, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -49296,14 +54107,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_23_provide( } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2720, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2891, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Resource._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2720, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2720, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2891, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2891, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_22_provide(((struct __pyx_obj_19dependency_injector_9providers_Resource *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -49324,7 +54135,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_22_provide( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_8Resource__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2720, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_8Resource__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2891, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -49341,7 +54152,1006 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_22_provide( return __pyx_r; } -/* "dependency_injector/providers.pyx":2765 +/* "dependency_injector/providers.pyx":2972 + * return self.__resource + * + * def _create_init_future(self, future, shutdowner=None): # <<<<<<<<<<<<<< + * callback = self._async_init_callback + * if shutdowner: + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_25_create_init_future(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_25_create_init_future(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_future = 0; + PyObject *__pyx_v_shutdowner = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_create_init_future (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_future,&__pyx_n_s_shutdowner,0}; + PyObject* values[2] = {0,0}; + values[1] = ((PyObject *)Py_None); + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + CYTHON_FALLTHROUGH; + case 1: + if (kw_args > 0) { + PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_shutdowner); + if (value) { values[1] = value; kw_args--; } + } + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_create_init_future") < 0)) __PYX_ERR(1, 2972, __pyx_L3_error) + } + } else { + switch (PyTuple_GET_SIZE(__pyx_args)) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + break; + default: goto __pyx_L5_argtuple_error; + } + } + __pyx_v_future = values[0]; + __pyx_v_shutdowner = values[1]; + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_create_init_future", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2972, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.Resource._create_init_future", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_24_create_init_future(((struct __pyx_obj_19dependency_injector_9providers_Resource *)__pyx_v_self), __pyx_v_future, __pyx_v_shutdowner); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_create_init_future(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v_future, PyObject *__pyx_v_shutdowner) { + PyObject *__pyx_v_callback = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_t_2; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_create_init_future", 0); + __Pyx_INCREF(__pyx_v_future); + + /* "dependency_injector/providers.pyx":2973 + * + * def _create_init_future(self, future, shutdowner=None): + * callback = self._async_init_callback # <<<<<<<<<<<<<< + * if shutdowner: + * callback = functools.partial(callback, shutdowner=shutdowner) + */ + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_async_init_callback); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2973, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_callback = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":2974 + * def _create_init_future(self, future, shutdowner=None): + * callback = self._async_init_callback + * if shutdowner: # <<<<<<<<<<<<<< + * callback = functools.partial(callback, shutdowner=shutdowner) + * + */ + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_shutdowner); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 2974, __pyx_L1_error) + if (__pyx_t_2) { + + /* "dependency_injector/providers.pyx":2975 + * callback = self._async_init_callback + * if shutdowner: + * callback = functools.partial(callback, shutdowner=shutdowner) # <<<<<<<<<<<<<< + * + * future = asyncio.ensure_future(future) + */ + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_functools); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2975, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_partial); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2975, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2975, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_v_callback); + __Pyx_GIVEREF(__pyx_v_callback); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_callback); + __pyx_t_4 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2975, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_shutdowner, __pyx_v_shutdowner) < 0) __PYX_ERR(1, 2975, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_1, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2975, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF_SET(__pyx_v_callback, __pyx_t_5); + __pyx_t_5 = 0; + + /* "dependency_injector/providers.pyx":2974 + * def _create_init_future(self, future, shutdowner=None): + * callback = self._async_init_callback + * if shutdowner: # <<<<<<<<<<<<<< + * callback = functools.partial(callback, shutdowner=shutdowner) + * + */ + } + + /* "dependency_injector/providers.pyx":2977 + * callback = functools.partial(callback, shutdowner=shutdowner) + * + * future = asyncio.ensure_future(future) # <<<<<<<<<<<<<< + * future.add_done_callback(callback) + * self.__resource = future + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2977, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2977, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_1, function); + } + } + __pyx_t_5 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_4, __pyx_v_future) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_future); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2977, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF_SET(__pyx_v_future, __pyx_t_5); + __pyx_t_5 = 0; + + /* "dependency_injector/providers.pyx":2978 + * + * future = asyncio.ensure_future(future) + * future.add_done_callback(callback) # <<<<<<<<<<<<<< + * self.__resource = future + * + */ + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2978, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_1, function); + } + } + __pyx_t_5 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_4, __pyx_v_callback) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_callback); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2978, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + + /* "dependency_injector/providers.pyx":2979 + * future = asyncio.ensure_future(future) + * future.add_done_callback(callback) + * self.__resource = future # <<<<<<<<<<<<<< + * + * return future + */ + __Pyx_INCREF(__pyx_v_future); + __Pyx_GIVEREF(__pyx_v_future); + __Pyx_GOTREF(__pyx_v_self->__pyx___resource); + __Pyx_DECREF(__pyx_v_self->__pyx___resource); + __pyx_v_self->__pyx___resource = __pyx_v_future; + + /* "dependency_injector/providers.pyx":2981 + * self.__resource = future + * + * return future # <<<<<<<<<<<<<< + * + * def _async_init_callback(self, initializer, shutdowner=None): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future); + __pyx_r = __pyx_v_future; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":2972 + * return self.__resource + * + * def _create_init_future(self, future, shutdowner=None): # <<<<<<<<<<<<<< + * callback = self._async_init_callback + * if shutdowner: + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_AddTraceback("dependency_injector.providers.Resource._create_init_future", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_callback); + __Pyx_XDECREF(__pyx_v_future); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":2983 + * return future + * + * def _async_init_callback(self, initializer, shutdowner=None): # <<<<<<<<<<<<<< + * try: + * resource = initializer.result() + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_27_async_init_callback(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_27_async_init_callback(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_initializer = 0; + PyObject *__pyx_v_shutdowner = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_async_init_callback (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_initializer,&__pyx_n_s_shutdowner,0}; + PyObject* values[2] = {0,0}; + values[1] = ((PyObject *)Py_None); + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_initializer)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + CYTHON_FALLTHROUGH; + case 1: + if (kw_args > 0) { + PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_shutdowner); + if (value) { values[1] = value; kw_args--; } + } + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_async_init_callback") < 0)) __PYX_ERR(1, 2983, __pyx_L3_error) + } + } else { + switch (PyTuple_GET_SIZE(__pyx_args)) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + break; + default: goto __pyx_L5_argtuple_error; + } + } + __pyx_v_initializer = values[0]; + __pyx_v_shutdowner = values[1]; + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_async_init_callback", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2983, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.Resource._async_init_callback", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_26_async_init_callback(((struct __pyx_obj_19dependency_injector_9providers_Resource *)__pyx_v_self), __pyx_v_initializer, __pyx_v_shutdowner); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26_async_init_callback(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v_initializer, PyObject *__pyx_v_shutdowner) { + PyObject *__pyx_v_resource = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_async_init_callback", 0); + + /* "dependency_injector/providers.pyx":2984 + * + * def _async_init_callback(self, initializer, shutdowner=None): + * try: # <<<<<<<<<<<<<< + * resource = initializer.result() + * except Exception: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); + __Pyx_XGOTREF(__pyx_t_1); + __Pyx_XGOTREF(__pyx_t_2); + __Pyx_XGOTREF(__pyx_t_3); + /*try:*/ { + + /* "dependency_injector/providers.pyx":2985 + * def _async_init_callback(self, initializer, shutdowner=None): + * try: + * resource = initializer.result() # <<<<<<<<<<<<<< + * except Exception: + * self.__initialized = False + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_initializer, __pyx_n_s_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2985, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2985, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_resource = __pyx_t_4; + __pyx_t_4 = 0; + + /* "dependency_injector/providers.pyx":2984 + * + * def _async_init_callback(self, initializer, shutdowner=None): + * try: # <<<<<<<<<<<<<< + * resource = initializer.result() + * except Exception: + */ + } + + /* "dependency_injector/providers.pyx":2990 + * raise + * else: + * self.__resource = resource # <<<<<<<<<<<<<< + * self.__shutdowner = shutdowner + * + */ + /*else:*/ { + __Pyx_INCREF(__pyx_v_resource); + __Pyx_GIVEREF(__pyx_v_resource); + __Pyx_GOTREF(__pyx_v_self->__pyx___resource); + __Pyx_DECREF(__pyx_v_self->__pyx___resource); + __pyx_v_self->__pyx___resource = __pyx_v_resource; + + /* "dependency_injector/providers.pyx":2991 + * else: + * self.__resource = resource + * self.__shutdowner = shutdowner # <<<<<<<<<<<<<< + * + * def _create_shutdown_future(self, shutdown_future): + */ + __Pyx_INCREF(__pyx_v_shutdowner); + __Pyx_GIVEREF(__pyx_v_shutdowner); + __Pyx_GOTREF(__pyx_v_self->__pyx___shutdowner); + __Pyx_DECREF(__pyx_v_self->__pyx___shutdowner); + __pyx_v_self->__pyx___shutdowner = __pyx_v_shutdowner; + } + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + goto __pyx_L8_try_end; + __pyx_L3_error:; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + + /* "dependency_injector/providers.pyx":2986 + * try: + * resource = initializer.result() + * except Exception: # <<<<<<<<<<<<<< + * self.__initialized = False + * raise + */ + __pyx_t_7 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0]))); + if (__pyx_t_7) { + __Pyx_AddTraceback("dependency_injector.providers.Resource._async_init_callback", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_5, &__pyx_t_6) < 0) __PYX_ERR(1, 2986, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_GOTREF(__pyx_t_5); + __Pyx_GOTREF(__pyx_t_6); + + /* "dependency_injector/providers.pyx":2987 + * resource = initializer.result() + * except Exception: + * self.__initialized = False # <<<<<<<<<<<<<< + * raise + * else: + */ + __pyx_v_self->__pyx___initialized = 0; + + /* "dependency_injector/providers.pyx":2988 + * except Exception: + * self.__initialized = False + * raise # <<<<<<<<<<<<<< + * else: + * self.__resource = resource + */ + __Pyx_GIVEREF(__pyx_t_4); + __Pyx_GIVEREF(__pyx_t_5); + __Pyx_XGIVEREF(__pyx_t_6); + __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_5, __pyx_t_6); + __pyx_t_4 = 0; __pyx_t_5 = 0; __pyx_t_6 = 0; + __PYX_ERR(1, 2988, __pyx_L5_except_error) + } + goto __pyx_L5_except_error; + __pyx_L5_except_error:; + + /* "dependency_injector/providers.pyx":2984 + * + * def _async_init_callback(self, initializer, shutdowner=None): + * try: # <<<<<<<<<<<<<< + * resource = initializer.result() + * except Exception: + */ + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L1_error; + __pyx_L8_try_end:; + } + + /* "dependency_injector/providers.pyx":2983 + * return future + * + * def _async_init_callback(self, initializer, shutdowner=None): # <<<<<<<<<<<<<< + * try: + * resource = initializer.result() + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_AddTraceback("dependency_injector.providers.Resource._async_init_callback", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_resource); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":2993 + * self.__shutdowner = shutdowner + * + * def _create_shutdown_future(self, shutdown_future): # <<<<<<<<<<<<<< + * future = asyncio.Future() + * shutdown_future = asyncio.ensure_future(shutdown_future) + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_29_create_shutdown_future(PyObject *__pyx_v_self, PyObject *__pyx_v_shutdown_future); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_29_create_shutdown_future(PyObject *__pyx_v_self, PyObject *__pyx_v_shutdown_future) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_create_shutdown_future (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_28_create_shutdown_future(((struct __pyx_obj_19dependency_injector_9providers_Resource *)__pyx_v_self), ((PyObject *)__pyx_v_shutdown_future)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_28_create_shutdown_future(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v_shutdown_future) { + PyObject *__pyx_v_future = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + PyObject *__pyx_t_8 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_create_shutdown_future", 0); + __Pyx_INCREF(__pyx_v_shutdown_future); + + /* "dependency_injector/providers.pyx":2994 + * + * def _create_shutdown_future(self, shutdown_future): + * future = asyncio.Future() # <<<<<<<<<<<<<< + * shutdown_future = asyncio.ensure_future(shutdown_future) + * shutdown_future.add_done_callback(functools.partial(self._async_shutdown_callback, future)) + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2994, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_Future); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2994, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2994, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_future = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":2995 + * def _create_shutdown_future(self, shutdown_future): + * future = asyncio.Future() + * shutdown_future = asyncio.ensure_future(shutdown_future) # <<<<<<<<<<<<<< + * shutdown_future.add_done_callback(functools.partial(self._async_shutdown_callback, future)) + * return future + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2995, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2995, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_shutdown_future) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_shutdown_future); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2995, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_shutdown_future, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":2996 + * future = asyncio.Future() + * shutdown_future = asyncio.ensure_future(shutdown_future) + * shutdown_future.add_done_callback(functools.partial(self._async_shutdown_callback, future)) # <<<<<<<<<<<<<< + * return future + * + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_shutdown_future, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2996, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_functools); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2996, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_partial); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2996, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_async_shutdown_callback); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2996, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_6 = NULL; + __pyx_t_7 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + __pyx_t_7 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_5)) { + PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_4, __pyx_v_future}; + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2996, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { + PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_4, __pyx_v_future}; + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2996, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + } else + #endif + { + __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2996, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + if (__pyx_t_6) { + __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; + } + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_7, __pyx_t_4); + __Pyx_INCREF(__pyx_v_future); + __Pyx_GIVEREF(__pyx_v_future); + PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_7, __pyx_v_future); + __pyx_t_4 = 0; + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2996, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + } + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_5, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2996, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":2997 + * shutdown_future = asyncio.ensure_future(shutdown_future) + * shutdown_future.add_done_callback(functools.partial(self._async_shutdown_callback, future)) + * return future # <<<<<<<<<<<<<< + * + * def _async_shutdown_callback(self, future_result, shutdowner): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future); + __pyx_r = __pyx_v_future; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":2993 + * self.__shutdowner = shutdowner + * + * def _create_shutdown_future(self, shutdown_future): # <<<<<<<<<<<<<< + * future = asyncio.Future() + * shutdown_future = asyncio.ensure_future(shutdown_future) + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_AddTraceback("dependency_injector.providers.Resource._create_shutdown_future", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_future); + __Pyx_XDECREF(__pyx_v_shutdown_future); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":2999 + * return future + * + * def _async_shutdown_callback(self, future_result, shutdowner): # <<<<<<<<<<<<<< + * try: + * shutdowner.result() + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_31_async_shutdown_callback(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_31_async_shutdown_callback(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_future_result = 0; + PyObject *__pyx_v_shutdowner = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_async_shutdown_callback (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_future_result,&__pyx_n_s_shutdowner,0}; + PyObject* values[2] = {0,0}; + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future_result)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + CYTHON_FALLTHROUGH; + case 1: + if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_shutdowner)) != 0)) kw_args--; + else { + __Pyx_RaiseArgtupleInvalid("_async_shutdown_callback", 1, 2, 2, 1); __PYX_ERR(1, 2999, __pyx_L3_error) + } + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_async_shutdown_callback") < 0)) __PYX_ERR(1, 2999, __pyx_L3_error) + } + } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { + goto __pyx_L5_argtuple_error; + } else { + values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + } + __pyx_v_future_result = values[0]; + __pyx_v_shutdowner = values[1]; + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_async_shutdown_callback", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2999, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.Resource._async_shutdown_callback", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_30_async_shutdown_callback(((struct __pyx_obj_19dependency_injector_9providers_Resource *)__pyx_v_self), __pyx_v_future_result, __pyx_v_shutdowner); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_30_async_shutdown_callback(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_shutdowner) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_async_shutdown_callback", 0); + + /* "dependency_injector/providers.pyx":3000 + * + * def _async_shutdown_callback(self, future_result, shutdowner): + * try: # <<<<<<<<<<<<<< + * shutdowner.result() + * except StopAsyncIteration: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); + __Pyx_XGOTREF(__pyx_t_1); + __Pyx_XGOTREF(__pyx_t_2); + __Pyx_XGOTREF(__pyx_t_3); + /*try:*/ { + + /* "dependency_injector/providers.pyx":3001 + * def _async_shutdown_callback(self, future_result, shutdowner): + * try: + * shutdowner.result() # <<<<<<<<<<<<<< + * except StopAsyncIteration: + * pass + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_shutdowner, __pyx_n_s_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3001, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3001, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + + /* "dependency_injector/providers.pyx":3000 + * + * def _async_shutdown_callback(self, future_result, shutdowner): + * try: # <<<<<<<<<<<<<< + * shutdowner.result() + * except StopAsyncIteration: + */ + } + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + goto __pyx_L8_try_end; + __pyx_L3_error:; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + + /* "dependency_injector/providers.pyx":3002 + * try: + * shutdowner.result() + * except StopAsyncIteration: # <<<<<<<<<<<<<< + * pass + * + */ + __pyx_t_7 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)__Pyx_PyExc_StopAsyncIteration)[0]))); + if (__pyx_t_7) { + __Pyx_ErrRestore(0,0,0); + goto __pyx_L4_exception_handled; + } + goto __pyx_L5_except_error; + __pyx_L5_except_error:; + + /* "dependency_injector/providers.pyx":3000 + * + * def _async_shutdown_callback(self, future_result, shutdowner): + * try: # <<<<<<<<<<<<<< + * shutdowner.result() + * except StopAsyncIteration: + */ + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L1_error; + __pyx_L4_exception_handled:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + __pyx_L8_try_end:; + } + + /* "dependency_injector/providers.pyx":3005 + * pass + * + * self.__resource = None # <<<<<<<<<<<<<< + * self.__initialized = False + * self.__shutdowner = None + */ + __Pyx_INCREF(Py_None); + __Pyx_GIVEREF(Py_None); + __Pyx_GOTREF(__pyx_v_self->__pyx___resource); + __Pyx_DECREF(__pyx_v_self->__pyx___resource); + __pyx_v_self->__pyx___resource = Py_None; + + /* "dependency_injector/providers.pyx":3006 + * + * self.__resource = None + * self.__initialized = False # <<<<<<<<<<<<<< + * self.__shutdowner = None + * + */ + __pyx_v_self->__pyx___initialized = 0; + + /* "dependency_injector/providers.pyx":3007 + * self.__resource = None + * self.__initialized = False + * self.__shutdowner = None # <<<<<<<<<<<<<< + * + * future_result.set_result(None) + */ + __Pyx_INCREF(Py_None); + __Pyx_GIVEREF(Py_None); + __Pyx_GOTREF(__pyx_v_self->__pyx___shutdowner); + __Pyx_DECREF(__pyx_v_self->__pyx___shutdowner); + __pyx_v_self->__pyx___shutdowner = Py_None; + + /* "dependency_injector/providers.pyx":3009 + * self.__shutdowner = None + * + * future_result.set_result(None) # <<<<<<<<<<<<<< + * + * @staticmethod + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3009, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, Py_None) : __Pyx_PyObject_CallOneArg(__pyx_t_5, Py_None); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3009, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + + /* "dependency_injector/providers.pyx":2999 + * return future + * + * def _async_shutdown_callback(self, future_result, shutdowner): # <<<<<<<<<<<<<< + * try: + * shutdowner.result() + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_AddTraceback("dependency_injector.providers.Resource._async_shutdown_callback", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":3012 * * @staticmethod * def _is_resource_subclass(instance): # <<<<<<<<<<<<<< @@ -49350,9 +55160,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_22_provide( */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_25_is_resource_subclass(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_8Resource_25_is_resource_subclass = {"_is_resource_subclass", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Resource_25_is_resource_subclass, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_25_is_resource_subclass(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_33_is_resource_subclass(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_8Resource_33_is_resource_subclass = {"_is_resource_subclass", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Resource_33_is_resource_subclass, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_33_is_resource_subclass(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_instance = 0; int __pyx_lineno = 0; const char *__pyx_filename = NULL; @@ -49379,7 +55189,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_25_is_resou else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_is_resource_subclass") < 0)) __PYX_ERR(1, 2765, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_is_resource_subclass") < 0)) __PYX_ERR(1, 3012, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -49390,20 +55200,20 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_25_is_resou } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_is_resource_subclass", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2765, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_is_resource_subclass", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3012, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Resource._is_resource_subclass", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_24_is_resource_subclass(__pyx_v_instance); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_32_is_resource_subclass(__pyx_v_instance); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_is_resource_subclass(PyObject *__pyx_v_instance) { +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_32_is_resource_subclass(PyObject *__pyx_v_instance) { PyObject *__pyx_v_resources = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations @@ -49416,25 +55226,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_is_resou int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_is_resource_subclass", 0); - /* "dependency_injector/providers.pyx":2766 + /* "dependency_injector/providers.pyx":3013 * @staticmethod * def _is_resource_subclass(instance): * if sys.version_info < (3, 5): # <<<<<<<<<<<<<< * return False * if not isinstance(instance, CLASS_TYPES): */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2766, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3013, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_version_info); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2766, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_version_info); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3013, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyObject_RichCompare(__pyx_t_2, __pyx_tuple__10, Py_LT); __Pyx_XGOTREF(__pyx_t_1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2766, __pyx_L1_error) + __pyx_t_1 = PyObject_RichCompare(__pyx_t_2, __pyx_tuple__11, Py_LT); __Pyx_XGOTREF(__pyx_t_1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3013, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(1, 2766, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(1, 3013, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; if (__pyx_t_3) { - /* "dependency_injector/providers.pyx":2767 + /* "dependency_injector/providers.pyx":3014 * def _is_resource_subclass(instance): * if sys.version_info < (3, 5): * return False # <<<<<<<<<<<<<< @@ -49446,7 +55256,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_is_resou __pyx_r = Py_False; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2766 + /* "dependency_injector/providers.pyx":3013 * @staticmethod * def _is_resource_subclass(instance): * if sys.version_info < (3, 5): # <<<<<<<<<<<<<< @@ -49455,7 +55265,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_is_resou */ } - /* "dependency_injector/providers.pyx":2768 + /* "dependency_injector/providers.pyx":3015 * if sys.version_info < (3, 5): * return False * if not isinstance(instance, CLASS_TYPES): # <<<<<<<<<<<<<< @@ -49464,12 +55274,12 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_is_resou */ __pyx_t_1 = __pyx_v_19dependency_injector_9providers_CLASS_TYPES; __Pyx_INCREF(__pyx_t_1); - __pyx_t_3 = PyObject_IsInstance(__pyx_v_instance, __pyx_t_1); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 2768, __pyx_L1_error) + __pyx_t_3 = PyObject_IsInstance(__pyx_v_instance, __pyx_t_1); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 3015, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_4 = ((!(__pyx_t_3 != 0)) != 0); if (__pyx_t_4) { - /* "dependency_injector/providers.pyx":2769 + /* "dependency_injector/providers.pyx":3016 * return False * if not isinstance(instance, CLASS_TYPES): * return # <<<<<<<<<<<<<< @@ -49480,7 +55290,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_is_resou __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2768 + /* "dependency_injector/providers.pyx":3015 * if sys.version_info < (3, 5): * return False * if not isinstance(instance, CLASS_TYPES): # <<<<<<<<<<<<<< @@ -49489,47 +55299,47 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_is_resou */ } - /* "dependency_injector/providers.pyx":2770 + /* "dependency_injector/providers.pyx":3017 * if not isinstance(instance, CLASS_TYPES): * return * from . import resources # <<<<<<<<<<<<<< * return issubclass(instance, resources.Resource) * */ - __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2770, __pyx_L1_error) + __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3017, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_n_s_resources); __Pyx_GIVEREF(__pyx_n_s_resources); PyList_SET_ITEM(__pyx_t_1, 0, __pyx_n_s_resources); - __pyx_t_2 = __Pyx_Import(__pyx_n_s__11, __pyx_t_1, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2770, __pyx_L1_error) + __pyx_t_2 = __Pyx_Import(__pyx_n_s__12, __pyx_t_1, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3017, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_2, __pyx_n_s_resources); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2770, __pyx_L1_error) + __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_2, __pyx_n_s_resources); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3017, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_t_1); __pyx_v_resources = __pyx_t_1; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2771 + /* "dependency_injector/providers.pyx":3018 * return * from . import resources * return issubclass(instance, resources.Resource) # <<<<<<<<<<<<<< * - * + * @staticmethod */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_resources, __pyx_n_s_Resource); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2771, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_resources, __pyx_n_s_Resource); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3018, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = PyObject_IsSubclass(__pyx_v_instance, __pyx_t_2); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(1, 2771, __pyx_L1_error) + __pyx_t_4 = PyObject_IsSubclass(__pyx_v_instance, __pyx_t_2); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(1, 3018, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_t_4); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2771, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_t_4); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3018, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2765 + /* "dependency_injector/providers.pyx":3012 * * @staticmethod * def _is_resource_subclass(instance): # <<<<<<<<<<<<<< @@ -49550,6 +55360,215 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_is_resou return __pyx_r; } +/* "dependency_injector/providers.pyx":3021 + * + * @staticmethod + * def _is_async_resource_subclass(instance): # <<<<<<<<<<<<<< + * if sys.version_info < (3, 5): + * return False + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_35_is_async_resource_subclass(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_8Resource_35_is_async_resource_subclass = {"_is_async_resource_subclass", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Resource_35_is_async_resource_subclass, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_35_is_async_resource_subclass(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_instance = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_is_async_resource_subclass (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_instance,0}; + PyObject* values[1] = {0}; + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_instance)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_is_async_resource_subclass") < 0)) __PYX_ERR(1, 3021, __pyx_L3_error) + } + } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { + goto __pyx_L5_argtuple_error; + } else { + values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + } + __pyx_v_instance = values[0]; + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_is_async_resource_subclass", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3021, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.Resource._is_async_resource_subclass", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_34_is_async_resource_subclass(__pyx_v_instance); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_34_is_async_resource_subclass(PyObject *__pyx_v_instance) { + PyObject *__pyx_v_resources = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + int __pyx_t_3; + int __pyx_t_4; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_is_async_resource_subclass", 0); + + /* "dependency_injector/providers.pyx":3022 + * @staticmethod + * def _is_async_resource_subclass(instance): + * if sys.version_info < (3, 5): # <<<<<<<<<<<<<< + * return False + * if not isinstance(instance, CLASS_TYPES): + */ + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3022, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_version_info); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3022, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_1 = PyObject_RichCompare(__pyx_t_2, __pyx_tuple__11, Py_LT); __Pyx_XGOTREF(__pyx_t_1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3022, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(1, 3022, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + if (__pyx_t_3) { + + /* "dependency_injector/providers.pyx":3023 + * def _is_async_resource_subclass(instance): + * if sys.version_info < (3, 5): + * return False # <<<<<<<<<<<<<< + * if not isinstance(instance, CLASS_TYPES): + * return + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(Py_False); + __pyx_r = Py_False; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":3022 + * @staticmethod + * def _is_async_resource_subclass(instance): + * if sys.version_info < (3, 5): # <<<<<<<<<<<<<< + * return False + * if not isinstance(instance, CLASS_TYPES): + */ + } + + /* "dependency_injector/providers.pyx":3024 + * if sys.version_info < (3, 5): + * return False + * if not isinstance(instance, CLASS_TYPES): # <<<<<<<<<<<<<< + * return + * from . import resources + */ + __pyx_t_1 = __pyx_v_19dependency_injector_9providers_CLASS_TYPES; + __Pyx_INCREF(__pyx_t_1); + __pyx_t_3 = PyObject_IsInstance(__pyx_v_instance, __pyx_t_1); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 3024, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_4 = ((!(__pyx_t_3 != 0)) != 0); + if (__pyx_t_4) { + + /* "dependency_injector/providers.pyx":3025 + * return False + * if not isinstance(instance, CLASS_TYPES): + * return # <<<<<<<<<<<<<< + * from . import resources + * return issubclass(instance, resources.AsyncResource) + */ + __Pyx_XDECREF(__pyx_r); + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":3024 + * if sys.version_info < (3, 5): + * return False + * if not isinstance(instance, CLASS_TYPES): # <<<<<<<<<<<<<< + * return + * from . import resources + */ + } + + /* "dependency_injector/providers.pyx":3026 + * if not isinstance(instance, CLASS_TYPES): + * return + * from . import resources # <<<<<<<<<<<<<< + * return issubclass(instance, resources.AsyncResource) + * + */ + __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3026, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_n_s_resources); + __Pyx_GIVEREF(__pyx_n_s_resources); + PyList_SET_ITEM(__pyx_t_1, 0, __pyx_n_s_resources); + __pyx_t_2 = __Pyx_Import(__pyx_n_s__12, __pyx_t_1, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3026, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_2, __pyx_n_s_resources); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3026, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_t_1); + __pyx_v_resources = __pyx_t_1; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":3027 + * return + * from . import resources + * return issubclass(instance, resources.AsyncResource) # <<<<<<<<<<<<<< + * + * + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_resources, __pyx_n_s_AsyncResource); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3027, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = PyObject_IsSubclass(__pyx_v_instance, __pyx_t_2); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(1, 3027, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_t_4); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3027, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":3021 + * + * @staticmethod + * def _is_async_resource_subclass(instance): # <<<<<<<<<<<<<< + * if sys.version_info < (3, 5): + * return False + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_AddTraceback("dependency_injector.providers.Resource._is_async_resource_subclass", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_resources); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + /* "(tree fragment)":1 * def __reduce_cython__(self): # <<<<<<<<<<<<<< * cdef tuple state @@ -49557,19 +55576,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_24_is_resou */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_27__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_27__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_37__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_37__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_Resource *)__pyx_v_self)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_36__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_Resource *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self) { +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_36__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self) { PyObject *__pyx_v_state = 0; PyObject *__pyx_v__dict = 0; int __pyx_v_use_setstate; @@ -49579,9 +55598,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_ PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; - int __pyx_t_5; + PyObject *__pyx_t_5 = NULL; int __pyx_t_6; int __pyx_t_7; + int __pyx_t_8; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -49590,73 +55610,78 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__initialized, self.__initializer, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__resource, self.__shutdowner) # <<<<<<<<<<<<<< + * state = (self.__args, self.__args_len, self.__async_mode, self.__initialized, self.__initializer, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__resource, self.__shutdowner) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_v_self->__pyx___initialized); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_v_self->__pyx___initialized); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = PyTuple_New(10); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = PyTuple_New(11); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); __Pyx_INCREF(__pyx_v_self->__pyx___args); __Pyx_GIVEREF(__pyx_v_self->__pyx___args); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->__pyx___args); + PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_v_self->__pyx___args); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_t_1); __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_5, 2, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_5, 3, __pyx_t_3); __Pyx_INCREF(__pyx_v_self->__pyx___initializer); __Pyx_GIVEREF(__pyx_v_self->__pyx___initializer); - PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_v_self->__pyx___initializer); + PyTuple_SET_ITEM(__pyx_t_5, 4, __pyx_v_self->__pyx___initializer); __Pyx_INCREF(__pyx_v_self->__pyx___kwargs); __Pyx_GIVEREF(__pyx_v_self->__pyx___kwargs); - PyTuple_SET_ITEM(__pyx_t_4, 4, __pyx_v_self->__pyx___kwargs); - __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_4, 5, __pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_5, 5, __pyx_v_self->__pyx___kwargs); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_5, 6, __pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_4, 6, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_5, 7, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_4, 7, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_5, 8, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx___resource); __Pyx_GIVEREF(__pyx_v_self->__pyx___resource); - PyTuple_SET_ITEM(__pyx_t_4, 8, __pyx_v_self->__pyx___resource); + PyTuple_SET_ITEM(__pyx_t_5, 9, __pyx_v_self->__pyx___resource); __Pyx_INCREF(__pyx_v_self->__pyx___shutdowner); __Pyx_GIVEREF(__pyx_v_self->__pyx___shutdowner); - PyTuple_SET_ITEM(__pyx_t_4, 9, __pyx_v_self->__pyx___shutdowner); + PyTuple_SET_ITEM(__pyx_t_5, 10, __pyx_v_self->__pyx___shutdowner); __pyx_t_1 = 0; __pyx_t_2 = 0; __pyx_t_3 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_5); + __pyx_t_5 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__initialized, self.__initializer, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__resource, self.__shutdowner) + * state = (self.__args, self.__args_len, self.__async_mode, self.__initialized, self.__initializer, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__resource, self.__shutdowner) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_4 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_v__dict = __pyx_t_4; - __pyx_t_4 = 0; + __pyx_t_5 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_v__dict = __pyx_t_5; + __pyx_t_5 = 0; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__initialized, self.__initializer, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__resource, self.__shutdowner) + * state = (self.__args, self.__args_len, self.__async_mode, self.__initialized, self.__initializer, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__resource, self.__shutdowner) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_5 = (__pyx_v__dict != Py_None); - __pyx_t_6 = (__pyx_t_5 != 0); - if (__pyx_t_6) { + __pyx_t_6 = (__pyx_v__dict != Py_None); + __pyx_t_7 = (__pyx_t_6 != 0); + if (__pyx_t_7) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -49665,16 +55690,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_ * use_setstate = True * else: */ - __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = PyTuple_New(1); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__dict); - __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3)); - __pyx_t_3 = 0; + PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_v__dict); + __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_5); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); + __pyx_t_4 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -49686,7 +55711,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__initialized, self.__initializer, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__resource, self.__shutdowner) + * state = (self.__args, self.__args_len, self.__async_mode, self.__initialized, self.__initializer, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__resource, self.__shutdowner) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -49700,56 +55725,56 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_ * else: * use_setstate = self.__args is not None or self.__initializer is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__resource is not None or self.__shutdowner is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Resource, (type(self), 0xe8b92e4, None), state + * return __pyx_unpickle_Resource, (type(self), 0x734cfcb, None), state */ /*else*/ { - __pyx_t_5 = (__pyx_v_self->__pyx___args != ((PyObject*)Py_None)); - __pyx_t_7 = (__pyx_t_5 != 0); - if (!__pyx_t_7) { + __pyx_t_6 = (__pyx_v_self->__pyx___args != ((PyObject*)Py_None)); + __pyx_t_8 = (__pyx_t_6 != 0); + if (!__pyx_t_8) { } else { - __pyx_t_6 = __pyx_t_7; + __pyx_t_7 = __pyx_t_8; goto __pyx_L4_bool_binop_done; } - __pyx_t_7 = (__pyx_v_self->__pyx___initializer != Py_None); - __pyx_t_5 = (__pyx_t_7 != 0); - if (!__pyx_t_5) { + __pyx_t_8 = (__pyx_v_self->__pyx___initializer != Py_None); + __pyx_t_6 = (__pyx_t_8 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_6 = __pyx_t_5; + __pyx_t_7 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx___kwargs != ((PyObject*)Py_None)); - __pyx_t_7 = (__pyx_t_5 != 0); - if (!__pyx_t_7) { + __pyx_t_6 = (__pyx_v_self->__pyx___kwargs != ((PyObject*)Py_None)); + __pyx_t_8 = (__pyx_t_6 != 0); + if (!__pyx_t_8) { } else { - __pyx_t_6 = __pyx_t_7; + __pyx_t_7 = __pyx_t_8; goto __pyx_L4_bool_binop_done; } - __pyx_t_7 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_7 != 0); - if (!__pyx_t_5) { + __pyx_t_8 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_6 = (__pyx_t_8 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_6 = __pyx_t_5; + __pyx_t_7 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_7 = (__pyx_t_5 != 0); - if (!__pyx_t_7) { + __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_8 = (__pyx_t_6 != 0); + if (!__pyx_t_8) { } else { - __pyx_t_6 = __pyx_t_7; + __pyx_t_7 = __pyx_t_8; goto __pyx_L4_bool_binop_done; } - __pyx_t_7 = (__pyx_v_self->__pyx___resource != Py_None); - __pyx_t_5 = (__pyx_t_7 != 0); - if (!__pyx_t_5) { + __pyx_t_8 = (__pyx_v_self->__pyx___resource != Py_None); + __pyx_t_6 = (__pyx_t_8 != 0); + if (!__pyx_t_6) { } else { - __pyx_t_6 = __pyx_t_5; + __pyx_t_7 = __pyx_t_6; goto __pyx_L4_bool_binop_done; } - __pyx_t_5 = (__pyx_v_self->__pyx___shutdowner != Py_None); - __pyx_t_7 = (__pyx_t_5 != 0); - __pyx_t_6 = __pyx_t_7; + __pyx_t_6 = (__pyx_v_self->__pyx___shutdowner != Py_None); + __pyx_t_8 = (__pyx_t_6 != 0); + __pyx_t_7 = __pyx_t_8; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_6; + __pyx_v_use_setstate = __pyx_t_7; } __pyx_L3:; @@ -49757,89 +55782,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_ * else: * use_setstate = self.__args is not None or self.__initializer is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__resource is not None or self.__shutdowner is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Resource, (type(self), 0xe8b92e4, None), state + * return __pyx_unpickle_Resource, (type(self), 0x734cfcb, None), state * else: */ - __pyx_t_6 = (__pyx_v_use_setstate != 0); - if (__pyx_t_6) { + __pyx_t_7 = (__pyx_v_use_setstate != 0); + if (__pyx_t_7) { /* "(tree fragment)":13 * use_setstate = self.__args is not None or self.__initializer is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__resource is not None or self.__shutdowner is not None * if use_setstate: - * return __pyx_unpickle_Resource, (type(self), 0xe8b92e4, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Resource, (type(self), 0x734cfcb, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Resource, (type(self), 0xe8b92e4, state) + * return __pyx_unpickle_Resource, (type(self), 0x734cfcb, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_Resource); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Resource); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = PyTuple_New(3); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_244028132); - __Pyx_GIVEREF(__pyx_int_244028132); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_244028132); + PyTuple_SET_ITEM(__pyx_t_5, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_120901579); + __Pyx_GIVEREF(__pyx_int_120901579); + PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_int_120901579); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_4, 2, Py_None); - __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_5, 2, Py_None); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); + __Pyx_GIVEREF(__pyx_t_5); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_5); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); - __pyx_t_3 = 0; + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); __pyx_t_4 = 0; - __pyx_r = __pyx_t_2; - __pyx_t_2 = 0; + __pyx_t_5 = 0; + __pyx_r = __pyx_t_3; + __pyx_t_3 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__args is not None or self.__initializer is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__resource is not None or self.__shutdowner is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Resource, (type(self), 0xe8b92e4, None), state + * return __pyx_unpickle_Resource, (type(self), 0x734cfcb, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Resource, (type(self), 0xe8b92e4, None), state + * return __pyx_unpickle_Resource, (type(self), 0x734cfcb, None), state * else: - * return __pyx_unpickle_Resource, (type(self), 0xe8b92e4, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Resource, (type(self), 0x734cfcb, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Resource__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_Resource); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_Resource); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_5 = PyTuple_New(3); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_244028132); - __Pyx_GIVEREF(__pyx_int_244028132); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_244028132); + PyTuple_SET_ITEM(__pyx_t_5, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_120901579); + __Pyx_GIVEREF(__pyx_int_120901579); + PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_int_120901579); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state); - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); - __pyx_t_2 = 0; - __pyx_t_4 = 0; - __pyx_r = __pyx_t_3; + PyTuple_SET_ITEM(__pyx_t_5, 2, __pyx_v_state); + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); + __Pyx_GIVEREF(__pyx_t_5); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_5); __pyx_t_3 = 0; + __pyx_t_5 = 0; + __pyx_r = __pyx_t_4; + __pyx_t_4 = 0; goto __pyx_L0; } @@ -49855,6 +55880,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_ __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __Pyx_AddTraceback("dependency_injector.providers.Resource.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -49867,25 +55893,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_26__reduce_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Resource, (type(self), 0xe8b92e4, state) + * return __pyx_unpickle_Resource, (type(self), 0x734cfcb, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Resource__set_state(self, __pyx_state) */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_29__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_29__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_39__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_8Resource_39__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_28__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_Resource *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_8Resource_38__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_Resource *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_28__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_38__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -49895,7 +55921,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_28__setstat __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Resource, (type(self), 0xe8b92e4, state) + * return __pyx_unpickle_Resource, (type(self), 0x734cfcb, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Resource__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -49906,7 +55932,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_28__setstat /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Resource, (type(self), 0xe8b92e4, state) + * return __pyx_unpickle_Resource, (type(self), 0x734cfcb, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Resource__set_state(self, __pyx_state) */ @@ -49924,7 +55950,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Resource_28__setstat return __pyx_r; } -/* "dependency_injector/providers.pyx":2781 +/* "dependency_injector/providers.pyx":3037 * """ * * def __init__(self, container_cls, container=None, **overriding_providers): # <<<<<<<<<<<<<< @@ -49978,7 +56004,7 @@ static int __pyx_pw_19dependency_injector_9providers_9Container_1__init__(PyObje } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_overriding_providers, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 2781, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_overriding_providers, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 3037, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -49994,7 +56020,7 @@ static int __pyx_pw_19dependency_injector_9providers_9Container_1__init__(PyObje } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2781, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3037, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_overriding_providers); __pyx_v_overriding_providers = 0; __Pyx_AddTraceback("dependency_injector.providers.Container.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); @@ -50023,7 +56049,7 @@ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct __Pyx_RefNannySetupContext("__init__", 0); __Pyx_INCREF(__pyx_v_container); - /* "dependency_injector/providers.pyx":2783 + /* "dependency_injector/providers.pyx":3039 * def __init__(self, container_cls, container=None, **overriding_providers): * """Initialize provider.""" * self.__container_cls = container_cls # <<<<<<<<<<<<<< @@ -50036,7 +56062,7 @@ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct __Pyx_DECREF(__pyx_v_self->__pyx___container_cls); __pyx_v_self->__pyx___container_cls = __pyx_v_container_cls; - /* "dependency_injector/providers.pyx":2784 + /* "dependency_injector/providers.pyx":3040 * """Initialize provider.""" * self.__container_cls = container_cls * self.__overriding_providers = overriding_providers # <<<<<<<<<<<<<< @@ -50049,7 +56075,7 @@ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct __Pyx_DECREF(__pyx_v_self->__pyx___overriding_providers); __pyx_v_self->__pyx___overriding_providers = __pyx_v_overriding_providers; - /* "dependency_injector/providers.pyx":2786 + /* "dependency_injector/providers.pyx":3042 * self.__overriding_providers = overriding_providers * * if container is None: # <<<<<<<<<<<<<< @@ -50060,7 +56086,7 @@ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct __pyx_t_2 = (__pyx_t_1 != 0); if (__pyx_t_2) { - /* "dependency_injector/providers.pyx":2787 + /* "dependency_injector/providers.pyx":3043 * * if container is None: * container = container_cls() # <<<<<<<<<<<<<< @@ -50080,27 +56106,27 @@ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2787, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3043, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF_SET(__pyx_v_container, __pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2788 + /* "dependency_injector/providers.pyx":3044 * if container is None: * container = container_cls() * container.override_providers(**overriding_providers) # <<<<<<<<<<<<<< * self.__container = container * */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_override_providers_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2788, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_override_providers_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3044, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_empty_tuple, __pyx_v_overriding_providers); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2788, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_empty_tuple, __pyx_v_overriding_providers); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3044, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":2786 + /* "dependency_injector/providers.pyx":3042 * self.__overriding_providers = overriding_providers * * if container is None: # <<<<<<<<<<<<<< @@ -50109,7 +56135,7 @@ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct */ } - /* "dependency_injector/providers.pyx":2789 + /* "dependency_injector/providers.pyx":3045 * container = container_cls() * container.override_providers(**overriding_providers) * self.__container = container # <<<<<<<<<<<<<< @@ -50122,14 +56148,14 @@ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct __Pyx_DECREF(__pyx_v_self->__pyx___container); __pyx_v_self->__pyx___container = __pyx_v_container; - /* "dependency_injector/providers.pyx":2791 + /* "dependency_injector/providers.pyx":3047 * self.__container = container * * super(Container, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2791, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3047, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Container)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Container)); @@ -50137,10 +56163,10 @@ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_3, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2791, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3047, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2791, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3047, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -50155,12 +56181,12 @@ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct } __pyx_t_4 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2791, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3047, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "dependency_injector/providers.pyx":2781 + /* "dependency_injector/providers.pyx":3037 * """ * * def __init__(self, container_cls, container=None, **overriding_providers): # <<<<<<<<<<<<<< @@ -50183,7 +56209,7 @@ static int __pyx_pf_19dependency_injector_9providers_9Container___init__(struct return __pyx_r; } -/* "dependency_injector/providers.pyx":2793 +/* "dependency_injector/providers.pyx":3049 * super(Container, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -50222,16 +56248,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":2795 + /* "dependency_injector/providers.pyx":3051 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2795, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3051, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2795, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3051, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -50246,13 +56272,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2795, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3051, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2796 + /* "dependency_injector/providers.pyx":3052 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -50263,7 +56289,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":2797 + /* "dependency_injector/providers.pyx":3053 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -50275,7 +56301,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2796 + /* "dependency_injector/providers.pyx":3052 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -50284,17 +56310,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop */ } - /* "dependency_injector/providers.pyx":2799 + /* "dependency_injector/providers.pyx":3055 * return copied * * copied = self.__class__( # <<<<<<<<<<<<<< * self.__container_cls, * deepcopy(self.__container, memo), */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2799, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3055, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":2801 + /* "dependency_injector/providers.pyx":3057 * copied = self.__class__( * self.__container_cls, * deepcopy(self.__container, memo), # <<<<<<<<<<<<<< @@ -50303,21 +56329,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop */ __pyx_t_2 = __pyx_v_self->__pyx___container; __Pyx_INCREF(__pyx_t_2); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2801, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3057, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_3 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2801, __pyx_L1_error) + __pyx_t_3 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3057, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2799 + /* "dependency_injector/providers.pyx":3055 * return copied * * copied = self.__class__( # <<<<<<<<<<<<<< * self.__container_cls, * deepcopy(self.__container, memo), */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2799, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3055, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_self->__pyx___container_cls); __Pyx_GIVEREF(__pyx_v_self->__pyx___container_cls); @@ -50326,7 +56352,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2802 + /* "dependency_injector/providers.pyx":3058 * self.__container_cls, * deepcopy(self.__container, memo), * **deepcopy(self.__overriding_providers, memo), # <<<<<<<<<<<<<< @@ -50335,34 +56361,34 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop */ __pyx_t_4 = __pyx_v_self->__pyx___overriding_providers; __Pyx_INCREF(__pyx_t_4); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2802, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3058, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_4, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2802, __pyx_L1_error) + __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_4, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3058, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; if (unlikely(__pyx_t_8 == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 2802, __pyx_L1_error) + __PYX_ERR(1, 3058, __pyx_L1_error) } if (likely(PyDict_CheckExact(__pyx_t_8))) { - __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2802, __pyx_L1_error) + __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3058, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { - __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2799, __pyx_L1_error) + __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3055, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } - /* "dependency_injector/providers.pyx":2799 + /* "dependency_injector/providers.pyx":3055 * return copied * * copied = self.__class__( # <<<<<<<<<<<<<< * self.__container_cls, * deepcopy(self.__container, memo), */ - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2799, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3055, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -50370,7 +56396,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":2805 + /* "dependency_injector/providers.pyx":3061 * ) * * return copied # <<<<<<<<<<<<<< @@ -50382,7 +56408,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2793 + /* "dependency_injector/providers.pyx":3049 * super(Container, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -50406,7 +56432,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_2__deepcop return __pyx_r; } -/* "dependency_injector/providers.pyx":2807 +/* "dependency_injector/providers.pyx":3063 * return copied * * def __getattr__(self, name): # <<<<<<<<<<<<<< @@ -50445,14 +56471,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_4__getattr int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getattr__", 0); - /* "dependency_injector/providers.pyx":2809 + /* "dependency_injector/providers.pyx":3065 * def __getattr__(self, name): * """Return dependency provider.""" * if name.startswith('__') and name.endswith('__'): # <<<<<<<<<<<<<< * raise AttributeError( * '\'{cls}\' object has no attribute ' */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_startswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2809, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_startswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3065, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -50466,17 +56492,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_4__getattr } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2809, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3065, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 2809, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 3065, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (__pyx_t_5) { } else { __pyx_t_1 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_endswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2809, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_endswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3065, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -50490,70 +56516,70 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_4__getattr } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2809, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3065, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 2809, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 3065, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_1 = __pyx_t_5; __pyx_L4_bool_binop_done:; if (unlikely(__pyx_t_1)) { - /* "dependency_injector/providers.pyx":2812 + /* "dependency_injector/providers.pyx":3068 * raise AttributeError( * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, # <<<<<<<<<<<<<< * attribute_name=name)) * return getattr(self.__container, name) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_cls_object_has_no_attribute_att, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2812, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_cls_object_has_no_attribute_att, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3068, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2812, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3068, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2812, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3068, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2812, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3068, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_cls, __pyx_t_6) < 0) __PYX_ERR(1, 2812, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_cls, __pyx_t_6) < 0) __PYX_ERR(1, 3068, __pyx_L1_error) __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":2813 + /* "dependency_injector/providers.pyx":3069 * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, * attribute_name=name)) # <<<<<<<<<<<<<< * return getattr(self.__container, name) * */ - if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_attribute_name, __pyx_v_name) < 0) __PYX_ERR(1, 2812, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_attribute_name, __pyx_v_name) < 0) __PYX_ERR(1, 3068, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2812 + /* "dependency_injector/providers.pyx":3068 * raise AttributeError( * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, # <<<<<<<<<<<<<< * attribute_name=name)) * return getattr(self.__container, name) */ - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2812, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3068, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2810 + /* "dependency_injector/providers.pyx":3066 * """Return dependency provider.""" * if name.startswith('__') and name.endswith('__'): * raise AttributeError( # <<<<<<<<<<<<<< * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, */ - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2810, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3066, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 2810, __pyx_L1_error) + __PYX_ERR(1, 3066, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2809 + /* "dependency_injector/providers.pyx":3065 * def __getattr__(self, name): * """Return dependency provider.""" * if name.startswith('__') and name.endswith('__'): # <<<<<<<<<<<<<< @@ -50562,7 +56588,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_4__getattr */ } - /* "dependency_injector/providers.pyx":2814 + /* "dependency_injector/providers.pyx":3070 * '\'{attribute_name}\''.format(cls=self.__class__.__name__, * attribute_name=name)) * return getattr(self.__container, name) # <<<<<<<<<<<<<< @@ -50572,14 +56598,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_4__getattr __Pyx_XDECREF(__pyx_r); __pyx_t_3 = __pyx_v_self->__pyx___container; __Pyx_INCREF(__pyx_t_3); - __pyx_t_6 = __Pyx_GetAttr(__pyx_t_3, __pyx_v_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2814, __pyx_L1_error) + __pyx_t_6 = __Pyx_GetAttr(__pyx_t_3, __pyx_v_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3070, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2807 + /* "dependency_injector/providers.pyx":3063 * return copied * * def __getattr__(self, name): # <<<<<<<<<<<<<< @@ -50601,7 +56627,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_4__getattr return __pyx_r; } -/* "dependency_injector/providers.pyx":2817 +/* "dependency_injector/providers.pyx":3073 * * @property * def container(self): # <<<<<<<<<<<<<< @@ -50627,7 +56653,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_9container __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":2818 + /* "dependency_injector/providers.pyx":3074 * @property * def container(self): * return self.__container # <<<<<<<<<<<<<< @@ -50639,7 +56665,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_9container __pyx_r = __pyx_v_self->__pyx___container; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2817 + /* "dependency_injector/providers.pyx":3073 * * @property * def container(self): # <<<<<<<<<<<<<< @@ -50654,7 +56680,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_9container return __pyx_r; } -/* "dependency_injector/providers.pyx":2820 +/* "dependency_injector/providers.pyx":3076 * return self.__container * * def override(self, provider): # <<<<<<<<<<<<<< @@ -50689,16 +56715,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_6override( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("override", 0); - /* "dependency_injector/providers.pyx":2822 + /* "dependency_injector/providers.pyx":3078 * def override(self, provider): * """Override provider with another provider.""" * raise Error('Provider {0} can not be overridden'.format(self)) # <<<<<<<<<<<<<< * * cpdef object _provide(self, tuple args, dict kwargs): */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2822, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3078, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Provider_0_can_not_be_overridden, __pyx_n_s_format); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2822, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Provider_0_can_not_be_overridden, __pyx_n_s_format); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3078, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -50712,7 +56738,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_6override( } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, ((PyObject *)__pyx_v_self)) : __Pyx_PyObject_CallOneArg(__pyx_t_4, ((PyObject *)__pyx_v_self)); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2822, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3078, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; @@ -50728,14 +56754,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_6override( __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2822, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3078, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 2822, __pyx_L1_error) + __PYX_ERR(1, 3078, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2820 + /* "dependency_injector/providers.pyx":3076 * return self.__container * * def override(self, provider): # <<<<<<<<<<<<<< @@ -50757,7 +56783,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_6override( return __pyx_r; } -/* "dependency_injector/providers.pyx":2824 +/* "dependency_injector/providers.pyx":3080 * raise Error('Provider {0} can not be overridden'.format(self)) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -50788,7 +56814,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Container__provide(st if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2824, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3080, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_9Container_9_provide)) { __Pyx_XDECREF(__pyx_r); @@ -50808,7 +56834,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Container__provide(st #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2824, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3080, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -50816,13 +56842,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Container__provide(st #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2824, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3080, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2824, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3080, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -50833,7 +56859,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Container__provide(st __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2824, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3080, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -50856,7 +56882,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Container__provide(st #endif } - /* "dependency_injector/providers.pyx":2826 + /* "dependency_injector/providers.pyx":3082 * cpdef object _provide(self, tuple args, dict kwargs): * """Return single instance.""" * return self.__container # <<<<<<<<<<<<<< @@ -50868,7 +56894,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_9Container__provide(st __pyx_r = __pyx_v_self->__pyx___container; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2824 + /* "dependency_injector/providers.pyx":3080 * raise Error('Provider {0} can not be overridden'.format(self)) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -50926,11 +56952,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_9Container_9_provide( case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2824, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 3080, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2824, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 3080, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -50943,14 +56969,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_9Container_9_provide( } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2824, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3080, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Container._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2824, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2824, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3080, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3080, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_9Container_8_provide(((struct __pyx_obj_19dependency_injector_9providers_Container *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -50971,7 +56997,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_8_provide( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_9Container__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2824, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_9Container__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3080, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -51014,9 +57040,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_10__reduce PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -51027,52 +57053,57 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_10__reduce /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__container, self.__container_cls, self.__last_overriding, self.__overridden, self.__overriding_providers) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__container, self.__container_cls, self.__last_overriding, self.__overridden, self.__overriding_providers) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(5); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx___container); __Pyx_GIVEREF(__pyx_v_self->__pyx___container); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->__pyx___container); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->__pyx___container); __Pyx_INCREF(__pyx_v_self->__pyx___container_cls); __Pyx_GIVEREF(__pyx_v_self->__pyx___container_cls); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx___container_cls); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx___container_cls); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 3, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx___overriding_providers); __Pyx_GIVEREF(__pyx_v_self->__pyx___overriding_providers); - PyTuple_SET_ITEM(__pyx_t_1, 4, __pyx_v_self->__pyx___overriding_providers); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 5, __pyx_v_self->__pyx___overriding_providers); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__container, self.__container_cls, self.__last_overriding, self.__overridden, self.__overriding_providers) + * state = (self.__async_mode, self.__container, self.__container_cls, self.__last_overriding, self.__overridden, self.__overriding_providers) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__container, self.__container_cls, self.__last_overriding, self.__overridden, self.__overriding_providers) + * state = (self.__async_mode, self.__container, self.__container_cls, self.__last_overriding, self.__overridden, self.__overriding_providers) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -51081,16 +57112,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_10__reduce * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -51102,7 +57133,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_10__reduce __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__container, self.__container_cls, self.__last_overriding, self.__overridden, self.__overriding_providers) + * state = (self.__async_mode, self.__container, self.__container_cls, self.__last_overriding, self.__overridden, self.__overriding_providers) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -51116,42 +57147,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_10__reduce * else: * use_setstate = self.__container is not None or self.__container_cls is not None or self.__last_overriding is not None or self.__overridden is not None or self.__overriding_providers is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Container, (type(self), 0x0433d08, None), state + * return __pyx_unpickle_Container, (type(self), 0x1bd47ec, None), state */ /*else*/ { - __pyx_t_2 = (__pyx_v_self->__pyx___container != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx___container != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx___container_cls != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx___overriding_providers != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (__pyx_v_self->__pyx___overriding_providers != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -51159,44 +57190,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_10__reduce * else: * use_setstate = self.__container is not None or self.__container_cls is not None or self.__last_overriding is not None or self.__overridden is not None or self.__overriding_providers is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Container, (type(self), 0x0433d08, None), state + * return __pyx_unpickle_Container, (type(self), 0x1bd47ec, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__container is not None or self.__container_cls is not None or self.__last_overriding is not None or self.__overridden is not None or self.__overriding_providers is not None * if use_setstate: - * return __pyx_unpickle_Container, (type(self), 0x0433d08, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Container, (type(self), 0x1bd47ec, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Container, (type(self), 0x0433d08, state) + * return __pyx_unpickle_Container, (type(self), 0x1bd47ec, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Container); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Container); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_4406536); - __Pyx_GIVEREF(__pyx_int_4406536); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_4406536); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_29181932); + __Pyx_GIVEREF(__pyx_int_29181932); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_29181932); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -51205,15 +57236,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_10__reduce * else: * use_setstate = self.__container is not None or self.__container_cls is not None or self.__last_overriding is not None or self.__overridden is not None or self.__overriding_providers is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Container, (type(self), 0x0433d08, None), state + * return __pyx_unpickle_Container, (type(self), 0x1bd47ec, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Container, (type(self), 0x0433d08, None), state + * return __pyx_unpickle_Container, (type(self), 0x1bd47ec, None), state * else: - * return __pyx_unpickle_Container, (type(self), 0x0433d08, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Container, (type(self), 0x1bd47ec, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Container__set_state(self, __pyx_state) */ @@ -51221,27 +57252,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_10__reduce __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_Container); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_4406536); - __Pyx_GIVEREF(__pyx_int_4406536); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_4406536); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_29181932); + __Pyx_GIVEREF(__pyx_int_29181932); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_29181932); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -51254,7 +57285,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_10__reduce /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.Container.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -51268,7 +57299,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_10__reduce /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Container, (type(self), 0x0433d08, state) + * return __pyx_unpickle_Container, (type(self), 0x1bd47ec, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Container__set_state(self, __pyx_state) */ @@ -51296,7 +57327,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_12__setsta __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Container, (type(self), 0x0433d08, state) + * return __pyx_unpickle_Container, (type(self), 0x1bd47ec, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Container__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -51307,7 +57338,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_12__setsta /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Container, (type(self), 0x0433d08, state) + * return __pyx_unpickle_Container, (type(self), 0x1bd47ec, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Container__set_state(self, __pyx_state) */ @@ -51325,7 +57356,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Container_12__setsta return __pyx_r; } -/* "dependency_injector/providers.pyx":2860 +/* "dependency_injector/providers.pyx":3116 * """ * * def __init__(self, selector, **providers): # <<<<<<<<<<<<<< @@ -51369,7 +57400,7 @@ static int __pyx_pw_19dependency_injector_9providers_8Selector_1__init__(PyObjec else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_providers, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 2860, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_providers, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 3116, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -51380,7 +57411,7 @@ static int __pyx_pw_19dependency_injector_9providers_8Selector_1__init__(PyObjec } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2860, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3116, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_providers); __pyx_v_providers = 0; __Pyx_AddTraceback("dependency_injector.providers.Selector.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); @@ -51406,7 +57437,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Selector___init__(struct _ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":2862 + /* "dependency_injector/providers.pyx":3118 * def __init__(self, selector, **providers): * """Initialize provider.""" * self.__selector = selector # <<<<<<<<<<<<<< @@ -51419,7 +57450,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Selector___init__(struct _ __Pyx_DECREF(__pyx_v_self->__pyx___selector); __pyx_v_self->__pyx___selector = __pyx_v_selector; - /* "dependency_injector/providers.pyx":2863 + /* "dependency_injector/providers.pyx":3119 * """Initialize provider.""" * self.__selector = selector * self.__providers = providers # <<<<<<<<<<<<<< @@ -51432,14 +57463,14 @@ static int __pyx_pf_19dependency_injector_9providers_8Selector___init__(struct _ __Pyx_DECREF(__pyx_v_self->__pyx___providers); __pyx_v_self->__pyx___providers = __pyx_v_providers; - /* "dependency_injector/providers.pyx":2864 + /* "dependency_injector/providers.pyx":3120 * self.__selector = selector * self.__providers = providers * super(Selector, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2864, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3120, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Selector)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_Selector)); @@ -51447,10 +57478,10 @@ static int __pyx_pf_19dependency_injector_9providers_8Selector___init__(struct _ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2864, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3120, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2864, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3120, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -51465,12 +57496,12 @@ static int __pyx_pf_19dependency_injector_9providers_8Selector___init__(struct _ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2864, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3120, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2860 + /* "dependency_injector/providers.pyx":3116 * """ * * def __init__(self, selector, **providers): # <<<<<<<<<<<<<< @@ -51492,7 +57523,7 @@ static int __pyx_pf_19dependency_injector_9providers_8Selector___init__(struct _ return __pyx_r; } -/* "dependency_injector/providers.pyx":2866 +/* "dependency_injector/providers.pyx":3122 * super(Selector, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -51531,16 +57562,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_2__deepcopy int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":2868 + /* "dependency_injector/providers.pyx":3124 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2868, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3124, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2868, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3124, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -51555,13 +57586,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_2__deepcopy __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2868, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3124, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2869 + /* "dependency_injector/providers.pyx":3125 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -51572,7 +57603,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_2__deepcopy __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":2870 + /* "dependency_injector/providers.pyx":3126 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -51584,7 +57615,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_2__deepcopy __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2869 + /* "dependency_injector/providers.pyx":3125 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -51593,17 +57624,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_2__deepcopy */ } - /* "dependency_injector/providers.pyx":2872 + /* "dependency_injector/providers.pyx":3128 * return copied * * copied = self.__class__( # <<<<<<<<<<<<<< * deepcopy(self.__selector, memo), * **deepcopy(self.__providers, memo), */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2872, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3128, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":2873 + /* "dependency_injector/providers.pyx":3129 * * copied = self.__class__( * deepcopy(self.__selector, memo), # <<<<<<<<<<<<<< @@ -51612,27 +57643,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_2__deepcopy */ __pyx_t_2 = __pyx_v_self->__pyx___selector; __Pyx_INCREF(__pyx_t_2); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2873, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3129, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_3 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2873, __pyx_L1_error) + __pyx_t_3 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3129, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":2872 + /* "dependency_injector/providers.pyx":3128 * return copied * * copied = self.__class__( # <<<<<<<<<<<<<< * deepcopy(self.__selector, memo), * **deepcopy(self.__providers, memo), */ - __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2872, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3128, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2874 + /* "dependency_injector/providers.pyx":3130 * copied = self.__class__( * deepcopy(self.__selector, memo), * **deepcopy(self.__providers, memo), # <<<<<<<<<<<<<< @@ -51641,34 +57672,34 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_2__deepcopy */ __pyx_t_4 = __pyx_v_self->__pyx___providers; __Pyx_INCREF(__pyx_t_4); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2874, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3130, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_4, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2874, __pyx_L1_error) + __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_4, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3130, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; if (unlikely(__pyx_t_8 == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 2874, __pyx_L1_error) + __PYX_ERR(1, 3130, __pyx_L1_error) } if (likely(PyDict_CheckExact(__pyx_t_8))) { - __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2874, __pyx_L1_error) + __pyx_t_3 = PyDict_Copy(__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3130, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { - __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2872, __pyx_L1_error) + __pyx_t_3 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3128, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } - /* "dependency_injector/providers.pyx":2872 + /* "dependency_injector/providers.pyx":3128 * return copied * * copied = self.__class__( # <<<<<<<<<<<<<< * deepcopy(self.__selector, memo), * **deepcopy(self.__providers, memo), */ - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2872, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3128, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -51676,18 +57707,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_2__deepcopy __Pyx_DECREF_SET(__pyx_v_copied, __pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":2876 + /* "dependency_injector/providers.pyx":3132 * **deepcopy(self.__providers, memo), * ) * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 2876, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2876, __pyx_L1_error) + if (!(likely(((__pyx_v_copied) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_copied, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 3132, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3132, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_Selector *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":2878 + /* "dependency_injector/providers.pyx":3134 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -51699,7 +57730,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_2__deepcopy __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2866 + /* "dependency_injector/providers.pyx":3122 * super(Selector, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -51723,7 +57754,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_2__deepcopy return __pyx_r; } -/* "dependency_injector/providers.pyx":2880 +/* "dependency_injector/providers.pyx":3136 * return copied * * def __getattr__(self, name): # <<<<<<<<<<<<<< @@ -51762,14 +57793,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_4__getattr_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getattr__", 0); - /* "dependency_injector/providers.pyx":2882 + /* "dependency_injector/providers.pyx":3138 * def __getattr__(self, name): * """Return provider.""" * if name.startswith('__') and name.endswith('__'): # <<<<<<<<<<<<<< * raise AttributeError( * '\'{cls}\' object has no attribute ' */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_startswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2882, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_startswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3138, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -51783,17 +57814,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_4__getattr_ } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2882, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3138, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 2882, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 3138, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (__pyx_t_5) { } else { __pyx_t_1 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_endswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2882, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_endswith); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3138, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -51807,70 +57838,70 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_4__getattr_ } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2882, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3138, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 2882, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(1, 3138, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_1 = __pyx_t_5; __pyx_L4_bool_binop_done:; if (unlikely(__pyx_t_1)) { - /* "dependency_injector/providers.pyx":2885 + /* "dependency_injector/providers.pyx":3141 * raise AttributeError( * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, # <<<<<<<<<<<<<< * attribute_name=name)) * if name not in self.__providers: */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_cls_object_has_no_attribute_att, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2885, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_cls_object_has_no_attribute_att, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3141, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2885, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_NewPresized(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3141, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2885, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3141, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2885, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3141, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_cls, __pyx_t_6) < 0) __PYX_ERR(1, 2885, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_cls, __pyx_t_6) < 0) __PYX_ERR(1, 3141, __pyx_L1_error) __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":2886 + /* "dependency_injector/providers.pyx":3142 * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, * attribute_name=name)) # <<<<<<<<<<<<<< * if name not in self.__providers: * raise AttributeError('Selector has no "{0}" provider'.format(name)) */ - if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_attribute_name, __pyx_v_name) < 0) __PYX_ERR(1, 2885, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_attribute_name, __pyx_v_name) < 0) __PYX_ERR(1, 3141, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2885 + /* "dependency_injector/providers.pyx":3141 * raise AttributeError( * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, # <<<<<<<<<<<<<< * attribute_name=name)) * if name not in self.__providers: */ - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2885, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3141, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2883 + /* "dependency_injector/providers.pyx":3139 * """Return provider.""" * if name.startswith('__') and name.endswith('__'): * raise AttributeError( # <<<<<<<<<<<<<< * '\'{cls}\' object has no attribute ' * '\'{attribute_name}\''.format(cls=self.__class__.__name__, */ - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2883, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3139, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_Raise(__pyx_t_3, 0, 0, 0); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __PYX_ERR(1, 2883, __pyx_L1_error) + __PYX_ERR(1, 3139, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2882 + /* "dependency_injector/providers.pyx":3138 * def __getattr__(self, name): * """Return provider.""" * if name.startswith('__') and name.endswith('__'): # <<<<<<<<<<<<<< @@ -51879,7 +57910,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_4__getattr_ */ } - /* "dependency_injector/providers.pyx":2887 + /* "dependency_injector/providers.pyx":3143 * '\'{attribute_name}\''.format(cls=self.__class__.__name__, * attribute_name=name)) * if name not in self.__providers: # <<<<<<<<<<<<<< @@ -51888,20 +57919,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_4__getattr_ */ if (unlikely(__pyx_v_self->__pyx___providers == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 2887, __pyx_L1_error) + __PYX_ERR(1, 3143, __pyx_L1_error) } - __pyx_t_1 = (__Pyx_PyDict_ContainsTF(__pyx_v_name, __pyx_v_self->__pyx___providers, Py_NE)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 2887, __pyx_L1_error) + __pyx_t_1 = (__Pyx_PyDict_ContainsTF(__pyx_v_name, __pyx_v_self->__pyx___providers, Py_NE)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(1, 3143, __pyx_L1_error) __pyx_t_5 = (__pyx_t_1 != 0); if (unlikely(__pyx_t_5)) { - /* "dependency_injector/providers.pyx":2888 + /* "dependency_injector/providers.pyx":3144 * attribute_name=name)) * if name not in self.__providers: * raise AttributeError('Selector has no "{0}" provider'.format(name)) # <<<<<<<<<<<<<< * * return self.__providers[name] */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Selector_has_no_0_provider, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2888, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Selector_has_no_0_provider, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3144, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -51915,17 +57946,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_4__getattr_ } __pyx_t_3 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_2, __pyx_v_name) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_name); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2888, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3144, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2888, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_builtin_AttributeError, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3144, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_6, 0, 0, 0); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - __PYX_ERR(1, 2888, __pyx_L1_error) + __PYX_ERR(1, 3144, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2887 + /* "dependency_injector/providers.pyx":3143 * '\'{attribute_name}\''.format(cls=self.__class__.__name__, * attribute_name=name)) * if name not in self.__providers: # <<<<<<<<<<<<<< @@ -51934,7 +57965,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_4__getattr_ */ } - /* "dependency_injector/providers.pyx":2890 + /* "dependency_injector/providers.pyx":3146 * raise AttributeError('Selector has no "{0}" provider'.format(name)) * * return self.__providers[name] # <<<<<<<<<<<<<< @@ -51944,15 +57975,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_4__getattr_ __Pyx_XDECREF(__pyx_r); if (unlikely(__pyx_v_self->__pyx___providers == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 2890, __pyx_L1_error) + __PYX_ERR(1, 3146, __pyx_L1_error) } - __pyx_t_6 = __Pyx_PyDict_GetItem(__pyx_v_self->__pyx___providers, __pyx_v_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2890, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyDict_GetItem(__pyx_v_self->__pyx___providers, __pyx_v_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3146, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2880 + /* "dependency_injector/providers.pyx":3136 * return copied * * def __getattr__(self, name): # <<<<<<<<<<<<<< @@ -51974,7 +58005,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_4__getattr_ return __pyx_r; } -/* "dependency_injector/providers.pyx":2892 +/* "dependency_injector/providers.pyx":3148 * return self.__providers[name] * * def __str__(self): # <<<<<<<<<<<<<< @@ -52000,7 +58031,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Selector_7__str__(Py } static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2generator1(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "dependency_injector/providers.pyx":2902 +/* "dependency_injector/providers.pyx":3158 * selector=self.__selector, * providers=', '.join(( * '{0}={1}'.format(name, provider) # <<<<<<<<<<<<<< @@ -52020,7 +58051,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_7__str___ge if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct_3_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(1, 2902, __pyx_L1_error) + __PYX_ERR(1, 3158, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -52028,7 +58059,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_7__str___ge __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_19dependency_injector_9providers_8Selector_7__str___2generator1, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_str___locals_genexpr, __pyx_n_s_dependency_injector_providers); if (unlikely(!gen)) __PYX_ERR(1, 2902, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_19dependency_injector_9providers_8Selector_7__str___2generator1, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_str___locals_genexpr, __pyx_n_s_dependency_injector_providers); if (unlikely(!gen)) __PYX_ERR(1, 3158, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -52070,29 +58101,29 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(1, 2902, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(1, 3158, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2903 + /* "dependency_injector/providers.pyx":3159 * providers=', '.join(( * '{0}={1}'.format(name, provider) * for name, provider in self.__providers.items() # <<<<<<<<<<<<<< * )), * address=hex(id(self)), */ - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_self)) { __Pyx_RaiseClosureNameError("self"); __PYX_ERR(1, 2903, __pyx_L1_error) } + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_self)) { __Pyx_RaiseClosureNameError("self"); __PYX_ERR(1, 3159, __pyx_L1_error) } if (unlikely(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_self->__pyx___providers == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "items"); - __PYX_ERR(1, 2903, __pyx_L1_error) + __PYX_ERR(1, 3159, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_Items(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_self->__pyx___providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2903, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_Items(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_self->__pyx___providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3159, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; __pyx_t_4 = NULL; } else { - __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2903, __pyx_L1_error) + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3159, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2903, __pyx_L1_error) + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3159, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -52100,17 +58131,17 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 2903, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 3159, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2903, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3159, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 2903, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 3159, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2903, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3159, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -52120,7 +58151,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 2903, __pyx_L1_error) + else __PYX_ERR(1, 3159, __pyx_L1_error) } break; } @@ -52132,7 +58163,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(1, 2903, __pyx_L1_error) + __PYX_ERR(1, 3159, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -52145,15 +58176,15 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2903, __pyx_L1_error) + __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3159, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2903, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3159, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 2903, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 3159, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -52161,7 +58192,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g __Pyx_GOTREF(__pyx_t_5); index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L6_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 2903, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 3159, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L7_unpacking_done; @@ -52169,7 +58200,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(1, 2903, __pyx_L1_error) + __PYX_ERR(1, 3159, __pyx_L1_error) __pyx_L7_unpacking_done:; } __Pyx_XGOTREF(__pyx_cur_scope->__pyx_v_name); @@ -52181,14 +58212,14 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g __Pyx_GIVEREF(__pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":2902 + /* "dependency_injector/providers.pyx":3158 * selector=self.__selector, * providers=', '.join(( * '{0}={1}'.format(name, provider) # <<<<<<<<<<<<<< * for name, provider in self.__providers.items() * )), */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2902, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_0_1, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3158, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_5 = NULL; __pyx_t_9 = 0; @@ -52205,7 +58236,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_cur_scope->__pyx_v_name, __pyx_cur_scope->__pyx_v_provider}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2902, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3158, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -52213,13 +58244,13 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_cur_scope->__pyx_v_name, __pyx_cur_scope->__pyx_v_provider}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2902, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3158, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_7 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 2902, __pyx_L1_error) + __pyx_t_7 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 3158, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_5) { __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL; @@ -52230,7 +58261,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g __Pyx_INCREF(__pyx_cur_scope->__pyx_v_provider); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_v_provider); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_9, __pyx_cur_scope->__pyx_v_provider); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_7, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2902, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_7, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3158, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } @@ -52253,9 +58284,9 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g __Pyx_XGOTREF(__pyx_t_2); __pyx_t_3 = __pyx_cur_scope->__pyx_t_1; __pyx_t_4 = __pyx_cur_scope->__pyx_t_2; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(1, 2902, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(1, 3158, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2903 + /* "dependency_injector/providers.pyx":3159 * providers=', '.join(( * '{0}={1}'.format(name, provider) * for name, provider in self.__providers.items() # <<<<<<<<<<<<<< @@ -52266,7 +58297,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; CYTHON_MAYBE_UNUSED_VAR(__pyx_cur_scope); - /* "dependency_injector/providers.pyx":2902 + /* "dependency_injector/providers.pyx":3158 * selector=self.__selector, * providers=', '.join(( * '{0}={1}'.format(name, provider) # <<<<<<<<<<<<<< @@ -52295,7 +58326,7 @@ static PyObject *__pyx_gb_19dependency_injector_9providers_8Selector_7__str___2g return __pyx_r; } -/* "dependency_injector/providers.pyx":2892 +/* "dependency_injector/providers.pyx":3148 * return self.__providers[name] * * def __str__(self): # <<<<<<<<<<<<<< @@ -52320,7 +58351,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_6__str__(st if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_19dependency_injector_9providers___pyx_scope_struct_2___str__ *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(1, 2892, __pyx_L1_error) + __PYX_ERR(1, 3148, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -52328,7 +58359,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_6__str__(st __Pyx_INCREF((PyObject *)__pyx_cur_scope->__pyx_v_self); __Pyx_GIVEREF((PyObject *)__pyx_cur_scope->__pyx_v_self); - /* "dependency_injector/providers.pyx":2898 + /* "dependency_injector/providers.pyx":3154 * """ * * return '<{provider}({selector}, {providers}) at {address}>'.format( # <<<<<<<<<<<<<< @@ -52336,29 +58367,29 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_6__str__(st * selector=self.__selector, */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_provider_selector_providers_at, __pyx_n_s_format); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2898, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_provider_selector_providers_at, __pyx_n_s_format); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":2899 + /* "dependency_injector/providers.pyx":3155 * * return '<{provider}({selector}, {providers}) at {address}>'.format( * provider='.'.join(( self.__class__.__module__, self.__class__.__name__)), # <<<<<<<<<<<<<< * selector=self.__selector, * providers=', '.join(( */ - __pyx_t_2 = __Pyx_PyDict_NewPresized(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2899, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyDict_NewPresized(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3155, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_cur_scope->__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2899, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_cur_scope->__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3155, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_module); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2899, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_module); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3155, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_cur_scope->__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2899, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_cur_scope->__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3155, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2899, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3155, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2899, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3155, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); @@ -52366,67 +58397,67 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_6__str__(st PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_5); __pyx_t_4 = 0; __pyx_t_5 = 0; - __pyx_t_5 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2899, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3155, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_provider, __pyx_t_5) < 0) __PYX_ERR(1, 2899, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_provider, __pyx_t_5) < 0) __PYX_ERR(1, 3155, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":2900 + /* "dependency_injector/providers.pyx":3156 * return '<{provider}({selector}, {providers}) at {address}>'.format( * provider='.'.join(( self.__class__.__module__, self.__class__.__name__)), * selector=self.__selector, # <<<<<<<<<<<<<< * providers=', '.join(( * '{0}={1}'.format(name, provider) */ - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_selector, __pyx_cur_scope->__pyx_v_self->__pyx___selector) < 0) __PYX_ERR(1, 2899, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_selector, __pyx_cur_scope->__pyx_v_self->__pyx___selector) < 0) __PYX_ERR(1, 3155, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2902 + /* "dependency_injector/providers.pyx":3158 * selector=self.__selector, * providers=', '.join(( * '{0}={1}'.format(name, provider) # <<<<<<<<<<<<<< * for name, provider in self.__providers.items() * )), */ - __pyx_t_5 = __pyx_pf_19dependency_injector_9providers_8Selector_7__str___genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2902, __pyx_L1_error) + __pyx_t_5 = __pyx_pf_19dependency_injector_9providers_8Selector_7__str___genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3158, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - /* "dependency_injector/providers.pyx":2901 + /* "dependency_injector/providers.pyx":3157 * provider='.'.join(( self.__class__.__module__, self.__class__.__name__)), * selector=self.__selector, * providers=', '.join(( # <<<<<<<<<<<<<< * '{0}={1}'.format(name, provider) * for name, provider in self.__providers.items() */ - __pyx_t_3 = __Pyx_PyString_Join(__pyx_kp_s__12, __pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2901, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyString_Join(__pyx_kp_s__13, __pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3157, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_providers, __pyx_t_3) < 0) __PYX_ERR(1, 2899, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_providers, __pyx_t_3) < 0) __PYX_ERR(1, 3155, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":2905 + /* "dependency_injector/providers.pyx":3161 * for name, provider in self.__providers.items() * )), * address=hex(id(self)), # <<<<<<<<<<<<<< * ) * */ - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_cur_scope->__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2905, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_cur_scope->__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3161, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_builtin_hex, __pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2905, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_builtin_hex, __pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3161, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_address, __pyx_t_5) < 0) __PYX_ERR(1, 2899, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_address, __pyx_t_5) < 0) __PYX_ERR(1, 3155, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":2898 + /* "dependency_injector/providers.pyx":3154 * """ * * return '<{provider}({selector}, {providers}) at {address}>'.format( # <<<<<<<<<<<<<< * provider='.'.join(( self.__class__.__module__, self.__class__.__name__)), * selector=self.__selector, */ - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2898, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -52434,7 +58465,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_6__str__(st __pyx_t_5 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2892 + /* "dependency_injector/providers.pyx":3148 * return self.__providers[name] * * def __str__(self): # <<<<<<<<<<<<<< @@ -52458,7 +58489,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_6__str__(st return __pyx_r; } -/* "dependency_injector/providers.pyx":2909 +/* "dependency_injector/providers.pyx":3165 * * @property * def providers(self): # <<<<<<<<<<<<<< @@ -52488,7 +58519,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_9providers_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":2911 + /* "dependency_injector/providers.pyx":3167 * def providers(self): * """Return providers.""" * return dict(self.__providers) # <<<<<<<<<<<<<< @@ -52498,15 +58529,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_9providers_ __Pyx_XDECREF(__pyx_r); if (unlikely(__pyx_v_self->__pyx___providers == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' is not iterable"); - __PYX_ERR(1, 2911, __pyx_L1_error) + __PYX_ERR(1, 3167, __pyx_L1_error) } - __pyx_t_1 = PyDict_Copy(__pyx_v_self->__pyx___providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2911, __pyx_L1_error) + __pyx_t_1 = PyDict_Copy(__pyx_v_self->__pyx___providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3167, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2909 + /* "dependency_injector/providers.pyx":3165 * * @property * def providers(self): # <<<<<<<<<<<<<< @@ -52525,7 +58556,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_9providers_ return __pyx_r; } -/* "dependency_injector/providers.pyx":2913 +/* "dependency_injector/providers.pyx":3169 * return dict(self.__providers) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -52559,7 +58590,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2913, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_8Selector_9_provide)) { __Pyx_XDECREF(__pyx_r); @@ -52579,7 +58610,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2913, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3169, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -52587,13 +58618,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2913, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3169, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2913, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -52604,7 +58635,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2913, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -52627,7 +58658,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str #endif } - /* "dependency_injector/providers.pyx":2915 + /* "dependency_injector/providers.pyx":3171 * cpdef object _provide(self, tuple args, dict kwargs): * """Return single instance.""" * selector_value = self.__selector() # <<<<<<<<<<<<<< @@ -52647,13 +58678,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2915, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3171, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_selector_value = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2917 + /* "dependency_injector/providers.pyx":3173 * selector_value = self.__selector() * * if selector_value is None: # <<<<<<<<<<<<<< @@ -52664,14 +58695,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str __pyx_t_8 = (__pyx_t_7 != 0); if (unlikely(__pyx_t_8)) { - /* "dependency_injector/providers.pyx":2918 + /* "dependency_injector/providers.pyx":3174 * * if selector_value is None: * raise Error('Selector value is undefined') # <<<<<<<<<<<<<< * * if selector_value not in self.__providers: */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2918, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3174, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { @@ -52685,14 +58716,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_kp_s_Selector_value_is_undefined) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_kp_s_Selector_value_is_undefined); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2918, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3174, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 2918, __pyx_L1_error) + __PYX_ERR(1, 3174, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2917 + /* "dependency_injector/providers.pyx":3173 * selector_value = self.__selector() * * if selector_value is None: # <<<<<<<<<<<<<< @@ -52701,7 +58732,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str */ } - /* "dependency_injector/providers.pyx":2920 + /* "dependency_injector/providers.pyx":3176 * raise Error('Selector value is undefined') * * if selector_value not in self.__providers: # <<<<<<<<<<<<<< @@ -52710,22 +58741,22 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str */ if (unlikely(__pyx_v_self->__pyx___providers == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 2920, __pyx_L1_error) + __PYX_ERR(1, 3176, __pyx_L1_error) } - __pyx_t_8 = (__Pyx_PyDict_ContainsTF(__pyx_v_selector_value, __pyx_v_self->__pyx___providers, Py_NE)); if (unlikely(__pyx_t_8 < 0)) __PYX_ERR(1, 2920, __pyx_L1_error) + __pyx_t_8 = (__Pyx_PyDict_ContainsTF(__pyx_v_selector_value, __pyx_v_self->__pyx___providers, Py_NE)); if (unlikely(__pyx_t_8 < 0)) __PYX_ERR(1, 3176, __pyx_L1_error) __pyx_t_7 = (__pyx_t_8 != 0); if (unlikely(__pyx_t_7)) { - /* "dependency_injector/providers.pyx":2921 + /* "dependency_injector/providers.pyx":3177 * * if selector_value not in self.__providers: * raise Error('Selector has no "{0}" provider'.format(selector_value)) # <<<<<<<<<<<<<< * * return self.__providers[selector_value](*args, **kwargs) */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2921, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_Error); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3177, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Selector_has_no_0_provider, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2921, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Selector_has_no_0_provider, __pyx_n_s_format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3177, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -52739,7 +58770,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str } __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_4, __pyx_v_selector_value) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_selector_value); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2921, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3177, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = NULL; @@ -52755,14 +58786,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_6, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2921, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3177, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __PYX_ERR(1, 2921, __pyx_L1_error) + __PYX_ERR(1, 3177, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2920 + /* "dependency_injector/providers.pyx":3176 * raise Error('Selector value is undefined') * * if selector_value not in self.__providers: # <<<<<<<<<<<<<< @@ -52771,7 +58802,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str */ } - /* "dependency_injector/providers.pyx":2923 + /* "dependency_injector/providers.pyx":3179 * raise Error('Selector has no "{0}" provider'.format(selector_value)) * * return self.__providers[selector_value](*args, **kwargs) # <<<<<<<<<<<<<< @@ -52781,26 +58812,26 @@ static PyObject *__pyx_f_19dependency_injector_9providers_8Selector__provide(str __Pyx_XDECREF(__pyx_r); if (unlikely(__pyx_v_self->__pyx___providers == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 2923, __pyx_L1_error) + __PYX_ERR(1, 3179, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_GetItem(__pyx_v_self->__pyx___providers, __pyx_v_selector_value); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2923, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_GetItem(__pyx_v_self->__pyx___providers, __pyx_v_selector_value); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3179, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (unlikely(__pyx_v_args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 2923, __pyx_L1_error) + __PYX_ERR(1, 3179, __pyx_L1_error) } if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 2923, __pyx_L1_error) + __PYX_ERR(1, 3179, __pyx_L1_error) } - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2923, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3179, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2913 + /* "dependency_injector/providers.pyx":3169 * return dict(self.__providers) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -52859,11 +58890,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Selector_9_provide(P case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2913, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 3169, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2913, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 3169, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -52876,14 +58907,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_8Selector_9_provide(P } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2913, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3169, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.Selector._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2913, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2913, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3169, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3169, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_8Selector_8_provide(((struct __pyx_obj_19dependency_injector_9providers_Selector *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -52904,7 +58935,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_8_provide(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_8Selector__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2913, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_8Selector__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3169, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -52947,9 +58978,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_10__reduce_ PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -52960,49 +58991,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_10__reduce_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__providers, self.__selector) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__providers, self.__selector) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(__pyx_v_self->__pyx___providers); __Pyx_GIVEREF(__pyx_v_self->__pyx___providers); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx___providers); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx___providers); __Pyx_INCREF(__pyx_v_self->__pyx___selector); __Pyx_GIVEREF(__pyx_v_self->__pyx___selector); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->__pyx___selector); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->__pyx___selector); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__providers, self.__selector) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__providers, self.__selector) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__providers, self.__selector) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__providers, self.__selector) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -53011,16 +59047,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_10__reduce_ * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -53032,7 +59068,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_10__reduce_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__providers, self.__selector) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__providers, self.__selector) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -53046,35 +59082,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_10__reduce_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__providers is not None or self.__selector is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_Selector, (type(self), 0x570b822, None), state + * return __pyx_unpickle_Selector, (type(self), 0x6a94d6b, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx___providers != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx___providers != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx___selector != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - __pyx_t_3 = __pyx_t_2; + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -53082,44 +59118,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_10__reduce_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__providers is not None or self.__selector is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Selector, (type(self), 0x570b822, None), state + * return __pyx_unpickle_Selector, (type(self), 0x6a94d6b, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__providers is not None or self.__selector is not None * if use_setstate: - * return __pyx_unpickle_Selector, (type(self), 0x570b822, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_Selector, (type(self), 0x6a94d6b, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_Selector, (type(self), 0x570b822, state) + * return __pyx_unpickle_Selector, (type(self), 0x6a94d6b, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Selector); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_Selector); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_91273250); - __Pyx_GIVEREF(__pyx_int_91273250); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_91273250); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_111758699); + __Pyx_GIVEREF(__pyx_int_111758699); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_111758699); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -53128,15 +59164,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_10__reduce_ * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__providers is not None or self.__selector is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_Selector, (type(self), 0x570b822, None), state + * return __pyx_unpickle_Selector, (type(self), 0x6a94d6b, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_Selector, (type(self), 0x570b822, None), state + * return __pyx_unpickle_Selector, (type(self), 0x6a94d6b, None), state * else: - * return __pyx_unpickle_Selector, (type(self), 0x570b822, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_Selector, (type(self), 0x6a94d6b, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Selector__set_state(self, __pyx_state) */ @@ -53144,27 +59180,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_10__reduce_ __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_Selector); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_91273250); - __Pyx_GIVEREF(__pyx_int_91273250); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_91273250); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_111758699); + __Pyx_GIVEREF(__pyx_int_111758699); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_111758699); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -53177,7 +59213,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_10__reduce_ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.Selector.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -53191,7 +59227,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_10__reduce_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Selector, (type(self), 0x570b822, state) + * return __pyx_unpickle_Selector, (type(self), 0x6a94d6b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Selector__set_state(self, __pyx_state) */ @@ -53219,7 +59255,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_12__setstat __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_Selector, (type(self), 0x570b822, state) + * return __pyx_unpickle_Selector, (type(self), 0x6a94d6b, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_Selector__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -53230,7 +59266,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_12__setstat /* "(tree fragment)":16 * else: - * return __pyx_unpickle_Selector, (type(self), 0x570b822, state) + * return __pyx_unpickle_Selector, (type(self), 0x6a94d6b, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_Selector__set_state(self, __pyx_state) */ @@ -53248,7 +59284,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8Selector_12__setstat return __pyx_r; } -/* "dependency_injector/providers.pyx":2957 +/* "dependency_injector/providers.pyx":3213 * """ * * def __init__(self, provider): # <<<<<<<<<<<<<< @@ -53285,7 +59321,7 @@ static int __pyx_pw_19dependency_injector_9providers_16ProvidedInstance_1__init_ else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 2957, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 3213, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -53296,7 +59332,7 @@ static int __pyx_pw_19dependency_injector_9providers_16ProvidedInstance_1__init_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2957, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3213, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ProvidedInstance.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -53320,14 +59356,14 @@ static int __pyx_pf_19dependency_injector_9providers_16ProvidedInstance___init__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":2958 + /* "dependency_injector/providers.pyx":3214 * * def __init__(self, provider): * self.__provider = provider # <<<<<<<<<<<<<< * super().__init__() * */ - if (!(likely(((__pyx_v_provider) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 2958, __pyx_L1_error) + if (!(likely(((__pyx_v_provider) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 3214, __pyx_L1_error) __pyx_t_1 = __pyx_v_provider; __Pyx_INCREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); @@ -53336,14 +59372,14 @@ static int __pyx_pf_19dependency_injector_9providers_16ProvidedInstance___init__ __pyx_v_self->__pyx___provider = ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2959 + /* "dependency_injector/providers.pyx":3215 * def __init__(self, provider): * self.__provider = provider * super().__init__() # <<<<<<<<<<<<<< * * def __repr__(self): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2959, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3215, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ProvidedInstance)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ProvidedInstance)); @@ -53351,10 +59387,10 @@ static int __pyx_pf_19dependency_injector_9providers_16ProvidedInstance___init__ __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2959, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3215, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2959, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3215, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -53369,12 +59405,12 @@ static int __pyx_pf_19dependency_injector_9providers_16ProvidedInstance___init__ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2959, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3215, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2957 + /* "dependency_injector/providers.pyx":3213 * """ * * def __init__(self, provider): # <<<<<<<<<<<<<< @@ -53396,7 +59432,7 @@ static int __pyx_pf_19dependency_injector_9providers_16ProvidedInstance___init__ return __pyx_r; } -/* "dependency_injector/providers.pyx":2961 +/* "dependency_injector/providers.pyx":3217 * super().__init__() * * def __repr__(self): # <<<<<<<<<<<<<< @@ -53430,7 +59466,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_2_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__repr__", 0); - /* "dependency_injector/providers.pyx":2962 + /* "dependency_injector/providers.pyx":3218 * * def __repr__(self): * return f'{self.__class__.__name__}(\'{self.__provider}\')' # <<<<<<<<<<<<<< @@ -53438,16 +59474,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_2_ * def __deepcopy__(self, memo=None): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2962, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3218, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = 0; __pyx_t_3 = 127; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2962, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3218, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 2962, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3218, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_t_5, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2962, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_t_5, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3218, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_3 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) > __pyx_t_3) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) : __pyx_t_3; @@ -53455,29 +59491,29 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_2_ __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_4); __pyx_t_4 = 0; - __Pyx_INCREF(__pyx_kp_u__13); + __Pyx_INCREF(__pyx_kp_u__14); __pyx_t_2 += 2; - __Pyx_GIVEREF(__pyx_kp_u__13); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_kp_u__13); - __pyx_t_4 = __Pyx_PyObject_FormatSimple(((PyObject *)__pyx_v_self->__pyx___provider), __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2962, __pyx_L1_error) + __Pyx_GIVEREF(__pyx_kp_u__14); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_kp_u__14); + __pyx_t_4 = __Pyx_PyObject_FormatSimple(((PyObject *)__pyx_v_self->__pyx___provider), __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3218, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_3 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) > __pyx_t_3) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) : __pyx_t_3; __pyx_t_2 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4); __pyx_t_4 = 0; - __Pyx_INCREF(__pyx_kp_u__14); + __Pyx_INCREF(__pyx_kp_u__15); __pyx_t_2 += 2; - __Pyx_GIVEREF(__pyx_kp_u__14); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_kp_u__14); - __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 4, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2962, __pyx_L1_error) + __Pyx_GIVEREF(__pyx_kp_u__15); + PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_kp_u__15); + __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 4, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3218, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_4; __pyx_t_4 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2961 + /* "dependency_injector/providers.pyx":3217 * super().__init__() * * def __repr__(self): # <<<<<<<<<<<<<< @@ -53498,7 +59534,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_2_ return __pyx_r; } -/* "dependency_injector/providers.pyx":2964 +/* "dependency_injector/providers.pyx":3220 * return f'{self.__class__.__name__}(\'{self.__provider}\')' * * def __deepcopy__(self, memo=None): # <<<<<<<<<<<<<< @@ -53538,7 +59574,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_16ProvidedInstance_5_ } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__deepcopy__") < 0)) __PYX_ERR(1, 2964, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__deepcopy__") < 0)) __PYX_ERR(1, 3220, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -53552,7 +59588,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_16ProvidedInstance_5_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__deepcopy__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2964, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__deepcopy__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3220, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ProvidedInstance.__deepcopy__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -53581,16 +59617,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_4_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":2967 + /* "dependency_injector/providers.pyx":3223 * cdef ProvidedInstance copied * * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2967, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3223, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 2967, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3223, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -53605,14 +59641,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_4_ __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2967, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3223, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_ProvidedInstance))))) __PYX_ERR(1, 2967, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_ProvidedInstance))))) __PYX_ERR(1, 3223, __pyx_L1_error) __pyx_v_copied = ((struct __pyx_obj_19dependency_injector_9providers_ProvidedInstance *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2968 + /* "dependency_injector/providers.pyx":3224 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -53623,7 +59659,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_4_ __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":2969 + /* "dependency_injector/providers.pyx":3225 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -53635,7 +59671,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_4_ __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2968 + /* "dependency_injector/providers.pyx":3224 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -53644,7 +59680,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_4_ */ } - /* "dependency_injector/providers.pyx":2971 + /* "dependency_injector/providers.pyx":3227 * return copied * * return self.__class__( # <<<<<<<<<<<<<< @@ -53652,10 +59688,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_4_ * ) */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2971, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3227, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - /* "dependency_injector/providers.pyx":2972 + /* "dependency_injector/providers.pyx":3228 * * return self.__class__( * deepcopy(self.__provider, memo), # <<<<<<<<<<<<<< @@ -53664,10 +59700,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_4_ */ __pyx_t_3 = ((PyObject *)__pyx_v_self->__pyx___provider); __Pyx_INCREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 2972, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3228, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 2972, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3228, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -53683,14 +59719,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_4_ __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2971, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3227, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2964 + /* "dependency_injector/providers.pyx":3220 * return f'{self.__class__.__name__}(\'{self.__provider}\')' * * def __deepcopy__(self, memo=None): # <<<<<<<<<<<<<< @@ -53713,7 +59749,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_4_ return __pyx_r; } -/* "dependency_injector/providers.pyx":2975 +/* "dependency_injector/providers.pyx":3231 * ) * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -53744,7 +59780,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_6_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getattr__", 0); - /* "dependency_injector/providers.pyx":2976 + /* "dependency_injector/providers.pyx":3232 * * def __getattr__(self, item): * return AttributeGetter(self, item) # <<<<<<<<<<<<<< @@ -53752,7 +59788,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_6_ * def __getitem__(self, item): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2976, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3232, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); @@ -53760,14 +59796,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_6_ __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_item); - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AttributeGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2976, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AttributeGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3232, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2975 + /* "dependency_injector/providers.pyx":3231 * ) * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -53787,7 +59823,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_6_ return __pyx_r; } -/* "dependency_injector/providers.pyx":2978 +/* "dependency_injector/providers.pyx":3234 * return AttributeGetter(self, item) * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -53818,7 +59854,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_8_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getitem__", 0); - /* "dependency_injector/providers.pyx":2979 + /* "dependency_injector/providers.pyx":3235 * * def __getitem__(self, item): * return ItemGetter(self, item) # <<<<<<<<<<<<<< @@ -53826,7 +59862,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_8_ * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2979, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3235, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); @@ -53834,14 +59870,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_8_ __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_item); - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ItemGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2979, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ItemGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3235, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2978 + /* "dependency_injector/providers.pyx":3234 * return AttributeGetter(self, item) * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -53861,7 +59897,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_8_ return __pyx_r; } -/* "dependency_injector/providers.pyx":2982 +/* "dependency_injector/providers.pyx":3238 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -53887,7 +59923,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_8p __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":2984 + /* "dependency_injector/providers.pyx":3240 * def provides(self): * """Return provider.""" * return self.__provider # <<<<<<<<<<<<<< @@ -53899,7 +59935,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_8p __pyx_r = ((PyObject *)__pyx_v_self->__pyx___provider); goto __pyx_L0; - /* "dependency_injector/providers.pyx":2982 + /* "dependency_injector/providers.pyx":3238 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -53914,7 +59950,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_8p return __pyx_r; } -/* "dependency_injector/providers.pyx":2986 +/* "dependency_injector/providers.pyx":3242 * return self.__provider * * def call(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -53958,7 +59994,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_10 int __pyx_clineno = 0; __Pyx_RefNannySetupContext("call", 0); - /* "dependency_injector/providers.pyx":2987 + /* "dependency_injector/providers.pyx":3243 * * def call(self, *args, **kwargs): * return MethodCaller(self, *args, **kwargs) # <<<<<<<<<<<<<< @@ -53966,22 +60002,22 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_10 * cpdef object _provide(self, tuple args, dict kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2987, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3243, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self)); - __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2987, __pyx_L1_error) + __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3243, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_MethodCaller), __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2987, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_MethodCaller), __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3243, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2986 + /* "dependency_injector/providers.pyx":3242 * return self.__provider * * def call(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -54001,7 +60037,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_10 return __pyx_r; } -/* "dependency_injector/providers.pyx":2989 +/* "dependency_injector/providers.pyx":3245 * return MethodCaller(self, *args, **kwargs) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -54032,7 +60068,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16ProvidedInstance__pr if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2989, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_16ProvidedInstance_13_provide)) { __Pyx_XDECREF(__pyx_r); @@ -54052,7 +60088,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16ProvidedInstance__pr #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2989, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3245, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -54060,13 +60096,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16ProvidedInstance__pr #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2989, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3245, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 2989, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -54077,7 +60113,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16ProvidedInstance__pr __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 2989, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -54100,7 +60136,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16ProvidedInstance__pr #endif } - /* "dependency_injector/providers.pyx":2990 + /* "dependency_injector/providers.pyx":3246 * * cpdef object _provide(self, tuple args, dict kwargs): * return self.__provider(*args, **kwargs) # <<<<<<<<<<<<<< @@ -54110,19 +60146,19 @@ static PyObject *__pyx_f_19dependency_injector_9providers_16ProvidedInstance__pr __Pyx_XDECREF(__pyx_r); if (unlikely(__pyx_v_args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 2990, __pyx_L1_error) + __PYX_ERR(1, 3246, __pyx_L1_error) } if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 2990, __pyx_L1_error) + __PYX_ERR(1, 3246, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx___provider), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2990, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx___provider), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3246, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":2989 + /* "dependency_injector/providers.pyx":3245 * return MethodCaller(self, *args, **kwargs) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -54179,11 +60215,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_16ProvidedInstance_13 case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 2989, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 3245, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 2989, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 3245, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -54196,14 +60232,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_16ProvidedInstance_13 } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2989, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3245, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ProvidedInstance._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 2989, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 2989, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3245, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3245, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_16ProvidedInstance_12_provide(((struct __pyx_obj_19dependency_injector_9providers_ProvidedInstance *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -54224,7 +60260,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_12 int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_16ProvidedInstance__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2989, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_16ProvidedInstance__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -54267,9 +60303,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_14 PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -54280,46 +60316,51 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_14 /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provider) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provider) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx___provider)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx___provider)); - PyTuple_SET_ITEM(__pyx_t_1, 2, ((PyObject *)__pyx_v_self->__pyx___provider)); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 3, ((PyObject *)__pyx_v_self->__pyx___provider)); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -54328,16 +60369,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_14 * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -54349,7 +60390,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_14 __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__async_mode, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -54363,28 +60404,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_14 * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_ProvidedInstance, (type(self), 0x0d07ffc, None), state + * return __pyx_unpickle_ProvidedInstance, (type(self), 0xfd61095, None), state */ /*else*/ { - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (((PyObject *)__pyx_v_self->__pyx___provider) != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); - __pyx_t_3 = __pyx_t_5; + __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx___provider) != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); + __pyx_t_4 = __pyx_t_5; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -54392,44 +60433,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_14 * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ProvidedInstance, (type(self), 0x0d07ffc, None), state + * return __pyx_unpickle_ProvidedInstance, (type(self), 0xfd61095, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: - * return __pyx_unpickle_ProvidedInstance, (type(self), 0x0d07ffc, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_ProvidedInstance, (type(self), 0xfd61095, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_ProvidedInstance, (type(self), 0x0d07ffc, state) + * return __pyx_unpickle_ProvidedInstance, (type(self), 0xfd61095, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_ProvidedInstance); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_ProvidedInstance); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_13664252); - __Pyx_GIVEREF(__pyx_int_13664252); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_13664252); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_265687189); + __Pyx_GIVEREF(__pyx_int_265687189); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_265687189); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -54438,15 +60479,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_14 * else: * use_setstate = self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ProvidedInstance, (type(self), 0x0d07ffc, None), state + * return __pyx_unpickle_ProvidedInstance, (type(self), 0xfd61095, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_ProvidedInstance, (type(self), 0x0d07ffc, None), state + * return __pyx_unpickle_ProvidedInstance, (type(self), 0xfd61095, None), state * else: - * return __pyx_unpickle_ProvidedInstance, (type(self), 0x0d07ffc, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_ProvidedInstance, (type(self), 0xfd61095, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ProvidedInstance__set_state(self, __pyx_state) */ @@ -54454,27 +60495,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_14 __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_ProvidedInstance); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_13664252); - __Pyx_GIVEREF(__pyx_int_13664252); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_13664252); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_265687189); + __Pyx_GIVEREF(__pyx_int_265687189); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_265687189); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -54487,7 +60528,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_14 /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.ProvidedInstance.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -54501,7 +60542,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_14 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ProvidedInstance, (type(self), 0x0d07ffc, state) + * return __pyx_unpickle_ProvidedInstance, (type(self), 0xfd61095, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ProvidedInstance__set_state(self, __pyx_state) */ @@ -54529,7 +60570,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_16 __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_ProvidedInstance, (type(self), 0x0d07ffc, state) + * return __pyx_unpickle_ProvidedInstance, (type(self), 0xfd61095, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ProvidedInstance__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -54540,7 +60581,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_16 /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ProvidedInstance, (type(self), 0x0d07ffc, state) + * return __pyx_unpickle_ProvidedInstance, (type(self), 0xfd61095, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ProvidedInstance__set_state(self, __pyx_state) */ @@ -54558,7 +60599,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16ProvidedInstance_16 return __pyx_r; } -/* "dependency_injector/providers.pyx":2999 +/* "dependency_injector/providers.pyx":3255 * """ * * def __init__(self, provider, attribute): # <<<<<<<<<<<<<< @@ -54600,11 +60641,11 @@ static int __pyx_pw_19dependency_injector_9providers_15AttributeGetter_1__init__ case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_attribute)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, 1); __PYX_ERR(1, 2999, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, 1); __PYX_ERR(1, 3255, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 2999, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 3255, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -54617,7 +60658,7 @@ static int __pyx_pw_19dependency_injector_9providers_15AttributeGetter_1__init__ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 2999, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3255, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.AttributeGetter.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -54641,14 +60682,14 @@ static int __pyx_pf_19dependency_injector_9providers_15AttributeGetter___init__( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":3000 + /* "dependency_injector/providers.pyx":3256 * * def __init__(self, provider, attribute): * self.__provider = provider # <<<<<<<<<<<<<< * self.__attribute = attribute * super().__init__() */ - if (!(likely(((__pyx_v_provider) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 3000, __pyx_L1_error) + if (!(likely(((__pyx_v_provider) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 3256, __pyx_L1_error) __pyx_t_1 = __pyx_v_provider; __Pyx_INCREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); @@ -54657,7 +60698,7 @@ static int __pyx_pf_19dependency_injector_9providers_15AttributeGetter___init__( __pyx_v_self->__pyx___provider = ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3001 + /* "dependency_injector/providers.pyx":3257 * def __init__(self, provider, attribute): * self.__provider = provider * self.__attribute = attribute # <<<<<<<<<<<<<< @@ -54670,14 +60711,14 @@ static int __pyx_pf_19dependency_injector_9providers_15AttributeGetter___init__( __Pyx_DECREF(__pyx_v_self->__pyx___attribute); __pyx_v_self->__pyx___attribute = __pyx_v_attribute; - /* "dependency_injector/providers.pyx":3002 + /* "dependency_injector/providers.pyx":3258 * self.__provider = provider * self.__attribute = attribute * super().__init__() # <<<<<<<<<<<<<< * * def __repr__(self): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3002, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3258, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AttributeGetter)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AttributeGetter)); @@ -54685,10 +60726,10 @@ static int __pyx_pf_19dependency_injector_9providers_15AttributeGetter___init__( __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3002, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3258, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3002, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3258, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -54703,12 +60744,12 @@ static int __pyx_pf_19dependency_injector_9providers_15AttributeGetter___init__( } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3002, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3258, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":2999 + /* "dependency_injector/providers.pyx":3255 * """ * * def __init__(self, provider, attribute): # <<<<<<<<<<<<<< @@ -54730,7 +60771,7 @@ static int __pyx_pf_19dependency_injector_9providers_15AttributeGetter___init__( return __pyx_r; } -/* "dependency_injector/providers.pyx":3004 +/* "dependency_injector/providers.pyx":3260 * super().__init__() * * def __repr__(self): # <<<<<<<<<<<<<< @@ -54764,7 +60805,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_2__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__repr__", 0); - /* "dependency_injector/providers.pyx":3005 + /* "dependency_injector/providers.pyx":3261 * * def __repr__(self): * return f'{self.__class__.__name__}(\'{self.__attribute}\')' # <<<<<<<<<<<<<< @@ -54772,16 +60813,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_2__ * def __deepcopy__(self, memo=None): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3005, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = 0; __pyx_t_3 = 127; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3005, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3005, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_t_5, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3005, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_t_5, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_3 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) > __pyx_t_3) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) : __pyx_t_3; @@ -54789,29 +60830,29 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_2__ __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_4); __pyx_t_4 = 0; - __Pyx_INCREF(__pyx_kp_u__13); + __Pyx_INCREF(__pyx_kp_u__14); __pyx_t_2 += 2; - __Pyx_GIVEREF(__pyx_kp_u__13); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_kp_u__13); - __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_v_self->__pyx___attribute, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3005, __pyx_L1_error) + __Pyx_GIVEREF(__pyx_kp_u__14); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_kp_u__14); + __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_v_self->__pyx___attribute, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_3 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) > __pyx_t_3) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) : __pyx_t_3; __pyx_t_2 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4); __pyx_t_4 = 0; - __Pyx_INCREF(__pyx_kp_u__14); + __Pyx_INCREF(__pyx_kp_u__15); __pyx_t_2 += 2; - __Pyx_GIVEREF(__pyx_kp_u__14); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_kp_u__14); - __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 4, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3005, __pyx_L1_error) + __Pyx_GIVEREF(__pyx_kp_u__15); + PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_kp_u__15); + __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 4, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_4; __pyx_t_4 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3004 + /* "dependency_injector/providers.pyx":3260 * super().__init__() * * def __repr__(self): # <<<<<<<<<<<<<< @@ -54832,7 +60873,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_2__ return __pyx_r; } -/* "dependency_injector/providers.pyx":3007 +/* "dependency_injector/providers.pyx":3263 * return f'{self.__class__.__name__}(\'{self.__attribute}\')' * * def __deepcopy__(self, memo=None): # <<<<<<<<<<<<<< @@ -54872,7 +60913,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_5__ } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__deepcopy__") < 0)) __PYX_ERR(1, 3007, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__deepcopy__") < 0)) __PYX_ERR(1, 3263, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -54886,7 +60927,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_5__ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__deepcopy__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3007, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__deepcopy__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3263, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.AttributeGetter.__deepcopy__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -54917,16 +60958,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":3010 + /* "dependency_injector/providers.pyx":3266 * cdef AttributeGetter copied * * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3010, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3266, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3010, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3266, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -54941,14 +60982,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3010, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3266, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_AttributeGetter))))) __PYX_ERR(1, 3010, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_AttributeGetter))))) __PYX_ERR(1, 3266, __pyx_L1_error) __pyx_v_copied = ((struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3011 + /* "dependency_injector/providers.pyx":3267 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -54959,7 +61000,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":3012 + /* "dependency_injector/providers.pyx":3268 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -54971,7 +61012,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":3011 + /* "dependency_injector/providers.pyx":3267 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -54980,7 +61021,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ */ } - /* "dependency_injector/providers.pyx":3014 + /* "dependency_injector/providers.pyx":3270 * return copied * * return self.__class__( # <<<<<<<<<<<<<< @@ -54988,10 +61029,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ * self.__attribute, */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3014, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - /* "dependency_injector/providers.pyx":3015 + /* "dependency_injector/providers.pyx":3271 * * return self.__class__( * deepcopy(self.__provider, memo), # <<<<<<<<<<<<<< @@ -55000,14 +61041,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ */ __pyx_t_3 = ((PyObject *)__pyx_v_self->__pyx___provider); __Pyx_INCREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3015, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3271, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3015, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3271, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":3016 + /* "dependency_injector/providers.pyx":3272 * return self.__class__( * deepcopy(self.__provider, memo), * self.__attribute, # <<<<<<<<<<<<<< @@ -55029,7 +61070,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_t_4, __pyx_v_self->__pyx___attribute}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3014, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3270, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -55038,14 +61079,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_t_4, __pyx_v_self->__pyx___attribute}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3014, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3270, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 3014, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 3270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_3) { __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_3); __pyx_t_3 = NULL; @@ -55056,7 +61097,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ __Pyx_GIVEREF(__pyx_v_self->__pyx___attribute); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, __pyx_v_self->__pyx___attribute); __pyx_t_4 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3014, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } @@ -55065,7 +61106,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3007 + /* "dependency_injector/providers.pyx":3263 * return f'{self.__class__.__name__}(\'{self.__attribute}\')' * * def __deepcopy__(self, memo=None): # <<<<<<<<<<<<<< @@ -55089,7 +61130,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4__ return __pyx_r; } -/* "dependency_injector/providers.pyx":3019 +/* "dependency_injector/providers.pyx":3275 * ) * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -55120,7 +61161,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_6__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getattr__", 0); - /* "dependency_injector/providers.pyx":3020 + /* "dependency_injector/providers.pyx":3276 * * def __getattr__(self, item): * return AttributeGetter(self, item) # <<<<<<<<<<<<<< @@ -55128,7 +61169,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_6__ * def __getitem__(self, item): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3020, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); @@ -55136,14 +61177,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_6__ __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_item); - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AttributeGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3020, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AttributeGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3276, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3019 + /* "dependency_injector/providers.pyx":3275 * ) * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -55163,7 +61204,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_6__ return __pyx_r; } -/* "dependency_injector/providers.pyx":3022 +/* "dependency_injector/providers.pyx":3278 * return AttributeGetter(self, item) * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -55194,7 +61235,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_8__ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getitem__", 0); - /* "dependency_injector/providers.pyx":3023 + /* "dependency_injector/providers.pyx":3279 * * def __getitem__(self, item): * return ItemGetter(self, item) # <<<<<<<<<<<<<< @@ -55202,7 +61243,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_8__ * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3023, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3279, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); @@ -55210,14 +61251,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_8__ __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_item); - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ItemGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3023, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ItemGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3279, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3022 + /* "dependency_injector/providers.pyx":3278 * return AttributeGetter(self, item) * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -55237,7 +61278,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_8__ return __pyx_r; } -/* "dependency_injector/providers.pyx":3026 +/* "dependency_injector/providers.pyx":3282 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -55263,7 +61304,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_8pr __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":3028 + /* "dependency_injector/providers.pyx":3284 * def provides(self): * """Return provider.""" * return self.__provider # <<<<<<<<<<<<<< @@ -55275,7 +61316,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_8pr __pyx_r = ((PyObject *)__pyx_v_self->__pyx___provider); goto __pyx_L0; - /* "dependency_injector/providers.pyx":3026 + /* "dependency_injector/providers.pyx":3282 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -55290,7 +61331,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_8pr return __pyx_r; } -/* "dependency_injector/providers.pyx":3031 +/* "dependency_injector/providers.pyx":3287 * * @property * def name(self): # <<<<<<<<<<<<<< @@ -55316,7 +61357,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4na __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":3033 + /* "dependency_injector/providers.pyx":3289 * def name(self): * """Return name of the attribute.""" * return self.__attribute # <<<<<<<<<<<<<< @@ -55328,7 +61369,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4na __pyx_r = __pyx_v_self->__pyx___attribute; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3031 + /* "dependency_injector/providers.pyx":3287 * * @property * def name(self): # <<<<<<<<<<<<<< @@ -55343,7 +61384,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_4na return __pyx_r; } -/* "dependency_injector/providers.pyx":3035 +/* "dependency_injector/providers.pyx":3291 * return self.__attribute * * def call(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -55387,7 +61428,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_10c int __pyx_clineno = 0; __Pyx_RefNannySetupContext("call", 0); - /* "dependency_injector/providers.pyx":3036 + /* "dependency_injector/providers.pyx":3292 * * def call(self, *args, **kwargs): * return MethodCaller(self, *args, **kwargs) # <<<<<<<<<<<<<< @@ -55395,22 +61436,22 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_10c * cpdef object _provide(self, tuple args, dict kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3036, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3292, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self)); - __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3036, __pyx_L1_error) + __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3292, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_MethodCaller), __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3036, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_MethodCaller), __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3292, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3035 + /* "dependency_injector/providers.pyx":3291 * return self.__attribute * * def call(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -55430,17 +61471,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_10c return __pyx_r; } -/* "dependency_injector/providers.pyx":3038 +/* "dependency_injector/providers.pyx":3294 * return MethodCaller(self, *args, **kwargs) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * provided = self.__provider(*args, **kwargs) - * return getattr(provided, self.__attribute) + * if __isawaitable(provided): */ static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_13_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_15AttributeGetter__provide(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch) { PyObject *__pyx_v_provided = NULL; + PyObject *__pyx_v_future_result = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -55449,6 +61491,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AttributeGetter__pro PyObject *__pyx_t_4 = NULL; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -55462,7 +61507,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AttributeGetter__pro if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3038, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3294, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_15AttributeGetter_13_provide)) { __Pyx_XDECREF(__pyx_r); @@ -55482,7 +61527,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AttributeGetter__pro #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3038, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3294, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -55490,13 +61535,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AttributeGetter__pro #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3038, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3294, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3038, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3294, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -55507,7 +61552,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AttributeGetter__pro __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3038, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3294, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -55530,49 +61575,221 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AttributeGetter__pro #endif } - /* "dependency_injector/providers.pyx":3039 + /* "dependency_injector/providers.pyx":3295 * * cpdef object _provide(self, tuple args, dict kwargs): * provided = self.__provider(*args, **kwargs) # <<<<<<<<<<<<<< - * return getattr(provided, self.__attribute) - * + * if __isawaitable(provided): + * future_result = asyncio.Future() */ if (unlikely(__pyx_v_args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 3039, __pyx_L1_error) + __PYX_ERR(1, 3295, __pyx_L1_error) } if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 3039, __pyx_L1_error) + __PYX_ERR(1, 3295, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx___provider), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3039, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx___provider), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3295, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_provided = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3040 + /* "dependency_injector/providers.pyx":3296 * cpdef object _provide(self, tuple args, dict kwargs): * provided = self.__provider(*args, **kwargs) + * if __isawaitable(provided): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * provided = asyncio.ensure_future(provided) + */ + __pyx_t_7 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_provided) != 0); + if (__pyx_t_7) { + + /* "dependency_injector/providers.pyx":3297 + * provided = self.__provider(*args, **kwargs) + * if __isawaitable(provided): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * provided = asyncio.ensure_future(provided) + * provided.add_done_callback(functools.partial(self._async_provide, future_result)) + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3297, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_Future); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3297, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3297, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_future_result = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3298 + * if __isawaitable(provided): + * future_result = asyncio.Future() + * provided = asyncio.ensure_future(provided) # <<<<<<<<<<<<<< + * provided.add_done_callback(functools.partial(self._async_provide, future_result)) + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3298, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3298, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_provided) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_provided); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3298, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_provided, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3299 + * future_result = asyncio.Future() + * provided = asyncio.ensure_future(provided) + * provided.add_done_callback(functools.partial(self._async_provide, future_result)) # <<<<<<<<<<<<<< + * return future_result + * return getattr(provided, self.__attribute) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provided, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3299, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_functools); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3299, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_partial); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3299, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_async_provide); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3299, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_8 = NULL; + __pyx_t_5 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_8)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_8); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + __pyx_t_5 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_4)) { + PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_6, __pyx_v_future_result}; + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3299, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { + PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_6, __pyx_v_future_result}; + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3299, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + { + __pyx_t_9 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 3299, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + if (__pyx_t_8) { + __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_8); __pyx_t_8 = NULL; + } + __Pyx_GIVEREF(__pyx_t_6); + PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_5, __pyx_t_6); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_5, __pyx_v_future_result); + __pyx_t_6 = 0; + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3299, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + } + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3299, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3300 + * provided = asyncio.ensure_future(provided) + * provided.add_done_callback(functools.partial(self._async_provide, future_result)) + * return future_result # <<<<<<<<<<<<<< + * return getattr(provided, self.__attribute) + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":3296 + * cpdef object _provide(self, tuple args, dict kwargs): + * provided = self.__provider(*args, **kwargs) + * if __isawaitable(provided): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * provided = asyncio.ensure_future(provided) + */ + } + + /* "dependency_injector/providers.pyx":3301 + * provided.add_done_callback(functools.partial(self._async_provide, future_result)) + * return future_result * return getattr(provided, self.__attribute) # <<<<<<<<<<<<<< * - * + * def _async_provide(self, future_result, future): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __pyx_v_self->__pyx___attribute; __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = __Pyx_GetAttr(__pyx_v_provided, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3040, __pyx_L1_error) + __pyx_t_2 = __Pyx_GetAttr(__pyx_v_provided, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3038 + /* "dependency_injector/providers.pyx":3294 * return MethodCaller(self, *args, **kwargs) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * provided = self.__provider(*args, **kwargs) - * return getattr(provided, self.__attribute) + * if __isawaitable(provided): */ /* function exit code */ @@ -55582,10 +61799,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_15AttributeGetter__pro __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.AttributeGetter._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_provided); + __Pyx_XDECREF(__pyx_v_future_result); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; @@ -55625,11 +61845,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_13_ case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 3038, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 3294, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 3038, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 3294, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -55642,14 +61862,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_13_ } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3038, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3294, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.AttributeGetter._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3038, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3038, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3294, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3294, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_15AttributeGetter_12_provide(((struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -55670,7 +61890,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_12_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_15AttributeGetter__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3038, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_15AttributeGetter__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3294, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -55687,6 +61907,184 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_12_ return __pyx_r; } +/* "dependency_injector/providers.pyx":3303 + * return getattr(provided, self.__attribute) + * + * def _async_provide(self, future_result, future): # <<<<<<<<<<<<<< + * provided = future.result() + * result = getattr(provided, self.__attribute) + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_15_async_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_15_async_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_future_result = 0; + PyObject *__pyx_v_future = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_async_provide (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_future_result,&__pyx_n_s_future,0}; + PyObject* values[2] = {0,0}; + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future_result)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + CYTHON_FALLTHROUGH; + case 1: + if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future)) != 0)) kw_args--; + else { + __Pyx_RaiseArgtupleInvalid("_async_provide", 1, 2, 2, 1); __PYX_ERR(1, 3303, __pyx_L3_error) + } + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_async_provide") < 0)) __PYX_ERR(1, 3303, __pyx_L3_error) + } + } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { + goto __pyx_L5_argtuple_error; + } else { + values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + } + __pyx_v_future_result = values[0]; + __pyx_v_future = values[1]; + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_async_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3303, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.AttributeGetter._async_provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + __pyx_r = __pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_async_provide(((struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *)__pyx_v_self), __pyx_v_future_result, __pyx_v_future); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_async_provide(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_future) { + PyObject *__pyx_v_provided = NULL; + PyObject *__pyx_v_result = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_async_provide", 0); + + /* "dependency_injector/providers.pyx":3304 + * + * def _async_provide(self, future_result, future): + * provided = future.result() # <<<<<<<<<<<<<< + * result = getattr(provided, self.__attribute) + * future_result.set_result(result) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3304, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3304, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_provided = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3305 + * def _async_provide(self, future_result, future): + * provided = future.result() + * result = getattr(provided, self.__attribute) # <<<<<<<<<<<<<< + * future_result.set_result(result) + * + */ + __pyx_t_1 = __pyx_v_self->__pyx___attribute; + __Pyx_INCREF(__pyx_t_1); + __pyx_t_2 = __Pyx_GetAttr(__pyx_v_provided, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3305, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v_result = __pyx_t_2; + __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":3306 + * provided = future.result() + * result = getattr(provided, self.__attribute) + * future_result.set_result(result) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3306, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_1, function); + } + } + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_3, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3306, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + + /* "dependency_injector/providers.pyx":3303 + * return getattr(provided, self.__attribute) + * + * def _async_provide(self, future_result, future): # <<<<<<<<<<<<<< + * provided = future.result() + * result = getattr(provided, self.__attribute) + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_AddTraceback("dependency_injector.providers.AttributeGetter._async_provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_provided); + __Pyx_XDECREF(__pyx_v_result); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + /* "(tree fragment)":1 * def __reduce_cython__(self): # <<<<<<<<<<<<<< * cdef tuple state @@ -55694,28 +62092,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_12_ */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_15__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_15__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { +static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_17__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_17__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_15AttributeGetter_14__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *)__pyx_v_self)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_15AttributeGetter_16__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self) { +static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_16__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self) { PyObject *__pyx_v_state = 0; PyObject *__pyx_v__dict = 0; int __pyx_v_use_setstate; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -55726,49 +62124,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_ /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__attribute, self.__last_overriding, self.__overridden, self.__provider) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__attribute, self.__last_overriding, self.__overridden, self.__provider) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx___attribute); __Pyx_GIVEREF(__pyx_v_self->__pyx___attribute); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->__pyx___attribute); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->__pyx___attribute); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx___provider)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx___provider)); - PyTuple_SET_ITEM(__pyx_t_1, 3, ((PyObject *)__pyx_v_self->__pyx___provider)); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 4, ((PyObject *)__pyx_v_self->__pyx___provider)); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__attribute, self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__async_mode, self.__attribute, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__attribute, self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__async_mode, self.__attribute, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -55777,16 +62180,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_ * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -55798,7 +62201,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_ __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__attribute, self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__async_mode, self.__attribute, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -55812,35 +62215,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_ * else: * use_setstate = self.__attribute is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_AttributeGetter, (type(self), 0xe01ff48, None), state + * return __pyx_unpickle_AttributeGetter, (type(self), 0x7ec84e3, None), state */ /*else*/ { - __pyx_t_2 = (__pyx_v_self->__pyx___attribute != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx___attribute != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx___provider) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - __pyx_t_3 = __pyx_t_2; + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -55848,44 +62251,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_ * else: * use_setstate = self.__attribute is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_AttributeGetter, (type(self), 0xe01ff48, None), state + * return __pyx_unpickle_AttributeGetter, (type(self), 0x7ec84e3, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__attribute is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: - * return __pyx_unpickle_AttributeGetter, (type(self), 0xe01ff48, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_AttributeGetter, (type(self), 0x7ec84e3, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_AttributeGetter, (type(self), 0xe01ff48, state) + * return __pyx_unpickle_AttributeGetter, (type(self), 0x7ec84e3, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_AttributeGetter); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_AttributeGetter); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_235011912); - __Pyx_GIVEREF(__pyx_int_235011912); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_235011912); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_132941027); + __Pyx_GIVEREF(__pyx_int_132941027); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_132941027); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -55894,15 +62297,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_ * else: * use_setstate = self.__attribute is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_AttributeGetter, (type(self), 0xe01ff48, None), state + * return __pyx_unpickle_AttributeGetter, (type(self), 0x7ec84e3, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_AttributeGetter, (type(self), 0xe01ff48, None), state + * return __pyx_unpickle_AttributeGetter, (type(self), 0x7ec84e3, None), state * else: - * return __pyx_unpickle_AttributeGetter, (type(self), 0xe01ff48, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_AttributeGetter, (type(self), 0x7ec84e3, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_AttributeGetter__set_state(self, __pyx_state) */ @@ -55910,27 +62313,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_ __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_AttributeGetter); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_235011912); - __Pyx_GIVEREF(__pyx_int_235011912); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_235011912); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_132941027); + __Pyx_GIVEREF(__pyx_int_132941027); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_132941027); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -55943,7 +62346,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.AttributeGetter.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -55957,25 +62360,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_14_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_AttributeGetter, (type(self), 0xe01ff48, state) + * return __pyx_unpickle_AttributeGetter, (type(self), 0x7ec84e3, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_AttributeGetter__set_state(self, __pyx_state) */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_17__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_17__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_19__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_15AttributeGetter_19__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_15AttributeGetter_16__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_15AttributeGetter_18__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_16__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_18__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -55985,7 +62388,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_16_ __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_AttributeGetter, (type(self), 0xe01ff48, state) + * return __pyx_unpickle_AttributeGetter, (type(self), 0x7ec84e3, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_AttributeGetter__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -55996,7 +62399,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_16_ /* "(tree fragment)":16 * else: - * return __pyx_unpickle_AttributeGetter, (type(self), 0xe01ff48, state) + * return __pyx_unpickle_AttributeGetter, (type(self), 0x7ec84e3, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_AttributeGetter__set_state(self, __pyx_state) */ @@ -56014,7 +62417,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_15AttributeGetter_16_ return __pyx_r; } -/* "dependency_injector/providers.pyx":3049 +/* "dependency_injector/providers.pyx":3315 * """ * * def __init__(self, Provider provider, object item): # <<<<<<<<<<<<<< @@ -56056,11 +62459,11 @@ static int __pyx_pw_19dependency_injector_9providers_10ItemGetter_1__init__(PyOb case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_item)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, 1); __PYX_ERR(1, 3049, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, 1); __PYX_ERR(1, 3315, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 3049, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 3315, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -56073,13 +62476,13 @@ static int __pyx_pw_19dependency_injector_9providers_10ItemGetter_1__init__(PyOb } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3049, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3315, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ItemGetter.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return -1; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_provider), __pyx_ptype_19dependency_injector_9providers_Provider, 1, "provider", 0))) __PYX_ERR(1, 3049, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_provider), __pyx_ptype_19dependency_injector_9providers_Provider, 1, "provider", 0))) __PYX_ERR(1, 3315, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_10ItemGetter___init__(((struct __pyx_obj_19dependency_injector_9providers_ItemGetter *)__pyx_v_self), __pyx_v_provider, __pyx_v_item); /* function exit code */ @@ -56102,7 +62505,7 @@ static int __pyx_pf_19dependency_injector_9providers_10ItemGetter___init__(struc int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":3050 + /* "dependency_injector/providers.pyx":3316 * * def __init__(self, Provider provider, object item): * self.__provider = provider # <<<<<<<<<<<<<< @@ -56115,7 +62518,7 @@ static int __pyx_pf_19dependency_injector_9providers_10ItemGetter___init__(struc __Pyx_DECREF(((PyObject *)__pyx_v_self->__pyx___provider)); __pyx_v_self->__pyx___provider = __pyx_v_provider; - /* "dependency_injector/providers.pyx":3051 + /* "dependency_injector/providers.pyx":3317 * def __init__(self, Provider provider, object item): * self.__provider = provider * self.__item = item # <<<<<<<<<<<<<< @@ -56128,14 +62531,14 @@ static int __pyx_pf_19dependency_injector_9providers_10ItemGetter___init__(struc __Pyx_DECREF(__pyx_v_self->__pyx___item); __pyx_v_self->__pyx___item = __pyx_v_item; - /* "dependency_injector/providers.pyx":3052 + /* "dependency_injector/providers.pyx":3318 * self.__provider = provider * self.__item = item * super().__init__() # <<<<<<<<<<<<<< * * def __repr__(self): */ - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3052, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3318, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ItemGetter)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ItemGetter)); @@ -56143,10 +62546,10 @@ static int __pyx_pf_19dependency_injector_9providers_10ItemGetter___init__(struc __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_2, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3052, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3318, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3052, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_init); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3318, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -56161,12 +62564,12 @@ static int __pyx_pf_19dependency_injector_9providers_10ItemGetter___init__(struc } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3052, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3318, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3049 + /* "dependency_injector/providers.pyx":3315 * """ * * def __init__(self, Provider provider, object item): # <<<<<<<<<<<<<< @@ -56188,7 +62591,7 @@ static int __pyx_pf_19dependency_injector_9providers_10ItemGetter___init__(struc return __pyx_r; } -/* "dependency_injector/providers.pyx":3054 +/* "dependency_injector/providers.pyx":3320 * super().__init__() * * def __repr__(self): # <<<<<<<<<<<<<< @@ -56222,7 +62625,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_2__repr_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__repr__", 0); - /* "dependency_injector/providers.pyx":3055 + /* "dependency_injector/providers.pyx":3321 * * def __repr__(self): * return f'{self.__class__.__name__}(\'{self.__item}\')' # <<<<<<<<<<<<<< @@ -56230,16 +62633,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_2__repr_ * def __deepcopy__(self, memo=None): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3055, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = 0; __pyx_t_3 = 127; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3055, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3055, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_t_5, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3055, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_t_5, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_3 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) > __pyx_t_3) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) : __pyx_t_3; @@ -56247,29 +62650,29 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_2__repr_ __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_4); __pyx_t_4 = 0; - __Pyx_INCREF(__pyx_kp_u__13); + __Pyx_INCREF(__pyx_kp_u__14); __pyx_t_2 += 2; - __Pyx_GIVEREF(__pyx_kp_u__13); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_kp_u__13); - __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_v_self->__pyx___item, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3055, __pyx_L1_error) + __Pyx_GIVEREF(__pyx_kp_u__14); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_kp_u__14); + __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_v_self->__pyx___item, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_3 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) > __pyx_t_3) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) : __pyx_t_3; __pyx_t_2 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4); __pyx_t_4 = 0; - __Pyx_INCREF(__pyx_kp_u__14); + __Pyx_INCREF(__pyx_kp_u__15); __pyx_t_2 += 2; - __Pyx_GIVEREF(__pyx_kp_u__14); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_kp_u__14); - __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 4, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3055, __pyx_L1_error) + __Pyx_GIVEREF(__pyx_kp_u__15); + PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_kp_u__15); + __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 4, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_4; __pyx_t_4 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3054 + /* "dependency_injector/providers.pyx":3320 * super().__init__() * * def __repr__(self): # <<<<<<<<<<<<<< @@ -56290,7 +62693,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_2__repr_ return __pyx_r; } -/* "dependency_injector/providers.pyx":3057 +/* "dependency_injector/providers.pyx":3323 * return f'{self.__class__.__name__}(\'{self.__item}\')' * * def __deepcopy__(self, memo=None): # <<<<<<<<<<<<<< @@ -56330,7 +62733,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_5__deepc } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__deepcopy__") < 0)) __PYX_ERR(1, 3057, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__deepcopy__") < 0)) __PYX_ERR(1, 3323, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -56344,7 +62747,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_5__deepc } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__deepcopy__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3057, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__deepcopy__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3323, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ItemGetter.__deepcopy__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -56375,16 +62778,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":3060 + /* "dependency_injector/providers.pyx":3326 * cdef ItemGetter copied * * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3060, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3326, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3060, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3326, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -56399,14 +62802,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3060, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3326, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_ItemGetter))))) __PYX_ERR(1, 3060, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_ItemGetter))))) __PYX_ERR(1, 3326, __pyx_L1_error) __pyx_v_copied = ((struct __pyx_obj_19dependency_injector_9providers_ItemGetter *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3061 + /* "dependency_injector/providers.pyx":3327 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -56417,7 +62820,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":3062 + /* "dependency_injector/providers.pyx":3328 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -56429,7 +62832,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":3061 + /* "dependency_injector/providers.pyx":3327 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -56438,7 +62841,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc */ } - /* "dependency_injector/providers.pyx":3064 + /* "dependency_injector/providers.pyx":3330 * return copied * * return self.__class__( # <<<<<<<<<<<<<< @@ -56446,10 +62849,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc * self.__item, */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3064, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3330, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - /* "dependency_injector/providers.pyx":3065 + /* "dependency_injector/providers.pyx":3331 * * return self.__class__( * deepcopy(self.__provider, memo), # <<<<<<<<<<<<<< @@ -56458,14 +62861,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc */ __pyx_t_3 = ((PyObject *)__pyx_v_self->__pyx___provider); __Pyx_INCREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3065, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3331, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3065, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3331, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":3066 + /* "dependency_injector/providers.pyx":3332 * return self.__class__( * deepcopy(self.__provider, memo), * self.__item, # <<<<<<<<<<<<<< @@ -56487,7 +62890,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_t_4, __pyx_v_self->__pyx___item}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3064, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3330, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -56496,14 +62899,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_t_4, __pyx_v_self->__pyx___item}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3064, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3330, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 3064, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 3330, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_3) { __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_3); __pyx_t_3 = NULL; @@ -56514,7 +62917,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc __Pyx_GIVEREF(__pyx_v_self->__pyx___item); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, __pyx_v_self->__pyx___item); __pyx_t_4 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3064, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3330, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } @@ -56523,7 +62926,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3057 + /* "dependency_injector/providers.pyx":3323 * return f'{self.__class__.__name__}(\'{self.__item}\')' * * def __deepcopy__(self, memo=None): # <<<<<<<<<<<<<< @@ -56547,7 +62950,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4__deepc return __pyx_r; } -/* "dependency_injector/providers.pyx":3069 +/* "dependency_injector/providers.pyx":3335 * ) * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -56578,7 +62981,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_6__getat int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getattr__", 0); - /* "dependency_injector/providers.pyx":3070 + /* "dependency_injector/providers.pyx":3336 * * def __getattr__(self, item): * return AttributeGetter(self, item) # <<<<<<<<<<<<<< @@ -56586,7 +62989,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_6__getat * def __getitem__(self, item): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3070, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3336, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); @@ -56594,14 +62997,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_6__getat __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_item); - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AttributeGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3070, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AttributeGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3336, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3069 + /* "dependency_injector/providers.pyx":3335 * ) * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -56621,7 +63024,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_6__getat return __pyx_r; } -/* "dependency_injector/providers.pyx":3072 +/* "dependency_injector/providers.pyx":3338 * return AttributeGetter(self, item) * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -56652,7 +63055,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_8__getit int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getitem__", 0); - /* "dependency_injector/providers.pyx":3073 + /* "dependency_injector/providers.pyx":3339 * * def __getitem__(self, item): * return ItemGetter(self, item) # <<<<<<<<<<<<<< @@ -56660,7 +63063,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_8__getit * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3073, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3339, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); @@ -56668,14 +63071,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_8__getit __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_item); - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ItemGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3073, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ItemGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3339, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3072 + /* "dependency_injector/providers.pyx":3338 * return AttributeGetter(self, item) * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -56695,7 +63098,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_8__getit return __pyx_r; } -/* "dependency_injector/providers.pyx":3076 +/* "dependency_injector/providers.pyx":3342 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -56721,7 +63124,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_8provide __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":3078 + /* "dependency_injector/providers.pyx":3344 * def provides(self): * """Return provider.""" * return self.__provider # <<<<<<<<<<<<<< @@ -56733,7 +63136,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_8provide __pyx_r = ((PyObject *)__pyx_v_self->__pyx___provider); goto __pyx_L0; - /* "dependency_injector/providers.pyx":3076 + /* "dependency_injector/providers.pyx":3342 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -56748,7 +63151,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_8provide return __pyx_r; } -/* "dependency_injector/providers.pyx":3081 +/* "dependency_injector/providers.pyx":3347 * * @property * def name(self): # <<<<<<<<<<<<<< @@ -56774,7 +63177,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4name___ __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":3083 + /* "dependency_injector/providers.pyx":3349 * def name(self): * """Return name of the item.""" * return self.__item # <<<<<<<<<<<<<< @@ -56786,7 +63189,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4name___ __pyx_r = __pyx_v_self->__pyx___item; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3081 + /* "dependency_injector/providers.pyx":3347 * * @property * def name(self): # <<<<<<<<<<<<<< @@ -56801,7 +63204,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_4name___ return __pyx_r; } -/* "dependency_injector/providers.pyx":3085 +/* "dependency_injector/providers.pyx":3351 * return self.__item * * def call(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -56845,7 +63248,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_10call(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("call", 0); - /* "dependency_injector/providers.pyx":3086 + /* "dependency_injector/providers.pyx":3352 * * def call(self, *args, **kwargs): * return MethodCaller(self, *args, **kwargs) # <<<<<<<<<<<<<< @@ -56853,22 +63256,22 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_10call(s * cpdef object _provide(self, tuple args, dict kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3086, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3352, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self)); - __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3086, __pyx_L1_error) + __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3352, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_MethodCaller), __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3086, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_MethodCaller), __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3352, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3085 + /* "dependency_injector/providers.pyx":3351 * return self.__item * * def call(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -56888,17 +63291,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_10call(s return __pyx_r; } -/* "dependency_injector/providers.pyx":3088 +/* "dependency_injector/providers.pyx":3354 * return MethodCaller(self, *args, **kwargs) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * provided = self.__provider(*args, **kwargs) - * return provided[self.__item] + * if __isawaitable(provided): */ static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_13_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_10ItemGetter__provide(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch) { PyObject *__pyx_v_provided = NULL; + PyObject *__pyx_v_future_result = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -56907,6 +63311,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers_10ItemGetter__provide( PyObject *__pyx_t_4 = NULL; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -56920,7 +63327,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_10ItemGetter__provide( if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3088, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3354, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_10ItemGetter_13_provide)) { __Pyx_XDECREF(__pyx_r); @@ -56940,7 +63347,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_10ItemGetter__provide( #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3088, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3354, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -56948,13 +63355,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_10ItemGetter__provide( #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3088, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3354, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3088, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3354, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -56965,7 +63372,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_10ItemGetter__provide( __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3088, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3354, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -56988,46 +63395,218 @@ static PyObject *__pyx_f_19dependency_injector_9providers_10ItemGetter__provide( #endif } - /* "dependency_injector/providers.pyx":3089 + /* "dependency_injector/providers.pyx":3355 * * cpdef object _provide(self, tuple args, dict kwargs): * provided = self.__provider(*args, **kwargs) # <<<<<<<<<<<<<< - * return provided[self.__item] - * + * if __isawaitable(provided): + * future_result = asyncio.Future() */ if (unlikely(__pyx_v_args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(1, 3089, __pyx_L1_error) + __PYX_ERR(1, 3355, __pyx_L1_error) } if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(1, 3089, __pyx_L1_error) + __PYX_ERR(1, 3355, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx___provider), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3089, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_self->__pyx___provider), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3355, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_provided = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3090 + /* "dependency_injector/providers.pyx":3356 * cpdef object _provide(self, tuple args, dict kwargs): * provided = self.__provider(*args, **kwargs) - * return provided[self.__item] # <<<<<<<<<<<<<< - * + * if __isawaitable(provided): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * provided = asyncio.ensure_future(provided) + */ + __pyx_t_7 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_provided) != 0); + if (__pyx_t_7) { + + /* "dependency_injector/providers.pyx":3357 + * provided = self.__provider(*args, **kwargs) + * if __isawaitable(provided): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * provided = asyncio.ensure_future(provided) + * provided.add_done_callback(functools.partial(self._async_provide, future_result)) + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3357, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_Future); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3357, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3357, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_future_result = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3358 + * if __isawaitable(provided): + * future_result = asyncio.Future() + * provided = asyncio.ensure_future(provided) # <<<<<<<<<<<<<< + * provided.add_done_callback(functools.partial(self._async_provide, future_result)) + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3358, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3358, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_provided) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_provided); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3358, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_provided, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3359 + * future_result = asyncio.Future() + * provided = asyncio.ensure_future(provided) + * provided.add_done_callback(functools.partial(self._async_provide, future_result)) # <<<<<<<<<<<<<< + * return future_result + * return provided[self.__item] + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_provided, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_functools); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_partial); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_async_provide); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_8 = NULL; + __pyx_t_5 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_8)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_8); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + __pyx_t_5 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_4)) { + PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_6, __pyx_v_future_result}; + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3359, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { + PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_6, __pyx_v_future_result}; + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3359, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + { + __pyx_t_9 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 3359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + if (__pyx_t_8) { + __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_8); __pyx_t_8 = NULL; + } + __Pyx_GIVEREF(__pyx_t_6); + PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_5, __pyx_t_6); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_5, __pyx_v_future_result); + __pyx_t_6 = 0; + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + } + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3360 + * provided = asyncio.ensure_future(provided) + * provided.add_done_callback(functools.partial(self._async_provide, future_result)) + * return future_result # <<<<<<<<<<<<<< + * return provided[self.__item] * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":3356 + * cpdef object _provide(self, tuple args, dict kwargs): + * provided = self.__provider(*args, **kwargs) + * if __isawaitable(provided): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * provided = asyncio.ensure_future(provided) + */ + } + + /* "dependency_injector/providers.pyx":3361 + * provided.add_done_callback(functools.partial(self._async_provide, future_result)) + * return future_result + * return provided[self.__item] # <<<<<<<<<<<<<< + * + * def _async_provide(self, future_result, future): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetItem(__pyx_v_provided, __pyx_v_self->__pyx___item); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3090, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetItem(__pyx_v_provided, __pyx_v_self->__pyx___item); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3361, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3088 + /* "dependency_injector/providers.pyx":3354 * return MethodCaller(self, *args, **kwargs) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * provided = self.__provider(*args, **kwargs) - * return provided[self.__item] + * if __isawaitable(provided): */ /* function exit code */ @@ -57037,10 +63616,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_10ItemGetter__provide( __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.ItemGetter._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_provided); + __Pyx_XDECREF(__pyx_v_future_result); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; @@ -57080,11 +63662,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_13_provi case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 3088, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 3354, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 3088, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 3354, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -57097,14 +63679,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_13_provi } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3088, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3354, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.ItemGetter._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3088, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3088, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3354, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3354, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_10ItemGetter_12_provide(((struct __pyx_obj_19dependency_injector_9providers_ItemGetter *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -57125,7 +63707,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_12_provi int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_10ItemGetter__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3088, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_10ItemGetter__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3354, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -57142,6 +63724,181 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_12_provi return __pyx_r; } +/* "dependency_injector/providers.pyx":3363 + * return provided[self.__item] + * + * def _async_provide(self, future_result, future): # <<<<<<<<<<<<<< + * provided = future.result() + * result = provided[self.__item] + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_15_async_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_15_async_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_future_result = 0; + PyObject *__pyx_v_future = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_async_provide (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_future_result,&__pyx_n_s_future,0}; + PyObject* values[2] = {0,0}; + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future_result)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + CYTHON_FALLTHROUGH; + case 1: + if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future)) != 0)) kw_args--; + else { + __Pyx_RaiseArgtupleInvalid("_async_provide", 1, 2, 2, 1); __PYX_ERR(1, 3363, __pyx_L3_error) + } + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_async_provide") < 0)) __PYX_ERR(1, 3363, __pyx_L3_error) + } + } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { + goto __pyx_L5_argtuple_error; + } else { + values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + } + __pyx_v_future_result = values[0]; + __pyx_v_future = values[1]; + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_async_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3363, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.ItemGetter._async_provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + __pyx_r = __pyx_pf_19dependency_injector_9providers_10ItemGetter_14_async_provide(((struct __pyx_obj_19dependency_injector_9providers_ItemGetter *)__pyx_v_self), __pyx_v_future_result, __pyx_v_future); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14_async_provide(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_future) { + PyObject *__pyx_v_provided = NULL; + PyObject *__pyx_v_result = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_async_provide", 0); + + /* "dependency_injector/providers.pyx":3364 + * + * def _async_provide(self, future_result, future): + * provided = future.result() # <<<<<<<<<<<<<< + * result = provided[self.__item] + * future_result.set_result(result) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3364, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3364, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_provided = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3365 + * def _async_provide(self, future_result, future): + * provided = future.result() + * result = provided[self.__item] # <<<<<<<<<<<<<< + * future_result.set_result(result) + * + */ + __pyx_t_1 = __Pyx_PyObject_GetItem(__pyx_v_provided, __pyx_v_self->__pyx___item); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3365, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_result = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3366 + * provided = future.result() + * result = provided[self.__item] + * future_result.set_result(result) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3366, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3366, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3363 + * return provided[self.__item] + * + * def _async_provide(self, future_result, future): # <<<<<<<<<<<<<< + * provided = future.result() + * result = provided[self.__item] + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_AddTraceback("dependency_injector.providers.ItemGetter._async_provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_provided); + __Pyx_XDECREF(__pyx_v_result); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + /* "(tree fragment)":1 * def __reduce_cython__(self): # <<<<<<<<<<<<<< * cdef tuple state @@ -57149,28 +63906,28 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_12_provi */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_15__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_15__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { +static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_17__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_17__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_10ItemGetter_14__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_ItemGetter *)__pyx_v_self)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_10ItemGetter_16__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_ItemGetter *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self) { +static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_16__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self) { PyObject *__pyx_v_state = 0; PyObject *__pyx_v__dict = 0; int __pyx_v_use_setstate; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; - int __pyx_t_2; + PyObject *__pyx_t_2 = NULL; int __pyx_t_3; - PyObject *__pyx_t_4 = NULL; + int __pyx_t_4; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_lineno = 0; @@ -57181,49 +63938,54 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__redu /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__item, self.__last_overriding, self.__overridden, self.__provider) # <<<<<<<<<<<<<< + * state = (self.__async_mode, self.__item, self.__last_overriding, self.__overridden, self.__provider) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(5); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(__pyx_v_self->__pyx___item); __Pyx_GIVEREF(__pyx_v_self->__pyx___item); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->__pyx___item); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->__pyx___item); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_2, 2, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx___provider)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx___provider)); - PyTuple_SET_ITEM(__pyx_t_1, 3, ((PyObject *)__pyx_v_self->__pyx___provider)); - __pyx_v_state = ((PyObject*)__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_2, 4, ((PyObject *)__pyx_v_self->__pyx___provider)); __pyx_t_1 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_2); + __pyx_t_2 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__item, self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__async_mode, self.__item, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_v__dict = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_v__dict = __pyx_t_2; + __pyx_t_2 = 0; /* "(tree fragment)":7 - * state = (self.__item, self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__async_mode, self.__item, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_2 = (__pyx_v__dict != Py_None); - __pyx_t_3 = (__pyx_t_2 != 0); - if (__pyx_t_3) { + __pyx_t_3 = (__pyx_v__dict != Py_None); + __pyx_t_4 = (__pyx_t_3 != 0); + if (__pyx_t_4) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -57232,16 +63994,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__redu * use_setstate = True * else: */ - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict); - __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4)); - __pyx_t_4 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict); + __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1)); + __pyx_t_1 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -57253,7 +64015,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__redu __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__item, self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__async_mode, self.__item, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -57267,35 +64029,35 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__redu * else: * use_setstate = self.__item is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_ItemGetter, (type(self), 0x5818eae, None), state + * return __pyx_unpickle_ItemGetter, (type(self), 0xa0575be, None), state */ /*else*/ { - __pyx_t_2 = (__pyx_v_self->__pyx___item != Py_None); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx___item != Py_None); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - if (!__pyx_t_2) { + __pyx_t_3 = (__pyx_t_5 != 0); + if (!__pyx_t_3) { } else { - __pyx_t_3 = __pyx_t_2; + __pyx_t_4 = __pyx_t_3; goto __pyx_L4_bool_binop_done; } - __pyx_t_2 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_5 = (__pyx_t_2 != 0); + __pyx_t_3 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_3 != 0); if (!__pyx_t_5) { } else { - __pyx_t_3 = __pyx_t_5; + __pyx_t_4 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx___provider) != Py_None); - __pyx_t_2 = (__pyx_t_5 != 0); - __pyx_t_3 = __pyx_t_2; + __pyx_t_3 = (__pyx_t_5 != 0); + __pyx_t_4 = __pyx_t_3; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_3; + __pyx_v_use_setstate = __pyx_t_4; } __pyx_L3:; @@ -57303,44 +64065,44 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__redu * else: * use_setstate = self.__item is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ItemGetter, (type(self), 0x5818eae, None), state + * return __pyx_unpickle_ItemGetter, (type(self), 0xa0575be, None), state * else: */ - __pyx_t_3 = (__pyx_v_use_setstate != 0); - if (__pyx_t_3) { + __pyx_t_4 = (__pyx_v_use_setstate != 0); + if (__pyx_t_4) { /* "(tree fragment)":13 * use_setstate = self.__item is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: - * return __pyx_unpickle_ItemGetter, (type(self), 0x5818eae, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_ItemGetter, (type(self), 0xa0575be, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_ItemGetter, (type(self), 0x5818eae, state) + * return __pyx_unpickle_ItemGetter, (type(self), 0xa0575be, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_ItemGetter); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_ItemGetter); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_92376750); - __Pyx_GIVEREF(__pyx_int_92376750); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_92376750); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_168129982); + __Pyx_GIVEREF(__pyx_int_168129982); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_168129982); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None); + PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __Pyx_GIVEREF(__pyx_t_4); - PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state); - __pyx_t_4 = 0; __pyx_t_1 = 0; + __pyx_t_2 = 0; __pyx_r = __pyx_t_6; __pyx_t_6 = 0; goto __pyx_L0; @@ -57349,15 +64111,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__redu * else: * use_setstate = self.__item is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_ItemGetter, (type(self), 0x5818eae, None), state + * return __pyx_unpickle_ItemGetter, (type(self), 0xa0575be, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_ItemGetter, (type(self), 0x5818eae, None), state + * return __pyx_unpickle_ItemGetter, (type(self), 0xa0575be, None), state * else: - * return __pyx_unpickle_ItemGetter, (type(self), 0x5818eae, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_ItemGetter, (type(self), 0xa0575be, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ItemGetter__set_state(self, __pyx_state) */ @@ -57365,27 +64127,27 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__redu __Pyx_XDECREF(__pyx_r); __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_pyx_unpickle_ItemGetter); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_92376750); - __Pyx_GIVEREF(__pyx_int_92376750); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_92376750); + PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_168129982); + __Pyx_GIVEREF(__pyx_int_168129982); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_168129982); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); - PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2); __pyx_t_6 = 0; + __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; __pyx_t_1 = 0; - __pyx_r = __pyx_t_4; - __pyx_t_4 = 0; goto __pyx_L0; } @@ -57398,7 +64160,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__redu /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.ItemGetter.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; @@ -57412,25 +64174,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_14__redu /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ItemGetter, (type(self), 0x5818eae, state) + * return __pyx_unpickle_ItemGetter, (type(self), 0xa0575be, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ItemGetter__set_state(self, __pyx_state) */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_17__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_17__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_19__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_10ItemGetter_19__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_10ItemGetter_16__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_ItemGetter *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_10ItemGetter_18__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_ItemGetter *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_16__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_18__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -57440,7 +64202,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_16__sets __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_ItemGetter, (type(self), 0x5818eae, state) + * return __pyx_unpickle_ItemGetter, (type(self), 0xa0575be, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_ItemGetter__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -57451,7 +64213,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_16__sets /* "(tree fragment)":16 * else: - * return __pyx_unpickle_ItemGetter, (type(self), 0x5818eae, state) + * return __pyx_unpickle_ItemGetter, (type(self), 0xa0575be, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_ItemGetter__set_state(self, __pyx_state) */ @@ -57469,7 +64231,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10ItemGetter_16__sets return __pyx_r; } -/* "dependency_injector/providers.pyx":3099 +/* "dependency_injector/providers.pyx":3375 * """ * * def __init__(self, provider, *args, **kwargs): # <<<<<<<<<<<<<< @@ -57522,7 +64284,7 @@ static int __pyx_pw_19dependency_injector_9providers_12MethodCaller_1__init__(Py } if (unlikely(kw_args > 0)) { const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1; - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 3099, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "__init__") < 0)) __PYX_ERR(1, 3375, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) < 1) { goto __pyx_L5_argtuple_error; @@ -57533,7 +64295,7 @@ static int __pyx_pw_19dependency_injector_9providers_12MethodCaller_1__init__(Py } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3099, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3375, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; @@ -57562,14 +64324,14 @@ static int __pyx_pf_19dependency_injector_9providers_12MethodCaller___init__(str int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":3100 + /* "dependency_injector/providers.pyx":3376 * * def __init__(self, provider, *args, **kwargs): * self.__provider = provider # <<<<<<<<<<<<<< * * self.__args = parse_positional_injections(args) */ - if (!(likely(((__pyx_v_provider) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 3100, __pyx_L1_error) + if (!(likely(((__pyx_v_provider) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_provider, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(1, 3376, __pyx_L1_error) __pyx_t_1 = __pyx_v_provider; __Pyx_INCREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); @@ -57578,14 +64340,14 @@ static int __pyx_pf_19dependency_injector_9providers_12MethodCaller___init__(str __pyx_v_self->__pyx___provider = ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3102 + /* "dependency_injector/providers.pyx":3378 * self.__provider = provider * * self.__args = parse_positional_injections(args) # <<<<<<<<<<<<<< * self.__args_len = len(self.__args) * */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3102, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3378, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___args); @@ -57593,7 +64355,7 @@ static int __pyx_pf_19dependency_injector_9providers_12MethodCaller___init__(str __pyx_v_self->__pyx___args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3103 + /* "dependency_injector/providers.pyx":3379 * * self.__args = parse_positional_injections(args) * self.__args_len = len(self.__args) # <<<<<<<<<<<<<< @@ -57604,20 +64366,20 @@ static int __pyx_pf_19dependency_injector_9providers_12MethodCaller___init__(str __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 3103, __pyx_L1_error) + __PYX_ERR(1, 3379, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 3103, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 3379, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___args_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":3105 + /* "dependency_injector/providers.pyx":3381 * self.__args_len = len(self.__args) * * self.__kwargs = parse_named_injections(kwargs) # <<<<<<<<<<<<<< * self.__kwargs_len = len(self.__kwargs) * */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3105, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3381, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->__pyx___kwargs); @@ -57625,7 +64387,7 @@ static int __pyx_pf_19dependency_injector_9providers_12MethodCaller___init__(str __pyx_v_self->__pyx___kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3106 + /* "dependency_injector/providers.pyx":3382 * * self.__kwargs = parse_named_injections(kwargs) * self.__kwargs_len = len(self.__kwargs) # <<<<<<<<<<<<<< @@ -57636,20 +64398,20 @@ static int __pyx_pf_19dependency_injector_9providers_12MethodCaller___init__(str __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 3106, __pyx_L1_error) + __PYX_ERR(1, 3382, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 3106, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 3382, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->__pyx___kwargs_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":3108 + /* "dependency_injector/providers.pyx":3384 * self.__kwargs_len = len(self.__kwargs) * * super().__init__() # <<<<<<<<<<<<<< * * def __repr__(self): */ - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3108, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3384, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_MethodCaller)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_MethodCaller)); @@ -57657,10 +64419,10 @@ static int __pyx_pf_19dependency_injector_9providers_12MethodCaller___init__(str __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_3, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3108, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3384, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3108, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_init); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3384, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; @@ -57675,12 +64437,12 @@ static int __pyx_pf_19dependency_injector_9providers_12MethodCaller___init__(str } __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3108, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3384, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3099 + /* "dependency_injector/providers.pyx":3375 * """ * * def __init__(self, provider, *args, **kwargs): # <<<<<<<<<<<<<< @@ -57702,7 +64464,7 @@ static int __pyx_pf_19dependency_injector_9providers_12MethodCaller___init__(str return __pyx_r; } -/* "dependency_injector/providers.pyx":3110 +/* "dependency_injector/providers.pyx":3386 * super().__init__() * * def __repr__(self): # <<<<<<<<<<<<<< @@ -57736,7 +64498,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_2__rep int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__repr__", 0); - /* "dependency_injector/providers.pyx":3111 + /* "dependency_injector/providers.pyx":3387 * * def __repr__(self): * return f'{self.__class__.__name__}({self.__provider})' # <<<<<<<<<<<<<< @@ -57744,16 +64506,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_2__rep * def __deepcopy__(self, memo=None): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3111, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3387, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = 0; __pyx_t_3 = 127; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3111, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3387, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3111, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3387, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_t_5, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3111, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_t_5, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3387, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_3 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) > __pyx_t_3) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) : __pyx_t_3; @@ -57761,29 +64523,29 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_2__rep __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_4); __pyx_t_4 = 0; - __Pyx_INCREF(__pyx_kp_u__8); + __Pyx_INCREF(__pyx_kp_u__9); __pyx_t_2 += 1; - __Pyx_GIVEREF(__pyx_kp_u__8); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_kp_u__8); - __pyx_t_4 = __Pyx_PyObject_FormatSimple(((PyObject *)__pyx_v_self->__pyx___provider), __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3111, __pyx_L1_error) + __Pyx_GIVEREF(__pyx_kp_u__9); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_kp_u__9); + __pyx_t_4 = __Pyx_PyObject_FormatSimple(((PyObject *)__pyx_v_self->__pyx___provider), __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3387, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_3 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) > __pyx_t_3) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_4) : __pyx_t_3; __pyx_t_2 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4); __pyx_t_4 = 0; - __Pyx_INCREF(__pyx_kp_u__9); + __Pyx_INCREF(__pyx_kp_u__10); __pyx_t_2 += 1; - __Pyx_GIVEREF(__pyx_kp_u__9); - PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_kp_u__9); - __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 4, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3111, __pyx_L1_error) + __Pyx_GIVEREF(__pyx_kp_u__10); + PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_kp_u__10); + __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 4, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3387, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_4; __pyx_t_4 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3110 + /* "dependency_injector/providers.pyx":3386 * super().__init__() * * def __repr__(self): # <<<<<<<<<<<<<< @@ -57804,7 +64566,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_2__rep return __pyx_r; } -/* "dependency_injector/providers.pyx":3113 +/* "dependency_injector/providers.pyx":3389 * return f'{self.__class__.__name__}({self.__provider})' * * def __deepcopy__(self, memo=None): # <<<<<<<<<<<<<< @@ -57844,7 +64606,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_5__dee } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__deepcopy__") < 0)) __PYX_ERR(1, 3113, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__deepcopy__") < 0)) __PYX_ERR(1, 3389, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -57858,7 +64620,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_5__dee } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__deepcopy__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3113, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__deepcopy__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3389, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.MethodCaller.__deepcopy__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -57888,16 +64650,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":3116 + /* "dependency_injector/providers.pyx":3392 * cdef MethodCaller copied * * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3116, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3392, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3116, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3392, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -57912,14 +64674,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3116, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3392, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_MethodCaller))))) __PYX_ERR(1, 3116, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_MethodCaller))))) __PYX_ERR(1, 3392, __pyx_L1_error) __pyx_v_copied = ((struct __pyx_obj_19dependency_injector_9providers_MethodCaller *)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3117 + /* "dependency_injector/providers.pyx":3393 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -57930,7 +64692,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":3118 + /* "dependency_injector/providers.pyx":3394 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -57942,7 +64704,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":3117 + /* "dependency_injector/providers.pyx":3393 * * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -57951,21 +64713,21 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee */ } - /* "dependency_injector/providers.pyx":3120 + /* "dependency_injector/providers.pyx":3396 * return copied * * copied = self.__class__(deepcopy(self.__provider, memo)) # <<<<<<<<<<<<<< * copied.__args = deepcopy(self.__args, memo) * copied.__args_len = self.__args_len */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3120, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3396, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = ((PyObject *)__pyx_v_self->__pyx___provider); __Pyx_INCREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3120, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3396, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3120, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3396, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -57981,14 +64743,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3120, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3396, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_MethodCaller))))) __PYX_ERR(1, 3120, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_MethodCaller))))) __PYX_ERR(1, 3396, __pyx_L1_error) __Pyx_DECREF_SET(__pyx_v_copied, ((struct __pyx_obj_19dependency_injector_9providers_MethodCaller *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3121 + /* "dependency_injector/providers.pyx":3397 * * copied = self.__class__(deepcopy(self.__provider, memo)) * copied.__args = deepcopy(self.__args, memo) # <<<<<<<<<<<<<< @@ -57997,20 +64759,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee */ __pyx_t_1 = __pyx_v_self->__pyx___args; __Pyx_INCREF(__pyx_t_1); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3121, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3397, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3121, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_1, 0, &__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3397, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (!(likely(PyTuple_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_2)->tp_name), 0))) __PYX_ERR(1, 3121, __pyx_L1_error) + if (!(likely(PyTuple_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_2)->tp_name), 0))) __PYX_ERR(1, 3397, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_2); __Pyx_GOTREF(__pyx_v_copied->__pyx___args); __Pyx_DECREF(__pyx_v_copied->__pyx___args); __pyx_v_copied->__pyx___args = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":3122 + /* "dependency_injector/providers.pyx":3398 * copied = self.__class__(deepcopy(self.__provider, memo)) * copied.__args = deepcopy(self.__args, memo) * copied.__args_len = self.__args_len # <<<<<<<<<<<<<< @@ -58020,7 +64782,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee __pyx_t_8 = __pyx_v_self->__pyx___args_len; __pyx_v_copied->__pyx___args_len = __pyx_t_8; - /* "dependency_injector/providers.pyx":3123 + /* "dependency_injector/providers.pyx":3399 * copied.__args = deepcopy(self.__args, memo) * copied.__args_len = self.__args_len * copied.__kwargs = deepcopy(self.__kwargs, memo) # <<<<<<<<<<<<<< @@ -58029,20 +64791,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee */ __pyx_t_2 = __pyx_v_self->__pyx___kwargs; __Pyx_INCREF(__pyx_t_2); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3123, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3399, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3123, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_2, 0, &__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3399, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 3123, __pyx_L1_error) + if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 3399, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_copied->__pyx___kwargs); __Pyx_DECREF(__pyx_v_copied->__pyx___kwargs); __pyx_v_copied->__pyx___kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3124 + /* "dependency_injector/providers.pyx":3400 * copied.__args_len = self.__args_len * copied.__kwargs = deepcopy(self.__kwargs, memo) * copied.__kwargs_len = self.__kwargs_len # <<<<<<<<<<<<<< @@ -58052,17 +64814,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee __pyx_t_8 = __pyx_v_self->__pyx___kwargs_len; __pyx_v_copied->__pyx___kwargs_len = __pyx_t_8; - /* "dependency_injector/providers.pyx":3126 + /* "dependency_injector/providers.pyx":3402 * copied.__kwargs_len = self.__kwargs_len * * self._copy_overridings(copied, memo) # <<<<<<<<<<<<<< * * return copied */ - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3126, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3402, __pyx_L1_error) ((struct __pyx_vtabstruct_19dependency_injector_9providers_MethodCaller *)__pyx_v_self->__pyx_base.__pyx_vtab)->__pyx_base._copy_overridings(((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_self), ((struct __pyx_obj_19dependency_injector_9providers_Provider *)__pyx_v_copied), ((PyObject*)__pyx_v_memo), 0); - /* "dependency_injector/providers.pyx":3128 + /* "dependency_injector/providers.pyx":3404 * self._copy_overridings(copied, memo) * * return copied # <<<<<<<<<<<<<< @@ -58074,7 +64836,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee __pyx_r = ((PyObject *)__pyx_v_copied); goto __pyx_L0; - /* "dependency_injector/providers.pyx":3113 + /* "dependency_injector/providers.pyx":3389 * return f'{self.__class__.__name__}({self.__provider})' * * def __deepcopy__(self, memo=None): # <<<<<<<<<<<<<< @@ -58097,7 +64859,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4__dee return __pyx_r; } -/* "dependency_injector/providers.pyx":3130 +/* "dependency_injector/providers.pyx":3406 * return copied * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -58128,7 +64890,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6__get int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getattr__", 0); - /* "dependency_injector/providers.pyx":3131 + /* "dependency_injector/providers.pyx":3407 * * def __getattr__(self, item): * return AttributeGetter(self, item) # <<<<<<<<<<<<<< @@ -58136,7 +64898,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6__get * def __getitem__(self, item): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3131, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3407, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); @@ -58144,14 +64906,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6__get __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_item); - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AttributeGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3131, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_AttributeGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3407, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3130 + /* "dependency_injector/providers.pyx":3406 * return copied * * def __getattr__(self, item): # <<<<<<<<<<<<<< @@ -58171,7 +64933,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6__get return __pyx_r; } -/* "dependency_injector/providers.pyx":3133 +/* "dependency_injector/providers.pyx":3409 * return AttributeGetter(self, item) * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -58202,7 +64964,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_8__get int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__getitem__", 0); - /* "dependency_injector/providers.pyx":3134 + /* "dependency_injector/providers.pyx":3410 * * def __getitem__(self, item): * return ItemGetter(self, item) # <<<<<<<<<<<<<< @@ -58210,7 +64972,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_8__get * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3134, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3410, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); @@ -58218,14 +64980,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_8__get __Pyx_INCREF(__pyx_v_item); __Pyx_GIVEREF(__pyx_v_item); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_item); - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ItemGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3134, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_ItemGetter), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3410, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3133 + /* "dependency_injector/providers.pyx":3409 * return AttributeGetter(self, item) * * def __getitem__(self, item): # <<<<<<<<<<<<<< @@ -58245,7 +65007,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_8__get return __pyx_r; } -/* "dependency_injector/providers.pyx":3137 +/* "dependency_injector/providers.pyx":3413 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -58271,7 +65033,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_8provi __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":3139 + /* "dependency_injector/providers.pyx":3415 * def provides(self): * """Return provider.""" * return self.__provider # <<<<<<<<<<<<<< @@ -58283,7 +65045,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_8provi __pyx_r = ((PyObject *)__pyx_v_self->__pyx___provider); goto __pyx_L0; - /* "dependency_injector/providers.pyx":3137 + /* "dependency_injector/providers.pyx":3413 * * @property * def provides(self): # <<<<<<<<<<<<<< @@ -58298,7 +65060,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_8provi return __pyx_r; } -/* "dependency_injector/providers.pyx":3142 +/* "dependency_injector/providers.pyx":3418 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -58335,19 +65097,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4args_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":3148 + /* "dependency_injector/providers.pyx":3424 * cdef list args * * args = list() # <<<<<<<<<<<<<< * for index in range(self.__args_len): * arg = self.__args[index] */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3148, __pyx_L1_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3424, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_args = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3149 + /* "dependency_injector/providers.pyx":3425 * * args = list() * for index in range(self.__args_len): # <<<<<<<<<<<<<< @@ -58359,7 +65121,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4args_ for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_index = __pyx_t_4; - /* "dependency_injector/providers.pyx":3150 + /* "dependency_injector/providers.pyx":3426 * args = list() * for index in range(self.__args_len): * arg = self.__args[index] # <<<<<<<<<<<<<< @@ -58368,15 +65130,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4args_ */ if (unlikely(__pyx_v_self->__pyx___args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 3150, __pyx_L1_error) + __PYX_ERR(1, 3426, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___args, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3150, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___args, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3426, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_PositionalInjection))))) __PYX_ERR(1, 3150, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_PositionalInjection))))) __PYX_ERR(1, 3426, __pyx_L1_error) __Pyx_XDECREF_SET(__pyx_v_arg, ((struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3151 + /* "dependency_injector/providers.pyx":3427 * for index in range(self.__args_len): * arg = self.__args[index] * args.append(arg.__value) # <<<<<<<<<<<<<< @@ -58385,11 +65147,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4args_ */ __pyx_t_1 = __pyx_v_arg->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_1); - __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_args, __pyx_t_1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 3151, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_args, __pyx_t_1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 3427, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - /* "dependency_injector/providers.pyx":3152 + /* "dependency_injector/providers.pyx":3428 * arg = self.__args[index] * args.append(arg.__value) * return tuple(args) # <<<<<<<<<<<<<< @@ -58397,13 +65159,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4args_ * @property */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyList_AsTuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3152, __pyx_L1_error) + __pyx_t_1 = PyList_AsTuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3428, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3142 + /* "dependency_injector/providers.pyx":3418 * * @property * def args(self): # <<<<<<<<<<<<<< @@ -58424,7 +65186,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_4args_ return __pyx_r; } -/* "dependency_injector/providers.pyx":3155 +/* "dependency_injector/providers.pyx":3431 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -58460,19 +65222,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6kwarg int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "dependency_injector/providers.pyx":3161 + /* "dependency_injector/providers.pyx":3437 * cdef dict kwargs * * kwargs = dict() # <<<<<<<<<<<<<< * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3161, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3437, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3162 + /* "dependency_injector/providers.pyx":3438 * * kwargs = dict() * for index in range(self.__kwargs_len): # <<<<<<<<<<<<<< @@ -58484,7 +65246,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6kwarg for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_index = __pyx_t_4; - /* "dependency_injector/providers.pyx":3163 + /* "dependency_injector/providers.pyx":3439 * kwargs = dict() * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] # <<<<<<<<<<<<<< @@ -58493,15 +65255,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6kwarg */ if (unlikely(__pyx_v_self->__pyx___kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 3163, __pyx_L1_error) + __PYX_ERR(1, 3439, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___kwargs, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3163, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v_self->__pyx___kwargs, __pyx_v_index, int, 1, __Pyx_PyInt_From_int, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3439, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_NamedInjection))))) __PYX_ERR(1, 3163, __pyx_L1_error) + if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_NamedInjection))))) __PYX_ERR(1, 3439, __pyx_L1_error) __Pyx_XDECREF_SET(__pyx_v_kwarg, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3164 + /* "dependency_injector/providers.pyx":3440 * for index in range(self.__kwargs_len): * kwarg = self.__kwargs[index] * kwargs[kwarg.__name] = kwarg.__value # <<<<<<<<<<<<<< @@ -58510,11 +65272,11 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6kwarg */ __pyx_t_1 = __pyx_v_kwarg->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_1); - if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_kwarg->__pyx___name, __pyx_t_1) < 0)) __PYX_ERR(1, 3164, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_kwarg->__pyx___name, __pyx_t_1) < 0)) __PYX_ERR(1, 3440, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } - /* "dependency_injector/providers.pyx":3165 + /* "dependency_injector/providers.pyx":3441 * kwarg = self.__kwargs[index] * kwargs[kwarg.__name] = kwarg.__value * return kwargs # <<<<<<<<<<<<<< @@ -58526,7 +65288,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6kwarg __pyx_r = __pyx_v_kwargs; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3155 + /* "dependency_injector/providers.pyx":3431 * * @property * def kwargs(self): # <<<<<<<<<<<<<< @@ -58547,7 +65309,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_6kwarg return __pyx_r; } -/* "dependency_injector/providers.pyx":3167 +/* "dependency_injector/providers.pyx":3443 * return kwargs * * def call(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -58591,7 +65353,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_10call int __pyx_clineno = 0; __Pyx_RefNannySetupContext("call", 0); - /* "dependency_injector/providers.pyx":3168 + /* "dependency_injector/providers.pyx":3444 * * def call(self, *args, **kwargs): * return MethodCaller(self, *args, **kwargs) # <<<<<<<<<<<<<< @@ -58599,22 +65361,22 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_10call * cpdef object _provide(self, tuple args, dict kwargs): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3168, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3444, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self)); - __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3168, __pyx_L1_error) + __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_v_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3444, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_MethodCaller), __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3168, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_MethodCaller), __pyx_t_2, __pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3444, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3167 + /* "dependency_injector/providers.pyx":3443 * return kwargs * * def call(self, *args, **kwargs): # <<<<<<<<<<<<<< @@ -58634,17 +65396,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_10call return __pyx_r; } -/* "dependency_injector/providers.pyx":3170 +/* "dependency_injector/providers.pyx":3446 * return MethodCaller(self, *args, **kwargs) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * call = self.__provider() - * return __call( + * if __isawaitable(call): */ static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_13_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provide(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, int __pyx_skip_dispatch) { PyObject *__pyx_v_call = NULL; + PyObject *__pyx_v_future_result = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -58653,6 +65416,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid PyObject *__pyx_t_4 = NULL; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -58666,7 +65432,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid if (unlikely(!__Pyx_object_dict_version_matches(((PyObject *)__pyx_v_self), __pyx_tp_dict_version, __pyx_obj_dict_version))) { PY_UINT64_T __pyx_type_dict_guard = __Pyx_get_tp_dict_version(((PyObject *)__pyx_v_self)); #endif - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3170, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_provide); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)(void*)__pyx_pw_19dependency_injector_9providers_12MethodCaller_13_provide)) { __Pyx_XDECREF(__pyx_r); @@ -58686,7 +65452,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3170, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3446, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else @@ -58694,13 +65460,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_args, __pyx_v_kwargs}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3170, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3446, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3170, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -58711,7 +65477,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid __Pyx_INCREF(__pyx_v_kwargs); __Pyx_GIVEREF(__pyx_v_kwargs); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_v_kwargs); - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3170, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -58734,12 +65500,12 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid #endif } - /* "dependency_injector/providers.pyx":3171 + /* "dependency_injector/providers.pyx":3447 * * cpdef object _provide(self, tuple args, dict kwargs): * call = self.__provider() # <<<<<<<<<<<<<< - * return __call( - * call, + * if __isawaitable(call): + * future_result = asyncio.Future() */ __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx___provider)); __pyx_t_2 = ((PyObject *)__pyx_v_self->__pyx___provider); __pyx_t_3 = NULL; @@ -58754,22 +65520,200 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3171, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3447, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_call = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3172 + /* "dependency_injector/providers.pyx":3448 * cpdef object _provide(self, tuple args, dict kwargs): * call = self.__provider() + * if __isawaitable(call): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * call = asyncio.ensure_future(call) + */ + __pyx_t_7 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_call) != 0); + if (__pyx_t_7) { + + /* "dependency_injector/providers.pyx":3449 + * call = self.__provider() + * if __isawaitable(call): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * call = asyncio.ensure_future(call) + * call.add_done_callback(functools.partial(self._async_provide, future_result, args, kwargs)) + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3449, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_Future); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3449, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3449, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_future_result = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3450 + * if __isawaitable(call): + * future_result = asyncio.Future() + * call = asyncio.ensure_future(call) # <<<<<<<<<<<<<< + * call.add_done_callback(functools.partial(self._async_provide, future_result, args, kwargs)) + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3450, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3450, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_call) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_call); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3450, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF_SET(__pyx_v_call, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3451 + * future_result = asyncio.Future() + * call = asyncio.ensure_future(call) + * call.add_done_callback(functools.partial(self._async_provide, future_result, args, kwargs)) # <<<<<<<<<<<<<< + * return future_result + * return __call( + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_call, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3451, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_functools); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3451, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_partial); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3451, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_async_provide); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3451, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_8 = NULL; + __pyx_t_5 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_8)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_8); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + __pyx_t_5 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_4)) { + PyObject *__pyx_temp[5] = {__pyx_t_8, __pyx_t_6, __pyx_v_future_result, __pyx_v_args, __pyx_v_kwargs}; + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_5, 4+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3451, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { + PyObject *__pyx_temp[5] = {__pyx_t_8, __pyx_t_6, __pyx_v_future_result, __pyx_v_args, __pyx_v_kwargs}; + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_5, 4+__pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3451, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else + #endif + { + __pyx_t_9 = PyTuple_New(4+__pyx_t_5); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 3451, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + if (__pyx_t_8) { + __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_8); __pyx_t_8 = NULL; + } + __Pyx_GIVEREF(__pyx_t_6); + PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_5, __pyx_t_6); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_5, __pyx_v_future_result); + __Pyx_INCREF(__pyx_v_args); + __Pyx_GIVEREF(__pyx_v_args); + PyTuple_SET_ITEM(__pyx_t_9, 2+__pyx_t_5, __pyx_v_args); + __Pyx_INCREF(__pyx_v_kwargs); + __Pyx_GIVEREF(__pyx_v_kwargs); + PyTuple_SET_ITEM(__pyx_t_9, 3+__pyx_t_5, __pyx_v_kwargs); + __pyx_t_6 = 0; + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3451, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + } + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3451, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3452 + * call = asyncio.ensure_future(call) + * call.add_done_callback(functools.partial(self._async_provide, future_result, args, kwargs)) + * return future_result # <<<<<<<<<<<<<< + * return __call( + * call, + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pyx":3448 + * cpdef object _provide(self, tuple args, dict kwargs): + * call = self.__provider() + * if __isawaitable(call): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * call = asyncio.ensure_future(call) + */ + } + + /* "dependency_injector/providers.pyx":3453 + * call.add_done_callback(functools.partial(self._async_provide, future_result, args, kwargs)) + * return future_result * return __call( # <<<<<<<<<<<<<< * call, * args, */ __Pyx_XDECREF(__pyx_r); - /* "dependency_injector/providers.pyx":3175 + /* "dependency_injector/providers.pyx":3456 * call, * args, * self.__args, # <<<<<<<<<<<<<< @@ -58779,7 +65723,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid __pyx_t_1 = __pyx_v_self->__pyx___args; __Pyx_INCREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":3178 + /* "dependency_injector/providers.pyx":3459 * self.__args_len, * kwargs, * self.__kwargs, # <<<<<<<<<<<<<< @@ -58789,14 +65733,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid __pyx_t_2 = __pyx_v_self->__pyx___kwargs; __Pyx_INCREF(__pyx_t_2); - /* "dependency_injector/providers.pyx":3172 - * cpdef object _provide(self, tuple args, dict kwargs): - * call = self.__provider() + /* "dependency_injector/providers.pyx":3453 + * call.add_done_callback(functools.partial(self._async_provide, future_result, args, kwargs)) + * return future_result * return __call( # <<<<<<<<<<<<<< * call, * args, */ - __pyx_t_3 = __pyx_f_19dependency_injector_9providers___call(__pyx_v_call, __pyx_v_args, ((PyObject*)__pyx_t_1), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3172, __pyx_L1_error) + __pyx_t_3 = __pyx_f_19dependency_injector_9providers___call(__pyx_v_call, __pyx_v_args, ((PyObject*)__pyx_t_1), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3453, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -58804,12 +65748,12 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3170 + /* "dependency_injector/providers.pyx":3446 * return MethodCaller(self, *args, **kwargs) * * cpdef object _provide(self, tuple args, dict kwargs): # <<<<<<<<<<<<<< * call = self.__provider() - * return __call( + * if __isawaitable(call): */ /* function exit code */ @@ -58819,10 +65763,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_12MethodCaller__provid __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.MethodCaller._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_call); + __Pyx_XDECREF(__pyx_v_future_result); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; @@ -58862,11 +65809,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_13_pro case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 3170, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, 1); __PYX_ERR(1, 3446, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 3170, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_provide") < 0)) __PYX_ERR(1, 3446, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -58879,14 +65826,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_13_pro } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3170, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("_provide", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3446, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.MethodCaller._provide", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3170, __pyx_L1_error) - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3170, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3446, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3446, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_12MethodCaller_12_provide(((struct __pyx_obj_19dependency_injector_9providers_MethodCaller *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs); /* function exit code */ @@ -58907,7 +65854,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_12_pro int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_provide", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_12MethodCaller__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3170, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_12MethodCaller__provide(__pyx_v_self, __pyx_v_args, __pyx_v_kwargs, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -58924,6 +65871,243 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_12_pro return __pyx_r; } +/* "dependency_injector/providers.pyx":3463 + * ) + * + * def _async_provide(self, future_result, args, kwargs, future): # <<<<<<<<<<<<<< + * call = future.result() + * result = __call( + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_15_async_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_15_async_provide(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { + PyObject *__pyx_v_future_result = 0; + PyObject *__pyx_v_args = 0; + PyObject *__pyx_v_kwargs = 0; + PyObject *__pyx_v_future = 0; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("_async_provide (wrapper)", 0); + { + static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_future_result,&__pyx_n_s_args,&__pyx_n_s_kwargs,&__pyx_n_s_future,0}; + PyObject* values[4] = {0,0,0,0}; + if (unlikely(__pyx_kwds)) { + Py_ssize_t kw_args; + const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); + switch (pos_args) { + case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); + CYTHON_FALLTHROUGH; + case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); + CYTHON_FALLTHROUGH; + case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + CYTHON_FALLTHROUGH; + case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + CYTHON_FALLTHROUGH; + case 0: break; + default: goto __pyx_L5_argtuple_error; + } + kw_args = PyDict_Size(__pyx_kwds); + switch (pos_args) { + case 0: + if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future_result)) != 0)) kw_args--; + else goto __pyx_L5_argtuple_error; + CYTHON_FALLTHROUGH; + case 1: + if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_args)) != 0)) kw_args--; + else { + __Pyx_RaiseArgtupleInvalid("_async_provide", 1, 4, 4, 1); __PYX_ERR(1, 3463, __pyx_L3_error) + } + CYTHON_FALLTHROUGH; + case 2: + if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_kwargs)) != 0)) kw_args--; + else { + __Pyx_RaiseArgtupleInvalid("_async_provide", 1, 4, 4, 2); __PYX_ERR(1, 3463, __pyx_L3_error) + } + CYTHON_FALLTHROUGH; + case 3: + if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_future)) != 0)) kw_args--; + else { + __Pyx_RaiseArgtupleInvalid("_async_provide", 1, 4, 4, 3); __PYX_ERR(1, 3463, __pyx_L3_error) + } + } + if (unlikely(kw_args > 0)) { + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_async_provide") < 0)) __PYX_ERR(1, 3463, __pyx_L3_error) + } + } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { + goto __pyx_L5_argtuple_error; + } else { + values[0] = PyTuple_GET_ITEM(__pyx_args, 0); + values[1] = PyTuple_GET_ITEM(__pyx_args, 1); + values[2] = PyTuple_GET_ITEM(__pyx_args, 2); + values[3] = PyTuple_GET_ITEM(__pyx_args, 3); + } + __pyx_v_future_result = values[0]; + __pyx_v_args = values[1]; + __pyx_v_kwargs = values[2]; + __pyx_v_future = values[3]; + } + goto __pyx_L4_argument_unpacking_done; + __pyx_L5_argtuple_error:; + __Pyx_RaiseArgtupleInvalid("_async_provide", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3463, __pyx_L3_error) + __pyx_L3_error:; + __Pyx_AddTraceback("dependency_injector.providers.MethodCaller._async_provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_RefNannyFinishContext(); + return NULL; + __pyx_L4_argument_unpacking_done:; + __pyx_r = __pyx_pf_19dependency_injector_9providers_12MethodCaller_14_async_provide(((struct __pyx_obj_19dependency_injector_9providers_MethodCaller *)__pyx_v_self), __pyx_v_future_result, __pyx_v_args, __pyx_v_kwargs, __pyx_v_future); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14_async_provide(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v_future_result, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, PyObject *__pyx_v_future) { + PyObject *__pyx_v_call = NULL; + PyObject *__pyx_v_result = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("_async_provide", 0); + + /* "dependency_injector/providers.pyx":3464 + * + * def _async_provide(self, future_result, args, kwargs, future): + * call = future.result() # <<<<<<<<<<<<<< + * result = __call( + * call, + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_call = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3467 + * result = __call( + * call, + * args, # <<<<<<<<<<<<<< + * self.__args, + * self.__args_len, + */ + if (!(likely(PyTuple_CheckExact(__pyx_v_args))||((__pyx_v_args) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v_args)->tp_name), 0))) __PYX_ERR(1, 3467, __pyx_L1_error) + + /* "dependency_injector/providers.pyx":3468 + * call, + * args, + * self.__args, # <<<<<<<<<<<<<< + * self.__args_len, + * kwargs, + */ + __pyx_t_1 = __pyx_v_self->__pyx___args; + __Pyx_INCREF(__pyx_t_1); + + /* "dependency_injector/providers.pyx":3470 + * self.__args, + * self.__args_len, + * kwargs, # <<<<<<<<<<<<<< + * self.__kwargs, + * self.__kwargs_len, + */ + if (!(likely(PyDict_CheckExact(__pyx_v_kwargs))||((__pyx_v_kwargs) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_kwargs)->tp_name), 0))) __PYX_ERR(1, 3470, __pyx_L1_error) + + /* "dependency_injector/providers.pyx":3471 + * self.__args_len, + * kwargs, + * self.__kwargs, # <<<<<<<<<<<<<< + * self.__kwargs_len, + * ) + */ + __pyx_t_2 = __pyx_v_self->__pyx___kwargs; + __Pyx_INCREF(__pyx_t_2); + + /* "dependency_injector/providers.pyx":3465 + * def _async_provide(self, future_result, args, kwargs, future): + * call = future.result() + * result = __call( # <<<<<<<<<<<<<< + * call, + * args, + */ + __pyx_t_3 = __pyx_f_19dependency_injector_9providers___call(__pyx_v_call, ((PyObject*)__pyx_v_args), ((PyObject*)__pyx_t_1), __pyx_v_self->__pyx___args_len, ((PyObject*)__pyx_v_kwargs), ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3465, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_result = __pyx_t_3; + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":3474 + * self.__kwargs_len, + * ) + * future_result.set_result(result) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3474, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_1 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_1 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_1)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_1); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_3 = (__pyx_t_1) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_1, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3474, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pyx":3463 + * ) + * + * def _async_provide(self, future_result, args, kwargs, future): # <<<<<<<<<<<<<< + * call = future.result() + * result = __call( + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_AddTraceback("dependency_injector.providers.MethodCaller._async_provide", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_call); + __Pyx_XDECREF(__pyx_v_result); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + /* "(tree fragment)":1 * def __reduce_cython__(self): # <<<<<<<<<<<<<< * cdef tuple state @@ -58931,19 +66115,19 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_12_pro */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_15__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_15__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { +static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_17__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_17__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_12MethodCaller_14__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_MethodCaller *)__pyx_v_self)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_12MethodCaller_16__reduce_cython__(((struct __pyx_obj_19dependency_injector_9providers_MethodCaller *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self) { +static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_16__reduce_cython__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self) { PyObject *__pyx_v_state = 0; PyObject *__pyx_v__dict = 0; int __pyx_v_use_setstate; @@ -58952,9 +66136,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14__re PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; - int __pyx_t_4; + PyObject *__pyx_t_4 = NULL; int __pyx_t_5; int __pyx_t_6; + int __pyx_t_7; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -58963,62 +66148,67 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14__re /* "(tree fragment)":5 * cdef object _dict * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provider) # <<<<<<<<<<<<<< + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provider) # <<<<<<<<<<<<<< * _dict = getattr(self, '__dict__', None) * if _dict is not None: */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx_base.__pyx___async_mode); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(7); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(8); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 5, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v_self->__pyx___args); __Pyx_GIVEREF(__pyx_v_self->__pyx___args); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->__pyx___args); + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->__pyx___args); __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2); __Pyx_INCREF(__pyx_v_self->__pyx___kwargs); __Pyx_GIVEREF(__pyx_v_self->__pyx___kwargs); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_self->__pyx___kwargs); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_3, 3, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_v_self->__pyx___kwargs); + __Pyx_GIVEREF(__pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_4, 4, __pyx_t_3); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); - PyTuple_SET_ITEM(__pyx_t_3, 4, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); + PyTuple_SET_ITEM(__pyx_t_4, 5, ((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding)); __Pyx_INCREF(__pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_GIVEREF(__pyx_v_self->__pyx_base.__pyx___overridden); - PyTuple_SET_ITEM(__pyx_t_3, 5, __pyx_v_self->__pyx_base.__pyx___overridden); + PyTuple_SET_ITEM(__pyx_t_4, 6, __pyx_v_self->__pyx_base.__pyx___overridden); __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx___provider)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self->__pyx___provider)); - PyTuple_SET_ITEM(__pyx_t_3, 6, ((PyObject *)__pyx_v_self->__pyx___provider)); + PyTuple_SET_ITEM(__pyx_t_4, 7, ((PyObject *)__pyx_v_self->__pyx___provider)); __pyx_t_1 = 0; __pyx_t_2 = 0; - __pyx_v_state = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_state = ((PyObject*)__pyx_t_4); + __pyx_t_4 = 0; /* "(tree fragment)":6 * cdef bint use_setstate - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<< * if _dict is not None: * state += (_dict,) */ - __pyx_t_3 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 6, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); - __pyx_v__dict = __pyx_t_3; - __pyx_t_3 = 0; + __pyx_t_4 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_v__dict = __pyx_t_4; + __pyx_t_4 = 0; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) * use_setstate = True */ - __pyx_t_4 = (__pyx_v__dict != Py_None); - __pyx_t_5 = (__pyx_t_4 != 0); - if (__pyx_t_5) { + __pyx_t_5 = (__pyx_v__dict != Py_None); + __pyx_t_6 = (__pyx_t_5 != 0); + if (__pyx_t_6) { /* "(tree fragment)":8 * _dict = getattr(self, '__dict__', None) @@ -59027,16 +66217,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14__re * use_setstate = True * else: */ - __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_v__dict); __Pyx_GIVEREF(__pyx_v__dict); - PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__dict); - __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 8, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_2)); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__dict); + __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 8, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3)); + __pyx_t_3 = 0; /* "(tree fragment)":9 * if _dict is not None: @@ -59048,7 +66238,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14__re __pyx_v_use_setstate = 1; /* "(tree fragment)":7 - * state = (self.__args, self.__args_len, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provider) + * state = (self.__args, self.__args_len, self.__async_mode, self.__kwargs, self.__kwargs_len, self.__last_overriding, self.__overridden, self.__provider) * _dict = getattr(self, '__dict__', None) * if _dict is not None: # <<<<<<<<<<<<<< * state += (_dict,) @@ -59062,42 +66252,42 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14__re * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None # <<<<<<<<<<<<<< * if use_setstate: - * return __pyx_unpickle_MethodCaller, (type(self), 0x2026b20, None), state + * return __pyx_unpickle_MethodCaller, (type(self), 0xe57552f, None), state */ /*else*/ { - __pyx_t_4 = (__pyx_v_self->__pyx___args != ((PyObject*)Py_None)); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (__pyx_v_self->__pyx___args != ((PyObject*)Py_None)); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx___kwargs != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx___kwargs != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - if (!__pyx_t_6) { + __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx___last_overriding) != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + if (!__pyx_t_7) { } else { - __pyx_t_5 = __pyx_t_6; + __pyx_t_6 = __pyx_t_7; goto __pyx_L4_bool_binop_done; } - __pyx_t_6 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); - __pyx_t_4 = (__pyx_t_6 != 0); - if (!__pyx_t_4) { + __pyx_t_7 = (__pyx_v_self->__pyx_base.__pyx___overridden != ((PyObject*)Py_None)); + __pyx_t_5 = (__pyx_t_7 != 0); + if (!__pyx_t_5) { } else { - __pyx_t_5 = __pyx_t_4; + __pyx_t_6 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = (((PyObject *)__pyx_v_self->__pyx___provider) != Py_None); - __pyx_t_6 = (__pyx_t_4 != 0); - __pyx_t_5 = __pyx_t_6; + __pyx_t_5 = (((PyObject *)__pyx_v_self->__pyx___provider) != Py_None); + __pyx_t_7 = (__pyx_t_5 != 0); + __pyx_t_6 = __pyx_t_7; __pyx_L4_bool_binop_done:; - __pyx_v_use_setstate = __pyx_t_5; + __pyx_v_use_setstate = __pyx_t_6; } __pyx_L3:; @@ -59105,89 +66295,89 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14__re * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_MethodCaller, (type(self), 0x2026b20, None), state + * return __pyx_unpickle_MethodCaller, (type(self), 0xe57552f, None), state * else: */ - __pyx_t_5 = (__pyx_v_use_setstate != 0); - if (__pyx_t_5) { + __pyx_t_6 = (__pyx_v_use_setstate != 0); + if (__pyx_t_6) { /* "(tree fragment)":13 * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: - * return __pyx_unpickle_MethodCaller, (type(self), 0x2026b20, None), state # <<<<<<<<<<<<<< + * return __pyx_unpickle_MethodCaller, (type(self), 0xe57552f, None), state # <<<<<<<<<<<<<< * else: - * return __pyx_unpickle_MethodCaller, (type(self), 0x2026b20, state) + * return __pyx_unpickle_MethodCaller, (type(self), 0xe57552f, state) */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_MethodCaller); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_MethodCaller); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_33712928); - __Pyx_GIVEREF(__pyx_int_33712928); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_33712928); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_240604463); + __Pyx_GIVEREF(__pyx_int_240604463); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_240604463); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); - PyTuple_SET_ITEM(__pyx_t_3, 2, Py_None); - __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __Pyx_GIVEREF(__pyx_t_2); - PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_4, 2, Py_None); + __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 13, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3); + PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state); - __pyx_t_2 = 0; + PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state); __pyx_t_3 = 0; - __pyx_r = __pyx_t_1; - __pyx_t_1 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_2; + __pyx_t_2 = 0; goto __pyx_L0; /* "(tree fragment)":12 * else: * use_setstate = self.__args is not None or self.__kwargs is not None or self.__last_overriding is not None or self.__overridden is not None or self.__provider is not None * if use_setstate: # <<<<<<<<<<<<<< - * return __pyx_unpickle_MethodCaller, (type(self), 0x2026b20, None), state + * return __pyx_unpickle_MethodCaller, (type(self), 0xe57552f, None), state * else: */ } /* "(tree fragment)":15 - * return __pyx_unpickle_MethodCaller, (type(self), 0x2026b20, None), state + * return __pyx_unpickle_MethodCaller, (type(self), 0xe57552f, None), state * else: - * return __pyx_unpickle_MethodCaller, (type(self), 0x2026b20, state) # <<<<<<<<<<<<<< + * return __pyx_unpickle_MethodCaller, (type(self), 0xe57552f, state) # <<<<<<<<<<<<<< * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_MethodCaller__set_state(self, __pyx_state) */ /*else*/ { __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_pyx_unpickle_MethodCaller); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_3); + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_MethodCaller); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); - __Pyx_INCREF(__pyx_int_33712928); - __Pyx_GIVEREF(__pyx_int_33712928); - PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_33712928); + PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self)))); + __Pyx_INCREF(__pyx_int_240604463); + __Pyx_GIVEREF(__pyx_int_240604463); + PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_240604463); __Pyx_INCREF(__pyx_v_state); __Pyx_GIVEREF(__pyx_v_state); - PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_state); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 15, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __Pyx_GIVEREF(__pyx_t_1); - PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); - __Pyx_GIVEREF(__pyx_t_3); - PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3); - __pyx_t_1 = 0; - __pyx_t_3 = 0; - __pyx_r = __pyx_t_2; + PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state); + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 15, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_GIVEREF(__pyx_t_2); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); + __Pyx_GIVEREF(__pyx_t_4); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; + __pyx_t_4 = 0; + __pyx_r = __pyx_t_3; + __pyx_t_3 = 0; goto __pyx_L0; } @@ -59202,6 +66392,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14__re __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("dependency_injector.providers.MethodCaller.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; @@ -59214,25 +66405,25 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_14__re /* "(tree fragment)":16 * else: - * return __pyx_unpickle_MethodCaller, (type(self), 0x2026b20, state) + * return __pyx_unpickle_MethodCaller, (type(self), 0xe57552f, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_MethodCaller__set_state(self, __pyx_state) */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_17__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ -static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_17__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_19__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/ +static PyObject *__pyx_pw_19dependency_injector_9providers_12MethodCaller_19__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0); - __pyx_r = __pyx_pf_19dependency_injector_9providers_12MethodCaller_16__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_MethodCaller *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); + __pyx_r = __pyx_pf_19dependency_injector_9providers_12MethodCaller_18__setstate_cython__(((struct __pyx_obj_19dependency_injector_9providers_MethodCaller *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_16__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_18__setstate_cython__(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v_self, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; @@ -59242,7 +66433,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_16__se __Pyx_RefNannySetupContext("__setstate_cython__", 0); /* "(tree fragment)":17 - * return __pyx_unpickle_MethodCaller, (type(self), 0x2026b20, state) + * return __pyx_unpickle_MethodCaller, (type(self), 0xe57552f, state) * def __setstate_cython__(self, __pyx_state): * __pyx_unpickle_MethodCaller__set_state(self, __pyx_state) # <<<<<<<<<<<<<< */ @@ -59253,7 +66444,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12MethodCaller_16__se /* "(tree fragment)":16 * else: - * return __pyx_unpickle_MethodCaller, (type(self), 0x2026b20, state) + * return __pyx_unpickle_MethodCaller, (type(self), 0xe57552f, state) * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<< * __pyx_unpickle_MethodCaller__set_state(self, __pyx_state) */ @@ -59581,7 +66772,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_9Injection_2__setstat return __pyx_r; } -/* "dependency_injector/providers.pyx":3190 +/* "dependency_injector/providers.pyx":3484 * """Positional injection class.""" * * def __init__(self, value): # <<<<<<<<<<<<<< @@ -59622,7 +66813,7 @@ static int __pyx_pw_19dependency_injector_9providers_19PositionalInjection_1__in else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 3190, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 3484, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -59633,7 +66824,7 @@ static int __pyx_pw_19dependency_injector_9providers_19PositionalInjection_1__in } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3190, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3484, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.PositionalInjection.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -59659,7 +66850,7 @@ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___ini int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":3192 + /* "dependency_injector/providers.pyx":3486 * def __init__(self, value): * """Initializer.""" * self.__value = value # <<<<<<<<<<<<<< @@ -59672,7 +66863,7 @@ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___ini __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___value); __pyx_v_self->__pyx_base.__pyx___value = __pyx_v_value; - /* "dependency_injector/providers.pyx":3193 + /* "dependency_injector/providers.pyx":3487 * """Initializer.""" * self.__value = value * self.__is_provider = is_provider(value) # <<<<<<<<<<<<<< @@ -59681,7 +66872,7 @@ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___ini */ __pyx_v_self->__pyx_base.__pyx___is_provider = ((int)__pyx_f_19dependency_injector_9providers_is_provider(__pyx_v_value, 0)); - /* "dependency_injector/providers.pyx":3194 + /* "dependency_injector/providers.pyx":3488 * self.__value = value * self.__is_provider = is_provider(value) * self.__is_delegated = is_delegated(value) # <<<<<<<<<<<<<< @@ -59690,7 +66881,7 @@ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___ini */ __pyx_v_self->__pyx_base.__pyx___is_delegated = ((int)__pyx_f_19dependency_injector_9providers_is_delegated(__pyx_v_value, 0)); - /* "dependency_injector/providers.pyx":3195 + /* "dependency_injector/providers.pyx":3489 * self.__is_provider = is_provider(value) * self.__is_delegated = is_delegated(value) * self.__call = (self.__is_provider == 1 and # <<<<<<<<<<<<<< @@ -59704,7 +66895,7 @@ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___ini goto __pyx_L3_bool_binop_done; } - /* "dependency_injector/providers.pyx":3196 + /* "dependency_injector/providers.pyx":3490 * self.__is_delegated = is_delegated(value) * self.__call = (self.__is_provider == 1 and * self.__is_delegated == 0) # <<<<<<<<<<<<<< @@ -59715,7 +66906,7 @@ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___ini __pyx_t_1 = __pyx_t_2; __pyx_L3_bool_binop_done:; - /* "dependency_injector/providers.pyx":3195 + /* "dependency_injector/providers.pyx":3489 * self.__is_provider = is_provider(value) * self.__is_delegated = is_delegated(value) * self.__call = (self.__is_provider == 1 and # <<<<<<<<<<<<<< @@ -59724,14 +66915,14 @@ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___ini */ __pyx_v_self->__pyx_base.__pyx___call = ((int)__pyx_t_1); - /* "dependency_injector/providers.pyx":3197 + /* "dependency_injector/providers.pyx":3491 * self.__call = (self.__is_provider == 1 and * self.__is_delegated == 0) * super(PositionalInjection, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3197, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3491, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_PositionalInjection)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_PositionalInjection)); @@ -59739,10 +66930,10 @@ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___ini __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3197, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3491, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3197, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3491, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -59757,12 +66948,12 @@ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___ini } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3197, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3491, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":3190 + /* "dependency_injector/providers.pyx":3484 * """Positional injection class.""" * * def __init__(self, value): # <<<<<<<<<<<<<< @@ -59784,7 +66975,7 @@ static int __pyx_pf_19dependency_injector_9providers_19PositionalInjection___ini return __pyx_r; } -/* "dependency_injector/providers.pyx":3199 +/* "dependency_injector/providers.pyx":3493 * super(PositionalInjection, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -59822,16 +67013,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":3201 + /* "dependency_injector/providers.pyx":3495 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3201, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3201, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -59846,13 +67037,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3201, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3202 + /* "dependency_injector/providers.pyx":3496 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -59863,7 +67054,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":3203 + /* "dependency_injector/providers.pyx":3497 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -59875,7 +67066,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3202 + /* "dependency_injector/providers.pyx":3496 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -59884,7 +67075,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection */ } - /* "dependency_injector/providers.pyx":3204 + /* "dependency_injector/providers.pyx":3498 * if copied is not None: * return copied * return self.__class__(deepcopy(self.__value, memo)) # <<<<<<<<<<<<<< @@ -59892,14 +67083,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection * def get_value(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3204, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3498, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = __pyx_v_self->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3204, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3498, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3204, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3498, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -59915,14 +67106,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3204, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3498, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3199 + /* "dependency_injector/providers.pyx":3493 * super(PositionalInjection, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -59945,7 +67136,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection return __pyx_r; } -/* "dependency_injector/providers.pyx":3206 +/* "dependency_injector/providers.pyx":3500 * return self.__class__(deepcopy(self.__value, memo)) * * def get_value(self): # <<<<<<<<<<<<<< @@ -59976,7 +67167,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_value", 0); - /* "dependency_injector/providers.pyx":3208 + /* "dependency_injector/providers.pyx":3502 * def get_value(self): * """Return injection value.""" * return __get_value(self) # <<<<<<<<<<<<<< @@ -59984,13 +67175,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection * def get_original_value(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_self)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3208, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_self)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3502, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3206 + /* "dependency_injector/providers.pyx":3500 * return self.__class__(deepcopy(self.__value, memo)) * * def get_value(self): # <<<<<<<<<<<<<< @@ -60009,7 +67200,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection return __pyx_r; } -/* "dependency_injector/providers.pyx":3210 +/* "dependency_injector/providers.pyx":3504 * return __get_value(self) * * def get_original_value(self): # <<<<<<<<<<<<<< @@ -60036,7 +67227,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_original_value", 0); - /* "dependency_injector/providers.pyx":3212 + /* "dependency_injector/providers.pyx":3506 * def get_original_value(self): * """Return original value.""" * return self.__value # <<<<<<<<<<<<<< @@ -60048,7 +67239,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection __pyx_r = __pyx_v_self->__pyx_base.__pyx___value; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3210 + /* "dependency_injector/providers.pyx":3504 * return __get_value(self) * * def get_original_value(self): # <<<<<<<<<<<<<< @@ -60373,7 +67564,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_19PositionalInjection return __pyx_r; } -/* "dependency_injector/providers.pyx":3218 +/* "dependency_injector/providers.pyx":3512 * """Keyword injection class.""" * * def __init__(self, name, value): # <<<<<<<<<<<<<< @@ -60419,11 +67610,11 @@ static int __pyx_pw_19dependency_injector_9providers_14NamedInjection_1__init__( case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, 1); __PYX_ERR(1, 3218, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, 1); __PYX_ERR(1, 3512, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 3218, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(1, 3512, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -60436,7 +67627,7 @@ static int __pyx_pw_19dependency_injector_9providers_14NamedInjection_1__init__( } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3218, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3512, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.NamedInjection.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -60462,7 +67653,7 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__init__", 0); - /* "dependency_injector/providers.pyx":3220 + /* "dependency_injector/providers.pyx":3514 * def __init__(self, name, value): * """Initializer.""" * self.__name = name # <<<<<<<<<<<<<< @@ -60475,7 +67666,7 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s __Pyx_DECREF(__pyx_v_self->__pyx___name); __pyx_v_self->__pyx___name = __pyx_v_name; - /* "dependency_injector/providers.pyx":3221 + /* "dependency_injector/providers.pyx":3515 * """Initializer.""" * self.__name = name * self.__value = value # <<<<<<<<<<<<<< @@ -60488,7 +67679,7 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s __Pyx_DECREF(__pyx_v_self->__pyx_base.__pyx___value); __pyx_v_self->__pyx_base.__pyx___value = __pyx_v_value; - /* "dependency_injector/providers.pyx":3222 + /* "dependency_injector/providers.pyx":3516 * self.__name = name * self.__value = value * self.__is_provider = is_provider(value) # <<<<<<<<<<<<<< @@ -60497,7 +67688,7 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s */ __pyx_v_self->__pyx_base.__pyx___is_provider = ((int)__pyx_f_19dependency_injector_9providers_is_provider(__pyx_v_value, 0)); - /* "dependency_injector/providers.pyx":3223 + /* "dependency_injector/providers.pyx":3517 * self.__value = value * self.__is_provider = is_provider(value) * self.__is_delegated = is_delegated(value) # <<<<<<<<<<<<<< @@ -60506,7 +67697,7 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s */ __pyx_v_self->__pyx_base.__pyx___is_delegated = ((int)__pyx_f_19dependency_injector_9providers_is_delegated(__pyx_v_value, 0)); - /* "dependency_injector/providers.pyx":3224 + /* "dependency_injector/providers.pyx":3518 * self.__is_provider = is_provider(value) * self.__is_delegated = is_delegated(value) * self.__call = (self.__is_provider == 1 and # <<<<<<<<<<<<<< @@ -60520,7 +67711,7 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s goto __pyx_L3_bool_binop_done; } - /* "dependency_injector/providers.pyx":3225 + /* "dependency_injector/providers.pyx":3519 * self.__is_delegated = is_delegated(value) * self.__call = (self.__is_provider == 1 and * self.__is_delegated == 0) # <<<<<<<<<<<<<< @@ -60531,7 +67722,7 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s __pyx_t_1 = __pyx_t_2; __pyx_L3_bool_binop_done:; - /* "dependency_injector/providers.pyx":3224 + /* "dependency_injector/providers.pyx":3518 * self.__is_provider = is_provider(value) * self.__is_delegated = is_delegated(value) * self.__call = (self.__is_provider == 1 and # <<<<<<<<<<<<<< @@ -60540,14 +67731,14 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s */ __pyx_v_self->__pyx_base.__pyx___call = ((int)__pyx_t_1); - /* "dependency_injector/providers.pyx":3226 + /* "dependency_injector/providers.pyx":3520 * self.__call = (self.__is_provider == 1 and * self.__is_delegated == 0) * super(NamedInjection, self).__init__() # <<<<<<<<<<<<<< * * def __deepcopy__(self, memo): */ - __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3226, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3520, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_NamedInjection)); __Pyx_GIVEREF(((PyObject *)__pyx_ptype_19dependency_injector_9providers_NamedInjection)); @@ -60555,10 +67746,10 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s __Pyx_INCREF(((PyObject *)__pyx_v_self)); __Pyx_GIVEREF(((PyObject *)__pyx_v_self)); PyTuple_SET_ITEM(__pyx_t_4, 1, ((PyObject *)__pyx_v_self)); - __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3226, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3520, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3226, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_init); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3520, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -60573,12 +67764,12 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3226, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3520, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":3218 + /* "dependency_injector/providers.pyx":3512 * """Keyword injection class.""" * * def __init__(self, name, value): # <<<<<<<<<<<<<< @@ -60600,7 +67791,7 @@ static int __pyx_pf_19dependency_injector_9providers_14NamedInjection___init__(s return __pyx_r; } -/* "dependency_injector/providers.pyx":3228 +/* "dependency_injector/providers.pyx":3522 * super(NamedInjection, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -60641,16 +67832,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__deepcopy__", 0); - /* "dependency_injector/providers.pyx":3230 + /* "dependency_injector/providers.pyx":3524 * def __deepcopy__(self, memo): * """Create and return full copy of provider.""" * copied = memo.get(id(self)) # <<<<<<<<<<<<<< * if copied is not None: * return copied */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3230, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_memo, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3524, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3230, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3524, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -60665,13 +67856,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3230, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3524, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_copied = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3231 + /* "dependency_injector/providers.pyx":3525 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -60682,7 +67873,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d __pyx_t_6 = (__pyx_t_5 != 0); if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":3232 + /* "dependency_injector/providers.pyx":3526 * copied = memo.get(id(self)) * if copied is not None: * return copied # <<<<<<<<<<<<<< @@ -60694,7 +67885,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d __pyx_r = __pyx_v_copied; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3231 + /* "dependency_injector/providers.pyx":3525 * """Create and return full copy of provider.""" * copied = memo.get(id(self)) * if copied is not None: # <<<<<<<<<<<<<< @@ -60703,7 +67894,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d */ } - /* "dependency_injector/providers.pyx":3233 + /* "dependency_injector/providers.pyx":3527 * if copied is not None: * return copied * return self.__class__(deepcopy(self.__name, memo), # <<<<<<<<<<<<<< @@ -60711,18 +67902,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3233, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3527, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = __pyx_v_self->__pyx___name; __Pyx_INCREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3233, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3527, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3233, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3527, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":3234 + /* "dependency_injector/providers.pyx":3528 * return copied * return self.__class__(deepcopy(self.__name, memo), * deepcopy(self.__value, memo)) # <<<<<<<<<<<<<< @@ -60731,10 +67922,10 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d */ __pyx_t_3 = __pyx_v_self->__pyx_base.__pyx___value; __Pyx_INCREF(__pyx_t_3); - if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3234, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_v_memo))||((__pyx_v_memo) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_memo)->tp_name), 0))) __PYX_ERR(1, 3528, __pyx_L1_error) __pyx_t_7.__pyx_n = 1; __pyx_t_7.memo = ((PyObject*)__pyx_v_memo); - __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3234, __pyx_L1_error) + __pyx_t_8 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_t_3, 0, &__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3528, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; @@ -60752,7 +67943,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_t_4, __pyx_t_8}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3233, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3527, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -60762,7 +67953,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_t_4, __pyx_t_8}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3233, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_9, 2+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3527, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -60770,7 +67961,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d } else #endif { - __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 3233, __pyx_L1_error) + __pyx_t_10 = PyTuple_New(2+__pyx_t_9); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 3527, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); if (__pyx_t_3) { __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL; @@ -60781,7 +67972,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_9, __pyx_t_8); __pyx_t_4 = 0; __pyx_t_8 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_10, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3233, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_10, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3527, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } @@ -60790,7 +67981,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3228 + /* "dependency_injector/providers.pyx":3522 * super(NamedInjection, self).__init__() * * def __deepcopy__(self, memo): # <<<<<<<<<<<<<< @@ -60815,7 +68006,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_2__d return __pyx_r; } -/* "dependency_injector/providers.pyx":3236 +/* "dependency_injector/providers.pyx":3530 * deepcopy(self.__value, memo)) * * def get_name(self): # <<<<<<<<<<<<<< @@ -60846,7 +68037,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_4get int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_name", 0); - /* "dependency_injector/providers.pyx":3238 + /* "dependency_injector/providers.pyx":3532 * def get_name(self): * """Return injection value.""" * return __get_name(self) # <<<<<<<<<<<<<< @@ -60854,13 +68045,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_4get * def get_value(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_self); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3238, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_self); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3532, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3236 + /* "dependency_injector/providers.pyx":3530 * deepcopy(self.__value, memo)) * * def get_name(self): # <<<<<<<<<<<<<< @@ -60879,7 +68070,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_4get return __pyx_r; } -/* "dependency_injector/providers.pyx":3240 +/* "dependency_injector/providers.pyx":3534 * return __get_name(self) * * def get_value(self): # <<<<<<<<<<<<<< @@ -60910,7 +68101,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_6get int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_value", 0); - /* "dependency_injector/providers.pyx":3242 + /* "dependency_injector/providers.pyx":3536 * def get_value(self): * """Return injection value.""" * return __get_value(self) # <<<<<<<<<<<<<< @@ -60918,13 +68109,13 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_6get * def get_original_value(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_self)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3242, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_self)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3536, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3240 + /* "dependency_injector/providers.pyx":3534 * return __get_name(self) * * def get_value(self): # <<<<<<<<<<<<<< @@ -60943,7 +68134,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_6get return __pyx_r; } -/* "dependency_injector/providers.pyx":3244 +/* "dependency_injector/providers.pyx":3538 * return __get_value(self) * * def get_original_value(self): # <<<<<<<<<<<<<< @@ -60970,7 +68161,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_8get __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_original_value", 0); - /* "dependency_injector/providers.pyx":3246 + /* "dependency_injector/providers.pyx":3540 * def get_original_value(self): * """Return original value.""" * return self.__value # <<<<<<<<<<<<<< @@ -60982,7 +68173,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_8get __pyx_r = __pyx_v_self->__pyx_base.__pyx___value; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3244 + /* "dependency_injector/providers.pyx":3538 * return __get_value(self) * * def get_original_value(self): # <<<<<<<<<<<<<< @@ -61321,7 +68512,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14NamedInjection_12__ return __pyx_r; } -/* "dependency_injector/providers.pyx":3251 +/* "dependency_injector/providers.pyx":3545 * @cython.boundscheck(False) * @cython.wraparound(False) * cpdef tuple parse_positional_injections(tuple args): # <<<<<<<<<<<<<< @@ -61349,19 +68540,19 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_positional_injec int __pyx_clineno = 0; __Pyx_RefNannySetupContext("parse_positional_injections", 0); - /* "dependency_injector/providers.pyx":3253 + /* "dependency_injector/providers.pyx":3547 * cpdef tuple parse_positional_injections(tuple args): * """Parse positional injections.""" * cdef list injections = list() # <<<<<<<<<<<<<< * cdef int args_len = len(args) * */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3253, __pyx_L1_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3547, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_injections = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3254 + /* "dependency_injector/providers.pyx":3548 * """Parse positional injections.""" * cdef list injections = list() * cdef int args_len = len(args) # <<<<<<<<<<<<<< @@ -61370,12 +68561,12 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_positional_injec */ if (unlikely(__pyx_v_args == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(1, 3254, __pyx_L1_error) + __PYX_ERR(1, 3548, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_SIZE(__pyx_v_args); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 3254, __pyx_L1_error) + __pyx_t_2 = PyTuple_GET_SIZE(__pyx_v_args); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(1, 3548, __pyx_L1_error) __pyx_v_args_len = __pyx_t_2; - /* "dependency_injector/providers.pyx":3260 + /* "dependency_injector/providers.pyx":3554 * cdef PositionalInjection injection * * for index in range(args_len): # <<<<<<<<<<<<<< @@ -61387,7 +68578,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_positional_injec for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) { __pyx_v_index = __pyx_t_5; - /* "dependency_injector/providers.pyx":3261 + /* "dependency_injector/providers.pyx":3555 * * for index in range(args_len): * arg = args[index] # <<<<<<<<<<<<<< @@ -61396,36 +68587,36 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_positional_injec */ if (unlikely(__pyx_v_args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(1, 3261, __pyx_L1_error) + __PYX_ERR(1, 3555, __pyx_L1_error) } __pyx_t_1 = PyTuple_GET_ITEM(__pyx_v_args, __pyx_v_index); __Pyx_INCREF(__pyx_t_1); __Pyx_XDECREF_SET(__pyx_v_arg, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3262 + /* "dependency_injector/providers.pyx":3556 * for index in range(args_len): * arg = args[index] * injection = PositionalInjection(arg) # <<<<<<<<<<<<<< * injections.append(injection) * */ - __pyx_t_1 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_PositionalInjection), __pyx_v_arg); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3262, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_19dependency_injector_9providers_PositionalInjection), __pyx_v_arg); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3556, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_XDECREF_SET(__pyx_v_injection, ((struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *)__pyx_t_1)); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3263 + /* "dependency_injector/providers.pyx":3557 * arg = args[index] * injection = PositionalInjection(arg) * injections.append(injection) # <<<<<<<<<<<<<< * * return tuple(injections) */ - __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_injections, ((PyObject *)__pyx_v_injection)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 3263, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_injections, ((PyObject *)__pyx_v_injection)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 3557, __pyx_L1_error) } - /* "dependency_injector/providers.pyx":3265 + /* "dependency_injector/providers.pyx":3559 * injections.append(injection) * * return tuple(injections) # <<<<<<<<<<<<<< @@ -61433,13 +68624,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_positional_injec * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyList_AsTuple(__pyx_v_injections); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3265, __pyx_L1_error) + __pyx_t_1 = PyList_AsTuple(__pyx_v_injections); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3559, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3251 + /* "dependency_injector/providers.pyx":3545 * @cython.boundscheck(False) * @cython.wraparound(False) * cpdef tuple parse_positional_injections(tuple args): # <<<<<<<<<<<<<< @@ -61471,7 +68662,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_7parse_positional_inj PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("parse_positional_injections (wrapper)", 0); - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3251, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_args), (&PyTuple_Type), 1, "args", 1))) __PYX_ERR(1, 3545, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_6parse_positional_injections(__pyx_self, ((PyObject*)__pyx_v_args)); /* function exit code */ @@ -61492,7 +68683,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6parse_positional_inj int __pyx_clineno = 0; __Pyx_RefNannySetupContext("parse_positional_injections", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3251, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_positional_injections(__pyx_v_args, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3545, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -61509,7 +68700,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_6parse_positional_inj return __pyx_r; } -/* "dependency_injector/providers.pyx":3270 +/* "dependency_injector/providers.pyx":3564 * @cython.boundscheck(False) * @cython.wraparound(False) * cpdef tuple parse_named_injections(dict kwargs): # <<<<<<<<<<<<<< @@ -61539,19 +68730,19 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections int __pyx_clineno = 0; __Pyx_RefNannySetupContext("parse_named_injections", 0); - /* "dependency_injector/providers.pyx":3272 + /* "dependency_injector/providers.pyx":3566 * cpdef tuple parse_named_injections(dict kwargs): * """Parse named injections.""" * cdef list injections = list() # <<<<<<<<<<<<<< * * cdef object name */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3272, __pyx_L1_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3566, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_injections = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3278 + /* "dependency_injector/providers.pyx":3572 * cdef NamedInjection injection * * for name, arg in kwargs.items(): # <<<<<<<<<<<<<< @@ -61560,17 +68751,17 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections */ if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "items"); - __PYX_ERR(1, 3278, __pyx_L1_error) + __PYX_ERR(1, 3572, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_Items(__pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3278, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_Items(__pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3572, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; __pyx_t_4 = NULL; } else { - __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3278, __pyx_L1_error) + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3572, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3278, __pyx_L1_error) + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3572, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -61578,17 +68769,17 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 3278, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 3572, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3278, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3572, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 3278, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(1, 3572, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3278, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3572, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -61598,7 +68789,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 3278, __pyx_L1_error) + else __PYX_ERR(1, 3572, __pyx_L1_error) } break; } @@ -61610,7 +68801,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(1, 3278, __pyx_L1_error) + __PYX_ERR(1, 3572, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -61623,15 +68814,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3278, __pyx_L1_error) + __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3572, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3278, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3572, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 3278, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 3572, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -61639,7 +68830,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections __Pyx_GOTREF(__pyx_t_5); index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 3278, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 3572, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L6_unpacking_done; @@ -61647,7 +68838,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(1, 3278, __pyx_L1_error) + __PYX_ERR(1, 3572, __pyx_L1_error) __pyx_L6_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_5); @@ -61655,14 +68846,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections __Pyx_XDECREF_SET(__pyx_v_arg, __pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":3279 + /* "dependency_injector/providers.pyx":3573 * * for name, arg in kwargs.items(): * injection = NamedInjection(name, arg) # <<<<<<<<<<<<<< * injections.append(injection) * */ - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3279, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3573, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); @@ -61670,22 +68861,22 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections __Pyx_INCREF(__pyx_v_arg); __Pyx_GIVEREF(__pyx_v_arg); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_arg); - __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_NamedInjection), __pyx_t_1, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3279, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_19dependency_injector_9providers_NamedInjection), __pyx_t_1, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3573, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF_SET(__pyx_v_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_6)); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":3280 + /* "dependency_injector/providers.pyx":3574 * for name, arg in kwargs.items(): * injection = NamedInjection(name, arg) * injections.append(injection) # <<<<<<<<<<<<<< * * return tuple(injections) */ - __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_injections, ((PyObject *)__pyx_v_injection)); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(1, 3280, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_injections, ((PyObject *)__pyx_v_injection)); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(1, 3574, __pyx_L1_error) - /* "dependency_injector/providers.pyx":3278 + /* "dependency_injector/providers.pyx":3572 * cdef NamedInjection injection * * for name, arg in kwargs.items(): # <<<<<<<<<<<<<< @@ -61695,7 +68886,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":3282 + /* "dependency_injector/providers.pyx":3576 * injections.append(injection) * * return tuple(injections) # <<<<<<<<<<<<<< @@ -61703,13 +68894,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_parse_named_injections * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = PyList_AsTuple(__pyx_v_injections); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3282, __pyx_L1_error) + __pyx_t_2 = PyList_AsTuple(__pyx_v_injections); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3576, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_r = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3270 + /* "dependency_injector/providers.pyx":3564 * @cython.boundscheck(False) * @cython.wraparound(False) * cpdef tuple parse_named_injections(dict kwargs): # <<<<<<<<<<<<<< @@ -61746,7 +68937,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_9parse_named_injectio PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("parse_named_injections (wrapper)", 0); - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3270, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_kwargs), (&PyDict_Type), 1, "kwargs", 1))) __PYX_ERR(1, 3564, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_8parse_named_injections(__pyx_self, ((PyObject*)__pyx_v_kwargs)); /* function exit code */ @@ -61767,7 +68958,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8parse_named_injectio int __pyx_clineno = 0; __Pyx_RefNannySetupContext("parse_named_injections", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3270, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_parse_named_injections(__pyx_v_kwargs, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3564, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -61784,7 +68975,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_8parse_named_injectio return __pyx_r; } -/* "dependency_injector/providers.pyx":3285 +/* "dependency_injector/providers.pyx":3579 * * * cpdef bint is_provider(object instance): # <<<<<<<<<<<<<< @@ -61805,7 +68996,7 @@ static int __pyx_f_19dependency_injector_9providers_is_provider(PyObject *__pyx_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("is_provider", 0); - /* "dependency_injector/providers.pyx":3293 + /* "dependency_injector/providers.pyx":3587 * :rtype: bool * """ * return (not isinstance(instance, CLASS_TYPES) and # <<<<<<<<<<<<<< @@ -61814,7 +69005,7 @@ static int __pyx_f_19dependency_injector_9providers_is_provider(PyObject *__pyx_ */ __pyx_t_2 = __pyx_v_19dependency_injector_9providers_CLASS_TYPES; __Pyx_INCREF(__pyx_t_2); - __pyx_t_3 = PyObject_IsInstance(__pyx_v_instance, __pyx_t_2); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 3293, __pyx_L1_error) + __pyx_t_3 = PyObject_IsInstance(__pyx_v_instance, __pyx_t_2); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 3587, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_4 = ((!(__pyx_t_3 != 0)) != 0); if (__pyx_t_4) { @@ -61823,14 +69014,14 @@ static int __pyx_f_19dependency_injector_9providers_is_provider(PyObject *__pyx_ goto __pyx_L3_bool_binop_done; } - /* "dependency_injector/providers.pyx":3294 + /* "dependency_injector/providers.pyx":3588 * """ * return (not isinstance(instance, CLASS_TYPES) and * getattr(instance, '__IS_PROVIDER__', False) is True) # <<<<<<<<<<<<<< * * */ - __pyx_t_2 = __Pyx_GetAttr3(__pyx_v_instance, __pyx_n_s_IS_PROVIDER, Py_False); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3294, __pyx_L1_error) + __pyx_t_2 = __Pyx_GetAttr3(__pyx_v_instance, __pyx_n_s_IS_PROVIDER, Py_False); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3588, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_4 = (__pyx_t_2 == Py_True); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -61840,7 +69031,7 @@ static int __pyx_f_19dependency_injector_9providers_is_provider(PyObject *__pyx_ __pyx_r = __pyx_t_1; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3285 + /* "dependency_injector/providers.pyx":3579 * * * cpdef bint is_provider(object instance): # <<<<<<<<<<<<<< @@ -61881,7 +69072,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10is_provider(CYTHON_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("is_provider", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_f_19dependency_injector_9providers_is_provider(__pyx_v_instance, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3285, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_f_19dependency_injector_9providers_is_provider(__pyx_v_instance, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3579, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -61898,7 +69089,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_10is_provider(CYTHON_ return __pyx_r; } -/* "dependency_injector/providers.pyx":3297 +/* "dependency_injector/providers.pyx":3591 * * * cpdef object ensure_is_provider(object instance): # <<<<<<<<<<<<<< @@ -61922,7 +69113,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_ensure_is_provider(PyO int __pyx_clineno = 0; __Pyx_RefNannySetupContext("ensure_is_provider", 0); - /* "dependency_injector/providers.pyx":3308 + /* "dependency_injector/providers.pyx":3602 * :rtype: :py:class:`dependency_injector.providers.Provider` * """ * if not is_provider(instance): # <<<<<<<<<<<<<< @@ -61932,26 +69123,26 @@ static PyObject *__pyx_f_19dependency_injector_9providers_ensure_is_provider(PyO __pyx_t_1 = ((!(__pyx_f_19dependency_injector_9providers_is_provider(__pyx_v_instance, 0) != 0)) != 0); if (unlikely(__pyx_t_1)) { - /* "dependency_injector/providers.pyx":3309 + /* "dependency_injector/providers.pyx":3603 * """ * if not is_provider(instance): * raise Error('Expected provider instance, ' # <<<<<<<<<<<<<< * 'got {0}'.format(str(instance))) * return instance */ - __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_Error); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3309, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_Error); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3603, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - /* "dependency_injector/providers.pyx":3310 + /* "dependency_injector/providers.pyx":3604 * if not is_provider(instance): * raise Error('Expected provider instance, ' * 'got {0}'.format(str(instance))) # <<<<<<<<<<<<<< * return instance * */ - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Expected_provider_instance_got_0, __pyx_n_s_format); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3310, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_Expected_provider_instance_got_0, __pyx_n_s_format); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3604, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_6 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyString_Type)), __pyx_v_instance); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3310, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyString_Type)), __pyx_v_instance); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3604, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { @@ -61966,7 +69157,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_ensure_is_provider(PyO __pyx_t_4 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_7, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3310, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3604, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; @@ -61982,14 +69173,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_ensure_is_provider(PyO __pyx_t_2 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3309, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3603, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __PYX_ERR(1, 3309, __pyx_L1_error) + __PYX_ERR(1, 3603, __pyx_L1_error) - /* "dependency_injector/providers.pyx":3308 + /* "dependency_injector/providers.pyx":3602 * :rtype: :py:class:`dependency_injector.providers.Provider` * """ * if not is_provider(instance): # <<<<<<<<<<<<<< @@ -61998,7 +69189,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_ensure_is_provider(PyO */ } - /* "dependency_injector/providers.pyx":3311 + /* "dependency_injector/providers.pyx":3605 * raise Error('Expected provider instance, ' * 'got {0}'.format(str(instance))) * return instance # <<<<<<<<<<<<<< @@ -62010,7 +69201,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_ensure_is_provider(PyO __pyx_r = __pyx_v_instance; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3297 + /* "dependency_injector/providers.pyx":3591 * * * cpdef object ensure_is_provider(object instance): # <<<<<<<<<<<<<< @@ -62057,7 +69248,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12ensure_is_provider( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("ensure_is_provider", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_ensure_is_provider(__pyx_v_instance, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3297, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_ensure_is_provider(__pyx_v_instance, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3591, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -62074,7 +69265,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_12ensure_is_provider( return __pyx_r; } -/* "dependency_injector/providers.pyx":3314 +/* "dependency_injector/providers.pyx":3608 * * * cpdef bint is_delegated(object instance): # <<<<<<<<<<<<<< @@ -62095,7 +69286,7 @@ static int __pyx_f_19dependency_injector_9providers_is_delegated(PyObject *__pyx int __pyx_clineno = 0; __Pyx_RefNannySetupContext("is_delegated", 0); - /* "dependency_injector/providers.pyx":3322 + /* "dependency_injector/providers.pyx":3616 * :rtype: bool * """ * return (not isinstance(instance, CLASS_TYPES) and # <<<<<<<<<<<<<< @@ -62104,7 +69295,7 @@ static int __pyx_f_19dependency_injector_9providers_is_delegated(PyObject *__pyx */ __pyx_t_2 = __pyx_v_19dependency_injector_9providers_CLASS_TYPES; __Pyx_INCREF(__pyx_t_2); - __pyx_t_3 = PyObject_IsInstance(__pyx_v_instance, __pyx_t_2); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 3322, __pyx_L1_error) + __pyx_t_3 = PyObject_IsInstance(__pyx_v_instance, __pyx_t_2); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 3616, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_4 = ((!(__pyx_t_3 != 0)) != 0); if (__pyx_t_4) { @@ -62113,14 +69304,14 @@ static int __pyx_f_19dependency_injector_9providers_is_delegated(PyObject *__pyx goto __pyx_L3_bool_binop_done; } - /* "dependency_injector/providers.pyx":3323 + /* "dependency_injector/providers.pyx":3617 * """ * return (not isinstance(instance, CLASS_TYPES) and * getattr(instance, '__IS_DELEGATED__', False) is True) # <<<<<<<<<<<<<< * * */ - __pyx_t_2 = __Pyx_GetAttr3(__pyx_v_instance, __pyx_n_s_IS_DELEGATED, Py_False); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3323, __pyx_L1_error) + __pyx_t_2 = __Pyx_GetAttr3(__pyx_v_instance, __pyx_n_s_IS_DELEGATED, Py_False); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3617, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_4 = (__pyx_t_2 == Py_True); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -62130,7 +69321,7 @@ static int __pyx_f_19dependency_injector_9providers_is_delegated(PyObject *__pyx __pyx_r = __pyx_t_1; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3314 + /* "dependency_injector/providers.pyx":3608 * * * cpdef bint is_delegated(object instance): # <<<<<<<<<<<<<< @@ -62171,7 +69362,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14is_delegated(CYTHON int __pyx_clineno = 0; __Pyx_RefNannySetupContext("is_delegated", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_f_19dependency_injector_9providers_is_delegated(__pyx_v_instance, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3314, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_f_19dependency_injector_9providers_is_delegated(__pyx_v_instance, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3608, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -62188,7 +69379,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_14is_delegated(CYTHON return __pyx_r; } -/* "dependency_injector/providers.pyx":3326 +/* "dependency_injector/providers.pyx":3620 * * * cpdef str represent_provider(object provider, object provides): # <<<<<<<<<<<<<< @@ -62211,7 +69402,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_represent_provider(PyO int __pyx_clineno = 0; __Pyx_RefNannySetupContext("represent_provider", 0); - /* "dependency_injector/providers.pyx":3338 + /* "dependency_injector/providers.pyx":3632 * :rtype: str * """ * return '<{provider}({provides}) at {address}>'.format( # <<<<<<<<<<<<<< @@ -62219,45 +69410,45 @@ static PyObject *__pyx_f_19dependency_injector_9providers_represent_provider(PyO * provider.__class__.__name__)), */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_provider_provides_at_address, __pyx_n_s_format); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3338, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_provider_provides_at_address, __pyx_n_s_format); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3632, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":3339 + /* "dependency_injector/providers.pyx":3633 * """ * return '<{provider}({provides}) at {address}>'.format( * provider='.'.join((provider.__class__.__module__, # <<<<<<<<<<<<<< * provider.__class__.__name__)), * provides=repr(provides) if provides is not None else '', */ - __pyx_t_2 = __Pyx_PyDict_NewPresized(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3339, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyDict_NewPresized(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3633, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3339, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3633, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_module); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3339, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_module); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3633, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":3340 + /* "dependency_injector/providers.pyx":3634 * return '<{provider}({provides}) at {address}>'.format( * provider='.'.join((provider.__class__.__module__, * provider.__class__.__name__)), # <<<<<<<<<<<<<< * provides=repr(provides) if provides is not None else '', * address=hex(id(provider))) */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3340, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_provider, __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3634, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3340, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_name); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3634, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":3339 + /* "dependency_injector/providers.pyx":3633 * """ * return '<{provider}({provides}) at {address}>'.format( * provider='.'.join((provider.__class__.__module__, # <<<<<<<<<<<<<< * provider.__class__.__name__)), * provides=repr(provides) if provides is not None else '', */ - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3339, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3633, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); @@ -62265,13 +69456,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_represent_provider(PyO PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_5); __pyx_t_4 = 0; __pyx_t_5 = 0; - __pyx_t_5 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3339, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyString_Join(__pyx_kp_s__5, __pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3633, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_provider, __pyx_t_5) < 0) __PYX_ERR(1, 3339, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_provider, __pyx_t_5) < 0) __PYX_ERR(1, 3633, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":3341 + /* "dependency_injector/providers.pyx":3635 * provider='.'.join((provider.__class__.__module__, * provider.__class__.__name__)), * provides=repr(provides) if provides is not None else '', # <<<<<<<<<<<<<< @@ -62280,49 +69471,49 @@ static PyObject *__pyx_f_19dependency_injector_9providers_represent_provider(PyO */ __pyx_t_6 = (__pyx_v_provides != Py_None); if ((__pyx_t_6 != 0)) { - __pyx_t_3 = PyObject_Repr(__pyx_v_provides); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3341, __pyx_L1_error) + __pyx_t_3 = PyObject_Repr(__pyx_v_provides); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3635, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_5 = __pyx_t_3; __pyx_t_3 = 0; } else { - __Pyx_INCREF(__pyx_n_s__11); - __pyx_t_5 = __pyx_n_s__11; + __Pyx_INCREF(__pyx_n_s__12); + __pyx_t_5 = __pyx_n_s__12; } - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_provides, __pyx_t_5) < 0) __PYX_ERR(1, 3339, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_provides, __pyx_t_5) < 0) __PYX_ERR(1, 3633, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":3342 + /* "dependency_injector/providers.pyx":3636 * provider.__class__.__name__)), * provides=repr(provides) if provides is not None else '', * address=hex(id(provider))) # <<<<<<<<<<<<<< * * */ - __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_v_provider); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3342, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_v_provider); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3636, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_hex, __pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3342, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_hex, __pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3636, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_address, __pyx_t_3) < 0) __PYX_ERR(1, 3339, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_address, __pyx_t_3) < 0) __PYX_ERR(1, 3633, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":3338 + /* "dependency_injector/providers.pyx":3632 * :rtype: str * """ * return '<{provider}({provides}) at {address}>'.format( # <<<<<<<<<<<<<< * provider='.'.join((provider.__class__.__module__, * provider.__class__.__name__)), */ - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3338, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3632, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(PyString_CheckExact(__pyx_t_3))||((__pyx_t_3) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_t_3)->tp_name), 0))) __PYX_ERR(1, 3338, __pyx_L1_error) + if (!(likely(PyString_CheckExact(__pyx_t_3))||((__pyx_t_3) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_t_3)->tp_name), 0))) __PYX_ERR(1, 3632, __pyx_L1_error) __pyx_r = ((PyObject*)__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3326 + /* "dependency_injector/providers.pyx":3620 * * * cpdef str represent_provider(object provider, object provides): # <<<<<<<<<<<<<< @@ -62380,11 +69571,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_17represent_provider( case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_provides)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("represent_provider", 1, 2, 2, 1); __PYX_ERR(1, 3326, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("represent_provider", 1, 2, 2, 1); __PYX_ERR(1, 3620, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "represent_provider") < 0)) __PYX_ERR(1, 3326, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "represent_provider") < 0)) __PYX_ERR(1, 3620, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -62397,7 +69588,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_17represent_provider( } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("represent_provider", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3326, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("represent_provider", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3620, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.represent_provider", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -62419,7 +69610,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16represent_provider( int __pyx_clineno = 0; __Pyx_RefNannySetupContext("represent_provider", 0); __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_represent_provider(__pyx_v_provider, __pyx_v_provides, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3326, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_represent_provider(__pyx_v_provider, __pyx_v_provides, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3620, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -62436,7 +69627,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_16represent_provider( return __pyx_r; } -/* "dependency_injector/providers.pyx":3345 +/* "dependency_injector/providers.pyx":3639 * * * cpdef object deepcopy(object instance, dict memo=None): # <<<<<<<<<<<<<< @@ -62467,7 +69658,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_deepcopy(PyObject *__p } __Pyx_INCREF(__pyx_v_memo); - /* "dependency_injector/providers.pyx":3347 + /* "dependency_injector/providers.pyx":3641 * cpdef object deepcopy(object instance, dict memo=None): * """Return full copy of provider or container with providers.""" * if memo is None: # <<<<<<<<<<<<<< @@ -62478,19 +69669,19 @@ static PyObject *__pyx_f_19dependency_injector_9providers_deepcopy(PyObject *__p __pyx_t_2 = (__pyx_t_1 != 0); if (__pyx_t_2) { - /* "dependency_injector/providers.pyx":3348 + /* "dependency_injector/providers.pyx":3642 * """Return full copy of provider or container with providers.""" * if memo is None: * memo = dict() # <<<<<<<<<<<<<< * * __add_sys_streams(memo) */ - __pyx_t_3 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3348, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3642, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF_SET(__pyx_v_memo, ((PyObject*)__pyx_t_3)); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":3347 + /* "dependency_injector/providers.pyx":3641 * cpdef object deepcopy(object instance, dict memo=None): * """Return full copy of provider or container with providers.""" * if memo is None: # <<<<<<<<<<<<<< @@ -62499,14 +69690,14 @@ static PyObject *__pyx_f_19dependency_injector_9providers_deepcopy(PyObject *__p */ } - /* "dependency_injector/providers.pyx":3350 + /* "dependency_injector/providers.pyx":3644 * memo = dict() * * __add_sys_streams(memo) # <<<<<<<<<<<<<< * * return copy.deepcopy(instance, memo) */ - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_add_sys_streams); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3350, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_add_sys_streams); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3644, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { @@ -62520,12 +69711,12 @@ static PyObject *__pyx_f_19dependency_injector_9providers_deepcopy(PyObject *__p } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_memo) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_memo); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3350, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3644, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "dependency_injector/providers.pyx":3352 + /* "dependency_injector/providers.pyx":3646 * __add_sys_streams(memo) * * return copy.deepcopy(instance, memo) # <<<<<<<<<<<<<< @@ -62533,9 +69724,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers_deepcopy(PyObject *__p * def __add_sys_streams(memo): */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_copy); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3352, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_copy); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3646, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_deepcopy); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3352, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_deepcopy); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3646, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; @@ -62553,7 +69744,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_deepcopy(PyObject *__p #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_instance, __pyx_v_memo}; - __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3352, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3646, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_3); } else @@ -62561,13 +69752,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers_deepcopy(PyObject *__p #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_instance, __pyx_v_memo}; - __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3352, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3646, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_3); } else #endif { - __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 3352, __pyx_L1_error) + __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 3646, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -62578,7 +69769,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_deepcopy(PyObject *__p __Pyx_INCREF(__pyx_v_memo); __Pyx_GIVEREF(__pyx_v_memo); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_v_memo); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3352, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3646, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } @@ -62587,7 +69778,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers_deepcopy(PyObject *__p __pyx_t_3 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3345 + /* "dependency_injector/providers.pyx":3639 * * * cpdef object deepcopy(object instance, dict memo=None): # <<<<<<<<<<<<<< @@ -62650,7 +69841,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19deepcopy(PyObject * } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "deepcopy") < 0)) __PYX_ERR(1, 3345, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "deepcopy") < 0)) __PYX_ERR(1, 3639, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -62666,13 +69857,13 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_19deepcopy(PyObject * } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("deepcopy", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3345, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("deepcopy", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3639, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.deepcopy", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_memo), (&PyDict_Type), 1, "memo", 1))) __PYX_ERR(1, 3345, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_memo), (&PyDict_Type), 1, "memo", 1))) __PYX_ERR(1, 3639, __pyx_L1_error) __pyx_r = __pyx_pf_19dependency_injector_9providers_18deepcopy(__pyx_self, __pyx_v_instance, __pyx_v_memo); /* function exit code */ @@ -62696,7 +69887,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18deepcopy(CYTHON_UNU __Pyx_XDECREF(__pyx_r); __pyx_t_2.__pyx_n = 1; __pyx_t_2.memo = __pyx_v_memo; - __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_v_instance, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3345, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers_deepcopy(__pyx_v_instance, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3639, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; @@ -62713,7 +69904,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_18deepcopy(CYTHON_UNU return __pyx_r; } -/* "dependency_injector/providers.pyx":3354 +/* "dependency_injector/providers.pyx":3648 * return copy.deepcopy(instance, memo) * * def __add_sys_streams(memo): # <<<<<<<<<<<<<< @@ -62747,79 +69938,79 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20__add_sys_streams(C int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__add_sys_streams", 0); - /* "dependency_injector/providers.pyx":3360 + /* "dependency_injector/providers.pyx":3654 * objects graph. * """ * memo[id(sys.stdin)] = sys.stdin # <<<<<<<<<<<<<< * memo[id(sys.stdout)] = sys.stdout * memo[id(sys.stderr)] = sys.stderr */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3360, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3654, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_stdin); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3360, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_stdin); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3654, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3360, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3654, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_stdin); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3360, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_stdin); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3654, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3360, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3654, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(PyObject_SetItem(__pyx_v_memo, __pyx_t_1, __pyx_t_2) < 0)) __PYX_ERR(1, 3360, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_v_memo, __pyx_t_1, __pyx_t_2) < 0)) __PYX_ERR(1, 3654, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":3361 + /* "dependency_injector/providers.pyx":3655 * """ * memo[id(sys.stdin)] = sys.stdin * memo[id(sys.stdout)] = sys.stdout # <<<<<<<<<<<<<< * memo[id(sys.stderr)] = sys.stderr * */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_sys); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3361, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_sys); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_stdout); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3361, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_stdout); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_sys); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3361, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_sys); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_stdout); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3361, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_stdout); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3361, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(PyObject_SetItem(__pyx_v_memo, __pyx_t_2, __pyx_t_1) < 0)) __PYX_ERR(1, 3361, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_v_memo, __pyx_t_2, __pyx_t_1) < 0)) __PYX_ERR(1, 3655, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3362 + /* "dependency_injector/providers.pyx":3656 * memo[id(sys.stdin)] = sys.stdin * memo[id(sys.stdout)] = sys.stdout * memo[id(sys.stderr)] = sys.stderr # <<<<<<<<<<<<<< * * */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3362, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3656, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_stderr); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3362, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_stderr); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3656, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3362, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3656, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_stderr); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3362, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_stderr); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3656, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3362, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3656, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(PyObject_SetItem(__pyx_v_memo, __pyx_t_1, __pyx_t_2) < 0)) __PYX_ERR(1, 3362, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_v_memo, __pyx_t_1, __pyx_t_2) < 0)) __PYX_ERR(1, 3656, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":3354 + /* "dependency_injector/providers.pyx":3648 * return copy.deepcopy(instance, memo) * * def __add_sys_streams(memo): # <<<<<<<<<<<<<< @@ -62842,7 +70033,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_20__add_sys_streams(C return __pyx_r; } -/* "dependency_injector/providers.pyx":3365 +/* "dependency_injector/providers.pyx":3659 * * * def merge_dicts(dict1, dict2): # <<<<<<<<<<<<<< @@ -62886,11 +70077,11 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_23merge_dicts(PyObjec case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dict2)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("merge_dicts", 1, 2, 2, 1); __PYX_ERR(1, 3365, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("merge_dicts", 1, 2, 2, 1); __PYX_ERR(1, 3659, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "merge_dicts") < 0)) __PYX_ERR(1, 3365, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "merge_dicts") < 0)) __PYX_ERR(1, 3659, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; @@ -62903,7 +70094,7 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_23merge_dicts(PyObjec } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("merge_dicts", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3365, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("merge_dicts", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 3659, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("dependency_injector.providers.merge_dicts", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -62940,14 +70131,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("merge_dicts", 0); - /* "dependency_injector/providers.pyx":3377 + /* "dependency_injector/providers.pyx":3671 * :rtype: dict * """ * for key, value in dict1.items(): # <<<<<<<<<<<<<< * if key in dict2: * if isinstance(value, dict) and isinstance(dict2[key], dict): */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_dict1, __pyx_n_s_items); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3377, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_dict1, __pyx_n_s_items); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3671, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -62961,16 +70152,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3377, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3671, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_4 = 0; __pyx_t_5 = NULL; } else { - __pyx_t_4 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3377, __pyx_L1_error) + __pyx_t_4 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3671, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_5 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3377, __pyx_L1_error) + __pyx_t_5 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3671, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -62978,17 +70169,17 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 3377, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 3671, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3377, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3671, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 3377, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_1); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(1, 3671, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3377, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3671, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -62998,7 +70189,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(1, 3377, __pyx_L1_error) + else __PYX_ERR(1, 3671, __pyx_L1_error) } break; } @@ -63010,7 +70201,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(1, 3377, __pyx_L1_error) + __PYX_ERR(1, 3671, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -63023,15 +70214,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3377, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3671, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3377, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3671, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 3377, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 3671, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -63039,7 +70230,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ __Pyx_GOTREF(__pyx_t_3); index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 3377, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(1, 3671, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L6_unpacking_done; @@ -63047,7 +70238,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(1, 3377, __pyx_L1_error) + __PYX_ERR(1, 3671, __pyx_L1_error) __pyx_L6_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_key, __pyx_t_3); @@ -63055,18 +70246,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pyx":3378 + /* "dependency_injector/providers.pyx":3672 * """ * for key, value in dict1.items(): * if key in dict2: # <<<<<<<<<<<<<< * if isinstance(value, dict) and isinstance(dict2[key], dict): * dict2[key] = merge_dicts(value, dict2[key]) */ - __pyx_t_9 = (__Pyx_PySequence_ContainsTF(__pyx_v_key, __pyx_v_dict2, Py_EQ)); if (unlikely(__pyx_t_9 < 0)) __PYX_ERR(1, 3378, __pyx_L1_error) + __pyx_t_9 = (__Pyx_PySequence_ContainsTF(__pyx_v_key, __pyx_v_dict2, Py_EQ)); if (unlikely(__pyx_t_9 < 0)) __PYX_ERR(1, 3672, __pyx_L1_error) __pyx_t_10 = (__pyx_t_9 != 0); if (__pyx_t_10) { - /* "dependency_injector/providers.pyx":3379 + /* "dependency_injector/providers.pyx":3673 * for key, value in dict1.items(): * if key in dict2: * if isinstance(value, dict) and isinstance(dict2[key], dict): # <<<<<<<<<<<<<< @@ -63080,7 +70271,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ __pyx_t_10 = __pyx_t_11; goto __pyx_L9_bool_binop_done; } - __pyx_t_1 = __Pyx_PyObject_GetItem(__pyx_v_dict2, __pyx_v_key); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3379, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetItem(__pyx_v_dict2, __pyx_v_key); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3673, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_11 = PyDict_Check(__pyx_t_1); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -63089,16 +70280,16 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ __pyx_L9_bool_binop_done:; if (__pyx_t_10) { - /* "dependency_injector/providers.pyx":3380 + /* "dependency_injector/providers.pyx":3674 * if key in dict2: * if isinstance(value, dict) and isinstance(dict2[key], dict): * dict2[key] = merge_dicts(value, dict2[key]) # <<<<<<<<<<<<<< * result = dict1.copy() * result.update(dict2) */ - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3380, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_merge_dicts); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3674, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_3 = __Pyx_PyObject_GetItem(__pyx_v_dict2, __pyx_v_key); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3380, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetItem(__pyx_v_dict2, __pyx_v_key); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3674, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_7 = NULL; __pyx_t_12 = 0; @@ -63115,7 +70306,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_value, __pyx_t_3}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3380, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3674, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -63124,14 +70315,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_value, __pyx_t_3}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3380, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3674, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif { - __pyx_t_13 = PyTuple_New(2+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 3380, __pyx_L1_error) + __pyx_t_13 = PyTuple_New(2+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 3674, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -63142,15 +70333,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_13, 1+__pyx_t_12, __pyx_t_3); __pyx_t_3 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_13, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3380, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_13, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3674, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(PyObject_SetItem(__pyx_v_dict2, __pyx_v_key, __pyx_t_1) < 0)) __PYX_ERR(1, 3380, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_v_dict2, __pyx_v_key, __pyx_t_1) < 0)) __PYX_ERR(1, 3674, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3379 + /* "dependency_injector/providers.pyx":3673 * for key, value in dict1.items(): * if key in dict2: * if isinstance(value, dict) and isinstance(dict2[key], dict): # <<<<<<<<<<<<<< @@ -63159,7 +70350,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ */ } - /* "dependency_injector/providers.pyx":3378 + /* "dependency_injector/providers.pyx":3672 * """ * for key, value in dict1.items(): * if key in dict2: # <<<<<<<<<<<<<< @@ -63168,7 +70359,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ */ } - /* "dependency_injector/providers.pyx":3377 + /* "dependency_injector/providers.pyx":3671 * :rtype: dict * """ * for key, value in dict1.items(): # <<<<<<<<<<<<<< @@ -63178,14 +70369,14 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":3381 + /* "dependency_injector/providers.pyx":3675 * if isinstance(value, dict) and isinstance(dict2[key], dict): * dict2[key] = merge_dicts(value, dict2[key]) * result = dict1.copy() # <<<<<<<<<<<<<< * result.update(dict2) * return result */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_dict1, __pyx_n_s_copy); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3381, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_dict1, __pyx_n_s_copy); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3675, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -63199,19 +70390,20 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ } __pyx_t_2 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3381, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3675, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_result = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":3382 + /* "dependency_injector/providers.pyx":3676 * dict2[key] = merge_dicts(value, dict2[key]) * result = dict1.copy() * result.update(dict2) # <<<<<<<<<<<<<< * return result + * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_result, __pyx_n_s_update); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3382, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_result, __pyx_n_s_update); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3676, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -63225,22 +70417,24 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ } __pyx_t_2 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_6, __pyx_v_dict2) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_dict2); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3382, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3676, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pyx":3383 + /* "dependency_injector/providers.pyx":3677 * result = dict1.copy() * result.update(dict2) * return result # <<<<<<<<<<<<<< + * + * */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_result); __pyx_r = __pyx_v_result; goto __pyx_L0; - /* "dependency_injector/providers.pyx":3365 + /* "dependency_injector/providers.pyx":3659 * * * def merge_dicts(dict1, dict2): # <<<<<<<<<<<<<< @@ -63267,6 +70461,540 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ return __pyx_r; } +/* "dependency_injector/providers.pyx":3680 + * + * + * def isawaitable(obj): # <<<<<<<<<<<<<< + * """Check if object is a coroutine function. + * + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_25isawaitable(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_24isawaitable[] = "Check if object is a coroutine function.\n\n Return False for any object in Python 3.4 or below.\n "; +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_25isawaitable = {"isawaitable", (PyCFunction)__pyx_pw_19dependency_injector_9providers_25isawaitable, METH_O, __pyx_doc_19dependency_injector_9providers_24isawaitable}; +static PyObject *__pyx_pw_19dependency_injector_9providers_25isawaitable(PyObject *__pyx_self, PyObject *__pyx_v_obj) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("isawaitable (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_24isawaitable(__pyx_self, ((PyObject *)__pyx_v_obj)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_24isawaitable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("isawaitable", 0); + + /* "dependency_injector/providers.pyx":3685 + * Return False for any object in Python 3.4 or below. + * """ + * try: # <<<<<<<<<<<<<< + * return inspect.isawaitable(obj) + * except AttributeError: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); + __Pyx_XGOTREF(__pyx_t_1); + __Pyx_XGOTREF(__pyx_t_2); + __Pyx_XGOTREF(__pyx_t_3); + /*try:*/ { + + /* "dependency_injector/providers.pyx":3686 + * """ + * try: + * return inspect.isawaitable(obj) # <<<<<<<<<<<<<< + * except AttributeError: + * return False + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_inspect); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3686, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_isawaitable); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3686, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_6, function); + } + } + __pyx_t_4 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_5, __pyx_v_obj) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_obj); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3686, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_r = __pyx_t_4; + __pyx_t_4 = 0; + goto __pyx_L7_try_return; + + /* "dependency_injector/providers.pyx":3685 + * Return False for any object in Python 3.4 or below. + * """ + * try: # <<<<<<<<<<<<<< + * return inspect.isawaitable(obj) + * except AttributeError: + */ + } + __pyx_L3_error:; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + + /* "dependency_injector/providers.pyx":3687 + * try: + * return inspect.isawaitable(obj) + * except AttributeError: # <<<<<<<<<<<<<< + * return False + * + */ + __pyx_t_7 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_AttributeError); + if (__pyx_t_7) { + __Pyx_AddTraceback("dependency_injector.providers.isawaitable", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_5) < 0) __PYX_ERR(1, 3687, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_GOTREF(__pyx_t_6); + __Pyx_GOTREF(__pyx_t_5); + + /* "dependency_injector/providers.pyx":3688 + * return inspect.isawaitable(obj) + * except AttributeError: + * return False # <<<<<<<<<<<<<< + * + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(Py_False); + __pyx_r = Py_False; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + goto __pyx_L6_except_return; + } + goto __pyx_L5_except_error; + __pyx_L5_except_error:; + + /* "dependency_injector/providers.pyx":3685 + * Return False for any object in Python 3.4 or below. + * """ + * try: # <<<<<<<<<<<<<< + * return inspect.isawaitable(obj) + * except AttributeError: + */ + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L1_error; + __pyx_L7_try_return:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L0; + __pyx_L6_except_return:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L0; + } + + /* "dependency_injector/providers.pyx":3680 + * + * + * def isawaitable(obj): # <<<<<<<<<<<<<< + * """Check if object is a coroutine function. + * + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_AddTraceback("dependency_injector.providers.isawaitable", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":3691 + * + * + * def iscoroutinefunction(obj): # <<<<<<<<<<<<<< + * """Check if object is a coroutine function. + * + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_27iscoroutinefunction(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_26iscoroutinefunction[] = "Check if object is a coroutine function.\n\n Return False for any object in Python 3.4 or below.\n "; +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_27iscoroutinefunction = {"iscoroutinefunction", (PyCFunction)__pyx_pw_19dependency_injector_9providers_27iscoroutinefunction, METH_O, __pyx_doc_19dependency_injector_9providers_26iscoroutinefunction}; +static PyObject *__pyx_pw_19dependency_injector_9providers_27iscoroutinefunction(PyObject *__pyx_self, PyObject *__pyx_v_obj) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("iscoroutinefunction (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_26iscoroutinefunction(__pyx_self, ((PyObject *)__pyx_v_obj)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_26iscoroutinefunction(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("iscoroutinefunction", 0); + + /* "dependency_injector/providers.pyx":3696 + * Return False for any object in Python 3.4 or below. + * """ + * try: # <<<<<<<<<<<<<< + * return inspect.iscoroutinefunction(obj) + * except AttributeError: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); + __Pyx_XGOTREF(__pyx_t_1); + __Pyx_XGOTREF(__pyx_t_2); + __Pyx_XGOTREF(__pyx_t_3); + /*try:*/ { + + /* "dependency_injector/providers.pyx":3697 + * """ + * try: + * return inspect.iscoroutinefunction(obj) # <<<<<<<<<<<<<< + * except AttributeError: + * return False + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_inspect); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3697, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_iscoroutinefunction); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3697, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_6, function); + } + } + __pyx_t_4 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_5, __pyx_v_obj) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_obj); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3697, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_r = __pyx_t_4; + __pyx_t_4 = 0; + goto __pyx_L7_try_return; + + /* "dependency_injector/providers.pyx":3696 + * Return False for any object in Python 3.4 or below. + * """ + * try: # <<<<<<<<<<<<<< + * return inspect.iscoroutinefunction(obj) + * except AttributeError: + */ + } + __pyx_L3_error:; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + + /* "dependency_injector/providers.pyx":3698 + * try: + * return inspect.iscoroutinefunction(obj) + * except AttributeError: # <<<<<<<<<<<<<< + * return False + * + */ + __pyx_t_7 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_AttributeError); + if (__pyx_t_7) { + __Pyx_AddTraceback("dependency_injector.providers.iscoroutinefunction", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_5) < 0) __PYX_ERR(1, 3698, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_GOTREF(__pyx_t_6); + __Pyx_GOTREF(__pyx_t_5); + + /* "dependency_injector/providers.pyx":3699 + * return inspect.iscoroutinefunction(obj) + * except AttributeError: + * return False # <<<<<<<<<<<<<< + * + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(Py_False); + __pyx_r = Py_False; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + goto __pyx_L6_except_return; + } + goto __pyx_L5_except_error; + __pyx_L5_except_error:; + + /* "dependency_injector/providers.pyx":3696 + * Return False for any object in Python 3.4 or below. + * """ + * try: # <<<<<<<<<<<<<< + * return inspect.iscoroutinefunction(obj) + * except AttributeError: + */ + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L1_error; + __pyx_L7_try_return:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L0; + __pyx_L6_except_return:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L0; + } + + /* "dependency_injector/providers.pyx":3691 + * + * + * def iscoroutinefunction(obj): # <<<<<<<<<<<<<< + * """Check if object is a coroutine function. + * + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_AddTraceback("dependency_injector.providers.iscoroutinefunction", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pyx":3702 + * + * + * def isasyncgenfunction(obj): # <<<<<<<<<<<<<< + * """Check if object is an asynchronous generator function. + * + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_19dependency_injector_9providers_29isasyncgenfunction(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/ +static char __pyx_doc_19dependency_injector_9providers_28isasyncgenfunction[] = "Check if object is an asynchronous generator function.\n\n Return False for any object in Python 3.4 or below.\n "; +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_29isasyncgenfunction = {"isasyncgenfunction", (PyCFunction)__pyx_pw_19dependency_injector_9providers_29isasyncgenfunction, METH_O, __pyx_doc_19dependency_injector_9providers_28isasyncgenfunction}; +static PyObject *__pyx_pw_19dependency_injector_9providers_29isasyncgenfunction(PyObject *__pyx_self, PyObject *__pyx_v_obj) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("isasyncgenfunction (wrapper)", 0); + __pyx_r = __pyx_pf_19dependency_injector_9providers_28isasyncgenfunction(__pyx_self, ((PyObject *)__pyx_v_obj)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_19dependency_injector_9providers_28isasyncgenfunction(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) { + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("isasyncgenfunction", 0); + + /* "dependency_injector/providers.pyx":3707 + * Return False for any object in Python 3.4 or below. + * """ + * try: # <<<<<<<<<<<<<< + * return inspect.isasyncgenfunction(obj) + * except AttributeError: + */ + { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); + __Pyx_XGOTREF(__pyx_t_1); + __Pyx_XGOTREF(__pyx_t_2); + __Pyx_XGOTREF(__pyx_t_3); + /*try:*/ { + + /* "dependency_injector/providers.pyx":3708 + * """ + * try: + * return inspect.isasyncgenfunction(obj) # <<<<<<<<<<<<<< + * except AttributeError: + * return False + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_inspect); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 3708, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_isasyncgenfunction); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 3708, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_6, function); + } + } + __pyx_t_4 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_5, __pyx_v_obj) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_obj); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 3708, __pyx_L3_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_r = __pyx_t_4; + __pyx_t_4 = 0; + goto __pyx_L7_try_return; + + /* "dependency_injector/providers.pyx":3707 + * Return False for any object in Python 3.4 or below. + * """ + * try: # <<<<<<<<<<<<<< + * return inspect.isasyncgenfunction(obj) + * except AttributeError: + */ + } + __pyx_L3_error:; + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + + /* "dependency_injector/providers.pyx":3709 + * try: + * return inspect.isasyncgenfunction(obj) + * except AttributeError: # <<<<<<<<<<<<<< + * return False + */ + __pyx_t_7 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_AttributeError); + if (__pyx_t_7) { + __Pyx_AddTraceback("dependency_injector.providers.isasyncgenfunction", __pyx_clineno, __pyx_lineno, __pyx_filename); + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_5) < 0) __PYX_ERR(1, 3709, __pyx_L5_except_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_GOTREF(__pyx_t_6); + __Pyx_GOTREF(__pyx_t_5); + + /* "dependency_injector/providers.pyx":3710 + * return inspect.isasyncgenfunction(obj) + * except AttributeError: + * return False # <<<<<<<<<<<<<< + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(Py_False); + __pyx_r = Py_False; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + goto __pyx_L6_except_return; + } + goto __pyx_L5_except_error; + __pyx_L5_except_error:; + + /* "dependency_injector/providers.pyx":3707 + * Return False for any object in Python 3.4 or below. + * """ + * try: # <<<<<<<<<<<<<< + * return inspect.isasyncgenfunction(obj) + * except AttributeError: + */ + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L1_error; + __pyx_L7_try_return:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L0; + __pyx_L6_except_return:; + __Pyx_XGIVEREF(__pyx_t_1); + __Pyx_XGIVEREF(__pyx_t_2); + __Pyx_XGIVEREF(__pyx_t_3); + __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); + goto __pyx_L0; + } + + /* "dependency_injector/providers.pyx":3702 + * + * + * def isasyncgenfunction(obj): # <<<<<<<<<<<<<< + * """Check if object is an asynchronous generator function. + * + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_AddTraceback("dependency_injector.providers.isasyncgenfunction", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + /* "(tree fragment)":1 * def __pyx_unpickle_Provider(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError @@ -63274,9 +71002,9 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_22merge_dicts(CYTHON_ */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_26__pyx_unpickle_Provider(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_26__pyx_unpickle_Provider = {"__pyx_unpickle_Provider", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_26__pyx_unpickle_Provider, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_26__pyx_unpickle_Provider(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_32__pyx_unpickle_Provider(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_32__pyx_unpickle_Provider = {"__pyx_unpickle_Provider", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_32__pyx_unpickle_Provider, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_32__pyx_unpickle_Provider(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -63342,14 +71070,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_26__pyx_unpickle_Prov __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_25__pyx_unpickle_Provider(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Provider(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_25__pyx_unpickle_Provider(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Provider(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -63368,18 +71096,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_25__pyx_unpickle_Prov /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x0f5c5dd: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xfeb8198: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0f5c5dd = (__last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfeb8198 = (__async_mode, __last_overriding, __overridden))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x0f5c5dd) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xfeb8198) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x0f5c5dd: + * if __pyx_checksum != 0xfeb8198: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0f5c5dd = (__last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfeb8198 = (__async_mode, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Provider.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -63398,15 +71126,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_25__pyx_unpickle_Prov __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x0f5c5dd: + * if __pyx_checksum != 0xfeb8198: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0f5c5dd = (__last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfeb8198 = (__async_mode, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Provider.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x0f, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xfe, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -63433,15 +71161,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_25__pyx_unpickle_Prov /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x0f5c5dd: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xfeb8198: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0f5c5dd = (__last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfeb8198 = (__async_mode, __last_overriding, __overridden))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0f5c5dd = (__last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfeb8198 = (__async_mode, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Provider.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Provider__set_state( __pyx_result, __pyx_state) @@ -63467,7 +71195,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_25__pyx_unpickle_Prov __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0f5c5dd = (__last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfeb8198 = (__async_mode, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Provider.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Provider__set_state( __pyx_result, __pyx_state) @@ -63490,7 +71218,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_25__pyx_unpickle_Prov __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0f5c5dd = (__last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfeb8198 = (__async_mode, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Provider.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Provider__set_state( __pyx_result, __pyx_state) @@ -63503,7 +71231,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_25__pyx_unpickle_Prov * __pyx_unpickle_Provider__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Provider__set_state(Provider __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -63536,8 +71264,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_25__pyx_unpickle_Prov * __pyx_unpickle_Provider__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Provider__set_state(Provider __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1] - * if len(__pyx_state) > 2 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provider__set_state(struct __pyx_obj_19dependency_injector_9providers_Provider *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -63545,12 +71273,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -63559,9 +71288,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Provider__set_state(Provider __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 2 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[2]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[3]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -63569,6 +71298,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___last_overriding); @@ -63579,7 +71317,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -63590,66 +71328,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide /* "(tree fragment)":13 * cdef __pyx_unpickle_Provider__set_state(Provider __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1] - * if len(__pyx_state) > 2 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[2]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[3]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 2) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 3) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1] - * if len(__pyx_state) > 2 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[2]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_Provider__set_state(Provider __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1] - * if len(__pyx_state) > 2 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[2]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[3]) */ } @@ -63657,8 +71395,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide * __pyx_unpickle_Provider__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Provider__set_state(Provider __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1] - * if len(__pyx_state) > 2 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -63666,9 +71404,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_Provider__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -63684,9 +71422,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_28__pyx_unpickle_Object(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_28__pyx_unpickle_Object = {"__pyx_unpickle_Object", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_28__pyx_unpickle_Object, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_28__pyx_unpickle_Object(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_34__pyx_unpickle_Object(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_34__pyx_unpickle_Object = {"__pyx_unpickle_Object", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_34__pyx_unpickle_Object, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_34__pyx_unpickle_Object(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -63752,14 +71490,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_28__pyx_unpickle_Obje __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_27__pyx_unpickle_Object(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_Object(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_27__pyx_unpickle_Object(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_Object(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -63778,18 +71516,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_27__pyx_unpickle_Obje /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3f4a3b6) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x328787b) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Object.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -63808,15 +71546,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_27__pyx_unpickle_Obje __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Object.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3f, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x32, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -63843,15 +71581,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_27__pyx_unpickle_Obje /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Object.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Object__set_state( __pyx_result, __pyx_state) @@ -63877,7 +71615,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_27__pyx_unpickle_Obje __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Object.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Object__set_state( __pyx_result, __pyx_state) @@ -63900,7 +71638,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_27__pyx_unpickle_Obje __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Object.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Object__set_state( __pyx_result, __pyx_state) @@ -63913,7 +71651,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_27__pyx_unpickle_Obje * __pyx_unpickle_Object__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Object__set_state(Object __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -63946,8 +71684,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_27__pyx_unpickle_Obje * __pyx_unpickle_Object__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Object__set_state(Object __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object__set_state(struct __pyx_obj_19dependency_injector_9providers_Object *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -63955,12 +71693,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object_ __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -63969,9 +71708,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object_ /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Object__set_state(Object __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -63979,6 +71718,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object_ } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___last_overriding); @@ -63989,7 +71737,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object_ PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -64001,7 +71749,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object_ PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___provides); @@ -64011,66 +71759,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object_ /* "(tree fragment)":13 * cdef __pyx_unpickle_Object__set_state(Object __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_Object__set_state(Object __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ } @@ -64078,8 +71826,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object_ * __pyx_unpickle_Object__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Object__set_state(Object __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -64087,9 +71835,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object_ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_Object__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -64105,9 +71853,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Object_ */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_30__pyx_unpickle_Delegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_30__pyx_unpickle_Delegate = {"__pyx_unpickle_Delegate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_30__pyx_unpickle_Delegate, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_30__pyx_unpickle_Delegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_36__pyx_unpickle_Delegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_36__pyx_unpickle_Delegate = {"__pyx_unpickle_Delegate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_36__pyx_unpickle_Delegate, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_36__pyx_unpickle_Delegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -64173,14 +71921,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_30__pyx_unpickle_Dele __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_29__pyx_unpickle_Delegate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_Delegate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_29__pyx_unpickle_Delegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_Delegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -64199,18 +71947,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3f4a3b6) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x328787b) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Delegate.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -64229,15 +71977,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Delegate.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3f, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x32, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -64264,15 +72012,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Delegate.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Delegate__set_state( __pyx_result, __pyx_state) @@ -64298,7 +72046,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29__pyx_unpickle_Dele __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Delegate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Delegate__set_state( __pyx_result, __pyx_state) @@ -64321,7 +72069,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Delegate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Delegate__set_state( __pyx_result, __pyx_state) @@ -64334,7 +72082,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29__pyx_unpickle_Dele * __pyx_unpickle_Delegate__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Delegate__set_state(Delegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -64367,8 +72115,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_29__pyx_unpickle_Dele * __pyx_unpickle_Delegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Delegate__set_state(Delegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegate__set_state(struct __pyx_obj_19dependency_injector_9providers_Delegate *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -64376,12 +72124,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -64390,9 +72139,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Delegate__set_state(Delegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -64400,6 +72149,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___last_overriding); @@ -64410,7 +72168,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -64422,7 +72180,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___provides); @@ -64432,66 +72190,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":13 * cdef __pyx_unpickle_Delegate__set_state(Delegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_Delegate__set_state(Delegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ } @@ -64499,8 +72257,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat * __pyx_unpickle_Delegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Delegate__set_state(Delegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -64508,9 +72266,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_Delegate__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -64526,9 +72284,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_32__pyx_unpickle_Dependency(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_32__pyx_unpickle_Dependency = {"__pyx_unpickle_Dependency", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_32__pyx_unpickle_Dependency, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_32__pyx_unpickle_Dependency(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_38__pyx_unpickle_Dependency(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_38__pyx_unpickle_Dependency = {"__pyx_unpickle_Dependency", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_38__pyx_unpickle_Dependency, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_38__pyx_unpickle_Dependency(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -64594,14 +72352,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_32__pyx_unpickle_Depe __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Dependency(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_37__pyx_unpickle_Dependency(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Dependency(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_37__pyx_unpickle_Dependency(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -64620,18 +72378,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Depe /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xf1f5217: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xd55614d: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xf1f5217) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xd55614d) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xf1f5217: + * if __pyx_checksum != 0xd55614d: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Dependency.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -64650,15 +72408,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Depe __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xf1f5217: + * if __pyx_checksum != 0xd55614d: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Dependency.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xf1, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xd5, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -64685,15 +72443,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Depe /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xf1f5217: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xd55614d: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Dependency.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Dependency__set_state( __pyx_result, __pyx_state) @@ -64719,7 +72477,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Depe __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Dependency.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Dependency__set_state( __pyx_result, __pyx_state) @@ -64742,7 +72500,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Depe __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Dependency.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Dependency__set_state( __pyx_result, __pyx_state) @@ -64755,7 +72513,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Depe * __pyx_unpickle_Dependency__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Dependency__set_state(Dependency __pyx_result, tuple __pyx_state): - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -64788,8 +72546,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_31__pyx_unpickle_Depe * __pyx_unpickle_Dependency__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Dependency__set_state(Dependency __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dependency__set_state(struct __pyx_obj_19dependency_injector_9providers_Dependency *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -64797,12 +72555,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -64811,9 +72570,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Dependency__set_state(Dependency __pyx_result, tuple __pyx_state): - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -64821,6 +72580,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___instance_of); __Pyx_DECREF(__pyx_v___pyx_result->__pyx___instance_of); @@ -64830,7 +72598,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -64842,7 +72610,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -64853,66 +72621,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende /* "(tree fragment)":13 * cdef __pyx_unpickle_Dependency__set_state(Dependency __pyx_result, tuple __pyx_state): - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_Dependency__set_state(Dependency __pyx_result, tuple __pyx_state): - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ } @@ -64920,8 +72688,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende * __pyx_unpickle_Dependency__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Dependency__set_state(Dependency __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -64929,9 +72697,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_Dependency__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -64947,9 +72715,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_34__pyx_unpickle_ExternalDependency(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_34__pyx_unpickle_ExternalDependency = {"__pyx_unpickle_ExternalDependency", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_34__pyx_unpickle_ExternalDependency, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_34__pyx_unpickle_ExternalDependency(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_40__pyx_unpickle_ExternalDependency(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_40__pyx_unpickle_ExternalDependency = {"__pyx_unpickle_ExternalDependency", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_40__pyx_unpickle_ExternalDependency, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_40__pyx_unpickle_ExternalDependency(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -65015,14 +72783,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_34__pyx_unpickle_Exte __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_ExternalDependency(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_ExternalDependency(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_ExternalDependency(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_ExternalDependency(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -65041,18 +72809,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_Exte /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xf1f5217: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xd55614d: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xf1f5217) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xd55614d) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xf1f5217: + * if __pyx_checksum != 0xd55614d: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = ExternalDependency.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -65071,15 +72839,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_Exte __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xf1f5217: + * if __pyx_checksum != 0xd55614d: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = ExternalDependency.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xf1, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xd5, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -65106,15 +72874,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_Exte /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xf1f5217: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xd55614d: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = ExternalDependency.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_ExternalDependency__set_state( __pyx_result, __pyx_state) @@ -65140,7 +72908,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_Exte __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = ExternalDependency.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ExternalDependency__set_state( __pyx_result, __pyx_state) @@ -65163,7 +72931,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_Exte __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xf1f5217 = (__instance_of, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd55614d = (__async_mode, __instance_of, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = ExternalDependency.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ExternalDependency__set_state( __pyx_result, __pyx_state) @@ -65176,7 +72944,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_Exte * __pyx_unpickle_ExternalDependency__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_ExternalDependency__set_state(ExternalDependency __pyx_result, tuple __pyx_state): - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -65209,8 +72977,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_33__pyx_unpickle_Exte * __pyx_unpickle_ExternalDependency__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ExternalDependency__set_state(ExternalDependency __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ExternalDependency__set_state(struct __pyx_obj_19dependency_injector_9providers_ExternalDependency *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -65218,12 +72986,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Externa __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -65232,9 +73001,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Externa /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_ExternalDependency__set_state(ExternalDependency __pyx_result, tuple __pyx_state): - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -65242,6 +73011,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Externa } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___instance_of); __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx___instance_of); @@ -65251,7 +73029,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Externa PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -65263,7 +73041,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Externa PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -65274,66 +73052,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Externa /* "(tree fragment)":13 * cdef __pyx_unpickle_ExternalDependency__set_state(ExternalDependency __pyx_result, tuple __pyx_state): - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_ExternalDependency__set_state(ExternalDependency __pyx_result, tuple __pyx_state): - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ } @@ -65341,8 +73119,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Externa * __pyx_unpickle_ExternalDependency__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ExternalDependency__set_state(ExternalDependency __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -65350,9 +73128,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Externa goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_ExternalDependency__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -65368,9 +73146,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Externa */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_36__pyx_unpickle_DependenciesContainer(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_36__pyx_unpickle_DependenciesContainer = {"__pyx_unpickle_DependenciesContainer", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_36__pyx_unpickle_DependenciesContainer, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_36__pyx_unpickle_DependenciesContainer(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_42__pyx_unpickle_DependenciesContainer(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_42__pyx_unpickle_DependenciesContainer = {"__pyx_unpickle_DependenciesContainer", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_42__pyx_unpickle_DependenciesContainer, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_42__pyx_unpickle_DependenciesContainer(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -65436,14 +73214,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_36__pyx_unpickle_Depe __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_DependenciesContainer(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_DependenciesContainer(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_DependenciesContainer(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_DependenciesContainer(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -65462,18 +73240,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_Depe /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xd8553c7: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x1cf9f6d: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd8553c7 = (__last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1cf9f6d = (__async_mode, __last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xd8553c7) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x1cf9f6d) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xd8553c7: + * if __pyx_checksum != 0x1cf9f6d: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd8553c7 = (__last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1cf9f6d = (__async_mode, __last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) * __pyx_result = DependenciesContainer.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -65492,15 +73270,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_Depe __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xd8553c7: + * if __pyx_checksum != 0x1cf9f6d: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd8553c7 = (__last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1cf9f6d = (__async_mode, __last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = DependenciesContainer.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xd8, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x1c, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -65527,15 +73305,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_Depe /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xd8553c7: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x1cf9f6d: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd8553c7 = (__last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1cf9f6d = (__async_mode, __last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd8553c7 = (__last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1cf9f6d = (__async_mode, __last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) * __pyx_result = DependenciesContainer.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_DependenciesContainer__set_state( __pyx_result, __pyx_state) @@ -65561,7 +73339,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_Depe __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd8553c7 = (__last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1cf9f6d = (__async_mode, __last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) * __pyx_result = DependenciesContainer.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DependenciesContainer__set_state( __pyx_result, __pyx_state) @@ -65584,7 +73362,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_Depe __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xd8553c7 = (__last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1cf9f6d = (__async_mode, __last_overriding, __overridden, __providers, __provides))" % __pyx_checksum) * __pyx_result = DependenciesContainer.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DependenciesContainer__set_state( __pyx_result, __pyx_state) @@ -65597,7 +73375,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_Depe * __pyx_unpickle_DependenciesContainer__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_DependenciesContainer__set_state(DependenciesContainer __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -65630,8 +73408,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_35__pyx_unpickle_Depe * __pyx_unpickle_DependenciesContainer__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DependenciesContainer__set_state(DependenciesContainer __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_DependenciesContainer__set_state(struct __pyx_obj_19dependency_injector_9providers_DependenciesContainer *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -65639,12 +73417,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -65653,9 +73432,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_DependenciesContainer__set_state(DependenciesContainer __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -65663,6 +73442,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___last_overriding); @@ -65673,7 +73461,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -65685,7 +73473,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -65697,7 +73485,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___provides); @@ -65707,66 +73495,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende /* "(tree fragment)":13 * cdef __pyx_unpickle_DependenciesContainer__set_state(DependenciesContainer __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 4) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_DependenciesContainer__set_state(DependenciesContainer __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -65774,8 +73562,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende * __pyx_unpickle_DependenciesContainer__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DependenciesContainer__set_state(DependenciesContainer __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -65783,9 +73571,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_DependenciesContainer__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -65801,9 +73589,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Depende */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_38__pyx_unpickle_OverridingContext(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_38__pyx_unpickle_OverridingContext = {"__pyx_unpickle_OverridingContext", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_38__pyx_unpickle_OverridingContext, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_38__pyx_unpickle_OverridingContext(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_44__pyx_unpickle_OverridingContext(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_44__pyx_unpickle_OverridingContext = {"__pyx_unpickle_OverridingContext", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_44__pyx_unpickle_OverridingContext, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_44__pyx_unpickle_OverridingContext(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -65869,14 +73657,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_38__pyx_unpickle_Over __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_37__pyx_unpickle_OverridingContext(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_OverridingContext(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_37__pyx_unpickle_OverridingContext(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_OverridingContext(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -66211,9 +73999,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Overrid */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_40__pyx_unpickle_Callable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_40__pyx_unpickle_Callable = {"__pyx_unpickle_Callable", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_40__pyx_unpickle_Callable, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_40__pyx_unpickle_Callable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_46__pyx_unpickle_Callable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_46__pyx_unpickle_Callable = {"__pyx_unpickle_Callable", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_46__pyx_unpickle_Callable, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_46__pyx_unpickle_Callable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -66279,14 +74067,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_40__pyx_unpickle_Call __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_Callable(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_Callable(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_Callable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_Callable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -66305,18 +74093,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_Call /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x03251dc) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3e02ba6) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Callable.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -66335,15 +74123,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_Call __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Callable.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x03, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3e, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -66370,15 +74158,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_Call /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Callable.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Callable__set_state( __pyx_result, __pyx_state) @@ -66404,7 +74192,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_Call __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Callable.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Callable__set_state( __pyx_result, __pyx_state) @@ -66427,7 +74215,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_Call __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Callable.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Callable__set_state( __pyx_result, __pyx_state) @@ -66440,7 +74228,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_Call * __pyx_unpickle_Callable__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Callable__set_state(Callable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -66473,8 +74261,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_39__pyx_unpickle_Call * __pyx_unpickle_Callable__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Callable__set_state(Callable __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callable__set_state(struct __pyx_obj_19dependency_injector_9providers_Callable *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -66497,9 +74285,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Callable__set_state(Callable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -66528,6 +74316,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___kwargs); @@ -66538,7 +74335,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -66547,7 +74344,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -66559,7 +74356,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -66571,7 +74368,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___provides); @@ -66581,16 +74378,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl /* "(tree fragment)":13 * cdef __pyx_unpickle_Callable__set_state(Callable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 7) != 0); + __pyx_t_5 = ((__pyx_t_4 > 8) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -66603,9 +74400,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) # <<<<<<<<<<<<<< + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -66616,7 +74413,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -66638,9 +74435,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl /* "(tree fragment)":13 * cdef __pyx_unpickle_Callable__set_state(Callable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ } @@ -66648,8 +74445,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl * __pyx_unpickle_Callable__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Callable__set_state(Callable __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -66675,9 +74472,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_42__pyx_unpickle_DelegatedCallable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_42__pyx_unpickle_DelegatedCallable = {"__pyx_unpickle_DelegatedCallable", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_42__pyx_unpickle_DelegatedCallable, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_42__pyx_unpickle_DelegatedCallable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_48__pyx_unpickle_DelegatedCallable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_48__pyx_unpickle_DelegatedCallable = {"__pyx_unpickle_DelegatedCallable", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_48__pyx_unpickle_DelegatedCallable, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_48__pyx_unpickle_DelegatedCallable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -66743,14 +74540,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_42__pyx_unpickle_Dele __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_DelegatedCallable(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_DelegatedCallable(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_DelegatedCallable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_DelegatedCallable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -66769,18 +74566,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x03251dc) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3e02ba6) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = DelegatedCallable.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -66799,15 +74596,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = DelegatedCallable.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x03, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3e, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -66834,15 +74631,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = DelegatedCallable.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_DelegatedCallable__set_state( __pyx_result, __pyx_state) @@ -66868,7 +74665,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_Dele __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = DelegatedCallable.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedCallable__set_state( __pyx_result, __pyx_state) @@ -66891,7 +74688,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = DelegatedCallable.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedCallable__set_state( __pyx_result, __pyx_state) @@ -66904,7 +74701,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_Dele * __pyx_unpickle_DelegatedCallable__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_DelegatedCallable__set_state(DelegatedCallable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -66937,8 +74734,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_41__pyx_unpickle_Dele * __pyx_unpickle_DelegatedCallable__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedCallable__set_state(DelegatedCallable __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_DelegatedCallable__set_state(struct __pyx_obj_19dependency_injector_9providers_DelegatedCallable *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -66961,9 +74758,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_DelegatedCallable__set_state(DelegatedCallable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -66992,6 +74789,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___kwargs); @@ -67002,7 +74808,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -67011,7 +74817,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -67023,7 +74829,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -67035,7 +74841,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___provides); @@ -67045,16 +74851,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedCallable__set_state(DelegatedCallable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 7) != 0); + __pyx_t_5 = ((__pyx_t_4 > 8) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -67067,9 +74873,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) # <<<<<<<<<<<<<< + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -67080,7 +74886,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -67102,9 +74908,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedCallable__set_state(DelegatedCallable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ } @@ -67112,8 +74918,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat * __pyx_unpickle_DelegatedCallable__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedCallable__set_state(DelegatedCallable __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -67139,9 +74945,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_44__pyx_unpickle_AbstractCallable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_44__pyx_unpickle_AbstractCallable = {"__pyx_unpickle_AbstractCallable", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_44__pyx_unpickle_AbstractCallable, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_44__pyx_unpickle_AbstractCallable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_50__pyx_unpickle_AbstractCallable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_50__pyx_unpickle_AbstractCallable = {"__pyx_unpickle_AbstractCallable", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_50__pyx_unpickle_AbstractCallable, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_50__pyx_unpickle_AbstractCallable(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -67207,14 +75013,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_44__pyx_unpickle_Abst __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_AbstractCallable(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_AbstractCallable(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_AbstractCallable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_AbstractCallable(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -67233,18 +75039,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_Abst /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x03251dc) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3e02ba6) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = AbstractCallable.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -67263,15 +75069,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_Abst __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = AbstractCallable.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x03, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3e, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -67298,15 +75104,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_Abst /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = AbstractCallable.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_AbstractCallable__set_state( __pyx_result, __pyx_state) @@ -67332,7 +75138,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_Abst __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = AbstractCallable.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractCallable__set_state( __pyx_result, __pyx_state) @@ -67355,7 +75161,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_Abst __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = AbstractCallable.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractCallable__set_state( __pyx_result, __pyx_state) @@ -67368,7 +75174,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_Abst * __pyx_unpickle_AbstractCallable__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_AbstractCallable__set_state(AbstractCallable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -67401,8 +75207,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_43__pyx_unpickle_Abst * __pyx_unpickle_AbstractCallable__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AbstractCallable__set_state(AbstractCallable __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_AbstractCallable__set_state(struct __pyx_obj_19dependency_injector_9providers_AbstractCallable *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -67425,9 +75231,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_AbstractCallable__set_state(AbstractCallable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -67456,6 +75262,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___kwargs); @@ -67466,7 +75281,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -67475,7 +75290,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -67487,7 +75302,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -67499,7 +75314,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___provides); @@ -67509,16 +75324,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac /* "(tree fragment)":13 * cdef __pyx_unpickle_AbstractCallable__set_state(AbstractCallable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 7) != 0); + __pyx_t_5 = ((__pyx_t_4 > 8) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -67531,9 +75346,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) # <<<<<<<<<<<<<< + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -67544,7 +75359,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -67566,9 +75381,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac /* "(tree fragment)":13 * cdef __pyx_unpickle_AbstractCallable__set_state(AbstractCallable __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ } @@ -67576,8 +75391,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac * __pyx_unpickle_AbstractCallable__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AbstractCallable__set_state(AbstractCallable __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -67603,9 +75418,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_46__pyx_unpickle_CallableDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_46__pyx_unpickle_CallableDelegate = {"__pyx_unpickle_CallableDelegate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_46__pyx_unpickle_CallableDelegate, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_46__pyx_unpickle_CallableDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_52__pyx_unpickle_CallableDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_52__pyx_unpickle_CallableDelegate = {"__pyx_unpickle_CallableDelegate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_52__pyx_unpickle_CallableDelegate, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_52__pyx_unpickle_CallableDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -67671,14 +75486,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_46__pyx_unpickle_Call __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_CallableDelegate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_CallableDelegate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_CallableDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_CallableDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -67697,18 +75512,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_Call /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3f4a3b6) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x328787b) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = CallableDelegate.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -67727,15 +75542,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_Call __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = CallableDelegate.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3f, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x32, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -67762,15 +75577,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_Call /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = CallableDelegate.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_CallableDelegate__set_state( __pyx_result, __pyx_state) @@ -67796,7 +75611,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_Call __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = CallableDelegate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_CallableDelegate__set_state( __pyx_result, __pyx_state) @@ -67819,7 +75634,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_Call __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = CallableDelegate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_CallableDelegate__set_state( __pyx_result, __pyx_state) @@ -67832,7 +75647,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_Call * __pyx_unpickle_CallableDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_CallableDelegate__set_state(CallableDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -67865,8 +75680,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_45__pyx_unpickle_Call * __pyx_unpickle_CallableDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_CallableDelegate__set_state(CallableDelegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_CallableDelegate__set_state(struct __pyx_obj_19dependency_injector_9providers_CallableDelegate *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -67874,12 +75689,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -67888,9 +75704,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_CallableDelegate__set_state(CallableDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -67898,6 +75714,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___last_overriding); @@ -67908,7 +75733,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -67920,7 +75745,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___provides); @@ -67930,66 +75755,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl /* "(tree fragment)":13 * cdef __pyx_unpickle_CallableDelegate__set_state(CallableDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_CallableDelegate__set_state(CallableDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ } @@ -67997,8 +75822,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl * __pyx_unpickle_CallableDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_CallableDelegate__set_state(CallableDelegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -68006,9 +75831,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_CallableDelegate__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -68024,9 +75849,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Callabl */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_48__pyx_unpickle_Coroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_48__pyx_unpickle_Coroutine = {"__pyx_unpickle_Coroutine", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_48__pyx_unpickle_Coroutine, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_48__pyx_unpickle_Coroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_54__pyx_unpickle_Coroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_54__pyx_unpickle_Coroutine = {"__pyx_unpickle_Coroutine", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_54__pyx_unpickle_Coroutine, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_54__pyx_unpickle_Coroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -68092,14 +75917,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_48__pyx_unpickle_Coro __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_Coroutine(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_Coroutine(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_Coroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_Coroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -68118,18 +75943,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_Coro /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x03251dc) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3e02ba6) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Coroutine.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -68148,15 +75973,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_Coro __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Coroutine.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x03, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3e, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -68183,15 +76008,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_Coro /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Coroutine.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Coroutine__set_state( __pyx_result, __pyx_state) @@ -68217,7 +76042,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_Coro __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Coroutine.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Coroutine__set_state( __pyx_result, __pyx_state) @@ -68240,7 +76065,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_Coro __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Coroutine.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Coroutine__set_state( __pyx_result, __pyx_state) @@ -68253,7 +76078,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_Coro * __pyx_unpickle_Coroutine__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Coroutine__set_state(Coroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -68286,8 +76111,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_47__pyx_unpickle_Coro * __pyx_unpickle_Coroutine__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Coroutine__set_state(Coroutine __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Coroutine__set_state(struct __pyx_obj_19dependency_injector_9providers_Coroutine *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -68310,9 +76135,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Coroutine__set_state(Coroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -68341,6 +76166,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___kwargs); @@ -68351,7 +76185,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -68360,7 +76194,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -68372,7 +76206,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -68384,7 +76218,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___provides); @@ -68394,16 +76228,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti /* "(tree fragment)":13 * cdef __pyx_unpickle_Coroutine__set_state(Coroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 7) != 0); + __pyx_t_5 = ((__pyx_t_4 > 8) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -68416,9 +76250,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) # <<<<<<<<<<<<<< + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -68429,7 +76263,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -68451,9 +76285,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti /* "(tree fragment)":13 * cdef __pyx_unpickle_Coroutine__set_state(Coroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ } @@ -68461,8 +76295,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti * __pyx_unpickle_Coroutine__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Coroutine__set_state(Coroutine __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -68488,9 +76322,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_50__pyx_unpickle_DelegatedCoroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_50__pyx_unpickle_DelegatedCoroutine = {"__pyx_unpickle_DelegatedCoroutine", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_50__pyx_unpickle_DelegatedCoroutine, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_50__pyx_unpickle_DelegatedCoroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_56__pyx_unpickle_DelegatedCoroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_56__pyx_unpickle_DelegatedCoroutine = {"__pyx_unpickle_DelegatedCoroutine", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_56__pyx_unpickle_DelegatedCoroutine, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_56__pyx_unpickle_DelegatedCoroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -68556,14 +76390,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_50__pyx_unpickle_Dele __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_DelegatedCoroutine(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_DelegatedCoroutine(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_DelegatedCoroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_DelegatedCoroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -68582,18 +76416,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x03251dc) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3e02ba6) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = DelegatedCoroutine.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -68612,15 +76446,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = DelegatedCoroutine.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x03, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3e, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -68647,15 +76481,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = DelegatedCoroutine.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_DelegatedCoroutine__set_state( __pyx_result, __pyx_state) @@ -68681,7 +76515,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_Dele __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = DelegatedCoroutine.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedCoroutine__set_state( __pyx_result, __pyx_state) @@ -68704,7 +76538,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = DelegatedCoroutine.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedCoroutine__set_state( __pyx_result, __pyx_state) @@ -68717,7 +76551,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_Dele * __pyx_unpickle_DelegatedCoroutine__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_DelegatedCoroutine__set_state(DelegatedCoroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -68750,8 +76584,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_49__pyx_unpickle_Dele * __pyx_unpickle_DelegatedCoroutine__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedCoroutine__set_state(DelegatedCoroutine __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_DelegatedCoroutine__set_state(struct __pyx_obj_19dependency_injector_9providers_DelegatedCoroutine *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -68774,9 +76608,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_DelegatedCoroutine__set_state(DelegatedCoroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -68805,6 +76639,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___kwargs); @@ -68815,7 +76658,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -68824,7 +76667,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -68836,7 +76679,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -68848,7 +76691,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___provides); @@ -68858,16 +76701,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedCoroutine__set_state(DelegatedCoroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 7) != 0); + __pyx_t_5 = ((__pyx_t_4 > 8) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -68880,9 +76723,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) # <<<<<<<<<<<<<< + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -68893,7 +76736,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -68915,9 +76758,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedCoroutine__set_state(DelegatedCoroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ } @@ -68925,8 +76768,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat * __pyx_unpickle_DelegatedCoroutine__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedCoroutine__set_state(DelegatedCoroutine __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -68952,9 +76795,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_52__pyx_unpickle_AbstractCoroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_52__pyx_unpickle_AbstractCoroutine = {"__pyx_unpickle_AbstractCoroutine", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_52__pyx_unpickle_AbstractCoroutine, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_52__pyx_unpickle_AbstractCoroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_58__pyx_unpickle_AbstractCoroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_58__pyx_unpickle_AbstractCoroutine = {"__pyx_unpickle_AbstractCoroutine", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_58__pyx_unpickle_AbstractCoroutine, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_58__pyx_unpickle_AbstractCoroutine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -69020,14 +76863,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_52__pyx_unpickle_Abst __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_AbstractCoroutine(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_AbstractCoroutine(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_AbstractCoroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_AbstractCoroutine(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -69046,18 +76889,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_Abst /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x03251dc) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3e02ba6) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = AbstractCoroutine.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -69076,15 +76919,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_Abst __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = AbstractCoroutine.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x03, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3e, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -69111,15 +76954,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_Abst /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = AbstractCoroutine.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_AbstractCoroutine__set_state( __pyx_result, __pyx_state) @@ -69145,7 +76988,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_Abst __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = AbstractCoroutine.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractCoroutine__set_state( __pyx_result, __pyx_state) @@ -69168,7 +77011,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_Abst __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = AbstractCoroutine.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractCoroutine__set_state( __pyx_result, __pyx_state) @@ -69181,7 +77024,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_Abst * __pyx_unpickle_AbstractCoroutine__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_AbstractCoroutine__set_state(AbstractCoroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -69214,8 +77057,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_51__pyx_unpickle_Abst * __pyx_unpickle_AbstractCoroutine__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AbstractCoroutine__set_state(AbstractCoroutine __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_AbstractCoroutine__set_state(struct __pyx_obj_19dependency_injector_9providers_AbstractCoroutine *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -69238,9 +77081,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_AbstractCoroutine__set_state(AbstractCoroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -69269,6 +77112,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___kwargs); @@ -69279,7 +77131,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -69288,7 +77140,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -69300,7 +77152,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -69312,7 +77164,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___provides); @@ -69322,16 +77174,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac /* "(tree fragment)":13 * cdef __pyx_unpickle_AbstractCoroutine__set_state(AbstractCoroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 7) != 0); + __pyx_t_5 = ((__pyx_t_4 > 8) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -69344,9 +77196,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) # <<<<<<<<<<<<<< + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -69357,7 +77209,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -69379,9 +77231,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac /* "(tree fragment)":13 * cdef __pyx_unpickle_AbstractCoroutine__set_state(AbstractCoroutine __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ } @@ -69389,8 +77241,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac * __pyx_unpickle_AbstractCoroutine__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AbstractCoroutine__set_state(AbstractCoroutine __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -69416,9 +77268,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_54__pyx_unpickle_CoroutineDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_54__pyx_unpickle_CoroutineDelegate = {"__pyx_unpickle_CoroutineDelegate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_54__pyx_unpickle_CoroutineDelegate, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_54__pyx_unpickle_CoroutineDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_60__pyx_unpickle_CoroutineDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_60__pyx_unpickle_CoroutineDelegate = {"__pyx_unpickle_CoroutineDelegate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_60__pyx_unpickle_CoroutineDelegate, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_60__pyx_unpickle_CoroutineDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -69484,14 +77336,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_54__pyx_unpickle_Coro __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_CoroutineDelegate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_CoroutineDelegate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_CoroutineDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_CoroutineDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -69510,18 +77362,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_Coro /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3f4a3b6) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x328787b) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = CoroutineDelegate.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -69540,15 +77392,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_Coro __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = CoroutineDelegate.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3f, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x32, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -69575,15 +77427,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_Coro /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = CoroutineDelegate.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_CoroutineDelegate__set_state( __pyx_result, __pyx_state) @@ -69609,7 +77461,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_Coro __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = CoroutineDelegate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_CoroutineDelegate__set_state( __pyx_result, __pyx_state) @@ -69632,7 +77484,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_Coro __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = CoroutineDelegate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_CoroutineDelegate__set_state( __pyx_result, __pyx_state) @@ -69645,7 +77497,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_Coro * __pyx_unpickle_CoroutineDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_CoroutineDelegate__set_state(CoroutineDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -69678,8 +77530,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_53__pyx_unpickle_Coro * __pyx_unpickle_CoroutineDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_CoroutineDelegate__set_state(CoroutineDelegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_CoroutineDelegate__set_state(struct __pyx_obj_19dependency_injector_9providers_CoroutineDelegate *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -69687,12 +77539,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -69701,9 +77554,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_CoroutineDelegate__set_state(CoroutineDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -69711,6 +77564,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___last_overriding); @@ -69721,7 +77583,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -69733,7 +77595,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___provides); @@ -69743,66 +77605,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti /* "(tree fragment)":13 * cdef __pyx_unpickle_CoroutineDelegate__set_state(CoroutineDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_CoroutineDelegate__set_state(CoroutineDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ } @@ -69810,8 +77672,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti * __pyx_unpickle_CoroutineDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_CoroutineDelegate__set_state(CoroutineDelegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -69819,9 +77681,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_CoroutineDelegate__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -69837,9 +77699,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Corouti */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_56__pyx_unpickle_ConfigurationOption(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_56__pyx_unpickle_ConfigurationOption = {"__pyx_unpickle_ConfigurationOption", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_56__pyx_unpickle_ConfigurationOption, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_56__pyx_unpickle_ConfigurationOption(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_62__pyx_unpickle_ConfigurationOption(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_62__pyx_unpickle_ConfigurationOption = {"__pyx_unpickle_ConfigurationOption", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_62__pyx_unpickle_ConfigurationOption, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_62__pyx_unpickle_ConfigurationOption(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -69905,14 +77767,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_56__pyx_unpickle_Conf __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_ConfigurationOption(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_ConfigurationOption(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_ConfigurationOption(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_ConfigurationOption(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -69931,18 +77793,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_Conf /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xb205ea7: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x66bc620: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xb205ea7 = (__cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x66bc620 = (__async_mode, __cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xb205ea7) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x66bc620) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xb205ea7: + * if __pyx_checksum != 0x66bc620: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xb205ea7 = (__cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x66bc620 = (__async_mode, __cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) * __pyx_result = ConfigurationOption.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -69961,15 +77823,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_Conf __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xb205ea7: + * if __pyx_checksum != 0x66bc620: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xb205ea7 = (__cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x66bc620 = (__async_mode, __cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = ConfigurationOption.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xb2, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x66, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -69996,15 +77858,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_Conf /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xb205ea7: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x66bc620: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xb205ea7 = (__cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x66bc620 = (__async_mode, __cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xb205ea7 = (__cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x66bc620 = (__async_mode, __cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) * __pyx_result = ConfigurationOption.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_ConfigurationOption__set_state( __pyx_result, __pyx_state) @@ -70030,7 +77892,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_Conf __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xb205ea7 = (__cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x66bc620 = (__async_mode, __cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) * __pyx_result = ConfigurationOption.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ConfigurationOption__set_state( __pyx_result, __pyx_state) @@ -70053,7 +77915,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_Conf __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xb205ea7 = (__cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x66bc620 = (__async_mode, __cache, __children, __last_overriding, __name, __overridden, __root_ref))" % __pyx_checksum) * __pyx_result = ConfigurationOption.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ConfigurationOption__set_state( __pyx_result, __pyx_state) @@ -70066,7 +77928,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_Conf * __pyx_unpickle_ConfigurationOption__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_ConfigurationOption__set_state(ConfigurationOption __pyx_result, tuple __pyx_state): - * __pyx_result.__cache = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__root_ref = __pyx_state[5] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__cache = __pyx_state[1]; __pyx_result.__children = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__name = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__root_ref = __pyx_state[6] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -70099,8 +77961,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_55__pyx_unpickle_Conf * __pyx_unpickle_ConfigurationOption__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ConfigurationOption__set_state(ConfigurationOption __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__cache = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__root_ref = __pyx_state[5] - * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__cache = __pyx_state[1]; __pyx_result.__children = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__name = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__root_ref = __pyx_state[6] + * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ConfigurationOption__set_state(struct __pyx_obj_19dependency_injector_9providers_ConfigurationOption *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -70108,12 +77970,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -70122,9 +77985,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_ConfigurationOption__set_state(ConfigurationOption __pyx_result, tuple __pyx_state): - * __pyx_result.__cache = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__root_ref = __pyx_state[5] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[6]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__cache = __pyx_state[1]; __pyx_result.__children = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__name = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__root_ref = __pyx_state[6] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[7]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -70132,6 +77995,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___cache); __Pyx_DECREF(__pyx_v___pyx_result->__pyx___cache); @@ -70141,7 +78013,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -70153,7 +78025,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -70165,7 +78037,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -70177,7 +78049,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -70189,7 +78061,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___root_ref); @@ -70199,66 +78071,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu /* "(tree fragment)":13 * cdef __pyx_unpickle_ConfigurationOption__set_state(ConfigurationOption __pyx_result, tuple __pyx_state): - * __pyx_result.__cache = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__root_ref = __pyx_state[5] - * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[6]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__cache = __pyx_state[1]; __pyx_result.__children = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__name = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__root_ref = __pyx_state[6] + * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[7]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 6) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 7) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__cache = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__root_ref = __pyx_state[5] - * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[6]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__cache = __pyx_state[1]; __pyx_result.__children = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__name = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__root_ref = __pyx_state[6] + * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[7]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_ConfigurationOption__set_state(ConfigurationOption __pyx_result, tuple __pyx_state): - * __pyx_result.__cache = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__root_ref = __pyx_state[5] - * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[6]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__cache = __pyx_state[1]; __pyx_result.__children = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__name = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__root_ref = __pyx_state[6] + * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[7]) */ } @@ -70266,8 +78138,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu * __pyx_unpickle_ConfigurationOption__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ConfigurationOption__set_state(ConfigurationOption __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__cache = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__root_ref = __pyx_state[5] - * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__cache = __pyx_state[1]; __pyx_result.__children = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__name = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__root_ref = __pyx_state[6] + * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -70275,9 +78147,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_ConfigurationOption__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -70293,9 +78165,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_58__pyx_unpickle_TypedConfigurationOption(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_58__pyx_unpickle_TypedConfigurationOption = {"__pyx_unpickle_TypedConfigurationOption", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_58__pyx_unpickle_TypedConfigurationOption, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_58__pyx_unpickle_TypedConfigurationOption(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_64__pyx_unpickle_TypedConfigurationOption(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_64__pyx_unpickle_TypedConfigurationOption = {"__pyx_unpickle_TypedConfigurationOption", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_64__pyx_unpickle_TypedConfigurationOption, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_64__pyx_unpickle_TypedConfigurationOption(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -70361,14 +78233,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_58__pyx_unpickle_Type __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_TypedConfigurationOption(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_TypedConfigurationOption(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_TypedConfigurationOption(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_TypedConfigurationOption(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -70387,18 +78259,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_Type /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x03251dc) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3e02ba6) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = TypedConfigurationOption.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -70417,15 +78289,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_Type __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x03251dc: + * if __pyx_checksum != 0x3e02ba6: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = TypedConfigurationOption.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x03, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3e, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -70452,15 +78324,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_Type /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x03251dc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3e02ba6: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = TypedConfigurationOption.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_TypedConfigurationOption__set_state( __pyx_result, __pyx_state) @@ -70486,7 +78358,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_Type __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = TypedConfigurationOption.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_TypedConfigurationOption__set_state( __pyx_result, __pyx_state) @@ -70509,7 +78381,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_Type __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x03251dc = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3e02ba6 = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = TypedConfigurationOption.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_TypedConfigurationOption__set_state( __pyx_result, __pyx_state) @@ -70522,7 +78394,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_Type * __pyx_unpickle_TypedConfigurationOption__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_TypedConfigurationOption__set_state(TypedConfigurationOption __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -70555,8 +78427,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_57__pyx_unpickle_Type * __pyx_unpickle_TypedConfigurationOption__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_TypedConfigurationOption__set_state(TypedConfigurationOption __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedConfigurationOption__set_state(struct __pyx_obj_19dependency_injector_9providers_TypedConfigurationOption *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -70579,9 +78451,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_TypedConfigurationOption__set_state(TypedConfigurationOption __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -70610,6 +78482,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___kwargs); @@ -70620,7 +78501,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -70629,7 +78510,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -70641,7 +78522,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -70653,7 +78534,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___provides); @@ -70663,16 +78544,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo /* "(tree fragment)":13 * cdef __pyx_unpickle_TypedConfigurationOption__set_state(TypedConfigurationOption __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 7) != 0); + __pyx_t_5 = ((__pyx_t_4 > 8) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -70685,9 +78566,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) # <<<<<<<<<<<<<< + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -70698,7 +78579,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -70720,9 +78601,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo /* "(tree fragment)":13 * cdef __pyx_unpickle_TypedConfigurationOption__set_state(TypedConfigurationOption __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ } @@ -70730,8 +78611,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo * __pyx_unpickle_TypedConfigurationOption__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_TypedConfigurationOption__set_state(TypedConfigurationOption __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -70757,9 +78638,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_TypedCo */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_60__pyx_unpickle_Configuration(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_60__pyx_unpickle_Configuration = {"__pyx_unpickle_Configuration", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_60__pyx_unpickle_Configuration, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_60__pyx_unpickle_Configuration(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_66__pyx_unpickle_Configuration(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_66__pyx_unpickle_Configuration = {"__pyx_unpickle_Configuration", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_66__pyx_unpickle_Configuration, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_66__pyx_unpickle_Configuration(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -70825,14 +78706,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_60__pyx_unpickle_Conf __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_Configuration(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_Configuration(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_Configuration(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_Configuration(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -70851,18 +78732,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_Conf /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa7663cf: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3460d23: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa7663cf = (__children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3460d23 = (__async_mode, __children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xa7663cf) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3460d23) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xa7663cf: + * if __pyx_checksum != 0x3460d23: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa7663cf = (__children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3460d23 = (__async_mode, __children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Configuration.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -70881,15 +78762,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_Conf __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xa7663cf: + * if __pyx_checksum != 0x3460d23: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa7663cf = (__children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3460d23 = (__async_mode, __children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Configuration.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xa7, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x34, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -70916,15 +78797,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_Conf /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa7663cf: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x3460d23: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa7663cf = (__children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3460d23 = (__async_mode, __children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa7663cf = (__children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3460d23 = (__async_mode, __children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Configuration.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Configuration__set_state( __pyx_result, __pyx_state) @@ -70950,7 +78831,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_Conf __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa7663cf = (__children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3460d23 = (__async_mode, __children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Configuration.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Configuration__set_state( __pyx_result, __pyx_state) @@ -70973,7 +78854,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_Conf __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa7663cf = (__children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3460d23 = (__async_mode, __children, __last_overriding, __name, __overridden, __provides))" % __pyx_checksum) * __pyx_result = Configuration.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Configuration__set_state( __pyx_result, __pyx_state) @@ -70986,7 +78867,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_Conf * __pyx_unpickle_Configuration__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Configuration__set_state(Configuration __pyx_result, tuple __pyx_state): - * __pyx_result.__children = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__name = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__provides = __pyx_state[5] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -71019,8 +78900,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_59__pyx_unpickle_Conf * __pyx_unpickle_Configuration__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Configuration__set_state(Configuration __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__children = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__name = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__provides = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configuration__set_state(struct __pyx_obj_19dependency_injector_9providers_Configuration *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -71028,12 +78909,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -71042,9 +78924,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Configuration__set_state(Configuration __pyx_result, tuple __pyx_state): - * __pyx_result.__children = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__name = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__provides = __pyx_state[5] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -71052,6 +78934,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___children); @@ -71062,7 +78953,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -71074,7 +78965,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyString_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -71086,7 +78977,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -71098,7 +78989,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___provides); @@ -71108,66 +78999,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu /* "(tree fragment)":13 * cdef __pyx_unpickle_Configuration__set_state(Configuration __pyx_result, tuple __pyx_state): - * __pyx_result.__children = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__name = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__provides = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 5) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 6) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__children = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__name = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__provides = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_Configuration__set_state(Configuration __pyx_result, tuple __pyx_state): - * __pyx_result.__children = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__name = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__provides = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ } @@ -71175,8 +79066,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu * __pyx_unpickle_Configuration__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Configuration__set_state(Configuration __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__children = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__name = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provides = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__children = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__name = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__provides = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -71184,9 +79075,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_Configuration__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -71202,9 +79093,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Configu */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_62__pyx_unpickle_Factory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_62__pyx_unpickle_Factory = {"__pyx_unpickle_Factory", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_62__pyx_unpickle_Factory, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_62__pyx_unpickle_Factory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_68__pyx_unpickle_Factory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_68__pyx_unpickle_Factory = {"__pyx_unpickle_Factory", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_68__pyx_unpickle_Factory, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_68__pyx_unpickle_Factory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -71270,14 +79161,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_62__pyx_unpickle_Fact __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_Factory(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_Factory(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_Factory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_Factory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -71296,18 +79187,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_Fact /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa73b866: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x7545337: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xa73b866) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x7545337) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xa73b866: + * if __pyx_checksum != 0x7545337: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Factory.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -71326,15 +79217,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_Fact __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xa73b866: + * if __pyx_checksum != 0x7545337: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Factory.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xa7_2, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x75, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -71361,15 +79252,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_Fact /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa73b866: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x7545337: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Factory.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Factory__set_state( __pyx_result, __pyx_state) @@ -71395,7 +79286,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_Fact __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Factory.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Factory__set_state( __pyx_result, __pyx_state) @@ -71418,7 +79309,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_Fact __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Factory.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Factory__set_state( __pyx_result, __pyx_state) @@ -71431,7 +79322,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_Fact * __pyx_unpickle_Factory__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Factory__set_state(Factory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -71464,8 +79355,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_61__pyx_unpickle_Fact * __pyx_unpickle_Factory__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Factory__set_state(Factory __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory__set_state(struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -71488,9 +79379,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Factory__set_state(Factory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -71498,6 +79389,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___attributes); @@ -71508,7 +79408,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -71517,7 +79417,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Callable))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -71529,7 +79429,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -71541,7 +79441,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -71552,16 +79452,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory /* "(tree fragment)":13 * cdef __pyx_unpickle_Factory__set_state(Factory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + __pyx_t_5 = ((__pyx_t_4 > 6) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -71574,9 +79474,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -71587,7 +79487,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -71609,9 +79509,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory /* "(tree fragment)":13 * cdef __pyx_unpickle_Factory__set_state(Factory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ } @@ -71619,8 +79519,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory * __pyx_unpickle_Factory__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Factory__set_state(Factory __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -71646,9 +79546,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_64__pyx_unpickle_DelegatedFactory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_64__pyx_unpickle_DelegatedFactory = {"__pyx_unpickle_DelegatedFactory", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_64__pyx_unpickle_DelegatedFactory, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_64__pyx_unpickle_DelegatedFactory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_70__pyx_unpickle_DelegatedFactory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_70__pyx_unpickle_DelegatedFactory = {"__pyx_unpickle_DelegatedFactory", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_70__pyx_unpickle_DelegatedFactory, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_70__pyx_unpickle_DelegatedFactory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -71714,14 +79614,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_64__pyx_unpickle_Dele __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_DelegatedFactory(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_DelegatedFactory(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_DelegatedFactory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_DelegatedFactory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -71740,18 +79640,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa73b866: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x7545337: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xa73b866) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x7545337) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xa73b866: + * if __pyx_checksum != 0x7545337: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = DelegatedFactory.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -71770,15 +79670,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xa73b866: + * if __pyx_checksum != 0x7545337: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = DelegatedFactory.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xa7_2, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x75, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -71805,15 +79705,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa73b866: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x7545337: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = DelegatedFactory.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_DelegatedFactory__set_state( __pyx_result, __pyx_state) @@ -71839,7 +79739,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_Dele __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = DelegatedFactory.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedFactory__set_state( __pyx_result, __pyx_state) @@ -71862,7 +79762,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = DelegatedFactory.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedFactory__set_state( __pyx_result, __pyx_state) @@ -71875,7 +79775,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_Dele * __pyx_unpickle_DelegatedFactory__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_DelegatedFactory__set_state(DelegatedFactory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -71908,8 +79808,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_63__pyx_unpickle_Dele * __pyx_unpickle_DelegatedFactory__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedFactory__set_state(DelegatedFactory __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_DelegatedFactory__set_state(struct __pyx_obj_19dependency_injector_9providers_DelegatedFactory *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -71932,9 +79832,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_DelegatedFactory__set_state(DelegatedFactory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -71942,6 +79842,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___attributes); @@ -71952,7 +79861,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -71961,7 +79870,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Callable))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -71973,7 +79882,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -71985,7 +79894,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -71996,16 +79905,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedFactory__set_state(DelegatedFactory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + __pyx_t_5 = ((__pyx_t_4 > 6) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -72018,9 +79927,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -72031,7 +79940,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -72053,9 +79962,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedFactory__set_state(DelegatedFactory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ } @@ -72063,8 +79972,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat * __pyx_unpickle_DelegatedFactory__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedFactory__set_state(DelegatedFactory __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -72090,9 +79999,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_66__pyx_unpickle_AbstractFactory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_66__pyx_unpickle_AbstractFactory = {"__pyx_unpickle_AbstractFactory", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_66__pyx_unpickle_AbstractFactory, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_66__pyx_unpickle_AbstractFactory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_72__pyx_unpickle_AbstractFactory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_72__pyx_unpickle_AbstractFactory = {"__pyx_unpickle_AbstractFactory", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_72__pyx_unpickle_AbstractFactory, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_72__pyx_unpickle_AbstractFactory(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -72158,14 +80067,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_66__pyx_unpickle_Abst __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_AbstractFactory(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_AbstractFactory(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_AbstractFactory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_AbstractFactory(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -72184,18 +80093,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_Abst /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa73b866: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x7545337: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xa73b866) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x7545337) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xa73b866: + * if __pyx_checksum != 0x7545337: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = AbstractFactory.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -72214,15 +80123,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_Abst __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xa73b866: + * if __pyx_checksum != 0x7545337: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = AbstractFactory.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xa7_2, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x75, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -72249,15 +80158,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_Abst /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa73b866: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x7545337: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = AbstractFactory.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_AbstractFactory__set_state( __pyx_result, __pyx_state) @@ -72283,7 +80192,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_Abst __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = AbstractFactory.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractFactory__set_state( __pyx_result, __pyx_state) @@ -72306,7 +80215,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_Abst __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa73b866 = (__attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7545337 = (__async_mode, __attributes, __attributes_len, __instantiator, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = AbstractFactory.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractFactory__set_state( __pyx_result, __pyx_state) @@ -72319,7 +80228,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_Abst * __pyx_unpickle_AbstractFactory__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_AbstractFactory__set_state(AbstractFactory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -72352,8 +80261,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_65__pyx_unpickle_Abst * __pyx_unpickle_AbstractFactory__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AbstractFactory__set_state(AbstractFactory __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_AbstractFactory__set_state(struct __pyx_obj_19dependency_injector_9providers_AbstractFactory *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -72376,9 +80285,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_AbstractFactory__set_state(AbstractFactory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -72386,6 +80295,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___attributes); @@ -72396,7 +80314,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -72405,7 +80323,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Callable))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -72417,7 +80335,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -72429,7 +80347,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -72440,16 +80358,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac /* "(tree fragment)":13 * cdef __pyx_unpickle_AbstractFactory__set_state(AbstractFactory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + __pyx_t_5 = ((__pyx_t_4 > 6) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -72462,9 +80380,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -72475,7 +80393,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -72497,9 +80415,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac /* "(tree fragment)":13 * cdef __pyx_unpickle_AbstractFactory__set_state(AbstractFactory __pyx_result, tuple __pyx_state): - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ } @@ -72507,8 +80425,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac * __pyx_unpickle_AbstractFactory__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AbstractFactory__set_state(AbstractFactory __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -72534,9 +80452,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_68__pyx_unpickle_FactoryDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_68__pyx_unpickle_FactoryDelegate = {"__pyx_unpickle_FactoryDelegate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_68__pyx_unpickle_FactoryDelegate, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_68__pyx_unpickle_FactoryDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_74__pyx_unpickle_FactoryDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_74__pyx_unpickle_FactoryDelegate = {"__pyx_unpickle_FactoryDelegate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_74__pyx_unpickle_FactoryDelegate, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_74__pyx_unpickle_FactoryDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -72602,14 +80520,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_68__pyx_unpickle_Fact __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_FactoryDelegate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_FactoryDelegate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_FactoryDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_FactoryDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -72628,18 +80546,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_Fact /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3f4a3b6) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x328787b) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = FactoryDelegate.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -72658,15 +80576,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_Fact __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = FactoryDelegate.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3f, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x32, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -72693,15 +80611,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_Fact /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = FactoryDelegate.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_FactoryDelegate__set_state( __pyx_result, __pyx_state) @@ -72727,7 +80645,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_Fact __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = FactoryDelegate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_FactoryDelegate__set_state( __pyx_result, __pyx_state) @@ -72750,7 +80668,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_Fact __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = FactoryDelegate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_FactoryDelegate__set_state( __pyx_result, __pyx_state) @@ -72763,7 +80681,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_Fact * __pyx_unpickle_FactoryDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_FactoryDelegate__set_state(FactoryDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -72796,8 +80714,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_67__pyx_unpickle_Fact * __pyx_unpickle_FactoryDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_FactoryDelegate__set_state(FactoryDelegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_FactoryDelegate__set_state(struct __pyx_obj_19dependency_injector_9providers_FactoryDelegate *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -72805,12 +80723,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -72819,9 +80738,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_FactoryDelegate__set_state(FactoryDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -72829,6 +80748,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___last_overriding); @@ -72839,7 +80767,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -72851,7 +80779,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___provides); @@ -72861,66 +80789,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory /* "(tree fragment)":13 * cdef __pyx_unpickle_FactoryDelegate__set_state(FactoryDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_FactoryDelegate__set_state(FactoryDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ } @@ -72928,8 +80856,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory * __pyx_unpickle_FactoryDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_FactoryDelegate__set_state(FactoryDelegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -72937,9 +80865,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_FactoryDelegate__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -72955,9 +80883,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_70__pyx_unpickle_FactoryAggregate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_70__pyx_unpickle_FactoryAggregate = {"__pyx_unpickle_FactoryAggregate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_70__pyx_unpickle_FactoryAggregate, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_70__pyx_unpickle_FactoryAggregate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_76__pyx_unpickle_FactoryAggregate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_76__pyx_unpickle_FactoryAggregate = {"__pyx_unpickle_FactoryAggregate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_76__pyx_unpickle_FactoryAggregate, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_76__pyx_unpickle_FactoryAggregate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -73023,14 +80951,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_70__pyx_unpickle_Fact __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_FactoryAggregate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_FactoryAggregate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_FactoryAggregate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_FactoryAggregate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -73049,18 +80977,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_Fact /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa6696fd: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xa264cf2: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa6696fd = (__factories, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa264cf2 = (__async_mode, __factories, __last_overriding, __overridden))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xa6696fd) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xa264cf2) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xa6696fd: + * if __pyx_checksum != 0xa264cf2: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa6696fd = (__factories, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa264cf2 = (__async_mode, __factories, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = FactoryAggregate.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -73079,15 +81007,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_Fact __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xa6696fd: + * if __pyx_checksum != 0xa264cf2: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa6696fd = (__factories, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa264cf2 = (__async_mode, __factories, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = FactoryAggregate.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xa6, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xa2, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -73114,15 +81042,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_Fact /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa6696fd: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xa264cf2: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa6696fd = (__factories, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa264cf2 = (__async_mode, __factories, __last_overriding, __overridden))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa6696fd = (__factories, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa264cf2 = (__async_mode, __factories, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = FactoryAggregate.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_FactoryAggregate__set_state( __pyx_result, __pyx_state) @@ -73148,7 +81076,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_Fact __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa6696fd = (__factories, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa264cf2 = (__async_mode, __factories, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = FactoryAggregate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_FactoryAggregate__set_state( __pyx_result, __pyx_state) @@ -73171,7 +81099,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_Fact __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa6696fd = (__factories, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa264cf2 = (__async_mode, __factories, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = FactoryAggregate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_FactoryAggregate__set_state( __pyx_result, __pyx_state) @@ -73184,7 +81112,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_Fact * __pyx_unpickle_FactoryAggregate__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_FactoryAggregate__set_state(FactoryAggregate __pyx_result, tuple __pyx_state): - * __pyx_result.__factories = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__factories = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -73217,8 +81145,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_69__pyx_unpickle_Fact * __pyx_unpickle_FactoryAggregate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_FactoryAggregate__set_state(FactoryAggregate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__factories = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__factories = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_FactoryAggregate__set_state(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -73226,12 +81154,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -73240,9 +81169,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_FactoryAggregate__set_state(FactoryAggregate __pyx_result, tuple __pyx_state): - * __pyx_result.__factories = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__factories = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -73250,6 +81179,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___factories); @@ -73260,7 +81198,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -73272,7 +81210,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -73283,66 +81221,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory /* "(tree fragment)":13 * cdef __pyx_unpickle_FactoryAggregate__set_state(FactoryAggregate __pyx_result, tuple __pyx_state): - * __pyx_result.__factories = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__factories = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__factories = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__factories = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_FactoryAggregate__set_state(FactoryAggregate __pyx_result, tuple __pyx_state): - * __pyx_result.__factories = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__factories = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ } @@ -73350,8 +81288,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory * __pyx_unpickle_FactoryAggregate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_FactoryAggregate__set_state(FactoryAggregate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__factories = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__factories = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -73359,9 +81297,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_FactoryAggregate__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -73377,9 +81315,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Factory */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_72__pyx_unpickle_BaseSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_72__pyx_unpickle_BaseSingleton = {"__pyx_unpickle_BaseSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_72__pyx_unpickle_BaseSingleton, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_72__pyx_unpickle_BaseSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_78__pyx_unpickle_BaseSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_78__pyx_unpickle_BaseSingleton = {"__pyx_unpickle_BaseSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_78__pyx_unpickle_BaseSingleton, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_78__pyx_unpickle_BaseSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -73445,14 +81383,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_72__pyx_unpickle_Base __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_BaseSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_BaseSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_BaseSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_BaseSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -73471,18 +81409,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_Base /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x0c49df0: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x0c49df0) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xce4d239) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x0c49df0: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = BaseSingleton.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -73501,15 +81439,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_Base __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x0c49df0: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = BaseSingleton.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x0c, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xce, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -73536,15 +81474,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_Base /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x0c49df0: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = BaseSingleton.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_BaseSingleton__set_state( __pyx_result, __pyx_state) @@ -73570,7 +81508,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_Base __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = BaseSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_BaseSingleton__set_state( __pyx_result, __pyx_state) @@ -73593,7 +81531,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_Base __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = BaseSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_BaseSingleton__set_state( __pyx_result, __pyx_state) @@ -73606,7 +81544,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_Base * __pyx_unpickle_BaseSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_BaseSingleton__set_state(BaseSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -73639,8 +81577,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_71__pyx_unpickle_Base * __pyx_unpickle_BaseSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_BaseSingleton__set_state(BaseSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_BaseSingleton__set_state(struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -73648,12 +81586,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_BaseSin __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -73662,9 +81601,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_BaseSin /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_BaseSingleton__set_state(BaseSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -73672,6 +81611,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_BaseSin } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Factory))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___instantiator); @@ -73682,7 +81630,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_BaseSin PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -73694,7 +81642,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_BaseSin PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -73702,69 +81650,80 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_BaseSin __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx___overridden); __pyx_v___pyx_result->__pyx_base.__pyx___overridden = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_GIVEREF(__pyx_t_1); + __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___storage); + __Pyx_DECREF(__pyx_v___pyx_result->__pyx___storage); + __pyx_v___pyx_result->__pyx___storage = __pyx_t_1; + __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_BaseSingleton__set_state(BaseSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_BaseSingleton__set_state(BaseSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -73772,8 +81731,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_BaseSin * __pyx_unpickle_BaseSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_BaseSingleton__set_state(BaseSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -73781,9 +81740,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_BaseSin goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_BaseSingleton__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -73799,9 +81758,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_BaseSin */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_74__pyx_unpickle_Singleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_74__pyx_unpickle_Singleton = {"__pyx_unpickle_Singleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_74__pyx_unpickle_Singleton, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_74__pyx_unpickle_Singleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_80__pyx_unpickle_Singleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_80__pyx_unpickle_Singleton = {"__pyx_unpickle_Singleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_80__pyx_unpickle_Singleton, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_80__pyx_unpickle_Singleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -73867,14 +81826,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_74__pyx_unpickle_Sing __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_Singleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_Singleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_Singleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_Singleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -73893,18 +81852,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_Sing /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x76eb8a2) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xce4d239) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = Singleton.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -73923,15 +81882,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_Sing __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x76eb8a2: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Singleton.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x76, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xce, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -73958,15 +81917,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_Sing /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = Singleton.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Singleton__set_state( __pyx_result, __pyx_state) @@ -73992,7 +81951,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_Sing __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = Singleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Singleton__set_state( __pyx_result, __pyx_state) @@ -74015,7 +81974,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_Sing __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = Singleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Singleton__set_state( __pyx_result, __pyx_state) @@ -74028,7 +81987,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_Sing * __pyx_unpickle_Singleton__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Singleton__set_state(Singleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -74061,8 +82020,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_73__pyx_unpickle_Sing * __pyx_unpickle_Singleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Singleton__set_state(Singleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singleton__set_state(struct __pyx_obj_19dependency_injector_9providers_Singleton *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -74070,12 +82029,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -74084,9 +82044,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Singleton__set_state(Singleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -74094,6 +82054,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Factory))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___instantiator); @@ -74104,7 +82073,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -74116,7 +82085,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -74128,76 +82097,76 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); - __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___storage); - __Pyx_DECREF(__pyx_v___pyx_result->__pyx___storage); - __pyx_v___pyx_result->__pyx___storage = __pyx_t_1; + __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); + __pyx_v___pyx_result->__pyx_base.__pyx___storage = __pyx_t_1; __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_Singleton__set_state(Singleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 4) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_Singleton__set_state(Singleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -74205,8 +82174,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet * __pyx_unpickle_Singleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Singleton__set_state(Singleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -74214,9 +82183,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_Singleton__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -74232,9 +82201,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_76__pyx_unpickle_DelegatedSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_76__pyx_unpickle_DelegatedSingleton = {"__pyx_unpickle_DelegatedSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_76__pyx_unpickle_DelegatedSingleton, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_76__pyx_unpickle_DelegatedSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_82__pyx_unpickle_DelegatedSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_82__pyx_unpickle_DelegatedSingleton = {"__pyx_unpickle_DelegatedSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_82__pyx_unpickle_DelegatedSingleton, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_82__pyx_unpickle_DelegatedSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -74300,14 +82269,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_76__pyx_unpickle_Dele __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_DelegatedSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_DelegatedSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_DelegatedSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_DelegatedSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -74326,18 +82295,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x76eb8a2) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xce4d239) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = DelegatedSingleton.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -74356,15 +82325,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x76eb8a2: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = DelegatedSingleton.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x76, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xce, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -74391,15 +82360,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = DelegatedSingleton.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_DelegatedSingleton__set_state( __pyx_result, __pyx_state) @@ -74425,7 +82394,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_Dele __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = DelegatedSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedSingleton__set_state( __pyx_result, __pyx_state) @@ -74448,7 +82417,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = DelegatedSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedSingleton__set_state( __pyx_result, __pyx_state) @@ -74461,7 +82430,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_Dele * __pyx_unpickle_DelegatedSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_DelegatedSingleton__set_state(DelegatedSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -74494,8 +82463,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_75__pyx_unpickle_Dele * __pyx_unpickle_DelegatedSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedSingleton__set_state(DelegatedSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_DelegatedSingleton__set_state(struct __pyx_obj_19dependency_injector_9providers_DelegatedSingleton *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -74503,12 +82472,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -74517,9 +82487,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_DelegatedSingleton__set_state(DelegatedSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -74527,6 +82497,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Factory))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___instantiator); @@ -74537,7 +82516,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -74549,7 +82528,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -74561,76 +82540,76 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); - __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); - __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); - __pyx_v___pyx_result->__pyx_base.__pyx___storage = __pyx_t_1; + __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___storage); + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___storage = __pyx_t_1; __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedSingleton__set_state(DelegatedSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 4) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedSingleton__set_state(DelegatedSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -74638,8 +82617,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat * __pyx_unpickle_DelegatedSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedSingleton__set_state(DelegatedSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -74647,9 +82626,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_DelegatedSingleton__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -74665,9 +82644,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_78__pyx_unpickle_ThreadSafeSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_78__pyx_unpickle_ThreadSafeSingleton = {"__pyx_unpickle_ThreadSafeSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_78__pyx_unpickle_ThreadSafeSingleton, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_78__pyx_unpickle_ThreadSafeSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_84__pyx_unpickle_ThreadSafeSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_84__pyx_unpickle_ThreadSafeSingleton = {"__pyx_unpickle_ThreadSafeSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_84__pyx_unpickle_ThreadSafeSingleton, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_84__pyx_unpickle_ThreadSafeSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -74733,14 +82712,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_78__pyx_unpickle_Thre __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_ThreadSafeSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_ThreadSafeSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_ThreadSafeSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_ThreadSafeSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -74759,18 +82738,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_Thre /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa5833ef: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x2a56a3c: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xa5833ef) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x2a56a3c) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xa5833ef: + * if __pyx_checksum != 0x2a56a3c: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) * __pyx_result = ThreadSafeSingleton.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -74789,15 +82768,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_Thre __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xa5833ef: + * if __pyx_checksum != 0x2a56a3c: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = ThreadSafeSingleton.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xa5, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x2a, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -74824,15 +82803,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_Thre /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa5833ef: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x2a56a3c: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) * __pyx_result = ThreadSafeSingleton.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_ThreadSafeSingleton__set_state( __pyx_result, __pyx_state) @@ -74858,7 +82837,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_Thre __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) * __pyx_result = ThreadSafeSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ThreadSafeSingleton__set_state( __pyx_result, __pyx_state) @@ -74881,7 +82860,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_Thre __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) * __pyx_result = ThreadSafeSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ThreadSafeSingleton__set_state( __pyx_result, __pyx_state) @@ -74894,7 +82873,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_Thre * __pyx_unpickle_ThreadSafeSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_ThreadSafeSingleton__set_state(ThreadSafeSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -74927,8 +82906,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_77__pyx_unpickle_Thre * __pyx_unpickle_ThreadSafeSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ThreadSafeSingleton__set_state(ThreadSafeSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadSafeSingleton__set_state(struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -74936,12 +82915,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadS __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -74950,9 +82930,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadS /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_ThreadSafeSingleton__set_state(ThreadSafeSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -74960,6 +82940,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadS } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Factory))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___instantiator); @@ -74970,7 +82959,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadS PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -74982,7 +82971,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadS PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -74994,18 +82983,18 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadS PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); - __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___storage); - __Pyx_DECREF(__pyx_v___pyx_result->__pyx___storage); - __pyx_v___pyx_result->__pyx___storage = __pyx_t_1; + __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); + __pyx_v___pyx_result->__pyx_base.__pyx___storage = __pyx_t_1; __pyx_t_1 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___storage_lock); @@ -75015,66 +83004,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadS /* "(tree fragment)":13 * cdef __pyx_unpickle_ThreadSafeSingleton__set_state(ThreadSafeSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 5) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 6) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_ThreadSafeSingleton__set_state(ThreadSafeSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ } @@ -75082,8 +83071,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadS * __pyx_unpickle_ThreadSafeSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ThreadSafeSingleton__set_state(ThreadSafeSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -75091,9 +83080,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadS goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_ThreadSafeSingleton__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -75109,9 +83098,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadS */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_80__pyx_unpickle_DelegatedThreadSafeSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_80__pyx_unpickle_DelegatedThreadSafeSingleton = {"__pyx_unpickle_DelegatedThreadSafeSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_80__pyx_unpickle_DelegatedThreadSafeSingleton, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_80__pyx_unpickle_DelegatedThreadSafeSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_86__pyx_unpickle_DelegatedThreadSafeSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_86__pyx_unpickle_DelegatedThreadSafeSingleton = {"__pyx_unpickle_DelegatedThreadSafeSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_86__pyx_unpickle_DelegatedThreadSafeSingleton, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_86__pyx_unpickle_DelegatedThreadSafeSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -75177,14 +83166,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_80__pyx_unpickle_Dele __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_DelegatedThreadSafeSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_DelegatedThreadSafeSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_DelegatedThreadSafeSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_DelegatedThreadSafeSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -75203,18 +83192,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa5833ef: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x2a56a3c: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xa5833ef) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x2a56a3c) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xa5833ef: + * if __pyx_checksum != 0x2a56a3c: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) * __pyx_result = DelegatedThreadSafeSingleton.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -75233,15 +83222,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xa5833ef: + * if __pyx_checksum != 0x2a56a3c: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = DelegatedThreadSafeSingleton.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xa5, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x2a, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -75268,15 +83257,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xa5833ef: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x2a56a3c: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) * __pyx_result = DelegatedThreadSafeSingleton.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_DelegatedThreadSafeSingleton__set_state( __pyx_result, __pyx_state) @@ -75302,7 +83291,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_Dele __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) * __pyx_result = DelegatedThreadSafeSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedThreadSafeSingleton__set_state( __pyx_result, __pyx_state) @@ -75325,7 +83314,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5833ef = (__instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2a56a3c = (__async_mode, __instantiator, __last_overriding, __overridden, __storage, __storage_lock))" % __pyx_checksum) * __pyx_result = DelegatedThreadSafeSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedThreadSafeSingleton__set_state( __pyx_result, __pyx_state) @@ -75338,7 +83327,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_Dele * __pyx_unpickle_DelegatedThreadSafeSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_DelegatedThreadSafeSingleton__set_state(DelegatedThreadSafeSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -75371,8 +83360,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_79__pyx_unpickle_Dele * __pyx_unpickle_DelegatedThreadSafeSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedThreadSafeSingleton__set_state(DelegatedThreadSafeSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_DelegatedThreadSafeSingleton__set_state(struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadSafeSingleton *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -75380,12 +83369,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -75394,9 +83384,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_DelegatedThreadSafeSingleton__set_state(DelegatedThreadSafeSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -75404,6 +83394,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Factory))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___instantiator); @@ -75414,7 +83413,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -75426,7 +83425,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -75438,18 +83437,18 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); - __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); - __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); - __pyx_v___pyx_result->__pyx_base.__pyx___storage = __pyx_t_1; + __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___storage); + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___storage = __pyx_t_1; __pyx_t_1 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage_lock); @@ -75459,66 +83458,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedThreadSafeSingleton__set_state(DelegatedThreadSafeSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 5) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 6) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedThreadSafeSingleton__set_state(DelegatedThreadSafeSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ } @@ -75526,8 +83525,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat * __pyx_unpickle_DelegatedThreadSafeSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedThreadSafeSingleton__set_state(DelegatedThreadSafeSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -75535,9 +83534,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_DelegatedThreadSafeSingleton__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -75553,9 +83552,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_82__pyx_unpickle_ThreadLocalSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_82__pyx_unpickle_ThreadLocalSingleton = {"__pyx_unpickle_ThreadLocalSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_82__pyx_unpickle_ThreadLocalSingleton, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_82__pyx_unpickle_ThreadLocalSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_88__pyx_unpickle_ThreadLocalSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_88__pyx_unpickle_ThreadLocalSingleton = {"__pyx_unpickle_ThreadLocalSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_88__pyx_unpickle_ThreadLocalSingleton, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_88__pyx_unpickle_ThreadLocalSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -75621,14 +83620,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_82__pyx_unpickle_Thre __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_ThreadLocalSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_ThreadLocalSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_ThreadLocalSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_ThreadLocalSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -75647,18 +83646,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_Thre /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x76eb8a2) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xce4d239) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = ThreadLocalSingleton.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -75677,15 +83676,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_Thre __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x76eb8a2: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = ThreadLocalSingleton.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x76, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xce, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -75712,15 +83711,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_Thre /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = ThreadLocalSingleton.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_ThreadLocalSingleton__set_state( __pyx_result, __pyx_state) @@ -75746,7 +83745,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_Thre __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = ThreadLocalSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ThreadLocalSingleton__set_state( __pyx_result, __pyx_state) @@ -75769,7 +83768,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_Thre __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = ThreadLocalSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ThreadLocalSingleton__set_state( __pyx_result, __pyx_state) @@ -75782,7 +83781,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_Thre * __pyx_unpickle_ThreadLocalSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_ThreadLocalSingleton__set_state(ThreadLocalSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -75815,8 +83814,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_81__pyx_unpickle_Thre * __pyx_unpickle_ThreadLocalSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ThreadLocalSingleton__set_state(ThreadLocalSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadLocalSingleton__set_state(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -75824,12 +83823,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadL __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -75838,9 +83838,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadL /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_ThreadLocalSingleton__set_state(ThreadLocalSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -75848,6 +83848,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadL } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Factory))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___instantiator); @@ -75858,7 +83867,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadL PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -75870,7 +83879,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadL PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -75882,76 +83891,76 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadL PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); - __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___storage); - __Pyx_DECREF(__pyx_v___pyx_result->__pyx___storage); - __pyx_v___pyx_result->__pyx___storage = __pyx_t_1; + __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); + __pyx_v___pyx_result->__pyx_base.__pyx___storage = __pyx_t_1; __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_ThreadLocalSingleton__set_state(ThreadLocalSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 4) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_ThreadLocalSingleton__set_state(ThreadLocalSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -75959,8 +83968,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadL * __pyx_unpickle_ThreadLocalSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ThreadLocalSingleton__set_state(ThreadLocalSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -75968,9 +83977,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadL goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_ThreadLocalSingleton__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -75986,9 +83995,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ThreadL */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_84__pyx_unpickle_DelegatedThreadLocalSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_84__pyx_unpickle_DelegatedThreadLocalSingleton = {"__pyx_unpickle_DelegatedThreadLocalSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_84__pyx_unpickle_DelegatedThreadLocalSingleton, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_84__pyx_unpickle_DelegatedThreadLocalSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_90__pyx_unpickle_DelegatedThreadLocalSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_90__pyx_unpickle_DelegatedThreadLocalSingleton = {"__pyx_unpickle_DelegatedThreadLocalSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_90__pyx_unpickle_DelegatedThreadLocalSingleton, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_90__pyx_unpickle_DelegatedThreadLocalSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -76054,14 +84063,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_84__pyx_unpickle_Dele __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_DelegatedThreadLocalSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_DelegatedThreadLocalSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_DelegatedThreadLocalSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_DelegatedThreadLocalSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -76080,18 +84089,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x76eb8a2) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xce4d239) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = DelegatedThreadLocalSingleton.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -76110,15 +84119,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x76eb8a2: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = DelegatedThreadLocalSingleton.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x76, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xce, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -76145,15 +84154,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_Dele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x76eb8a2: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = DelegatedThreadLocalSingleton.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_DelegatedThreadLocalSingleton__set_state( __pyx_result, __pyx_state) @@ -76179,7 +84188,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_Dele __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = DelegatedThreadLocalSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedThreadLocalSingleton__set_state( __pyx_result, __pyx_state) @@ -76202,7 +84211,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_Dele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x76eb8a2 = (__instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = DelegatedThreadLocalSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_DelegatedThreadLocalSingleton__set_state( __pyx_result, __pyx_state) @@ -76215,7 +84224,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_Dele * __pyx_unpickle_DelegatedThreadLocalSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_DelegatedThreadLocalSingleton__set_state(DelegatedThreadLocalSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -76248,8 +84257,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_83__pyx_unpickle_Dele * __pyx_unpickle_DelegatedThreadLocalSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedThreadLocalSingleton__set_state(DelegatedThreadLocalSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_DelegatedThreadLocalSingleton__set_state(struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadLocalSingleton *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -76257,12 +84266,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -76271,9 +84281,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_DelegatedThreadLocalSingleton__set_state(DelegatedThreadLocalSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -76281,6 +84291,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Factory))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___instantiator); @@ -76291,7 +84310,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -76303,7 +84322,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -76315,76 +84334,76 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); - __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); - __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); - __pyx_v___pyx_result->__pyx_base.__pyx___storage = __pyx_t_1; + __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___storage); + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___storage = __pyx_t_1; __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedThreadLocalSingleton__set_state(DelegatedThreadLocalSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 4) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_DelegatedThreadLocalSingleton__set_state(DelegatedThreadLocalSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -76392,8 +84411,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat * __pyx_unpickle_DelegatedThreadLocalSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedThreadLocalSingleton__set_state(DelegatedThreadLocalSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -76401,9 +84420,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_DelegatedThreadLocalSingleton__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -76419,9 +84438,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Delegat */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_86__pyx_unpickle_AbstractSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_86__pyx_unpickle_AbstractSingleton = {"__pyx_unpickle_AbstractSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_86__pyx_unpickle_AbstractSingleton, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_86__pyx_unpickle_AbstractSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_92__pyx_unpickle_AbstractSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_92__pyx_unpickle_AbstractSingleton = {"__pyx_unpickle_AbstractSingleton", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_92__pyx_unpickle_AbstractSingleton, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_92__pyx_unpickle_AbstractSingleton(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -76487,14 +84506,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_86__pyx_unpickle_Abst __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_AbstractSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_AbstractSingleton(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_AbstractSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_AbstractSingleton(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -76513,18 +84532,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_Abst /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x0c49df0: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x0c49df0) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xce4d239) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x0c49df0: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = AbstractSingleton.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -76543,15 +84562,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_Abst __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x0c49df0: + * if __pyx_checksum != 0xce4d239: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = AbstractSingleton.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x0c, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xce, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -76578,15 +84597,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_Abst /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x0c49df0: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xce4d239: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = AbstractSingleton.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_AbstractSingleton__set_state( __pyx_result, __pyx_state) @@ -76612,7 +84631,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_Abst __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = AbstractSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractSingleton__set_state( __pyx_result, __pyx_state) @@ -76635,7 +84654,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_Abst __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0c49df0 = (__instantiator, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xce4d239 = (__async_mode, __instantiator, __last_overriding, __overridden, __storage))" % __pyx_checksum) * __pyx_result = AbstractSingleton.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_AbstractSingleton__set_state( __pyx_result, __pyx_state) @@ -76648,7 +84667,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_Abst * __pyx_unpickle_AbstractSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_AbstractSingleton__set_state(AbstractSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -76681,8 +84700,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_85__pyx_unpickle_Abst * __pyx_unpickle_AbstractSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AbstractSingleton__set_state(AbstractSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_AbstractSingleton__set_state(struct __pyx_obj_19dependency_injector_9providers_AbstractSingleton *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -76690,12 +84709,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -76704,9 +84724,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_AbstractSingleton__set_state(AbstractSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -76714,6 +84734,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Factory))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___instantiator); @@ -76724,7 +84753,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -76736,7 +84765,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -76744,69 +84773,80 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___overridden); __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___overridden = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_GIVEREF(__pyx_t_1); + __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); + __Pyx_DECREF(__pyx_v___pyx_result->__pyx_base.__pyx___storage); + __pyx_v___pyx_result->__pyx_base.__pyx___storage = __pyx_t_1; + __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_AbstractSingleton__set_state(AbstractSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_AbstractSingleton__set_state(AbstractSingleton __pyx_result, tuple __pyx_state): - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -76814,8 +84854,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac * __pyx_unpickle_AbstractSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AbstractSingleton__set_state(AbstractSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -76823,9 +84863,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_AbstractSingleton__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -76841,9 +84881,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Abstrac */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_88__pyx_unpickle_SingletonDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_88__pyx_unpickle_SingletonDelegate = {"__pyx_unpickle_SingletonDelegate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_88__pyx_unpickle_SingletonDelegate, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_88__pyx_unpickle_SingletonDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_94__pyx_unpickle_SingletonDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_94__pyx_unpickle_SingletonDelegate = {"__pyx_unpickle_SingletonDelegate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_94__pyx_unpickle_SingletonDelegate, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_94__pyx_unpickle_SingletonDelegate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -76909,14 +84949,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_88__pyx_unpickle_Sing __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_SingletonDelegate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_SingletonDelegate(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_SingletonDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_SingletonDelegate(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -76935,18 +84975,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_Sing /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3f4a3b6) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x328787b) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = SingletonDelegate.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -76965,15 +85005,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_Sing __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x3f4a3b6: + * if __pyx_checksum != 0x328787b: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = SingletonDelegate.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3f, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x32, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -77000,15 +85040,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_Sing /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x3f4a3b6: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x328787b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = SingletonDelegate.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_SingletonDelegate__set_state( __pyx_result, __pyx_state) @@ -77034,7 +85074,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_Sing __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = SingletonDelegate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_SingletonDelegate__set_state( __pyx_result, __pyx_state) @@ -77057,7 +85097,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_Sing __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3f4a3b6 = (__last_overriding, __overridden, __provides))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x328787b = (__async_mode, __last_overriding, __overridden, __provides))" % __pyx_checksum) * __pyx_result = SingletonDelegate.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_SingletonDelegate__set_state( __pyx_result, __pyx_state) @@ -77070,7 +85110,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_Sing * __pyx_unpickle_SingletonDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_SingletonDelegate__set_state(SingletonDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -77103,8 +85143,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_87__pyx_unpickle_Sing * __pyx_unpickle_SingletonDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_SingletonDelegate__set_state(SingletonDelegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_SingletonDelegate__set_state(struct __pyx_obj_19dependency_injector_9providers_SingletonDelegate *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -77112,12 +85152,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -77126,9 +85167,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_SingletonDelegate__set_state(SingletonDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -77136,6 +85177,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx_base.__pyx___last_overriding); @@ -77146,7 +85196,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -77158,7 +85208,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___provides); @@ -77168,66 +85218,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet /* "(tree fragment)":13 * cdef __pyx_unpickle_SingletonDelegate__set_state(SingletonDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_SingletonDelegate__set_state(SingletonDelegate __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ } @@ -77235,8 +85285,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet * __pyx_unpickle_SingletonDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_SingletonDelegate__set_state(SingletonDelegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -77244,9 +85294,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_SingletonDelegate__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -77262,9 +85312,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Singlet */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_90__pyx_unpickle_List(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_90__pyx_unpickle_List = {"__pyx_unpickle_List", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_90__pyx_unpickle_List, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_90__pyx_unpickle_List(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_96__pyx_unpickle_List(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_96__pyx_unpickle_List = {"__pyx_unpickle_List", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_96__pyx_unpickle_List, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_96__pyx_unpickle_List(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -77330,14 +85380,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_90__pyx_unpickle_List __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_List(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_List(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_List(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_List(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -77356,18 +85406,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_List /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x631cff7: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x42b6146: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x631cff7 = (__args, __args_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x42b6146 = (__args, __args_len, __async_mode, __last_overriding, __overridden))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x631cff7) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x42b6146) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x631cff7: + * if __pyx_checksum != 0x42b6146: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x631cff7 = (__args, __args_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x42b6146 = (__args, __args_len, __async_mode, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = List.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -77386,15 +85436,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_List __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x631cff7: + * if __pyx_checksum != 0x42b6146: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x631cff7 = (__args, __args_len, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x42b6146 = (__args, __args_len, __async_mode, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = List.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x63, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x42, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -77421,15 +85471,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_List /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x631cff7: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x42b6146: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x631cff7 = (__args, __args_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x42b6146 = (__args, __args_len, __async_mode, __last_overriding, __overridden))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x631cff7 = (__args, __args_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x42b6146 = (__args, __args_len, __async_mode, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = List.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_List__set_state( __pyx_result, __pyx_state) @@ -77455,7 +85505,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_List __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x631cff7 = (__args, __args_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x42b6146 = (__args, __args_len, __async_mode, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = List.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_List__set_state( __pyx_result, __pyx_state) @@ -77478,7 +85528,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_List __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x631cff7 = (__args, __args_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x42b6146 = (__args, __args_len, __async_mode, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = List.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_List__set_state( __pyx_result, __pyx_state) @@ -77491,7 +85541,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_List * __pyx_unpickle_List__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_List__set_state(List __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -77524,8 +85574,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_89__pyx_unpickle_List * __pyx_unpickle_List__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_List__set_state(List __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_List__set_state(struct __pyx_obj_19dependency_injector_9providers_List *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -77548,9 +85598,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_List__s /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_List__set_state(List __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -77579,6 +85629,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_List__s } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___last_overriding); @@ -77589,7 +85648,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_List__s PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -77600,16 +85659,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_List__s /* "(tree fragment)":13 * cdef __pyx_unpickle_List__set_state(List __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -77622,9 +85681,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_List__s if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -77635,7 +85694,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_List__s PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -77657,9 +85716,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_List__s /* "(tree fragment)":13 * cdef __pyx_unpickle_List__set_state(List __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -77667,8 +85726,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_List__s * __pyx_unpickle_List__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_List__set_state(List __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -77694,9 +85753,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_List__s */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_92__pyx_unpickle_Dict(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_92__pyx_unpickle_Dict = {"__pyx_unpickle_Dict", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_92__pyx_unpickle_Dict, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_92__pyx_unpickle_Dict(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_98__pyx_unpickle_Dict(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_98__pyx_unpickle_Dict = {"__pyx_unpickle_Dict", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_98__pyx_unpickle_Dict, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_98__pyx_unpickle_Dict(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -77762,14 +85821,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_92__pyx_unpickle_Dict __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_Dict(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Dict(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_Dict(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Dict(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -77788,18 +85847,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_Dict /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x97c970c: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xff73c9f: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x97c970c = (__kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xff73c9f = (__async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x97c970c) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xff73c9f) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x97c970c: + * if __pyx_checksum != 0xff73c9f: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x97c970c = (__kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xff73c9f = (__async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Dict.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -77818,15 +85877,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_Dict __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x97c970c: + * if __pyx_checksum != 0xff73c9f: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x97c970c = (__kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xff73c9f = (__async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Dict.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x97, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xff, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -77853,15 +85912,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_Dict /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x97c970c: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xff73c9f: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x97c970c = (__kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xff73c9f = (__async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x97c970c = (__kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xff73c9f = (__async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Dict.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Dict__set_state( __pyx_result, __pyx_state) @@ -77887,7 +85946,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_Dict __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x97c970c = (__kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xff73c9f = (__async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Dict.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Dict__set_state( __pyx_result, __pyx_state) @@ -77910,7 +85969,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_Dict __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x97c970c = (__kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xff73c9f = (__async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden))" % __pyx_checksum) * __pyx_result = Dict.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Dict__set_state( __pyx_result, __pyx_state) @@ -77923,7 +85982,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_Dict * __pyx_unpickle_Dict__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Dict__set_state(Dict __pyx_result, tuple __pyx_state): - * __pyx_result.__kwargs = __pyx_state[0]; __pyx_result.__kwargs_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__kwargs = __pyx_state[1]; __pyx_result.__kwargs_len = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -77956,8 +86015,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_91__pyx_unpickle_Dict * __pyx_unpickle_Dict__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Dict__set_state(Dict __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__kwargs = __pyx_state[0]; __pyx_result.__kwargs_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__kwargs = __pyx_state[1]; __pyx_result.__kwargs_len = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__set_state(struct __pyx_obj_19dependency_injector_9providers_Dict *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -77980,9 +86039,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Dict__set_state(Dict __pyx_result, tuple __pyx_state): - * __pyx_result.__kwargs = __pyx_state[0]; __pyx_result.__kwargs_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__kwargs = __pyx_state[1]; __pyx_result.__kwargs_len = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -77990,6 +86049,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___kwargs); @@ -78000,7 +86068,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -78009,7 +86077,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -78021,7 +86089,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -78032,16 +86100,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s /* "(tree fragment)":13 * cdef __pyx_unpickle_Dict__set_state(Dict __pyx_result, tuple __pyx_state): - * __pyx_result.__kwargs = __pyx_state[0]; __pyx_result.__kwargs_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__kwargs = __pyx_state[1]; __pyx_result.__kwargs_len = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -78054,9 +86122,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__kwargs = __pyx_state[0]; __pyx_result.__kwargs_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__kwargs = __pyx_state[1]; __pyx_result.__kwargs_len = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -78067,7 +86135,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -78089,9 +86157,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s /* "(tree fragment)":13 * cdef __pyx_unpickle_Dict__set_state(Dict __pyx_result, tuple __pyx_state): - * __pyx_result.__kwargs = __pyx_state[0]; __pyx_result.__kwargs_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__kwargs = __pyx_state[1]; __pyx_result.__kwargs_len = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -78099,8 +86167,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s * __pyx_unpickle_Dict__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Dict__set_state(Dict __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__kwargs = __pyx_state[0]; __pyx_result.__kwargs_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__kwargs = __pyx_state[1]; __pyx_result.__kwargs_len = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -78126,9 +86194,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Dict__s */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_94__pyx_unpickle_Resource(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_94__pyx_unpickle_Resource = {"__pyx_unpickle_Resource", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_94__pyx_unpickle_Resource, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_94__pyx_unpickle_Resource(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_100__pyx_unpickle_Resource(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_100__pyx_unpickle_Resource = {"__pyx_unpickle_Resource", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_100__pyx_unpickle_Resource, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_100__pyx_unpickle_Resource(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -78194,14 +86262,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_94__pyx_unpickle_Reso __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_Resource(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_Resource(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_Resource(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_Resource(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -78220,18 +86288,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_Reso /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xe8b92e4: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x734cfcb: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe8b92e4 = (__args, __args_len, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x734cfcb = (__args, __args_len, __async_mode, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xe8b92e4) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x734cfcb) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xe8b92e4: + * if __pyx_checksum != 0x734cfcb: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe8b92e4 = (__args, __args_len, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x734cfcb = (__args, __args_len, __async_mode, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) * __pyx_result = Resource.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -78250,15 +86318,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_Reso __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xe8b92e4: + * if __pyx_checksum != 0x734cfcb: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe8b92e4 = (__args, __args_len, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x734cfcb = (__args, __args_len, __async_mode, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Resource.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xe8, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x73, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -78285,15 +86353,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_Reso /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xe8b92e4: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x734cfcb: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe8b92e4 = (__args, __args_len, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x734cfcb = (__args, __args_len, __async_mode, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe8b92e4 = (__args, __args_len, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x734cfcb = (__args, __args_len, __async_mode, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) * __pyx_result = Resource.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Resource__set_state( __pyx_result, __pyx_state) @@ -78319,7 +86387,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_Reso __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe8b92e4 = (__args, __args_len, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x734cfcb = (__args, __args_len, __async_mode, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) * __pyx_result = Resource.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Resource__set_state( __pyx_result, __pyx_state) @@ -78342,7 +86410,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_Reso __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe8b92e4 = (__args, __args_len, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x734cfcb = (__args, __args_len, __async_mode, __initialized, __initializer, __kwargs, __kwargs_len, __last_overriding, __overridden, __resource, __shutdowner))" % __pyx_checksum) * __pyx_result = Resource.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Resource__set_state( __pyx_result, __pyx_state) @@ -78355,7 +86423,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_Reso * __pyx_unpickle_Resource__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Resource__set_state(Resource __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__initialized = __pyx_state[2]; __pyx_result.__initializer = __pyx_state[3]; __pyx_result.__kwargs = __pyx_state[4]; __pyx_result.__kwargs_len = __pyx_state[5]; __pyx_result.__last_overriding = __pyx_state[6]; __pyx_result.__overridden = __pyx_state[7]; __pyx_result.__resource = __pyx_state[8]; __pyx_result.__shutdowner = __pyx_state[9] + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__initialized = __pyx_state[3]; __pyx_result.__initializer = __pyx_state[4]; __pyx_result.__kwargs = __pyx_state[5]; __pyx_result.__kwargs_len = __pyx_state[6]; __pyx_result.__last_overriding = __pyx_state[7]; __pyx_result.__overridden = __pyx_state[8]; __pyx_result.__resource = __pyx_state[9]; __pyx_result.__shutdowner = __pyx_state[10] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -78388,8 +86456,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_93__pyx_unpickle_Reso * __pyx_unpickle_Resource__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Resource__set_state(Resource __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__initialized = __pyx_state[2]; __pyx_result.__initializer = __pyx_state[3]; __pyx_result.__kwargs = __pyx_state[4]; __pyx_result.__kwargs_len = __pyx_state[5]; __pyx_result.__last_overriding = __pyx_state[6]; __pyx_result.__overridden = __pyx_state[7]; __pyx_result.__resource = __pyx_state[8]; __pyx_result.__shutdowner = __pyx_state[9] - * if len(__pyx_state) > 10 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__initialized = __pyx_state[3]; __pyx_result.__initializer = __pyx_state[4]; __pyx_result.__kwargs = __pyx_state[5]; __pyx_result.__kwargs_len = __pyx_state[6]; __pyx_result.__last_overriding = __pyx_state[7]; __pyx_result.__overridden = __pyx_state[8]; __pyx_result.__resource = __pyx_state[9]; __pyx_result.__shutdowner = __pyx_state[10] + * if len(__pyx_state) > 11 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resource__set_state(struct __pyx_obj_19dependency_injector_9providers_Resource *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -78412,9 +86480,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Resource__set_state(Resource __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__initialized = __pyx_state[2]; __pyx_result.__initializer = __pyx_state[3]; __pyx_result.__kwargs = __pyx_state[4]; __pyx_result.__kwargs_len = __pyx_state[5]; __pyx_result.__last_overriding = __pyx_state[6]; __pyx_result.__overridden = __pyx_state[7]; __pyx_result.__resource = __pyx_state[8]; __pyx_result.__shutdowner = __pyx_state[9] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 10 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[10]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__initialized = __pyx_state[3]; __pyx_result.__initializer = __pyx_state[4]; __pyx_result.__kwargs = __pyx_state[5]; __pyx_result.__kwargs_len = __pyx_state[6]; __pyx_result.__last_overriding = __pyx_state[7]; __pyx_result.__overridden = __pyx_state[8]; __pyx_result.__resource = __pyx_state[9]; __pyx_result.__shutdowner = __pyx_state[10] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 11 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[11]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -78443,6 +86511,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v___pyx_result->__pyx___initialized = __pyx_t_3; @@ -78450,7 +86527,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___initializer); @@ -78461,7 +86538,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -78473,7 +86550,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -78482,7 +86559,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -78494,7 +86571,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -78506,7 +86583,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 9, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___resource); @@ -78517,7 +86594,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 9, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 10, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___shutdowner); @@ -78527,16 +86604,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc /* "(tree fragment)":13 * cdef __pyx_unpickle_Resource__set_state(Resource __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__initialized = __pyx_state[2]; __pyx_result.__initializer = __pyx_state[3]; __pyx_result.__kwargs = __pyx_state[4]; __pyx_result.__kwargs_len = __pyx_state[5]; __pyx_result.__last_overriding = __pyx_state[6]; __pyx_result.__overridden = __pyx_state[7]; __pyx_result.__resource = __pyx_state[8]; __pyx_result.__shutdowner = __pyx_state[9] - * if len(__pyx_state) > 10 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[10]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__initialized = __pyx_state[3]; __pyx_result.__initializer = __pyx_state[4]; __pyx_result.__kwargs = __pyx_state[5]; __pyx_result.__kwargs_len = __pyx_state[6]; __pyx_result.__last_overriding = __pyx_state[7]; __pyx_result.__overridden = __pyx_state[8]; __pyx_result.__resource = __pyx_state[9]; __pyx_result.__shutdowner = __pyx_state[10] + * if len(__pyx_state) > 11 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[11]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 10) != 0); + __pyx_t_5 = ((__pyx_t_4 > 11) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -78549,9 +86626,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__initialized = __pyx_state[2]; __pyx_result.__initializer = __pyx_state[3]; __pyx_result.__kwargs = __pyx_state[4]; __pyx_result.__kwargs_len = __pyx_state[5]; __pyx_result.__last_overriding = __pyx_state[6]; __pyx_result.__overridden = __pyx_state[7]; __pyx_result.__resource = __pyx_state[8]; __pyx_result.__shutdowner = __pyx_state[9] - * if len(__pyx_state) > 10 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[10]) # <<<<<<<<<<<<<< + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__initialized = __pyx_state[3]; __pyx_result.__initializer = __pyx_state[4]; __pyx_result.__kwargs = __pyx_state[5]; __pyx_result.__kwargs_len = __pyx_state[6]; __pyx_result.__last_overriding = __pyx_state[7]; __pyx_result.__overridden = __pyx_state[8]; __pyx_result.__resource = __pyx_state[9]; __pyx_result.__shutdowner = __pyx_state[10] + * if len(__pyx_state) > 11 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[11]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -78562,7 +86639,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 10, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 11, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -78584,9 +86661,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc /* "(tree fragment)":13 * cdef __pyx_unpickle_Resource__set_state(Resource __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__initialized = __pyx_state[2]; __pyx_result.__initializer = __pyx_state[3]; __pyx_result.__kwargs = __pyx_state[4]; __pyx_result.__kwargs_len = __pyx_state[5]; __pyx_result.__last_overriding = __pyx_state[6]; __pyx_result.__overridden = __pyx_state[7]; __pyx_result.__resource = __pyx_state[8]; __pyx_result.__shutdowner = __pyx_state[9] - * if len(__pyx_state) > 10 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[10]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__initialized = __pyx_state[3]; __pyx_result.__initializer = __pyx_state[4]; __pyx_result.__kwargs = __pyx_state[5]; __pyx_result.__kwargs_len = __pyx_state[6]; __pyx_result.__last_overriding = __pyx_state[7]; __pyx_result.__overridden = __pyx_state[8]; __pyx_result.__resource = __pyx_state[9]; __pyx_result.__shutdowner = __pyx_state[10] + * if len(__pyx_state) > 11 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[11]) */ } @@ -78594,8 +86671,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc * __pyx_unpickle_Resource__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Resource__set_state(Resource __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__initialized = __pyx_state[2]; __pyx_result.__initializer = __pyx_state[3]; __pyx_result.__kwargs = __pyx_state[4]; __pyx_result.__kwargs_len = __pyx_state[5]; __pyx_result.__last_overriding = __pyx_state[6]; __pyx_result.__overridden = __pyx_state[7]; __pyx_result.__resource = __pyx_state[8]; __pyx_result.__shutdowner = __pyx_state[9] - * if len(__pyx_state) > 10 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__initialized = __pyx_state[3]; __pyx_result.__initializer = __pyx_state[4]; __pyx_result.__kwargs = __pyx_state[5]; __pyx_result.__kwargs_len = __pyx_state[6]; __pyx_result.__last_overriding = __pyx_state[7]; __pyx_result.__overridden = __pyx_state[8]; __pyx_result.__resource = __pyx_state[9]; __pyx_result.__shutdowner = __pyx_state[10] + * if len(__pyx_state) > 11 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -78621,9 +86698,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Resourc */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_96__pyx_unpickle_Container(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_96__pyx_unpickle_Container = {"__pyx_unpickle_Container", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_96__pyx_unpickle_Container, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_96__pyx_unpickle_Container(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_102__pyx_unpickle_Container(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_102__pyx_unpickle_Container = {"__pyx_unpickle_Container", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_102__pyx_unpickle_Container, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_102__pyx_unpickle_Container(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -78689,14 +86766,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_96__pyx_unpickle_Cont __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_Container(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_Container(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_Container(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_Container(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -78715,18 +86792,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_Cont /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x0433d08: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x1bd47ec: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0433d08 = (__container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1bd47ec = (__async_mode, __container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x0433d08) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x1bd47ec) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x0433d08: + * if __pyx_checksum != 0x1bd47ec: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0433d08 = (__container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1bd47ec = (__async_mode, __container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) * __pyx_result = Container.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -78745,15 +86822,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_Cont __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x0433d08: + * if __pyx_checksum != 0x1bd47ec: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0433d08 = (__container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1bd47ec = (__async_mode, __container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Container.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x04, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x1b, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -78780,15 +86857,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_Cont /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x0433d08: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x1bd47ec: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0433d08 = (__container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1bd47ec = (__async_mode, __container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0433d08 = (__container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1bd47ec = (__async_mode, __container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) * __pyx_result = Container.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Container__set_state( __pyx_result, __pyx_state) @@ -78814,7 +86891,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_Cont __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0433d08 = (__container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1bd47ec = (__async_mode, __container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) * __pyx_result = Container.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Container__set_state( __pyx_result, __pyx_state) @@ -78837,7 +86914,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_Cont __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0433d08 = (__container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x1bd47ec = (__async_mode, __container, __container_cls, __last_overriding, __overridden, __overriding_providers))" % __pyx_checksum) * __pyx_result = Container.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Container__set_state( __pyx_result, __pyx_state) @@ -78850,7 +86927,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_Cont * __pyx_unpickle_Container__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Container__set_state(Container __pyx_result, tuple __pyx_state): - * __pyx_result.__container = __pyx_state[0]; __pyx_result.__container_cls = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__overriding_providers = __pyx_state[4] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__container = __pyx_state[1]; __pyx_result.__container_cls = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__overriding_providers = __pyx_state[5] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -78883,8 +86960,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_95__pyx_unpickle_Cont * __pyx_unpickle_Container__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Container__set_state(Container __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__container = __pyx_state[0]; __pyx_result.__container_cls = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__overriding_providers = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__container = __pyx_state[1]; __pyx_result.__container_cls = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__overriding_providers = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Container__set_state(struct __pyx_obj_19dependency_injector_9providers_Container *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -78892,12 +86969,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -78906,9 +86984,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Container__set_state(Container __pyx_result, tuple __pyx_state): - * __pyx_result.__container = __pyx_state[0]; __pyx_result.__container_cls = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__overriding_providers = __pyx_state[4] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__container = __pyx_state[1]; __pyx_result.__container_cls = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__overriding_providers = __pyx_state[5] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -78916,6 +86994,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___container); __Pyx_DECREF(__pyx_v___pyx_result->__pyx___container); @@ -78925,7 +87012,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___container_cls); @@ -78936,7 +87023,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -78948,7 +87035,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -78960,7 +87047,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -78971,66 +87058,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain /* "(tree fragment)":13 * cdef __pyx_unpickle_Container__set_state(Container __pyx_result, tuple __pyx_state): - * __pyx_result.__container = __pyx_state[0]; __pyx_result.__container_cls = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__overriding_providers = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__container = __pyx_state[1]; __pyx_result.__container_cls = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__overriding_providers = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 5) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 6) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__container = __pyx_state[0]; __pyx_result.__container_cls = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__overriding_providers = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__container = __pyx_state[1]; __pyx_result.__container_cls = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__overriding_providers = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[6]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_Container__set_state(Container __pyx_result, tuple __pyx_state): - * __pyx_result.__container = __pyx_state[0]; __pyx_result.__container_cls = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__overriding_providers = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[5]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__container = __pyx_state[1]; __pyx_result.__container_cls = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__overriding_providers = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[6]) */ } @@ -79038,8 +87125,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain * __pyx_unpickle_Container__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Container__set_state(Container __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__container = __pyx_state[0]; __pyx_result.__container_cls = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__overriding_providers = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__container = __pyx_state[1]; __pyx_result.__container_cls = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4]; __pyx_result.__overriding_providers = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -79047,9 +87134,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_Container__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -79065,9 +87152,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Contain */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_98__pyx_unpickle_Selector(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_98__pyx_unpickle_Selector = {"__pyx_unpickle_Selector", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_98__pyx_unpickle_Selector, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_98__pyx_unpickle_Selector(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_104__pyx_unpickle_Selector(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_104__pyx_unpickle_Selector = {"__pyx_unpickle_Selector", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_104__pyx_unpickle_Selector, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_104__pyx_unpickle_Selector(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -79133,14 +87220,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_98__pyx_unpickle_Sele __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Selector(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_Selector(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Selector(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_Selector(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -79159,18 +87246,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Sele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x570b822: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x6a94d6b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x570b822 = (__last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x6a94d6b = (__async_mode, __last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x570b822) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x6a94d6b) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x570b822: + * if __pyx_checksum != 0x6a94d6b: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x570b822 = (__last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x6a94d6b = (__async_mode, __last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) * __pyx_result = Selector.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -79189,15 +87276,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Sele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x570b822: + * if __pyx_checksum != 0x6a94d6b: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x570b822 = (__last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x6a94d6b = (__async_mode, __last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = Selector.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x57, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x6a, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -79224,15 +87311,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Sele /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x570b822: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x6a94d6b: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x570b822 = (__last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x6a94d6b = (__async_mode, __last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x570b822 = (__last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x6a94d6b = (__async_mode, __last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) * __pyx_result = Selector.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_Selector__set_state( __pyx_result, __pyx_state) @@ -79258,7 +87345,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Sele __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x570b822 = (__last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x6a94d6b = (__async_mode, __last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) * __pyx_result = Selector.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Selector__set_state( __pyx_result, __pyx_state) @@ -79281,7 +87368,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Sele __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x570b822 = (__last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x6a94d6b = (__async_mode, __last_overriding, __overridden, __providers, __selector))" % __pyx_checksum) * __pyx_result = Selector.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_Selector__set_state( __pyx_result, __pyx_state) @@ -79294,7 +87381,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Sele * __pyx_unpickle_Selector__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_Selector__set_state(Selector __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__selector = __pyx_state[3] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__selector = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -79327,8 +87414,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_97__pyx_unpickle_Sele * __pyx_unpickle_Selector__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Selector__set_state(Selector __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__selector = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__selector = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selector__set_state(struct __pyx_obj_19dependency_injector_9providers_Selector *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -79336,12 +87423,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selecto __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -79350,9 +87438,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selecto /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_Selector__set_state(Selector __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__selector = __pyx_state[3] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__selector = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -79360,6 +87448,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selecto } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___last_overriding); @@ -79370,7 +87467,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selecto PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -79382,7 +87479,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selecto PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -79394,7 +87491,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selecto PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___selector); @@ -79404,66 +87501,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selecto /* "(tree fragment)":13 * cdef __pyx_unpickle_Selector__set_state(Selector __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__selector = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__selector = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 4) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__selector = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__selector = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_Selector__set_state(Selector __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__selector = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__selector = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -79471,8 +87568,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selecto * __pyx_unpickle_Selector__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Selector__set_state(Selector __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__selector = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__selector = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -79480,9 +87577,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selecto goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_Selector__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -79498,9 +87595,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Selecto */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_100__pyx_unpickle_ProvidedInstance(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_100__pyx_unpickle_ProvidedInstance = {"__pyx_unpickle_ProvidedInstance", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_100__pyx_unpickle_ProvidedInstance, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_100__pyx_unpickle_ProvidedInstance(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_106__pyx_unpickle_ProvidedInstance(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_106__pyx_unpickle_ProvidedInstance = {"__pyx_unpickle_ProvidedInstance", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_106__pyx_unpickle_ProvidedInstance, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_106__pyx_unpickle_ProvidedInstance(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -79566,14 +87663,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_100__pyx_unpickle_Pro __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_ProvidedInstance(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_ProvidedInstance(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_ProvidedInstance(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_ProvidedInstance(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -79592,18 +87689,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_Prov /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x0d07ffc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xfd61095: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0d07ffc = (__last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfd61095 = (__async_mode, __last_overriding, __overridden, __provider))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x0d07ffc) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xfd61095) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x0d07ffc: + * if __pyx_checksum != 0xfd61095: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0d07ffc = (__last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfd61095 = (__async_mode, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = ProvidedInstance.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -79622,15 +87719,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_Prov __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x0d07ffc: + * if __pyx_checksum != 0xfd61095: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0d07ffc = (__last_overriding, __overridden, __provider))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfd61095 = (__async_mode, __last_overriding, __overridden, __provider))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = ProvidedInstance.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x0d, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xfd, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -79657,15 +87754,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_Prov /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x0d07ffc: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xfd61095: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0d07ffc = (__last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfd61095 = (__async_mode, __last_overriding, __overridden, __provider))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0d07ffc = (__last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfd61095 = (__async_mode, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = ProvidedInstance.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_ProvidedInstance__set_state( __pyx_result, __pyx_state) @@ -79691,7 +87788,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_Prov __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0d07ffc = (__last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfd61095 = (__async_mode, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = ProvidedInstance.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ProvidedInstance__set_state( __pyx_result, __pyx_state) @@ -79714,7 +87811,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_Prov __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x0d07ffc = (__last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xfd61095 = (__async_mode, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = ProvidedInstance.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ProvidedInstance__set_state( __pyx_result, __pyx_state) @@ -79727,7 +87824,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_Prov * __pyx_unpickle_ProvidedInstance__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_ProvidedInstance__set_state(ProvidedInstance __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provider = __pyx_state[2] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -79760,8 +87857,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_99__pyx_unpickle_Prov * __pyx_unpickle_ProvidedInstance__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ProvidedInstance__set_state(ProvidedInstance __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provider = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ProvidedInstance__set_state(struct __pyx_obj_19dependency_injector_9providers_ProvidedInstance *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -79769,12 +87866,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -79783,9 +87881,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_ProvidedInstance__set_state(ProvidedInstance __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provider = __pyx_state[2] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -79793,6 +87891,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx_base.__pyx___last_overriding); @@ -79803,7 +87910,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -79815,7 +87922,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -79826,66 +87933,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide /* "(tree fragment)":13 * cdef __pyx_unpickle_ProvidedInstance__set_state(ProvidedInstance __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provider = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 3) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 4) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provider = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[3]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_ProvidedInstance__set_state(ProvidedInstance __pyx_result, tuple __pyx_state): - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provider = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[3]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[4]) */ } @@ -79893,8 +88000,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide * __pyx_unpickle_ProvidedInstance__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ProvidedInstance__set_state(ProvidedInstance __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provider = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -79902,9 +88009,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_ProvidedInstance__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -79920,9 +88027,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Provide */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_102__pyx_unpickle_AttributeGetter(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_102__pyx_unpickle_AttributeGetter = {"__pyx_unpickle_AttributeGetter", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_102__pyx_unpickle_AttributeGetter, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_102__pyx_unpickle_AttributeGetter(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_108__pyx_unpickle_AttributeGetter(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_108__pyx_unpickle_AttributeGetter = {"__pyx_unpickle_AttributeGetter", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_108__pyx_unpickle_AttributeGetter, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_108__pyx_unpickle_AttributeGetter(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -79988,14 +88095,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_102__pyx_unpickle_Att __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_AttributeGetter(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_107__pyx_unpickle_AttributeGetter(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_AttributeGetter(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_107__pyx_unpickle_AttributeGetter(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -80014,18 +88121,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_Att /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xe01ff48: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x7ec84e3: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe01ff48 = (__attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7ec84e3 = (__async_mode, __attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xe01ff48) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x7ec84e3) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0xe01ff48: + * if __pyx_checksum != 0x7ec84e3: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe01ff48 = (__attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7ec84e3 = (__async_mode, __attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = AttributeGetter.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -80044,15 +88151,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_Att __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0xe01ff48: + * if __pyx_checksum != 0x7ec84e3: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe01ff48 = (__attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7ec84e3 = (__async_mode, __attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = AttributeGetter.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xe0, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x7e, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -80079,15 +88186,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_Att /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0xe01ff48: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0x7ec84e3: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe01ff48 = (__attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7ec84e3 = (__async_mode, __attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe01ff48 = (__attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7ec84e3 = (__async_mode, __attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = AttributeGetter.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_AttributeGetter__set_state( __pyx_result, __pyx_state) @@ -80113,7 +88220,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_Att __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe01ff48 = (__attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7ec84e3 = (__async_mode, __attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = AttributeGetter.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_AttributeGetter__set_state( __pyx_result, __pyx_state) @@ -80136,7 +88243,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_Att __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe01ff48 = (__attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0x7ec84e3 = (__async_mode, __attribute, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = AttributeGetter.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_AttributeGetter__set_state( __pyx_result, __pyx_state) @@ -80149,7 +88256,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_Att * __pyx_unpickle_AttributeGetter__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_AttributeGetter__set_state(AttributeGetter __pyx_result, tuple __pyx_state): - * __pyx_result.__attribute = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attribute = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -80182,8 +88289,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_101__pyx_unpickle_Att * __pyx_unpickle_AttributeGetter__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AttributeGetter__set_state(AttributeGetter __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attribute = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attribute = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_AttributeGetter__set_state(struct __pyx_obj_19dependency_injector_9providers_AttributeGetter *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -80191,12 +88298,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Attribu __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -80205,9 +88313,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Attribu /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_AttributeGetter__set_state(AttributeGetter __pyx_result, tuple __pyx_state): - * __pyx_result.__attribute = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attribute = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -80215,6 +88323,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Attribu } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___attribute); __Pyx_DECREF(__pyx_v___pyx_result->__pyx___attribute); @@ -80224,7 +88341,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Attribu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -80236,7 +88353,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Attribu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -80248,7 +88365,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Attribu PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -80259,66 +88376,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Attribu /* "(tree fragment)":13 * cdef __pyx_unpickle_AttributeGetter__set_state(AttributeGetter __pyx_result, tuple __pyx_state): - * __pyx_result.__attribute = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attribute = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 4) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__attribute = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attribute = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_AttributeGetter__set_state(AttributeGetter __pyx_result, tuple __pyx_state): - * __pyx_result.__attribute = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attribute = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -80326,8 +88443,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Attribu * __pyx_unpickle_AttributeGetter__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AttributeGetter__set_state(AttributeGetter __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attribute = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attribute = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -80335,9 +88452,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Attribu goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_AttributeGetter__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -80353,9 +88470,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Attribu */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_104__pyx_unpickle_ItemGetter(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_104__pyx_unpickle_ItemGetter = {"__pyx_unpickle_ItemGetter", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_104__pyx_unpickle_ItemGetter, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_104__pyx_unpickle_ItemGetter(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_110__pyx_unpickle_ItemGetter(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_110__pyx_unpickle_ItemGetter = {"__pyx_unpickle_ItemGetter", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_110__pyx_unpickle_ItemGetter, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_110__pyx_unpickle_ItemGetter(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -80421,14 +88538,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_104__pyx_unpickle_Ite __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_ItemGetter(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_109__pyx_unpickle_ItemGetter(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_ItemGetter(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_109__pyx_unpickle_ItemGetter(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -80447,18 +88564,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_Ite /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x5818eae: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xa0575be: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x5818eae = (__item, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa0575be = (__async_mode, __item, __last_overriding, __overridden, __provider))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x5818eae) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xa0575be) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x5818eae: + * if __pyx_checksum != 0xa0575be: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x5818eae = (__item, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa0575be = (__async_mode, __item, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = ItemGetter.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -80477,15 +88594,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_Ite __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x5818eae: + * if __pyx_checksum != 0xa0575be: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x5818eae = (__item, __last_overriding, __overridden, __provider))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa0575be = (__async_mode, __item, __last_overriding, __overridden, __provider))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = ItemGetter.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x58, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xa0, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -80512,15 +88629,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_Ite /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x5818eae: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xa0575be: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x5818eae = (__item, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa0575be = (__async_mode, __item, __last_overriding, __overridden, __provider))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x5818eae = (__item, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa0575be = (__async_mode, __item, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = ItemGetter.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_ItemGetter__set_state( __pyx_result, __pyx_state) @@ -80546,7 +88663,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_Ite __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x5818eae = (__item, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa0575be = (__async_mode, __item, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = ItemGetter.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ItemGetter__set_state( __pyx_result, __pyx_state) @@ -80569,7 +88686,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_Ite __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x5818eae = (__item, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xa0575be = (__async_mode, __item, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = ItemGetter.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_ItemGetter__set_state( __pyx_result, __pyx_state) @@ -80582,7 +88699,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_Ite * __pyx_unpickle_ItemGetter__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_ItemGetter__set_state(ItemGetter __pyx_result, tuple __pyx_state): - * __pyx_result.__item = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__item = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -80615,8 +88732,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_103__pyx_unpickle_Ite * __pyx_unpickle_ItemGetter__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ItemGetter__set_state(ItemGetter __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__item = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__item = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGetter__set_state(struct __pyx_obj_19dependency_injector_9providers_ItemGetter *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -80624,12 +88741,13 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGet __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; - Py_ssize_t __pyx_t_3; - int __pyx_t_4; + int __pyx_t_3; + Py_ssize_t __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; + int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; @@ -80638,9 +88756,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGet /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_ItemGetter__set_state(ItemGetter __pyx_result, tuple __pyx_state): - * __pyx_result.__item = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__item = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -80648,6 +88766,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGet } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___item); __Pyx_DECREF(__pyx_v___pyx_result->__pyx___item); @@ -80657,7 +88784,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGet PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -80669,7 +88796,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGet PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -80681,7 +88808,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGet PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -80692,66 +88819,66 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGet /* "(tree fragment)":13 * cdef __pyx_unpickle_ItemGetter__set_state(ItemGetter __pyx_result, tuple __pyx_state): - * __pyx_result.__item = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__item = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } - __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_4 = ((__pyx_t_3 > 4) != 0); - if (__pyx_t_4) { + __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_5 = ((__pyx_t_4 > 5) != 0); + if (__pyx_t_5) { } else { - __pyx_t_2 = __pyx_t_4; + __pyx_t_3 = __pyx_t_5; goto __pyx_L4_bool_binop_done; } - __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = (__pyx_t_4 != 0); - __pyx_t_2 = __pyx_t_5; + __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(2, 13, __pyx_L1_error) + __pyx_t_6 = (__pyx_t_5 != 0); + __pyx_t_3 = __pyx_t_6; __pyx_L4_bool_binop_done:; - if (__pyx_t_2) { + if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__item = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[4]) # <<<<<<<<<<<<<< + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__item = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[5]) # <<<<<<<<<<<<<< */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 14, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __pyx_t_8 = NULL; - if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { - __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); - if (likely(__pyx_t_8)) { - PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); - __Pyx_INCREF(__pyx_t_8); + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_9 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { + __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); + if (likely(__pyx_t_9)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); - __Pyx_DECREF_SET(__pyx_t_7, function); + __Pyx_DECREF_SET(__pyx_t_8, function); } } - __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); - __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); + __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":13 * cdef __pyx_unpickle_ItemGetter__set_state(ItemGetter __pyx_result, tuple __pyx_state): - * __pyx_result.__item = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[4]) + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__item = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[5]) */ } @@ -80759,8 +88886,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGet * __pyx_unpickle_ItemGetter__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ItemGetter__set_state(ItemGetter __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__item = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__item = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -80768,9 +88895,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGet goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); - __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__pyx_unpickle_ItemGetter__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; @@ -80786,9 +88913,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_ItemGet */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_106__pyx_unpickle_MethodCaller(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_106__pyx_unpickle_MethodCaller = {"__pyx_unpickle_MethodCaller", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_106__pyx_unpickle_MethodCaller, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_106__pyx_unpickle_MethodCaller(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_112__pyx_unpickle_MethodCaller(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_112__pyx_unpickle_MethodCaller = {"__pyx_unpickle_MethodCaller", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_112__pyx_unpickle_MethodCaller, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_112__pyx_unpickle_MethodCaller(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -80854,14 +88981,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_106__pyx_unpickle_Met __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_MethodCaller(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_111__pyx_unpickle_MethodCaller(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_MethodCaller(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_111__pyx_unpickle_MethodCaller(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -80880,18 +89007,18 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_Met /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x2026b20: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xe57552f: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2026b20 = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe57552f = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) */ - __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x2026b20) != 0); + __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xe57552f) != 0); if (__pyx_t_1) { /* "(tree fragment)":5 * cdef object __pyx_result - * if __pyx_checksum != 0x2026b20: + * if __pyx_checksum != 0xe57552f: * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<< - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2026b20 = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe57552f = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = MethodCaller.__new__(__pyx_type) */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 5, __pyx_L1_error) @@ -80910,15 +89037,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_Met __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":6 - * if __pyx_checksum != 0x2026b20: + * if __pyx_checksum != 0xe57552f: * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2026b20 = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) # <<<<<<<<<<<<<< + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe57552f = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) # <<<<<<<<<<<<<< * __pyx_result = MethodCaller.__new__(__pyx_type) * if __pyx_state is not None: */ __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x20_2, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xe5, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_INCREF(__pyx_v___pyx_PickleError); @@ -80945,15 +89072,15 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_Met /* "(tree fragment)":4 * cdef object __pyx_PickleError * cdef object __pyx_result - * if __pyx_checksum != 0x2026b20: # <<<<<<<<<<<<<< + * if __pyx_checksum != 0xe57552f: # <<<<<<<<<<<<<< * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2026b20 = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe57552f = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) */ } /* "(tree fragment)":7 * from pickle import PickleError as __pyx_PickleError - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2026b20 = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe57552f = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = MethodCaller.__new__(__pyx_type) # <<<<<<<<<<<<<< * if __pyx_state is not None: * __pyx_unpickle_MethodCaller__set_state( __pyx_result, __pyx_state) @@ -80979,7 +89106,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_Met __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2026b20 = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe57552f = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = MethodCaller.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_MethodCaller__set_state( __pyx_result, __pyx_state) @@ -81002,7 +89129,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_Met __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "(tree fragment)":8 - * raise __pyx_PickleError("Incompatible checksums (%s vs 0x2026b20 = (__args, __args_len, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) + * raise __pyx_PickleError("Incompatible checksums (%s vs 0xe57552f = (__args, __args_len, __async_mode, __kwargs, __kwargs_len, __last_overriding, __overridden, __provider))" % __pyx_checksum) * __pyx_result = MethodCaller.__new__(__pyx_type) * if __pyx_state is not None: # <<<<<<<<<<<<<< * __pyx_unpickle_MethodCaller__set_state( __pyx_result, __pyx_state) @@ -81015,7 +89142,7 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_Met * __pyx_unpickle_MethodCaller__set_state( __pyx_result, __pyx_state) * return __pyx_result # <<<<<<<<<<<<<< * cdef __pyx_unpickle_MethodCaller__set_state(MethodCaller __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provider = __pyx_state[6] + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provider = __pyx_state[7] */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v___pyx_result); @@ -81048,8 +89175,8 @@ static PyObject *__pyx_pf_19dependency_injector_9providers_105__pyx_unpickle_Met * __pyx_unpickle_MethodCaller__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_MethodCaller__set_state(MethodCaller __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provider = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provider = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodCaller__set_state(struct __pyx_obj_19dependency_injector_9providers_MethodCaller *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) { @@ -81072,9 +89199,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC /* "(tree fragment)":12 * return __pyx_result * cdef __pyx_unpickle_MethodCaller__set_state(MethodCaller __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provider = __pyx_state[6] # <<<<<<<<<<<<<< - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provider = __pyx_state[7] # <<<<<<<<<<<<<< + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); @@ -81103,6 +89230,15 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC } __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v___pyx_result->__pyx_base.__pyx___async_mode = __pyx_t_2; + if (unlikely(__pyx_v___pyx_state == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(2, 12, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v___pyx_result->__pyx___kwargs); @@ -81113,7 +89249,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; @@ -81122,7 +89258,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -81134,7 +89270,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -81146,7 +89282,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 12, __pyx_L1_error) } - __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_19dependency_injector_9providers_Provider))))) __PYX_ERR(2, 12, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); @@ -81157,16 +89293,16 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC /* "(tree fragment)":13 * cdef __pyx_unpickle_MethodCaller__set_state(MethodCaller __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provider = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provider = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ if (unlikely(__pyx_v___pyx_state == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); __PYX_ERR(2, 13, __pyx_L1_error) } __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(2, 13, __pyx_L1_error) - __pyx_t_5 = ((__pyx_t_4 > 7) != 0); + __pyx_t_5 = ((__pyx_t_4 > 8) != 0); if (__pyx_t_5) { } else { __pyx_t_3 = __pyx_t_5; @@ -81179,9 +89315,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC if (__pyx_t_3) { /* "(tree fragment)":14 - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provider = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): - * __pyx_result.__dict__.update(__pyx_state[7]) # <<<<<<<<<<<<<< + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provider = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__dict__.update(__pyx_state[8]) # <<<<<<<<<<<<<< */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); @@ -81192,7 +89328,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 14, __pyx_L1_error) } - __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) + __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { @@ -81214,9 +89350,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC /* "(tree fragment)":13 * cdef __pyx_unpickle_MethodCaller__set_state(MethodCaller __pyx_result, tuple __pyx_state): - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provider = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< - * __pyx_result.__dict__.update(__pyx_state[7]) + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provider = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<< + * __pyx_result.__dict__.update(__pyx_state[8]) */ } @@ -81224,8 +89360,8 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC * __pyx_unpickle_MethodCaller__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_MethodCaller__set_state(MethodCaller __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provider = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provider = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ /* function exit code */ @@ -81251,9 +89387,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_MethodC */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_108__pyx_unpickle_Injection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_108__pyx_unpickle_Injection = {"__pyx_unpickle_Injection", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_108__pyx_unpickle_Injection, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_108__pyx_unpickle_Injection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_114__pyx_unpickle_Injection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_114__pyx_unpickle_Injection = {"__pyx_unpickle_Injection", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_114__pyx_unpickle_Injection, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_114__pyx_unpickle_Injection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -81319,14 +89455,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_108__pyx_unpickle_Inj __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_107__pyx_unpickle_Injection(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_113__pyx_unpickle_Injection(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_107__pyx_unpickle_Injection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_113__pyx_unpickle_Injection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -81676,9 +89812,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Injecti */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_110__pyx_unpickle_PositionalInjection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_110__pyx_unpickle_PositionalInjection = {"__pyx_unpickle_PositionalInjection", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_110__pyx_unpickle_PositionalInjection, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_110__pyx_unpickle_PositionalInjection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_116__pyx_unpickle_PositionalInjection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_116__pyx_unpickle_PositionalInjection = {"__pyx_unpickle_PositionalInjection", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_116__pyx_unpickle_PositionalInjection, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_116__pyx_unpickle_PositionalInjection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -81744,14 +89880,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_110__pyx_unpickle_Pos __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_109__pyx_unpickle_PositionalInjection(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_115__pyx_unpickle_PositionalInjection(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_109__pyx_unpickle_PositionalInjection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_115__pyx_unpickle_PositionalInjection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -82101,9 +90237,9 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_Positio */ /* Python wrapper */ -static PyObject *__pyx_pw_19dependency_injector_9providers_112__pyx_unpickle_NamedInjection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static PyMethodDef __pyx_mdef_19dependency_injector_9providers_112__pyx_unpickle_NamedInjection = {"__pyx_unpickle_NamedInjection", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_112__pyx_unpickle_NamedInjection, METH_VARARGS|METH_KEYWORDS, 0}; -static PyObject *__pyx_pw_19dependency_injector_9providers_112__pyx_unpickle_NamedInjection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pw_19dependency_injector_9providers_118__pyx_unpickle_NamedInjection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyMethodDef __pyx_mdef_19dependency_injector_9providers_118__pyx_unpickle_NamedInjection = {"__pyx_unpickle_NamedInjection", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_118__pyx_unpickle_NamedInjection, METH_VARARGS|METH_KEYWORDS, 0}; +static PyObject *__pyx_pw_19dependency_injector_9providers_118__pyx_unpickle_NamedInjection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v___pyx_type = 0; long __pyx_v___pyx_checksum; PyObject *__pyx_v___pyx_state = 0; @@ -82169,14 +90305,14 @@ static PyObject *__pyx_pw_19dependency_injector_9providers_112__pyx_unpickle_Nam __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - __pyx_r = __pyx_pf_19dependency_injector_9providers_111__pyx_unpickle_NamedInjection(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); + __pyx_r = __pyx_pf_19dependency_injector_9providers_117__pyx_unpickle_NamedInjection(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } -static PyObject *__pyx_pf_19dependency_injector_9providers_111__pyx_unpickle_NamedInjection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { +static PyObject *__pyx_pf_19dependency_injector_9providers_117__pyx_unpickle_NamedInjection(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) { PyObject *__pyx_v___pyx_PickleError = 0; PyObject *__pyx_v___pyx_result = 0; PyObject *__pyx_r = NULL; @@ -82530,7 +90666,7 @@ static PyObject *__pyx_f_19dependency_injector_9providers___pyx_unpickle_NamedIn return __pyx_r; } -/* "dependency_injector/providers.pxd":297 +/* "dependency_injector/providers.pxd":303 * * # Inline helper functions * cdef inline object __get_name(NamedInjection self): # <<<<<<<<<<<<<< @@ -82543,7 +90679,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_na __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get_name", 0); - /* "dependency_injector/providers.pxd":298 + /* "dependency_injector/providers.pxd":304 * # Inline helper functions * cdef inline object __get_name(NamedInjection self): * return self.__name # <<<<<<<<<<<<<< @@ -82555,7 +90691,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_na __pyx_r = __pyx_v_self->__pyx___name; goto __pyx_L0; - /* "dependency_injector/providers.pxd":297 + /* "dependency_injector/providers.pxd":303 * * # Inline helper functions * cdef inline object __get_name(NamedInjection self): # <<<<<<<<<<<<<< @@ -82570,7 +90706,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_na return __pyx_r; } -/* "dependency_injector/providers.pxd":301 +/* "dependency_injector/providers.pxd":307 * * * cdef inline object __get_value(Injection self): # <<<<<<<<<<<<<< @@ -82590,7 +90726,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get_value", 0); - /* "dependency_injector/providers.pxd":302 + /* "dependency_injector/providers.pxd":308 * * cdef inline object __get_value(Injection self): * if self.__call == 0: # <<<<<<<<<<<<<< @@ -82600,7 +90736,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va __pyx_t_1 = ((__pyx_v_self->__pyx___call == 0) != 0); if (__pyx_t_1) { - /* "dependency_injector/providers.pxd":303 + /* "dependency_injector/providers.pxd":309 * cdef inline object __get_value(Injection self): * if self.__call == 0: * return self.__value # <<<<<<<<<<<<<< @@ -82612,7 +90748,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va __pyx_r = __pyx_v_self->__pyx___value; goto __pyx_L0; - /* "dependency_injector/providers.pxd":302 + /* "dependency_injector/providers.pxd":308 * * cdef inline object __get_value(Injection self): * if self.__call == 0: # <<<<<<<<<<<<<< @@ -82621,7 +90757,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va */ } - /* "dependency_injector/providers.pxd":304 + /* "dependency_injector/providers.pxd":310 * if self.__call == 0: * return self.__value * return self.__value() # <<<<<<<<<<<<<< @@ -82642,14 +90778,14 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 304, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 310, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pxd":301 + /* "dependency_injector/providers.pxd":307 * * * cdef inline object __get_value(Injection self): # <<<<<<<<<<<<<< @@ -82670,7 +90806,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va return __pyx_r; } -/* "dependency_injector/providers.pxd":307 +/* "dependency_injector/providers.pxd":313 * * * cdef inline object __get_value_kwargs(Injection self, dict kwargs): # <<<<<<<<<<<<<< @@ -82688,7 +90824,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get_value_kwargs", 0); - /* "dependency_injector/providers.pxd":308 + /* "dependency_injector/providers.pxd":314 * * cdef inline object __get_value_kwargs(Injection self, dict kwargs): * if self.__call == 0: # <<<<<<<<<<<<<< @@ -82698,7 +90834,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va __pyx_t_1 = ((__pyx_v_self->__pyx___call == 0) != 0); if (__pyx_t_1) { - /* "dependency_injector/providers.pxd":309 + /* "dependency_injector/providers.pxd":315 * cdef inline object __get_value_kwargs(Injection self, dict kwargs): * if self.__call == 0: * return self.__value # <<<<<<<<<<<<<< @@ -82710,7 +90846,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va __pyx_r = __pyx_v_self->__pyx___value; goto __pyx_L0; - /* "dependency_injector/providers.pxd":308 + /* "dependency_injector/providers.pxd":314 * * cdef inline object __get_value_kwargs(Injection self, dict kwargs): * if self.__call == 0: # <<<<<<<<<<<<<< @@ -82719,7 +90855,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va */ } - /* "dependency_injector/providers.pxd":310 + /* "dependency_injector/providers.pxd":316 * if self.__call == 0: * return self.__value * return self.__value(**kwargs) # <<<<<<<<<<<<<< @@ -82729,15 +90865,15 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va __Pyx_XDECREF(__pyx_r); if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(0, 310, __pyx_L1_error) + __PYX_ERR(0, 316, __pyx_L1_error) } - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_v_self->__pyx___value, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 310, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_v_self->__pyx___value, __pyx_empty_tuple, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 316, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pxd":307 + /* "dependency_injector/providers.pxd":313 * * * cdef inline object __get_value_kwargs(Injection self, dict kwargs): # <<<<<<<<<<<<<< @@ -82756,7 +90892,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___get_va return __pyx_r; } -/* "dependency_injector/providers.pxd":313 +/* "dependency_injector/providers.pxd":319 * * * cdef inline tuple __separate_prefixed_kwargs(dict kwargs): # <<<<<<<<<<<<<< @@ -82789,31 +90925,31 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__separate_prefixed_kwargs", 0); - /* "dependency_injector/providers.pxd":314 + /* "dependency_injector/providers.pxd":320 * * cdef inline tuple __separate_prefixed_kwargs(dict kwargs): * cdef dict plain_kwargs = {} # <<<<<<<<<<<<<< * cdef dict prefixed_kwargs = {} * */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 314, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 320, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_plain_kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":315 + /* "dependency_injector/providers.pxd":321 * cdef inline tuple __separate_prefixed_kwargs(dict kwargs): * cdef dict plain_kwargs = {} * cdef dict prefixed_kwargs = {} # <<<<<<<<<<<<<< * * for key, value in kwargs.items(): */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 315, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_prefixed_kwargs = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":317 + /* "dependency_injector/providers.pxd":323 * cdef dict prefixed_kwargs = {} * * for key, value in kwargs.items(): # <<<<<<<<<<<<<< @@ -82822,17 +90958,17 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa */ if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "items"); - __PYX_ERR(0, 317, __pyx_L1_error) + __PYX_ERR(0, 323, __pyx_L1_error) } - __pyx_t_1 = __Pyx_PyDict_Items(__pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 317, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_Items(__pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; __pyx_t_4 = NULL; } else { - __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 317, __pyx_L1_error) + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 317, __pyx_L1_error) + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 323, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { @@ -82840,17 +90976,17 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(0, 317, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(0, 323, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 317, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(0, 317, __pyx_L1_error) + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(0, 323, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 317, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } @@ -82860,7 +90996,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); - else __PYX_ERR(0, 317, __pyx_L1_error) + else __PYX_ERR(0, 323, __pyx_L1_error) } break; } @@ -82872,7 +91008,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 317, __pyx_L1_error) + __PYX_ERR(0, 323, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { @@ -82885,15 +91021,15 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(__pyx_t_6); #else - __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 317, __pyx_L1_error) + __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 317, __pyx_L1_error) + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); #endif __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { Py_ssize_t index = -1; - __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 317, __pyx_L1_error) + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; @@ -82901,7 +91037,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __Pyx_GOTREF(__pyx_t_5); index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; __Pyx_GOTREF(__pyx_t_6); - if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 317, __pyx_L1_error) + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 323, __pyx_L1_error) __pyx_t_8 = NULL; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L6_unpacking_done; @@ -82909,7 +91045,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_8 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); - __PYX_ERR(0, 317, __pyx_L1_error) + __PYX_ERR(0, 323, __pyx_L1_error) __pyx_L6_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_key, __pyx_t_5); @@ -82917,27 +91053,27 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_6); __pyx_t_6 = 0; - /* "dependency_injector/providers.pxd":318 + /* "dependency_injector/providers.pxd":324 * * for key, value in kwargs.items(): * if '__' not in key: # <<<<<<<<<<<<<< * plain_kwargs[key] = value * continue */ - __pyx_t_9 = (__Pyx_PySequence_ContainsTF(__pyx_n_s__4, __pyx_v_key, Py_NE)); if (unlikely(__pyx_t_9 < 0)) __PYX_ERR(0, 318, __pyx_L1_error) + __pyx_t_9 = (__Pyx_PySequence_ContainsTF(__pyx_n_s__4, __pyx_v_key, Py_NE)); if (unlikely(__pyx_t_9 < 0)) __PYX_ERR(0, 324, __pyx_L1_error) __pyx_t_10 = (__pyx_t_9 != 0); if (__pyx_t_10) { - /* "dependency_injector/providers.pxd":319 + /* "dependency_injector/providers.pxd":325 * for key, value in kwargs.items(): * if '__' not in key: * plain_kwargs[key] = value # <<<<<<<<<<<<<< * continue * */ - if (unlikely(PyDict_SetItem(__pyx_v_plain_kwargs, __pyx_v_key, __pyx_v_value) < 0)) __PYX_ERR(0, 319, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_plain_kwargs, __pyx_v_key, __pyx_v_value) < 0)) __PYX_ERR(0, 325, __pyx_L1_error) - /* "dependency_injector/providers.pxd":320 + /* "dependency_injector/providers.pxd":326 * if '__' not in key: * plain_kwargs[key] = value * continue # <<<<<<<<<<<<<< @@ -82946,7 +91082,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa */ goto __pyx_L3_continue; - /* "dependency_injector/providers.pxd":318 + /* "dependency_injector/providers.pxd":324 * * for key, value in kwargs.items(): * if '__' not in key: # <<<<<<<<<<<<<< @@ -82955,14 +91091,14 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa */ } - /* "dependency_injector/providers.pxd":322 + /* "dependency_injector/providers.pxd":328 * continue * * index = key.index('__') # <<<<<<<<<<<<<< * prefix, name = key[:index], key[index+2:] * */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_key, __pyx_n_s_index); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 322, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_key, __pyx_n_s_index); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 328, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -82976,24 +91112,24 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa } __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_5, __pyx_n_s__4) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_n_s__4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 322, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 328, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF_SET(__pyx_v_index, __pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":323 + /* "dependency_injector/providers.pxd":329 * * index = key.index('__') * prefix, name = key[:index], key[index+2:] # <<<<<<<<<<<<<< * * if prefix not in prefixed_kwargs: */ - __pyx_t_1 = __Pyx_PyObject_GetSlice(__pyx_v_key, 0, 0, NULL, &__pyx_v_index, NULL, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 323, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetSlice(__pyx_v_key, 0, 0, NULL, &__pyx_v_index, NULL, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 329, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_6 = __Pyx_PyInt_AddObjC(__pyx_v_index, __pyx_int_2, 2, 0, 0); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 323, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyInt_AddObjC(__pyx_v_index, __pyx_int_2, 2, 0, 0); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 329, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_5 = __Pyx_PyObject_GetSlice(__pyx_v_key, 0, 0, &__pyx_t_6, NULL, NULL, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 323, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetSlice(__pyx_v_key, 0, 0, &__pyx_t_6, NULL, NULL, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 329, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_1); @@ -83001,30 +91137,30 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pxd":325 + /* "dependency_injector/providers.pxd":331 * prefix, name = key[:index], key[index+2:] * * if prefix not in prefixed_kwargs: # <<<<<<<<<<<<<< * prefixed_kwargs[prefix] = {} * prefixed_kwargs[prefix][name] = value */ - __pyx_t_10 = (__Pyx_PyDict_ContainsTF(__pyx_v_prefix, __pyx_v_prefixed_kwargs, Py_NE)); if (unlikely(__pyx_t_10 < 0)) __PYX_ERR(0, 325, __pyx_L1_error) + __pyx_t_10 = (__Pyx_PyDict_ContainsTF(__pyx_v_prefix, __pyx_v_prefixed_kwargs, Py_NE)); if (unlikely(__pyx_t_10 < 0)) __PYX_ERR(0, 331, __pyx_L1_error) __pyx_t_9 = (__pyx_t_10 != 0); if (__pyx_t_9) { - /* "dependency_injector/providers.pxd":326 + /* "dependency_injector/providers.pxd":332 * * if prefix not in prefixed_kwargs: * prefixed_kwargs[prefix] = {} # <<<<<<<<<<<<<< * prefixed_kwargs[prefix][name] = value * */ - __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 326, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 332, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - if (unlikely(PyDict_SetItem(__pyx_v_prefixed_kwargs, __pyx_v_prefix, __pyx_t_5) < 0)) __PYX_ERR(0, 326, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_prefixed_kwargs, __pyx_v_prefix, __pyx_t_5) < 0)) __PYX_ERR(0, 332, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pxd":325 + /* "dependency_injector/providers.pxd":331 * prefix, name = key[:index], key[index+2:] * * if prefix not in prefixed_kwargs: # <<<<<<<<<<<<<< @@ -83033,19 +91169,19 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa */ } - /* "dependency_injector/providers.pxd":327 + /* "dependency_injector/providers.pxd":333 * if prefix not in prefixed_kwargs: * prefixed_kwargs[prefix] = {} * prefixed_kwargs[prefix][name] = value # <<<<<<<<<<<<<< * * return plain_kwargs, prefixed_kwargs */ - __pyx_t_5 = __Pyx_PyDict_GetItem(__pyx_v_prefixed_kwargs, __pyx_v_prefix); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 327, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyDict_GetItem(__pyx_v_prefixed_kwargs, __pyx_v_prefix); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 333, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - if (unlikely(PyObject_SetItem(__pyx_t_5, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 327, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_t_5, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 333, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pxd":317 + /* "dependency_injector/providers.pxd":323 * cdef dict prefixed_kwargs = {} * * for key, value in kwargs.items(): # <<<<<<<<<<<<<< @@ -83056,7 +91192,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "dependency_injector/providers.pxd":329 + /* "dependency_injector/providers.pxd":335 * prefixed_kwargs[prefix][name] = value * * return plain_kwargs, prefixed_kwargs # <<<<<<<<<<<<<< @@ -83064,7 +91200,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 329, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 335, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_plain_kwargs); __Pyx_GIVEREF(__pyx_v_plain_kwargs); @@ -83076,7 +91212,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa __pyx_t_2 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pxd":313 + /* "dependency_injector/providers.pxd":319 * * * cdef inline tuple __separate_prefixed_kwargs(dict kwargs): # <<<<<<<<<<<<<< @@ -83106,10 +91242,10 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa return __pyx_r; } -/* "dependency_injector/providers.pxd":334 +/* "dependency_injector/providers.pxd":340 * @cython.boundscheck(False) * @cython.wraparound(False) - * cdef inline tuple __provide_positional_args( # <<<<<<<<<<<<<< + * cdef inline object __provide_positional_args( # <<<<<<<<<<<<<< * tuple args, * tuple inj_args, */ @@ -83117,43 +91253,70 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___separa static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provide_positional_args(PyObject *__pyx_v_args, PyObject *__pyx_v_inj_args, int __pyx_v_inj_args_len) { int __pyx_v_index; PyObject *__pyx_v_positional_args = 0; + PyObject *__pyx_v_awaitables = 0; struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *__pyx_v_injection = 0; + PyObject *__pyx_v_value = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations - int __pyx_t_1; - PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_1 = NULL; + int __pyx_t_2; int __pyx_t_3; int __pyx_t_4; int __pyx_t_5; int __pyx_t_6; + PyObject *__pyx_t_7 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__provide_positional_args", 0); - /* "dependency_injector/providers.pxd":343 + /* "dependency_injector/providers.pxd":346 + * ): + * cdef int index + * cdef list positional_args = [] # <<<<<<<<<<<<<< + * cdef list awaitables = [] + * cdef PositionalInjection injection + */ + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 346, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_positional_args = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":347 + * cdef int index + * cdef list positional_args = [] + * cdef list awaitables = [] # <<<<<<<<<<<<<< + * cdef PositionalInjection injection + * + */ + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 347, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_awaitables = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":350 * cdef PositionalInjection injection * * if inj_args_len == 0: # <<<<<<<<<<<<<< * return args * */ - __pyx_t_1 = ((__pyx_v_inj_args_len == 0) != 0); - if (__pyx_t_1) { + __pyx_t_2 = ((__pyx_v_inj_args_len == 0) != 0); + if (__pyx_t_2) { - /* "dependency_injector/providers.pxd":344 + /* "dependency_injector/providers.pxd":351 * * if inj_args_len == 0: * return args # <<<<<<<<<<<<<< * - * positional_args = list() + * for index in range(inj_args_len): */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_args); __pyx_r = __pyx_v_args; goto __pyx_L0; - /* "dependency_injector/providers.pxd":343 + /* "dependency_injector/providers.pxd":350 * cdef PositionalInjection injection * * if inj_args_len == 0: # <<<<<<<<<<<<<< @@ -83162,107 +91325,177 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ } - /* "dependency_injector/providers.pxd":346 + /* "dependency_injector/providers.pxd":353 * return args * - * positional_args = list() # <<<<<<<<<<<<<< - * for index in range(inj_args_len): - * injection = inj_args[index] - */ - __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 346, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_v_positional_args = ((PyObject*)__pyx_t_2); - __pyx_t_2 = 0; - - /* "dependency_injector/providers.pxd":347 - * - * positional_args = list() * for index in range(inj_args_len): # <<<<<<<<<<<<<< * injection = inj_args[index] - * positional_args.append(__get_value(injection)) + * value = __get_value(injection) */ __pyx_t_3 = __pyx_v_inj_args_len; __pyx_t_4 = __pyx_t_3; for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) { __pyx_v_index = __pyx_t_5; - /* "dependency_injector/providers.pxd":348 - * positional_args = list() + /* "dependency_injector/providers.pxd":354 + * * for index in range(inj_args_len): * injection = inj_args[index] # <<<<<<<<<<<<<< - * positional_args.append(__get_value(injection)) - * positional_args.extend(args) + * value = __get_value(injection) + * positional_args.append(value) */ if (unlikely(__pyx_v_inj_args == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 348, __pyx_L1_error) + __PYX_ERR(0, 354, __pyx_L1_error) } - __pyx_t_2 = PyTuple_GET_ITEM(__pyx_v_inj_args, __pyx_v_index); - __Pyx_INCREF(__pyx_t_2); - __Pyx_XDECREF_SET(__pyx_v_injection, ((struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *)__pyx_t_2)); - __pyx_t_2 = 0; + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_v_inj_args, __pyx_v_index); + __Pyx_INCREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_injection, ((struct __pyx_obj_19dependency_injector_9providers_PositionalInjection *)__pyx_t_1)); + __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":349 + /* "dependency_injector/providers.pxd":355 * for index in range(inj_args_len): * injection = inj_args[index] - * positional_args.append(__get_value(injection)) # <<<<<<<<<<<<<< - * positional_args.extend(args) + * value = __get_value(injection) # <<<<<<<<<<<<<< + * positional_args.append(value) * */ - __pyx_t_2 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_injection)); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 349, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_positional_args, __pyx_t_2); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 349, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_injection)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 355, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":356 + * injection = inj_args[index] + * value = __get_value(injection) + * positional_args.append(value) # <<<<<<<<<<<<<< + * + * if __isawaitable(value): + */ + __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_positional_args, __pyx_v_value); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 356, __pyx_L1_error) + + /* "dependency_injector/providers.pxd":358 + * positional_args.append(value) + * + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((index, value)) + * + */ + __pyx_t_2 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_value) != 0); + if (__pyx_t_2) { + + /* "dependency_injector/providers.pxd":359 + * + * if __isawaitable(value): + * awaitables.append((index, value)) # <<<<<<<<<<<<<< + * + * positional_args.extend(args) + */ + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_index); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_7 = PyTuple_New(2); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 359, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __Pyx_GIVEREF(__pyx_t_1); + PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_1); + __Pyx_INCREF(__pyx_v_value); + __Pyx_GIVEREF(__pyx_v_value); + PyTuple_SET_ITEM(__pyx_t_7, 1, __pyx_v_value); + __pyx_t_1 = 0; + __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_awaitables, __pyx_t_7); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 359, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + + /* "dependency_injector/providers.pxd":358 + * positional_args.append(value) + * + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((index, value)) + * + */ + } } - /* "dependency_injector/providers.pxd":350 - * injection = inj_args[index] - * positional_args.append(__get_value(injection)) + /* "dependency_injector/providers.pxd":361 + * awaitables.append((index, value)) + * * positional_args.extend(args) # <<<<<<<<<<<<<< * - * return tuple(positional_args) + * if awaitables: */ - __pyx_t_6 = __Pyx_PyList_Extend(__pyx_v_positional_args, __pyx_v_args); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 350, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyList_Extend(__pyx_v_positional_args, __pyx_v_args); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 361, __pyx_L1_error) - /* "dependency_injector/providers.pxd":352 + /* "dependency_injector/providers.pxd":363 * positional_args.extend(args) * - * return tuple(positional_args) # <<<<<<<<<<<<<< + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(positional_args, awaitables) + * + */ + __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_awaitables) != 0); + if (__pyx_t_2) { + + /* "dependency_injector/providers.pxd":364 + * + * if awaitables: + * return __awaitable_args_kwargs_future(positional_args, awaitables) # <<<<<<<<<<<<<< + * + * return positional_args + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_7 = __pyx_f_19dependency_injector_9providers___awaitable_args_kwargs_future(__pyx_v_positional_args, __pyx_v_awaitables); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 364, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_r = __pyx_t_7; + __pyx_t_7 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":363 + * positional_args.extend(args) + * + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(positional_args, awaitables) + * + */ + } + + /* "dependency_injector/providers.pxd":366 + * return __awaitable_args_kwargs_future(positional_args, awaitables) + * + * return positional_args # <<<<<<<<<<<<<< * * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = PyList_AsTuple(__pyx_v_positional_args); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 352, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_2); - __pyx_r = ((PyObject*)__pyx_t_2); - __pyx_t_2 = 0; + __Pyx_INCREF(__pyx_v_positional_args); + __pyx_r = __pyx_v_positional_args; goto __pyx_L0; - /* "dependency_injector/providers.pxd":334 + /* "dependency_injector/providers.pxd":340 * @cython.boundscheck(False) * @cython.wraparound(False) - * cdef inline tuple __provide_positional_args( # <<<<<<<<<<<<<< + * cdef inline object __provide_positional_args( # <<<<<<<<<<<<<< * tuple args, * tuple inj_args, */ /* function exit code */ __pyx_L1_error:; - __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_7); __Pyx_AddTraceback("dependency_injector.providers.__provide_positional_args", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_positional_args); + __Pyx_XDECREF(__pyx_v_awaitables); __Pyx_XDECREF((PyObject *)__pyx_v_injection); + __Pyx_XDECREF(__pyx_v_value); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "dependency_injector/providers.pxd":357 +/* "dependency_injector/providers.pxd":371 * @cython.boundscheck(False) * @cython.wraparound(False) - * cdef inline dict __provide_keyword_args( # <<<<<<<<<<<<<< + * cdef inline object __provide_keyword_args( # <<<<<<<<<<<<<< * dict kwargs, * tuple inj_kwargs, */ @@ -83272,25 +91505,51 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid PyObject *__pyx_v_name = 0; PyObject *__pyx_v_value = 0; PyObject *__pyx_v_prefixed = 0; + PyObject *__pyx_v_awaitables = 0; struct __pyx_obj_19dependency_injector_9providers_NamedInjection *__pyx_v_kw_injection = 0; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations - Py_ssize_t __pyx_t_1; - int __pyx_t_2; + PyObject *__pyx_t_1 = NULL; + Py_ssize_t __pyx_t_2; int __pyx_t_3; int __pyx_t_4; int __pyx_t_5; - PyObject *__pyx_t_6 = NULL; - PyObject *__pyx_t_7 = NULL; + int __pyx_t_6; + int __pyx_t_7; PyObject *__pyx_t_8 = NULL; - int __pyx_t_9; + PyObject *__pyx_t_9 = NULL; + int __pyx_t_10; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__provide_keyword_args", 0); __Pyx_INCREF(__pyx_v_kwargs); - /* "dependency_injector/providers.pxd":368 + /* "dependency_injector/providers.pxd":379 + * cdef object name + * cdef object value + * cdef dict prefixed = {} # <<<<<<<<<<<<<< + * cdef list awaitables = [] + * cdef NamedInjection kw_injection + */ + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 379, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_prefixed = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":380 + * cdef object value + * cdef dict prefixed = {} + * cdef list awaitables = [] # <<<<<<<<<<<<<< + * cdef NamedInjection kw_injection + * + */ + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 380, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_awaitables = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":383 * cdef NamedInjection kw_injection * * if len(kwargs) == 0: # <<<<<<<<<<<<<< @@ -83299,70 +91558,116 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(0, 368, __pyx_L1_error) + __PYX_ERR(0, 383, __pyx_L1_error) } - __pyx_t_1 = PyDict_Size(__pyx_v_kwargs); if (unlikely(__pyx_t_1 == ((Py_ssize_t)-1))) __PYX_ERR(0, 368, __pyx_L1_error) - __pyx_t_2 = ((__pyx_t_1 == 0) != 0); - if (__pyx_t_2) { + __pyx_t_2 = PyDict_Size(__pyx_v_kwargs); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 383, __pyx_L1_error) + __pyx_t_3 = ((__pyx_t_2 == 0) != 0); + if (__pyx_t_3) { - /* "dependency_injector/providers.pxd":369 + /* "dependency_injector/providers.pxd":384 * * if len(kwargs) == 0: * for index in range(inj_kwargs_len): # <<<<<<<<<<<<<< * kw_injection = inj_kwargs[index] * name = __get_name(kw_injection) */ - __pyx_t_3 = __pyx_v_inj_kwargs_len; - __pyx_t_4 = __pyx_t_3; - for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) { - __pyx_v_index = __pyx_t_5; + __pyx_t_4 = __pyx_v_inj_kwargs_len; + __pyx_t_5 = __pyx_t_4; + for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) { + __pyx_v_index = __pyx_t_6; - /* "dependency_injector/providers.pxd":370 + /* "dependency_injector/providers.pxd":385 * if len(kwargs) == 0: * for index in range(inj_kwargs_len): * kw_injection = inj_kwargs[index] # <<<<<<<<<<<<<< * name = __get_name(kw_injection) - * kwargs[name] = __get_value(kw_injection) + * value = __get_value(kw_injection) */ if (unlikely(__pyx_v_inj_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 370, __pyx_L1_error) + __PYX_ERR(0, 385, __pyx_L1_error) } - __pyx_t_6 = PyTuple_GET_ITEM(__pyx_v_inj_kwargs, __pyx_v_index); - __Pyx_INCREF(__pyx_t_6); - __Pyx_XDECREF_SET(__pyx_v_kw_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_6)); - __pyx_t_6 = 0; + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_v_inj_kwargs, __pyx_v_index); + __Pyx_INCREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_kw_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); + __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":371 + /* "dependency_injector/providers.pxd":386 * for index in range(inj_kwargs_len): * kw_injection = inj_kwargs[index] * name = __get_name(kw_injection) # <<<<<<<<<<<<<< - * kwargs[name] = __get_value(kw_injection) - * else: + * value = __get_value(kw_injection) + * kwargs[name] = value */ - __pyx_t_6 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_kw_injection); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 371, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_6); - __pyx_t_6 = 0; + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_kw_injection); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 386, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_1); + __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":372 + /* "dependency_injector/providers.pxd":387 * kw_injection = inj_kwargs[index] * name = __get_name(kw_injection) - * kwargs[name] = __get_value(kw_injection) # <<<<<<<<<<<<<< + * value = __get_value(kw_injection) # <<<<<<<<<<<<<< + * kwargs[name] = value + * if __isawaitable(value): + */ + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 387, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":388 + * name = __get_name(kw_injection) + * value = __get_value(kw_injection) + * kwargs[name] = value # <<<<<<<<<<<<<< + * if __isawaitable(value): + * awaitables.append((name, value)) + */ + if (unlikely(__pyx_v_kwargs == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(0, 388, __pyx_L1_error) + } + if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 388, __pyx_L1_error) + + /* "dependency_injector/providers.pxd":389 + * value = __get_value(kw_injection) + * kwargs[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * else: + */ + __pyx_t_3 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_value) != 0); + if (__pyx_t_3) { + + /* "dependency_injector/providers.pxd":390 + * kwargs[name] = value + * if __isawaitable(value): + * awaitables.append((name, value)) # <<<<<<<<<<<<<< * else: * kwargs, prefixed = __separate_prefixed_kwargs(kwargs) */ - __pyx_t_6 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection)); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 372, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - if (unlikely(__pyx_v_kwargs == Py_None)) { - PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 372, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 390, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_v_name); + __Pyx_GIVEREF(__pyx_v_name); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_name); + __Pyx_INCREF(__pyx_v_value); + __Pyx_GIVEREF(__pyx_v_value); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_value); + __pyx_t_7 = __Pyx_PyList_Append(__pyx_v_awaitables, __pyx_t_1); if (unlikely(__pyx_t_7 == ((int)-1))) __PYX_ERR(0, 390, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":389 + * value = __get_value(kw_injection) + * kwargs[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * else: + */ } - if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_name, __pyx_t_6) < 0)) __PYX_ERR(0, 372, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } - /* "dependency_injector/providers.pxd":368 + /* "dependency_injector/providers.pxd":383 * cdef NamedInjection kw_injection * * if len(kwargs) == 0: # <<<<<<<<<<<<<< @@ -83372,59 +91677,59 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid goto __pyx_L3; } - /* "dependency_injector/providers.pxd":374 - * kwargs[name] = __get_value(kw_injection) + /* "dependency_injector/providers.pxd":392 + * awaitables.append((name, value)) * else: * kwargs, prefixed = __separate_prefixed_kwargs(kwargs) # <<<<<<<<<<<<<< * * */ /*else*/ { - __pyx_t_6 = __pyx_f_19dependency_injector_9providers___separate_prefixed_kwargs(__pyx_v_kwargs); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 374, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - if (likely(__pyx_t_6 != Py_None)) { - PyObject* sequence = __pyx_t_6; + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___separate_prefixed_kwargs(__pyx_v_kwargs); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 392, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (likely(__pyx_t_1 != Py_None)) { + PyObject* sequence = __pyx_t_1; Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); if (unlikely(size != 2)) { if (size > 2) __Pyx_RaiseTooManyValuesError(2); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); - __PYX_ERR(0, 374, __pyx_L1_error) + __PYX_ERR(0, 392, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_7 = PyTuple_GET_ITEM(sequence, 0); - __pyx_t_8 = PyTuple_GET_ITEM(sequence, 1); - __Pyx_INCREF(__pyx_t_7); + __pyx_t_8 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_9 = PyTuple_GET_ITEM(sequence, 1); __Pyx_INCREF(__pyx_t_8); + __Pyx_INCREF(__pyx_t_9); #else - __pyx_t_7 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 374, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_7); - __pyx_t_8 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 374, __pyx_L1_error) + __pyx_t_8 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 392, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); + __pyx_t_9 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 392, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); #endif - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { - __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(0, 374, __pyx_L1_error) + __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(0, 392, __pyx_L1_error) } - if (!(likely(PyDict_CheckExact(__pyx_t_7))||((__pyx_t_7) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_7)->tp_name), 0))) __PYX_ERR(0, 374, __pyx_L1_error) - if (!(likely(PyDict_CheckExact(__pyx_t_8))||((__pyx_t_8) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_8)->tp_name), 0))) __PYX_ERR(0, 374, __pyx_L1_error) - __Pyx_DECREF_SET(__pyx_v_kwargs, ((PyObject*)__pyx_t_7)); - __pyx_t_7 = 0; - __pyx_v_prefixed = ((PyObject*)__pyx_t_8); + if (!(likely(PyDict_CheckExact(__pyx_t_8))||((__pyx_t_8) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_8)->tp_name), 0))) __PYX_ERR(0, 392, __pyx_L1_error) + if (!(likely(PyDict_CheckExact(__pyx_t_9))||((__pyx_t_9) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_9)->tp_name), 0))) __PYX_ERR(0, 392, __pyx_L1_error) + __Pyx_DECREF_SET(__pyx_v_kwargs, ((PyObject*)__pyx_t_8)); __pyx_t_8 = 0; + __Pyx_DECREF_SET(__pyx_v_prefixed, ((PyObject*)__pyx_t_9)); + __pyx_t_9 = 0; - /* "dependency_injector/providers.pxd":377 + /* "dependency_injector/providers.pxd":395 * * * for index in range(inj_kwargs_len): # <<<<<<<<<<<<<< * kw_injection = inj_kwargs[index] * name = __get_name(kw_injection) */ - __pyx_t_3 = __pyx_v_inj_kwargs_len; - __pyx_t_4 = __pyx_t_3; - for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) { - __pyx_v_index = __pyx_t_5; + __pyx_t_4 = __pyx_v_inj_kwargs_len; + __pyx_t_5 = __pyx_t_4; + for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) { + __pyx_v_index = __pyx_t_6; - /* "dependency_injector/providers.pxd":378 + /* "dependency_injector/providers.pxd":396 * * for index in range(inj_kwargs_len): * kw_injection = inj_kwargs[index] # <<<<<<<<<<<<<< @@ -83433,26 +91738,26 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ if (unlikely(__pyx_v_inj_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 378, __pyx_L1_error) + __PYX_ERR(0, 396, __pyx_L1_error) } - __pyx_t_6 = PyTuple_GET_ITEM(__pyx_v_inj_kwargs, __pyx_v_index); - __Pyx_INCREF(__pyx_t_6); - __Pyx_XDECREF_SET(__pyx_v_kw_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_6)); - __pyx_t_6 = 0; + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_v_inj_kwargs, __pyx_v_index); + __Pyx_INCREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_kw_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); + __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":379 + /* "dependency_injector/providers.pxd":397 * for index in range(inj_kwargs_len): * kw_injection = inj_kwargs[index] * name = __get_name(kw_injection) # <<<<<<<<<<<<<< * * if name in kwargs: */ - __pyx_t_6 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_kw_injection); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 379, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_6); - __pyx_t_6 = 0; + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_kw_injection); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 397, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_1); + __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":381 + /* "dependency_injector/providers.pxd":399 * name = __get_name(kw_injection) * * if name in kwargs: # <<<<<<<<<<<<<< @@ -83461,22 +91766,22 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 381, __pyx_L1_error) + __PYX_ERR(0, 399, __pyx_L1_error) } - __pyx_t_2 = (__Pyx_PyDict_ContainsTF(__pyx_v_name, __pyx_v_kwargs, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 381, __pyx_L1_error) - __pyx_t_9 = (__pyx_t_2 != 0); - if (__pyx_t_9) { + __pyx_t_3 = (__Pyx_PyDict_ContainsTF(__pyx_v_name, __pyx_v_kwargs, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 399, __pyx_L1_error) + __pyx_t_10 = (__pyx_t_3 != 0); + if (__pyx_t_10) { - /* "dependency_injector/providers.pxd":382 + /* "dependency_injector/providers.pxd":400 * * if name in kwargs: * continue # <<<<<<<<<<<<<< * * if name in prefixed: */ - goto __pyx_L6_continue; + goto __pyx_L7_continue; - /* "dependency_injector/providers.pxd":381 + /* "dependency_injector/providers.pxd":399 * name = __get_name(kw_injection) * * if name in kwargs: # <<<<<<<<<<<<<< @@ -83485,7 +91790,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ } - /* "dependency_injector/providers.pxd":384 + /* "dependency_injector/providers.pxd":402 * continue * * if name in prefixed: # <<<<<<<<<<<<<< @@ -83494,13 +91799,13 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ if (unlikely(__pyx_v_prefixed == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 384, __pyx_L1_error) + __PYX_ERR(0, 402, __pyx_L1_error) } - __pyx_t_9 = (__Pyx_PyDict_ContainsTF(__pyx_v_name, __pyx_v_prefixed, Py_EQ)); if (unlikely(__pyx_t_9 < 0)) __PYX_ERR(0, 384, __pyx_L1_error) - __pyx_t_2 = (__pyx_t_9 != 0); - if (__pyx_t_2) { + __pyx_t_10 = (__Pyx_PyDict_ContainsTF(__pyx_v_name, __pyx_v_prefixed, Py_EQ)); if (unlikely(__pyx_t_10 < 0)) __PYX_ERR(0, 402, __pyx_L1_error) + __pyx_t_3 = (__pyx_t_10 != 0); + if (__pyx_t_3) { - /* "dependency_injector/providers.pxd":385 + /* "dependency_injector/providers.pxd":403 * * if name in prefixed: * value = __get_value_kwargs(kw_injection, prefixed[name]) # <<<<<<<<<<<<<< @@ -83509,28 +91814,28 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid */ if (unlikely(__pyx_v_prefixed == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 385, __pyx_L1_error) + __PYX_ERR(0, 403, __pyx_L1_error) } - __pyx_t_6 = __Pyx_PyDict_GetItem(__pyx_v_prefixed, __pyx_v_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 385, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_6); - if (!(likely(PyDict_CheckExact(__pyx_t_6))||((__pyx_t_6) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_6)->tp_name), 0))) __PYX_ERR(0, 385, __pyx_L1_error) - __pyx_t_8 = __pyx_f_19dependency_injector_9providers___get_value_kwargs(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection), ((PyObject*)__pyx_t_6)); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 385, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_8); - __pyx_t_8 = 0; + __pyx_t_1 = __Pyx_PyDict_GetItem(__pyx_v_prefixed, __pyx_v_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 403, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 403, __pyx_L1_error) + __pyx_t_9 = __pyx_f_19dependency_injector_9providers___get_value_kwargs(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection), ((PyObject*)__pyx_t_1)); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 403, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_9); + __pyx_t_9 = 0; - /* "dependency_injector/providers.pxd":384 + /* "dependency_injector/providers.pxd":402 * continue * * if name in prefixed: # <<<<<<<<<<<<<< * value = __get_value_kwargs(kw_injection, prefixed[name]) * else: */ - goto __pyx_L9; + goto __pyx_L10; } - /* "dependency_injector/providers.pxd":387 + /* "dependency_injector/providers.pxd":405 * value = __get_value_kwargs(kw_injection, prefixed[name]) * else: * value = __get_value(kw_injection) # <<<<<<<<<<<<<< @@ -83538,32 +91843,102 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid * kwargs[name] = value */ /*else*/ { - __pyx_t_8 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection)); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 387, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_8); - __pyx_t_8 = 0; + __pyx_t_9 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_kw_injection)); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 405, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_9); + __pyx_t_9 = 0; } - __pyx_L9:; + __pyx_L10:; - /* "dependency_injector/providers.pxd":389 + /* "dependency_injector/providers.pxd":407 * value = __get_value(kw_injection) * * kwargs[name] = value # <<<<<<<<<<<<<< - * - * return kwargs + * if __isawaitable(value): + * awaitables.append((name, value)) */ if (unlikely(__pyx_v_kwargs == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 389, __pyx_L1_error) + __PYX_ERR(0, 407, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 389, __pyx_L1_error) - __pyx_L6_continue:; + if (unlikely(PyDict_SetItem(__pyx_v_kwargs, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 407, __pyx_L1_error) + + /* "dependency_injector/providers.pxd":408 + * + * kwargs[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * + */ + __pyx_t_3 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_value) != 0); + if (__pyx_t_3) { + + /* "dependency_injector/providers.pxd":409 + * kwargs[name] = value + * if __isawaitable(value): + * awaitables.append((name, value)) # <<<<<<<<<<<<<< + * + * if awaitables: + */ + __pyx_t_9 = PyTuple_New(2); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 409, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_INCREF(__pyx_v_name); + __Pyx_GIVEREF(__pyx_v_name); + PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_v_name); + __Pyx_INCREF(__pyx_v_value); + __Pyx_GIVEREF(__pyx_v_value); + PyTuple_SET_ITEM(__pyx_t_9, 1, __pyx_v_value); + __pyx_t_7 = __Pyx_PyList_Append(__pyx_v_awaitables, __pyx_t_9); if (unlikely(__pyx_t_7 == ((int)-1))) __PYX_ERR(0, 409, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + + /* "dependency_injector/providers.pxd":408 + * + * kwargs[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * + */ + } + __pyx_L7_continue:; } } __pyx_L3:; - /* "dependency_injector/providers.pxd":391 - * kwargs[name] = value + /* "dependency_injector/providers.pxd":411 + * awaitables.append((name, value)) + * + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(kwargs, awaitables) + * + */ + __pyx_t_3 = (PyList_GET_SIZE(__pyx_v_awaitables) != 0); + if (__pyx_t_3) { + + /* "dependency_injector/providers.pxd":412 + * + * if awaitables: + * return __awaitable_args_kwargs_future(kwargs, awaitables) # <<<<<<<<<<<<<< + * + * return kwargs + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_9 = __pyx_f_19dependency_injector_9providers___awaitable_args_kwargs_future(__pyx_v_kwargs, __pyx_v_awaitables); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 412, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __pyx_r = __pyx_t_9; + __pyx_t_9 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":411 + * awaitables.append((name, value)) + * + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(kwargs, awaitables) + * + */ + } + + /* "dependency_injector/providers.pxd":414 + * return __awaitable_args_kwargs_future(kwargs, awaitables) * * return kwargs # <<<<<<<<<<<<<< * @@ -83574,25 +91949,26 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid __pyx_r = __pyx_v_kwargs; goto __pyx_L0; - /* "dependency_injector/providers.pxd":357 + /* "dependency_injector/providers.pxd":371 * @cython.boundscheck(False) * @cython.wraparound(False) - * cdef inline dict __provide_keyword_args( # <<<<<<<<<<<<<< + * cdef inline object __provide_keyword_args( # <<<<<<<<<<<<<< * dict kwargs, * tuple inj_kwargs, */ /* function exit code */ __pyx_L1_error:; - __Pyx_XDECREF(__pyx_t_6); - __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("dependency_injector.providers.__provide_keyword_args", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_name); __Pyx_XDECREF(__pyx_v_value); __Pyx_XDECREF(__pyx_v_prefixed); + __Pyx_XDECREF(__pyx_v_awaitables); __Pyx_XDECREF((PyObject *)__pyx_v_kw_injection); __Pyx_XDECREF(__pyx_v_kwargs); __Pyx_XGIVEREF(__pyx_r); @@ -83600,114 +91976,1537 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provid return __pyx_r; } -/* "dependency_injector/providers.pxd":396 - * @cython.boundscheck(False) - * @cython.wraparound(False) - * cdef inline object __inject_attributes( # <<<<<<<<<<<<<< - * object instance, - * tuple attributes, +/* "dependency_injector/providers.pxd":417 + * + * + * cdef inline object __awaitable_args_kwargs_future(object args, list awaitables): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * */ -static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___inject_attributes(PyObject *__pyx_v_instance, PyObject *__pyx_v_attributes, int __pyx_v_attributes_len) { - struct __pyx_obj_19dependency_injector_9providers_NamedInjection *__pyx_v_attr_injection = 0; - int __pyx_v_index; +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___awaitable_args_kwargs_future(PyObject *__pyx_v_args, PyObject *__pyx_v_awaitables) { + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_args_future = NULL; + PyObject *__pyx_v_args_ready = NULL; + CYTHON_UNUSED PyObject *__pyx_v__ = NULL; + PyObject *__pyx_v_value = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations - int __pyx_t_1; - int __pyx_t_2; - int __pyx_t_3; + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; - PyObject *__pyx_t_5 = NULL; - int __pyx_t_6; + Py_ssize_t __pyx_t_5; + PyObject *__pyx_t_6 = NULL; + PyObject *__pyx_t_7 = NULL; + PyObject *__pyx_t_8 = NULL; + PyObject *__pyx_t_9 = NULL; + PyObject *(*__pyx_t_10)(PyObject *); int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; - __Pyx_RefNannySetupContext("__inject_attributes", 0); + __Pyx_RefNannySetupContext("__awaitable_args_kwargs_future", 0); - /* "dependency_injector/providers.pxd":402 - * ): - * cdef NamedInjection attr_injection - * for index in range(attributes_len): # <<<<<<<<<<<<<< - * attr_injection = attributes[index] - * setattr(instance, + /* "dependency_injector/providers.pxd":418 + * + * cdef inline object __awaitable_args_kwargs_future(object args, list awaitables): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * + * args_future = asyncio.Future() */ - __pyx_t_1 = __pyx_v_attributes_len; - __pyx_t_2 = __pyx_t_1; - for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) { - __pyx_v_index = __pyx_t_3; - - /* "dependency_injector/providers.pxd":403 - * cdef NamedInjection attr_injection - * for index in range(attributes_len): - * attr_injection = attributes[index] # <<<<<<<<<<<<<< - * setattr(instance, - * __get_name(attr_injection), - */ - if (unlikely(__pyx_v_attributes == Py_None)) { - PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 403, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 418, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_Future); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 418, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); } - __pyx_t_4 = PyTuple_GET_ITEM(__pyx_v_attributes, __pyx_v_index); - __Pyx_INCREF(__pyx_t_4); - __Pyx_XDECREF_SET(__pyx_v_attr_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_4)); - __pyx_t_4 = 0; - - /* "dependency_injector/providers.pxd":405 - * attr_injection = attributes[index] - * setattr(instance, - * __get_name(attr_injection), # <<<<<<<<<<<<<< - * __get_value(attr_injection)) - * - */ - __pyx_t_4 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_attr_injection); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 405, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_4); - - /* "dependency_injector/providers.pxd":406 - * setattr(instance, - * __get_name(attr_injection), - * __get_value(attr_injection)) # <<<<<<<<<<<<<< - * - * - */ - __pyx_t_5 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_attr_injection)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 406, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_5); - - /* "dependency_injector/providers.pxd":404 - * for index in range(attributes_len): - * attr_injection = attributes[index] - * setattr(instance, # <<<<<<<<<<<<<< - * __get_name(attr_injection), - * __get_value(attr_injection)) - */ - __pyx_t_6 = PyObject_SetAttr(__pyx_v_instance, __pyx_t_4, __pyx_t_5); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 404, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 418, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_future_result = __pyx_t_1; + __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":396 - * @cython.boundscheck(False) - * @cython.wraparound(False) - * cdef inline object __inject_attributes( # <<<<<<<<<<<<<< - * object instance, - * tuple attributes, + /* "dependency_injector/providers.pxd":420 + * future_result = asyncio.Future() + * + * args_future = asyncio.Future() # <<<<<<<<<<<<<< + * args_future.set_result((future_result, args, awaitables)) + * + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 420, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_Future); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 420, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 420, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_args_future = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":421 + * + * args_future = asyncio.Future() + * args_future.set_result((future_result, args, awaitables)) # <<<<<<<<<<<<<< + * + * args_ready = asyncio.gather(args_future, *[value for _, value in awaitables]) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_args_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 421, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 421, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_future_result); + __Pyx_INCREF(__pyx_v_args); + __Pyx_GIVEREF(__pyx_v_args); + PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_args); + __Pyx_INCREF(__pyx_v_awaitables); + __Pyx_GIVEREF(__pyx_v_awaitables); + PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_awaitables); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 421, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":423 + * args_future.set_result((future_result, args, awaitables)) + * + * args_ready = asyncio.gather(args_future, *[value for _, value in awaitables]) # <<<<<<<<<<<<<< + * args_ready.add_done_callback(__async_prepare_args_kwargs_callback) + * asyncio.ensure_future(args_ready) + */ + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_gather); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_v_args_future); + __Pyx_GIVEREF(__pyx_v_args_future); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_args_future); + __pyx_t_3 = PyList_New(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + if (unlikely(__pyx_v_awaitables == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); + __PYX_ERR(0, 423, __pyx_L1_error) + } + __pyx_t_4 = __pyx_v_awaitables; __Pyx_INCREF(__pyx_t_4); __pyx_t_5 = 0; + for (;;) { + if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_4)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_6 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_5); __Pyx_INCREF(__pyx_t_6); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 423, __pyx_L1_error) + #else + __pyx_t_6 = PySequence_ITEM(__pyx_t_4, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + #endif + if ((likely(PyTuple_CheckExact(__pyx_t_6))) || (PyList_CheckExact(__pyx_t_6))) { + PyObject* sequence = __pyx_t_6; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 2)) { + if (size > 2) __Pyx_RaiseTooManyValuesError(2); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(0, 423, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_7 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_8 = PyTuple_GET_ITEM(sequence, 1); + } else { + __pyx_t_7 = PyList_GET_ITEM(sequence, 0); + __pyx_t_8 = PyList_GET_ITEM(sequence, 1); + } + __Pyx_INCREF(__pyx_t_7); + __Pyx_INCREF(__pyx_t_8); + #else + __pyx_t_7 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __pyx_t_8 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + #endif + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_9 = PyObject_GetIter(__pyx_t_6); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_9); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_10 = Py_TYPE(__pyx_t_9)->tp_iternext; + index = 0; __pyx_t_7 = __pyx_t_10(__pyx_t_9); if (unlikely(!__pyx_t_7)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_7); + index = 1; __pyx_t_8 = __pyx_t_10(__pyx_t_9); if (unlikely(!__pyx_t_8)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_8); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_9), 2) < 0) __PYX_ERR(0, 423, __pyx_L1_error) + __pyx_t_10 = NULL; + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + goto __pyx_L6_unpacking_done; + __pyx_L5_unpacking_failed:; + __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; + __pyx_t_10 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(0, 423, __pyx_L1_error) + __pyx_L6_unpacking_done:; + } + __Pyx_XDECREF_SET(__pyx_v__, __pyx_t_7); + __pyx_t_7 = 0; + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_8); + __pyx_t_8 = 0; + if (unlikely(__Pyx_ListComp_Append(__pyx_t_3, (PyObject*)__pyx_v_value))) __PYX_ERR(0, 423, __pyx_L1_error) + } + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = PySequence_Tuple(__pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = PyNumber_Add(__pyx_t_1, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 423, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_args_ready = __pyx_t_4; + __pyx_t_4 = 0; + + /* "dependency_injector/providers.pxd":424 + * + * args_ready = asyncio.gather(args_future, *[value for _, value in awaitables]) + * args_ready.add_done_callback(__async_prepare_args_kwargs_callback) # <<<<<<<<<<<<<< + * asyncio.ensure_future(args_ready) + * + */ + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_args_ready, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 424, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_CFunc_void____object___to_py(__pyx_f_19dependency_injector_9providers___async_prepare_args_kwargs_callback); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 424, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_1 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_1 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_1)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_1); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_4 = (__pyx_t_1) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_1, __pyx_t_2) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2); + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 424, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + + /* "dependency_injector/providers.pxd":425 + * args_ready = asyncio.gather(args_future, *[value for _, value in awaitables]) + * args_ready.add_done_callback(__async_prepare_args_kwargs_callback) + * asyncio.ensure_future(args_ready) # <<<<<<<<<<<<<< + * + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 425, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 425, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_4 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_args_ready) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_args_ready); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 425, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + + /* "dependency_injector/providers.pxd":427 + * asyncio.ensure_future(args_ready) + * + * return future_result # <<<<<<<<<<<<<< + * + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":417 + * + * + * cdef inline object __awaitable_args_kwargs_future(object args, list awaitables): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * */ /* function exit code */ - __pyx_r = Py_None; __Pyx_INCREF(Py_None); - goto __pyx_L0; __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); - __Pyx_XDECREF(__pyx_t_5); - __Pyx_AddTraceback("dependency_injector.providers.__inject_attributes", __pyx_clineno, __pyx_lineno, __pyx_filename); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_XDECREF(__pyx_t_9); + __Pyx_AddTraceback("dependency_injector.providers.__awaitable_args_kwargs_future", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; - __Pyx_XDECREF((PyObject *)__pyx_v_attr_injection); + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_args_future); + __Pyx_XDECREF(__pyx_v_args_ready); + __Pyx_XDECREF(__pyx_v__); + __Pyx_XDECREF(__pyx_v_value); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "dependency_injector/providers.pxd":409 +/* "dependency_injector/providers.pxd":430 + * + * + * cdef inline void __async_prepare_args_kwargs_callback(object future): # <<<<<<<<<<<<<< + * (future_result, args, awaitables), *awaited = future.result() + * for value, (key, _) in zip(awaited, awaitables): + */ + +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_prepare_args_kwargs_callback(PyObject *__pyx_v_future) { + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_args = NULL; + PyObject *__pyx_v_awaitables = NULL; + PyObject *__pyx_v_awaited = NULL; + PyObject *__pyx_v_value = NULL; + PyObject *__pyx_v_key = NULL; + CYTHON_UNUSED PyObject *__pyx_v__ = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *(*__pyx_t_4)(PyObject *); + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + PyObject *__pyx_t_7 = NULL; + PyObject *__pyx_t_8 = NULL; + Py_ssize_t __pyx_t_9; + PyObject *(*__pyx_t_10)(PyObject *); + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__async_prepare_args_kwargs_callback", 0); + + /* "dependency_injector/providers.pxd":431 + * + * cdef inline void __async_prepare_args_kwargs_callback(object future): + * (future_result, args, awaitables), *awaited = future.result() # <<<<<<<<<<<<<< + * for value, (key, _) in zip(awaited, awaitables): + * args[key] = value + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + { + Py_ssize_t index = -1; + PyObject** temps[2] = {&__pyx_t_2}; + __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_4 = Py_TYPE(__pyx_t_3)->tp_iternext; + for (index=0; index < 1; index++) { + PyObject* item = __pyx_t_4(__pyx_t_3); if (unlikely(!item)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(item); + *(temps[index]) = item; + } + goto __pyx_L4_unpacking_done; + __pyx_L3_unpacking_failed:; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_4 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(0, 431, __pyx_L1_error) + __pyx_L4_unpacking_done:; + } + __pyx_t_5 = PySequence_List(__pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + if ((likely(PyTuple_CheckExact(__pyx_t_2))) || (PyList_CheckExact(__pyx_t_2))) { + PyObject* sequence = __pyx_t_2; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 3)) { + if (size > 3) __Pyx_RaiseTooManyValuesError(3); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(0, 431, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_3 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_6 = PyTuple_GET_ITEM(sequence, 1); + __pyx_t_7 = PyTuple_GET_ITEM(sequence, 2); + } else { + __pyx_t_3 = PyList_GET_ITEM(sequence, 0); + __pyx_t_6 = PyList_GET_ITEM(sequence, 1); + __pyx_t_7 = PyList_GET_ITEM(sequence, 2); + } + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(__pyx_t_7); + #else + __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_7 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + #endif + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_8 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 431, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_4 = Py_TYPE(__pyx_t_8)->tp_iternext; + index = 0; __pyx_t_3 = __pyx_t_4(__pyx_t_8); if (unlikely(!__pyx_t_3)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_3); + index = 1; __pyx_t_6 = __pyx_t_4(__pyx_t_8); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_6); + index = 2; __pyx_t_7 = __pyx_t_4(__pyx_t_8); if (unlikely(!__pyx_t_7)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_7); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_4(__pyx_t_8), 3) < 0) __PYX_ERR(0, 431, __pyx_L1_error) + __pyx_t_4 = NULL; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + goto __pyx_L6_unpacking_done; + __pyx_L5_unpacking_failed:; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_4 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(0, 431, __pyx_L1_error) + __pyx_L6_unpacking_done:; + } + __pyx_v_future_result = __pyx_t_3; + __pyx_t_3 = 0; + __pyx_v_args = __pyx_t_6; + __pyx_t_6 = 0; + __pyx_v_awaitables = __pyx_t_7; + __pyx_t_7 = 0; + __pyx_v_awaited = ((PyObject*)__pyx_t_5); + __pyx_t_5 = 0; + + /* "dependency_injector/providers.pxd":432 + * cdef inline void __async_prepare_args_kwargs_callback(object future): + * (future_result, args, awaitables), *awaited = future.result() + * for value, (key, _) in zip(awaited, awaitables): # <<<<<<<<<<<<<< + * args[key] = value + * future_result.set_result(args) + */ + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_v_awaited); + __Pyx_GIVEREF(__pyx_v_awaited); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_awaited); + __Pyx_INCREF(__pyx_v_awaitables); + __Pyx_GIVEREF(__pyx_v_awaitables); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_awaitables); + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_zip, __pyx_t_1, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) { + __pyx_t_1 = __pyx_t_5; __Pyx_INCREF(__pyx_t_1); __pyx_t_9 = 0; + __pyx_t_10 = NULL; + } else { + __pyx_t_9 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_t_10 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 432, __pyx_L1_error) + } + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + for (;;) { + if (likely(!__pyx_t_10)) { + if (likely(PyList_CheckExact(__pyx_t_1))) { + if (__pyx_t_9 >= PyList_GET_SIZE(__pyx_t_1)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_5 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_9); __Pyx_INCREF(__pyx_t_5); __pyx_t_9++; if (unlikely(0 < 0)) __PYX_ERR(0, 432, __pyx_L1_error) + #else + __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_9); __pyx_t_9++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + #endif + } else { + if (__pyx_t_9 >= PyTuple_GET_SIZE(__pyx_t_1)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_9); __Pyx_INCREF(__pyx_t_5); __pyx_t_9++; if (unlikely(0 < 0)) __PYX_ERR(0, 432, __pyx_L1_error) + #else + __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_9); __pyx_t_9++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + #endif + } + } else { + __pyx_t_5 = __pyx_t_10(__pyx_t_1); + if (unlikely(!__pyx_t_5)) { + PyObject* exc_type = PyErr_Occurred(); + if (exc_type) { + if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); + else __PYX_ERR(0, 432, __pyx_L1_error) + } + break; + } + __Pyx_GOTREF(__pyx_t_5); + } + if ((likely(PyTuple_CheckExact(__pyx_t_5))) || (PyList_CheckExact(__pyx_t_5))) { + PyObject* sequence = __pyx_t_5; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 2)) { + if (size > 2) __Pyx_RaiseTooManyValuesError(2); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(0, 432, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_2 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_7 = PyTuple_GET_ITEM(sequence, 1); + } else { + __pyx_t_2 = PyList_GET_ITEM(sequence, 0); + __pyx_t_7 = PyList_GET_ITEM(sequence, 1); + } + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(__pyx_t_7); + #else + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_7 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + #endif + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_6 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_4 = Py_TYPE(__pyx_t_6)->tp_iternext; + index = 0; __pyx_t_2 = __pyx_t_4(__pyx_t_6); if (unlikely(!__pyx_t_2)) goto __pyx_L9_unpacking_failed; + __Pyx_GOTREF(__pyx_t_2); + index = 1; __pyx_t_7 = __pyx_t_4(__pyx_t_6); if (unlikely(!__pyx_t_7)) goto __pyx_L9_unpacking_failed; + __Pyx_GOTREF(__pyx_t_7); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_4(__pyx_t_6), 2) < 0) __PYX_ERR(0, 432, __pyx_L1_error) + __pyx_t_4 = NULL; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + goto __pyx_L10_unpacking_done; + __pyx_L9_unpacking_failed:; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_t_4 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(0, 432, __pyx_L1_error) + __pyx_L10_unpacking_done:; + } + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_2); + __pyx_t_2 = 0; + if ((likely(PyTuple_CheckExact(__pyx_t_7))) || (PyList_CheckExact(__pyx_t_7))) { + PyObject* sequence = __pyx_t_7; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 2)) { + if (size > 2) __Pyx_RaiseTooManyValuesError(2); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(0, 432, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_6 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_3 = PyTuple_GET_ITEM(sequence, 1); + } else { + __pyx_t_6 = PyList_GET_ITEM(sequence, 0); + __pyx_t_3 = PyList_GET_ITEM(sequence, 1); + } + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(__pyx_t_3); + #else + __pyx_t_6 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_3 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + #endif + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_8 = PyObject_GetIter(__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 432, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_4 = Py_TYPE(__pyx_t_8)->tp_iternext; + index = 0; __pyx_t_6 = __pyx_t_4(__pyx_t_8); if (unlikely(!__pyx_t_6)) goto __pyx_L11_unpacking_failed; + __Pyx_GOTREF(__pyx_t_6); + index = 1; __pyx_t_3 = __pyx_t_4(__pyx_t_8); if (unlikely(!__pyx_t_3)) goto __pyx_L11_unpacking_failed; + __Pyx_GOTREF(__pyx_t_3); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_4(__pyx_t_8), 2) < 0) __PYX_ERR(0, 432, __pyx_L1_error) + __pyx_t_4 = NULL; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + goto __pyx_L12_unpacking_done; + __pyx_L11_unpacking_failed:; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_4 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(0, 432, __pyx_L1_error) + __pyx_L12_unpacking_done:; + } + __Pyx_XDECREF_SET(__pyx_v_key, __pyx_t_6); + __pyx_t_6 = 0; + __Pyx_XDECREF_SET(__pyx_v__, __pyx_t_3); + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pxd":433 + * (future_result, args, awaitables), *awaited = future.result() + * for value, (key, _) in zip(awaited, awaitables): + * args[key] = value # <<<<<<<<<<<<<< + * future_result.set_result(args) + * + */ + if (unlikely(PyObject_SetItem(__pyx_v_args, __pyx_v_key, __pyx_v_value) < 0)) __PYX_ERR(0, 433, __pyx_L1_error) + + /* "dependency_injector/providers.pxd":432 + * cdef inline void __async_prepare_args_kwargs_callback(object future): + * (future_result, args, awaitables), *awaited = future.result() + * for value, (key, _) in zip(awaited, awaitables): # <<<<<<<<<<<<<< + * args[key] = value + * future_result.set_result(args) + */ + } + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":434 + * for value, (key, _) in zip(awaited, awaitables): + * args[key] = value + * future_result.set_result(args) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 434, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_7 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_7)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_7); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_7, __pyx_v_args) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_args); + __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 434, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":430 + * + * + * cdef inline void __async_prepare_args_kwargs_callback(object future): # <<<<<<<<<<<<<< + * (future_result, args, awaitables), *awaited = future.result() + * for value, (key, _) in zip(awaited, awaitables): + */ + + /* function exit code */ + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_WriteUnraisable("dependency_injector.providers.__async_prepare_args_kwargs_callback", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_args); + __Pyx_XDECREF(__pyx_v_awaitables); + __Pyx_XDECREF(__pyx_v_awaited); + __Pyx_XDECREF(__pyx_v_value); + __Pyx_XDECREF(__pyx_v_key); + __Pyx_XDECREF(__pyx_v__); + __Pyx_RefNannyFinishContext(); +} + +/* "dependency_injector/providers.pxd":439 + * @cython.boundscheck(False) + * @cython.wraparound(False) + * cdef inline object __provide_attributes(tuple attributes, int attributes_len): # <<<<<<<<<<<<<< + * cdef NamedInjection attr_injection + * cdef dict attribute_injections = {} + */ + +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___provide_attributes(PyObject *__pyx_v_attributes, int __pyx_v_attributes_len) { + struct __pyx_obj_19dependency_injector_9providers_NamedInjection *__pyx_v_attr_injection = 0; + PyObject *__pyx_v_attribute_injections = 0; + PyObject *__pyx_v_awaitables = 0; + int __pyx_v_index; + PyObject *__pyx_v_name = NULL; + PyObject *__pyx_v_value = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_t_2; + int __pyx_t_3; + int __pyx_t_4; + int __pyx_t_5; + int __pyx_t_6; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__provide_attributes", 0); + + /* "dependency_injector/providers.pxd":441 + * cdef inline object __provide_attributes(tuple attributes, int attributes_len): + * cdef NamedInjection attr_injection + * cdef dict attribute_injections = {} # <<<<<<<<<<<<<< + * cdef list awaitables = [] + * + */ + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 441, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_attribute_injections = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":442 + * cdef NamedInjection attr_injection + * cdef dict attribute_injections = {} + * cdef list awaitables = [] # <<<<<<<<<<<<<< + * + * for index in range(attributes_len): + */ + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 442, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_awaitables = ((PyObject*)__pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":444 + * cdef list awaitables = [] + * + * for index in range(attributes_len): # <<<<<<<<<<<<<< + * attr_injection = attributes[index] + * name = __get_name(attr_injection) + */ + __pyx_t_2 = __pyx_v_attributes_len; + __pyx_t_3 = __pyx_t_2; + for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { + __pyx_v_index = __pyx_t_4; + + /* "dependency_injector/providers.pxd":445 + * + * for index in range(attributes_len): + * attr_injection = attributes[index] # <<<<<<<<<<<<<< + * name = __get_name(attr_injection) + * value = __get_value(attr_injection) + */ + if (unlikely(__pyx_v_attributes == Py_None)) { + PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); + __PYX_ERR(0, 445, __pyx_L1_error) + } + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_v_attributes, __pyx_v_index); + __Pyx_INCREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_attr_injection, ((struct __pyx_obj_19dependency_injector_9providers_NamedInjection *)__pyx_t_1)); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":446 + * for index in range(attributes_len): + * attr_injection = attributes[index] + * name = __get_name(attr_injection) # <<<<<<<<<<<<<< + * value = __get_value(attr_injection) + * attribute_injections[name] = value + */ + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_name(__pyx_v_attr_injection); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 446, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":447 + * attr_injection = attributes[index] + * name = __get_name(attr_injection) + * value = __get_value(attr_injection) # <<<<<<<<<<<<<< + * attribute_injections[name] = value + * if __isawaitable(value): + */ + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___get_value(((struct __pyx_obj_19dependency_injector_9providers_Injection *)__pyx_v_attr_injection)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 447, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":448 + * name = __get_name(attr_injection) + * value = __get_value(attr_injection) + * attribute_injections[name] = value # <<<<<<<<<<<<<< + * if __isawaitable(value): + * awaitables.append((name, value)) + */ + if (unlikely(PyDict_SetItem(__pyx_v_attribute_injections, __pyx_v_name, __pyx_v_value) < 0)) __PYX_ERR(0, 448, __pyx_L1_error) + + /* "dependency_injector/providers.pxd":449 + * value = __get_value(attr_injection) + * attribute_injections[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * + */ + __pyx_t_5 = (__pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_value) != 0); + if (__pyx_t_5) { + + /* "dependency_injector/providers.pxd":450 + * attribute_injections[name] = value + * if __isawaitable(value): + * awaitables.append((name, value)) # <<<<<<<<<<<<<< + * + * if awaitables: + */ + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 450, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_INCREF(__pyx_v_name); + __Pyx_GIVEREF(__pyx_v_name); + PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_name); + __Pyx_INCREF(__pyx_v_value); + __Pyx_GIVEREF(__pyx_v_value); + PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_value); + __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_awaitables, __pyx_t_1); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 450, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":449 + * value = __get_value(attr_injection) + * attribute_injections[name] = value + * if __isawaitable(value): # <<<<<<<<<<<<<< + * awaitables.append((name, value)) + * + */ + } + } + + /* "dependency_injector/providers.pxd":452 + * awaitables.append((name, value)) + * + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(attribute_injections, awaitables) + * + */ + __pyx_t_5 = (PyList_GET_SIZE(__pyx_v_awaitables) != 0); + if (__pyx_t_5) { + + /* "dependency_injector/providers.pxd":453 + * + * if awaitables: + * return __awaitable_args_kwargs_future(attribute_injections, awaitables) # <<<<<<<<<<<<<< + * + * return attribute_injections + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___awaitable_args_kwargs_future(__pyx_v_attribute_injections, __pyx_v_awaitables); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 453, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":452 + * awaitables.append((name, value)) + * + * if awaitables: # <<<<<<<<<<<<<< + * return __awaitable_args_kwargs_future(attribute_injections, awaitables) + * + */ + } + + /* "dependency_injector/providers.pxd":455 + * return __awaitable_args_kwargs_future(attribute_injections, awaitables) + * + * return attribute_injections # <<<<<<<<<<<<<< + * + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_attribute_injections); + __pyx_r = __pyx_v_attribute_injections; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":439 + * @cython.boundscheck(False) + * @cython.wraparound(False) + * cdef inline object __provide_attributes(tuple attributes, int attributes_len): # <<<<<<<<<<<<<< + * cdef NamedInjection attr_injection + * cdef dict attribute_injections = {} + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_AddTraceback("dependency_injector.providers.__provide_attributes", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = 0; + __pyx_L0:; + __Pyx_XDECREF((PyObject *)__pyx_v_attr_injection); + __Pyx_XDECREF(__pyx_v_attribute_injections); + __Pyx_XDECREF(__pyx_v_awaitables); + __Pyx_XDECREF(__pyx_v_name); + __Pyx_XDECREF(__pyx_v_value); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pxd":458 + * + * + * cdef inline object __async_inject_attributes(future_instance, future_attributes): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * + */ + +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___async_inject_attributes(PyObject *__pyx_v_future_instance, PyObject *__pyx_v_future_attributes) { + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_future = NULL; + PyObject *__pyx_v_attributes_ready = NULL; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + int __pyx_t_4; + PyObject *__pyx_t_5 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__async_inject_attributes", 0); + + /* "dependency_injector/providers.pxd":459 + * + * cdef inline object __async_inject_attributes(future_instance, future_attributes): + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * + * future = asyncio.Future() + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 459, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_Future); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 459, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 459, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_future_result = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":461 + * future_result = asyncio.Future() + * + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result(future_result) + * + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 461, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_Future); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 461, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 461, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_v_future = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":462 + * + * future = asyncio.Future() + * future.set_result(future_result) # <<<<<<<<<<<<<< + * + * attributes_ready = asyncio.gather(future, future_instance, future_attributes) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 462, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_future_result) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_future_result); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 462, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":464 + * future.set_result(future_result) + * + * attributes_ready = asyncio.gather(future, future_instance, future_attributes) # <<<<<<<<<<<<<< + * attributes_ready.add_done_callback(__async_inject_attributes_callback) + * asyncio.ensure_future(attributes_ready) + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_gather); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + __pyx_t_4 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + __pyx_t_4 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_3)) { + PyObject *__pyx_temp[4] = {__pyx_t_2, __pyx_v_future, __pyx_v_future_instance, __pyx_v_future_attributes}; + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 464, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_GOTREF(__pyx_t_1); + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { + PyObject *__pyx_temp[4] = {__pyx_t_2, __pyx_v_future, __pyx_v_future_instance, __pyx_v_future_attributes}; + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 464, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_GOTREF(__pyx_t_1); + } else + #endif + { + __pyx_t_5 = PyTuple_New(3+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + if (__pyx_t_2) { + __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_2); __pyx_t_2 = NULL; + } + __Pyx_INCREF(__pyx_v_future); + __Pyx_GIVEREF(__pyx_v_future); + PyTuple_SET_ITEM(__pyx_t_5, 0+__pyx_t_4, __pyx_v_future); + __Pyx_INCREF(__pyx_v_future_instance); + __Pyx_GIVEREF(__pyx_v_future_instance); + PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_4, __pyx_v_future_instance); + __Pyx_INCREF(__pyx_v_future_attributes); + __Pyx_GIVEREF(__pyx_v_future_attributes); + PyTuple_SET_ITEM(__pyx_t_5, 2+__pyx_t_4, __pyx_v_future_attributes); + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 464, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + } + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_v_attributes_ready = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":465 + * + * attributes_ready = asyncio.gather(future, future_instance, future_attributes) + * attributes_ready.add_done_callback(__async_inject_attributes_callback) # <<<<<<<<<<<<<< + * asyncio.ensure_future(attributes_ready) + * + */ + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_attributes_ready, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 465, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_5 = __Pyx_CFunc_void____object___to_py(__pyx_f_19dependency_injector_9providers___async_inject_attributes_callback); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 465, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_5); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 465, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":466 + * attributes_ready = asyncio.gather(future, future_instance, future_attributes) + * attributes_ready.add_done_callback(__async_inject_attributes_callback) + * asyncio.ensure_future(attributes_ready) # <<<<<<<<<<<<<< + * + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 466, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 466, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_3, __pyx_v_attributes_ready) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_attributes_ready); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 466, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":468 + * asyncio.ensure_future(attributes_ready) + * + * return future_result # <<<<<<<<<<<<<< + * + * cdef inline void __async_inject_attributes_callback(future): + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":458 + * + * + * cdef inline object __async_inject_attributes(future_instance, future_attributes): # <<<<<<<<<<<<<< + * future_result = asyncio.Future() + * + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_AddTraceback("dependency_injector.providers.__async_inject_attributes", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = 0; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_future); + __Pyx_XDECREF(__pyx_v_attributes_ready); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pxd":470 + * return future_result + * + * cdef inline void __async_inject_attributes_callback(future): # <<<<<<<<<<<<<< + * future_result, instance, attributes = future.result() + * __inject_attributes(instance, attributes) + */ + +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_inject_attributes_callback(PyObject *__pyx_v_future) { + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_instance = NULL; + PyObject *__pyx_v_attributes = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *(*__pyx_t_6)(PyObject *); + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__async_inject_attributes_callback", 0); + + /* "dependency_injector/providers.pxd":471 + * + * cdef inline void __async_inject_attributes_callback(future): + * future_result, instance, attributes = future.result() # <<<<<<<<<<<<<< + * __inject_attributes(instance, attributes) + * future_result.set_result(instance) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + if ((likely(PyTuple_CheckExact(__pyx_t_1))) || (PyList_CheckExact(__pyx_t_1))) { + PyObject* sequence = __pyx_t_1; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 3)) { + if (size > 3) __Pyx_RaiseTooManyValuesError(3); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(0, 471, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_2 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_3 = PyTuple_GET_ITEM(sequence, 1); + __pyx_t_4 = PyTuple_GET_ITEM(sequence, 2); + } else { + __pyx_t_2 = PyList_GET_ITEM(sequence, 0); + __pyx_t_3 = PyList_GET_ITEM(sequence, 1); + __pyx_t_4 = PyList_GET_ITEM(sequence, 2); + } + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + #else + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + #endif + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_5 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 471, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_6 = Py_TYPE(__pyx_t_5)->tp_iternext; + index = 0; __pyx_t_2 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_2)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_2); + index = 1; __pyx_t_3 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_3)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_3); + index = 2; __pyx_t_4 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_4)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_4); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_6(__pyx_t_5), 3) < 0) __PYX_ERR(0, 471, __pyx_L1_error) + __pyx_t_6 = NULL; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + goto __pyx_L4_unpacking_done; + __pyx_L3_unpacking_failed:; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_6 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(0, 471, __pyx_L1_error) + __pyx_L4_unpacking_done:; + } + __pyx_v_future_result = __pyx_t_2; + __pyx_t_2 = 0; + __pyx_v_instance = __pyx_t_3; + __pyx_t_3 = 0; + __pyx_v_attributes = __pyx_t_4; + __pyx_t_4 = 0; + + /* "dependency_injector/providers.pxd":472 + * cdef inline void __async_inject_attributes_callback(future): + * future_result, instance, attributes = future.result() + * __inject_attributes(instance, attributes) # <<<<<<<<<<<<<< + * future_result.set_result(instance) + * + */ + if (!(likely(PyDict_CheckExact(__pyx_v_attributes))||((__pyx_v_attributes) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_attributes)->tp_name), 0))) __PYX_ERR(0, 472, __pyx_L1_error) + __pyx_f_19dependency_injector_9providers___inject_attributes(__pyx_v_instance, ((PyObject*)__pyx_v_attributes)); + + /* "dependency_injector/providers.pxd":473 + * future_result, instance, attributes = future.result() + * __inject_attributes(instance, attributes) + * future_result.set_result(instance) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 473, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_3, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 473, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":470 + * return future_result + * + * cdef inline void __async_inject_attributes_callback(future): # <<<<<<<<<<<<<< + * future_result, instance, attributes = future.result() + * __inject_attributes(instance, attributes) + */ + + /* function exit code */ + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_WriteUnraisable("dependency_injector.providers.__async_inject_attributes_callback", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_attributes); + __Pyx_RefNannyFinishContext(); +} + +/* "dependency_injector/providers.pxd":476 + * + * + * cdef inline void __inject_attributes(object instance, dict attributes): # <<<<<<<<<<<<<< + * for name, value in attributes.items(): + * setattr(instance, name, value) + */ + +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___inject_attributes(PyObject *__pyx_v_instance, PyObject *__pyx_v_attributes) { + PyObject *__pyx_v_name = NULL; + PyObject *__pyx_v_value = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + Py_ssize_t __pyx_t_3; + PyObject *(*__pyx_t_4)(PyObject *); + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + PyObject *__pyx_t_7 = NULL; + PyObject *(*__pyx_t_8)(PyObject *); + int __pyx_t_9; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__inject_attributes", 0); + + /* "dependency_injector/providers.pxd":477 + * + * cdef inline void __inject_attributes(object instance, dict attributes): + * for name, value in attributes.items(): # <<<<<<<<<<<<<< + * setattr(instance, name, value) + * + */ + if (unlikely(__pyx_v_attributes == Py_None)) { + PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "items"); + __PYX_ERR(0, 477, __pyx_L1_error) + } + __pyx_t_1 = __Pyx_PyDict_Items(__pyx_v_attributes); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { + __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; + __pyx_t_4 = NULL; + } else { + __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 477, __pyx_L1_error) + } + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + for (;;) { + if (likely(!__pyx_t_4)) { + if (likely(PyList_CheckExact(__pyx_t_2))) { + if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(0, 477, __pyx_L1_error) + #else + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + #endif + } else { + if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break; + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_1); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(0, 477, __pyx_L1_error) + #else + __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + #endif + } + } else { + __pyx_t_1 = __pyx_t_4(__pyx_t_2); + if (unlikely(!__pyx_t_1)) { + PyObject* exc_type = PyErr_Occurred(); + if (exc_type) { + if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); + else __PYX_ERR(0, 477, __pyx_L1_error) + } + break; + } + __Pyx_GOTREF(__pyx_t_1); + } + if ((likely(PyTuple_CheckExact(__pyx_t_1))) || (PyList_CheckExact(__pyx_t_1))) { + PyObject* sequence = __pyx_t_1; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 2)) { + if (size > 2) __Pyx_RaiseTooManyValuesError(2); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(0, 477, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_5 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_6 = PyTuple_GET_ITEM(sequence, 1); + } else { + __pyx_t_5 = PyList_GET_ITEM(sequence, 0); + __pyx_t_6 = PyList_GET_ITEM(sequence, 1); + } + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(__pyx_t_6); + #else + __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + #endif + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_7 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 477, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext; + index = 0; __pyx_t_5 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_5)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_5); + index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_6); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) __PYX_ERR(0, 477, __pyx_L1_error) + __pyx_t_8 = NULL; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + goto __pyx_L6_unpacking_done; + __pyx_L5_unpacking_failed:; + __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; + __pyx_t_8 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(0, 477, __pyx_L1_error) + __pyx_L6_unpacking_done:; + } + __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_5); + __pyx_t_5 = 0; + __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_6); + __pyx_t_6 = 0; + + /* "dependency_injector/providers.pxd":478 + * cdef inline void __inject_attributes(object instance, dict attributes): + * for name, value in attributes.items(): + * setattr(instance, name, value) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_9 = PyObject_SetAttr(__pyx_v_instance, __pyx_v_name, __pyx_v_value); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 478, __pyx_L1_error) + + /* "dependency_injector/providers.pxd":477 + * + * cdef inline void __inject_attributes(object instance, dict attributes): + * for name, value in attributes.items(): # <<<<<<<<<<<<<< + * setattr(instance, name, value) + * + */ + } + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + + /* "dependency_injector/providers.pxd":476 + * + * + * cdef inline void __inject_attributes(object instance, dict attributes): # <<<<<<<<<<<<<< + * for name, value in attributes.items(): + * setattr(instance, name, value) + */ + + /* function exit code */ + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); + __Pyx_XDECREF(__pyx_t_7); + __Pyx_WriteUnraisable("dependency_injector.providers.__inject_attributes", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_name); + __Pyx_XDECREF(__pyx_v_value); + __Pyx_RefNannyFinishContext(); +} + +/* "dependency_injector/providers.pxd":481 * * * cdef inline object __call( # <<<<<<<<<<<<<< @@ -83715,64 +93514,525 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___inject * tuple context_args, */ -static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___call(PyObject *__pyx_v_call, PyObject *__pyx_v_context_args, PyObject *__pyx_v_injection_args, int __pyx_v_injection_args_len, PyObject *__pyx_v_kwargs, PyObject *__pyx_v_injection_kwargs, int __pyx_v_injection_kwargs_len) { - PyObject *__pyx_v_positional_args = 0; - PyObject *__pyx_v_keyword_args = 0; +static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___call(PyObject *__pyx_v_call, PyObject *__pyx_v_context_args, PyObject *__pyx_v_injection_args, int __pyx_v_injection_args_len, PyObject *__pyx_v_context_kwargs, PyObject *__pyx_v_injection_kwargs, int __pyx_v_injection_kwargs_len) { + PyObject *__pyx_v_args = NULL; + PyObject *__pyx_v_kwargs = NULL; + int __pyx_v_args_awaitable; + int __pyx_v_kwargs_awaitable; + PyObject *__pyx_v_future = NULL; + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_args_kwargs_ready = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; + int __pyx_t_2; + int __pyx_t_3; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *__pyx_t_6 = NULL; + int __pyx_t_7; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__call", 0); - /* "dependency_injector/providers.pxd":421 - * cdef dict keyword_args - * - * positional_args = __provide_positional_args( # <<<<<<<<<<<<<< + /* "dependency_injector/providers.pxd":490 + * int injection_kwargs_len, + * ): + * args = __provide_positional_args( # <<<<<<<<<<<<<< * context_args, * injection_args, */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___provide_positional_args(__pyx_v_context_args, __pyx_v_injection_args, __pyx_v_injection_args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 421, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___provide_positional_args(__pyx_v_context_args, __pyx_v_injection_args, __pyx_v_injection_args_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 490, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_v_positional_args = ((PyObject*)__pyx_t_1); + __pyx_v_args = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":426 + /* "dependency_injector/providers.pxd":495 * injection_args_len, * ) - * keyword_args = __provide_keyword_args( # <<<<<<<<<<<<<< - * kwargs, + * kwargs = __provide_keyword_args( # <<<<<<<<<<<<<< + * context_kwargs, * injection_kwargs, */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___provide_keyword_args(__pyx_v_kwargs, __pyx_v_injection_kwargs, __pyx_v_injection_kwargs_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 426, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___provide_keyword_args(__pyx_v_context_kwargs, __pyx_v_injection_kwargs, __pyx_v_injection_kwargs_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_v_keyword_args = ((PyObject*)__pyx_t_1); + __pyx_v_kwargs = __pyx_t_1; __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":432 + /* "dependency_injector/providers.pxd":501 * ) * - * return call(*positional_args, **keyword_args) # <<<<<<<<<<<<<< + * args_awaitable = __isawaitable(args) # <<<<<<<<<<<<<< + * kwargs_awaitable = __isawaitable(kwargs) + * + */ + __pyx_v_args_awaitable = __pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_args); + + /* "dependency_injector/providers.pxd":502 + * + * args_awaitable = __isawaitable(args) + * kwargs_awaitable = __isawaitable(kwargs) # <<<<<<<<<<<<<< + * + * if args_awaitable or kwargs_awaitable: + */ + __pyx_v_kwargs_awaitable = __pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_kwargs); + + /* "dependency_injector/providers.pxd":504 + * kwargs_awaitable = __isawaitable(kwargs) + * + * if args_awaitable or kwargs_awaitable: # <<<<<<<<<<<<<< + * if not args_awaitable: + * future = asyncio.Future() + */ + __pyx_t_3 = (__pyx_v_args_awaitable != 0); + if (!__pyx_t_3) { + } else { + __pyx_t_2 = __pyx_t_3; + goto __pyx_L4_bool_binop_done; + } + __pyx_t_3 = (__pyx_v_kwargs_awaitable != 0); + __pyx_t_2 = __pyx_t_3; + __pyx_L4_bool_binop_done:; + if (__pyx_t_2) { + + /* "dependency_injector/providers.pxd":505 + * + * if args_awaitable or kwargs_awaitable: + * if not args_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(args) + */ + __pyx_t_2 = ((!(__pyx_v_args_awaitable != 0)) != 0); + if (__pyx_t_2) { + + /* "dependency_injector/providers.pxd":506 + * if args_awaitable or kwargs_awaitable: + * if not args_awaitable: + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result(args) + * args = future + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 506, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_Future); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 506, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 506, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_future = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":507 + * if not args_awaitable: + * future = asyncio.Future() + * future.set_result(args) # <<<<<<<<<<<<<< + * args = future + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 507, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_v_args) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_args); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 507, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":508 + * future = asyncio.Future() + * future.set_result(args) + * args = future # <<<<<<<<<<<<<< + * + * if not kwargs_awaitable: + */ + __Pyx_INCREF(__pyx_v_future); + __Pyx_DECREF_SET(__pyx_v_args, __pyx_v_future); + + /* "dependency_injector/providers.pxd":505 + * + * if args_awaitable or kwargs_awaitable: + * if not args_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(args) + */ + } + + /* "dependency_injector/providers.pxd":510 + * args = future + * + * if not kwargs_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(kwargs) + */ + __pyx_t_2 = ((!(__pyx_v_kwargs_awaitable != 0)) != 0); + if (__pyx_t_2) { + + /* "dependency_injector/providers.pxd":511 + * + * if not kwargs_awaitable: + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result(kwargs) + * kwargs = future + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 511, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_Future); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 511, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 511, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF_SET(__pyx_v_future, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":512 + * if not kwargs_awaitable: + * future = asyncio.Future() + * future.set_result(kwargs) # <<<<<<<<<<<<<< + * kwargs = future + * + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 512, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_kwargs) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_kwargs); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 512, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":513 + * future = asyncio.Future() + * future.set_result(kwargs) + * kwargs = future # <<<<<<<<<<<<<< + * + * future_result = asyncio.Future() + */ + __Pyx_INCREF(__pyx_v_future); + __Pyx_DECREF_SET(__pyx_v_kwargs, __pyx_v_future); + + /* "dependency_injector/providers.pxd":510 + * args = future + * + * if not kwargs_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(kwargs) + */ + } + + /* "dependency_injector/providers.pxd":515 + * kwargs = future + * + * future_result = asyncio.Future() # <<<<<<<<<<<<<< + * + * future = asyncio.Future() + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 515, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_Future); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 515, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 515, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_future_result = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":517 + * future_result = asyncio.Future() + * + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result((future_result, call)) + * + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 517, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_Future); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 517, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 517, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_XDECREF_SET(__pyx_v_future, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":518 + * + * future = asyncio.Future() + * future.set_result((future_result, call)) # <<<<<<<<<<<<<< + * + * args_kwargs_ready = asyncio.gather(future, args, kwargs) + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 518, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 518, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_INCREF(__pyx_v_future_result); + __Pyx_GIVEREF(__pyx_v_future_result); + PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_v_future_result); + __Pyx_INCREF(__pyx_v_call); + __Pyx_GIVEREF(__pyx_v_call); + PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_v_call); + __pyx_t_6 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_6)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_6); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 518, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":520 + * future.set_result((future_result, call)) + * + * args_kwargs_ready = asyncio.gather(future, args, kwargs) # <<<<<<<<<<<<<< + * args_kwargs_ready.add_done_callback(__async_call_callback) + * asyncio.ensure_future(args_kwargs_ready) + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 520, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_gather); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 520, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + __pyx_t_7 = 0; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + __pyx_t_7 = 1; + } + } + #if CYTHON_FAST_PYCALL + if (PyFunction_Check(__pyx_t_5)) { + PyObject *__pyx_temp[4] = {__pyx_t_4, __pyx_v_future, __pyx_v_args, __pyx_v_kwargs}; + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 520, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_GOTREF(__pyx_t_1); + } else + #endif + #if CYTHON_FAST_PYCCALL + if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { + PyObject *__pyx_temp[4] = {__pyx_t_4, __pyx_v_future, __pyx_v_args, __pyx_v_kwargs}; + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 520, __pyx_L1_error) + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_GOTREF(__pyx_t_1); + } else + #endif + { + __pyx_t_6 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 520, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + if (__pyx_t_4) { + __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; + } + __Pyx_INCREF(__pyx_v_future); + __Pyx_GIVEREF(__pyx_v_future); + PyTuple_SET_ITEM(__pyx_t_6, 0+__pyx_t_7, __pyx_v_future); + __Pyx_INCREF(__pyx_v_args); + __Pyx_GIVEREF(__pyx_v_args); + PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_7, __pyx_v_args); + __Pyx_INCREF(__pyx_v_kwargs); + __Pyx_GIVEREF(__pyx_v_kwargs); + PyTuple_SET_ITEM(__pyx_t_6, 2+__pyx_t_7, __pyx_v_kwargs); + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 520, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + } + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_args_kwargs_ready = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":521 + * + * args_kwargs_ready = asyncio.gather(future, args, kwargs) + * args_kwargs_ready.add_done_callback(__async_call_callback) # <<<<<<<<<<<<<< + * asyncio.ensure_future(args_kwargs_ready) + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_args_kwargs_ready, __pyx_n_s_add_done_callback); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 521, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = __Pyx_CFunc_void____object___to_py(__pyx_f_19dependency_injector_9providers___async_call_callback); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 521, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_4, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 521, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":522 + * args_kwargs_ready = asyncio.gather(future, args, kwargs) + * args_kwargs_ready.add_done_callback(__async_call_callback) + * asyncio.ensure_future(args_kwargs_ready) # <<<<<<<<<<<<<< + * + * return future_result + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 522, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_ensure_future); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 522, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_6, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_5, __pyx_v_args_kwargs_ready) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_args_kwargs_ready); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 522, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":524 + * asyncio.ensure_future(args_kwargs_ready) + * + * return future_result # <<<<<<<<<<<<<< + * + * return call(*args, **kwargs) + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_future_result); + __pyx_r = __pyx_v_future_result; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":504 + * kwargs_awaitable = __isawaitable(kwargs) + * + * if args_awaitable or kwargs_awaitable: # <<<<<<<<<<<<<< + * if not args_awaitable: + * future = asyncio.Future() + */ + } + + /* "dependency_injector/providers.pxd":526 + * return future_result + * + * return call(*args, **kwargs) # <<<<<<<<<<<<<< * * */ __Pyx_XDECREF(__pyx_r); - if (unlikely(__pyx_v_positional_args == Py_None)) { - PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 432, __pyx_L1_error) - } - if (unlikely(__pyx_v_keyword_args == Py_None)) { - PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); - __PYX_ERR(0, 432, __pyx_L1_error) - } - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_v_call, __pyx_v_positional_args, __pyx_v_keyword_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 432, __pyx_L1_error) + __pyx_t_1 = __Pyx_PySequence_Tuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 526, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_r = __pyx_t_1; - __pyx_t_1 = 0; + if (unlikely(__pyx_v_kwargs == Py_None)) { + PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); + __PYX_ERR(0, 526, __pyx_L1_error) + } + if (likely(PyDict_CheckExact(__pyx_v_kwargs))) { + __pyx_t_6 = PyDict_Copy(__pyx_v_kwargs); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 526, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + } else { + __pyx_t_6 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_v_kwargs, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 526, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_6); + } + __pyx_t_5 = __Pyx_PyObject_Call(__pyx_v_call, __pyx_t_1, __pyx_t_6); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 526, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; + __pyx_r = __pyx_t_5; + __pyx_t_5 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pxd":409 + /* "dependency_injector/providers.pxd":481 * * * cdef inline object __call( # <<<<<<<<<<<<<< @@ -83783,17 +94043,264 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___call(P /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("dependency_injector.providers.__call", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; - __Pyx_XDECREF(__pyx_v_positional_args); - __Pyx_XDECREF(__pyx_v_keyword_args); + __Pyx_XDECREF(__pyx_v_args); + __Pyx_XDECREF(__pyx_v_kwargs); + __Pyx_XDECREF(__pyx_v_future); + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_args_kwargs_ready); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } -/* "dependency_injector/providers.pxd":435 +/* "dependency_injector/providers.pxd":529 + * + * + * cdef inline void __async_call_callback(object future): # <<<<<<<<<<<<<< + * (future_result, call), args, kwargs = future.result() + * result = call(*args, **kwargs) + */ + +static CYTHON_INLINE void __pyx_f_19dependency_injector_9providers___async_call_callback(PyObject *__pyx_v_future) { + PyObject *__pyx_v_future_result = NULL; + PyObject *__pyx_v_call = NULL; + PyObject *__pyx_v_args = NULL; + PyObject *__pyx_v_kwargs = NULL; + PyObject *__pyx_v_result = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + PyObject *__pyx_t_5 = NULL; + PyObject *(*__pyx_t_6)(PyObject *); + PyObject *__pyx_t_7 = NULL; + PyObject *__pyx_t_8 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__async_call_callback", 0); + + /* "dependency_injector/providers.pxd":530 + * + * cdef inline void __async_call_callback(object future): + * (future_result, call), args, kwargs = future.result() # <<<<<<<<<<<<<< + * result = call(*args, **kwargs) + * future_result.set_result(result) + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + if ((likely(PyTuple_CheckExact(__pyx_t_1))) || (PyList_CheckExact(__pyx_t_1))) { + PyObject* sequence = __pyx_t_1; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 3)) { + if (size > 3) __Pyx_RaiseTooManyValuesError(3); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(0, 530, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_2 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_3 = PyTuple_GET_ITEM(sequence, 1); + __pyx_t_4 = PyTuple_GET_ITEM(sequence, 2); + } else { + __pyx_t_2 = PyList_GET_ITEM(sequence, 0); + __pyx_t_3 = PyList_GET_ITEM(sequence, 1); + __pyx_t_4 = PyList_GET_ITEM(sequence, 2); + } + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + #else + __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_3 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + #endif + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_5 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_t_6 = Py_TYPE(__pyx_t_5)->tp_iternext; + index = 0; __pyx_t_2 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_2)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_2); + index = 1; __pyx_t_3 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_3)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_3); + index = 2; __pyx_t_4 = __pyx_t_6(__pyx_t_5); if (unlikely(!__pyx_t_4)) goto __pyx_L3_unpacking_failed; + __Pyx_GOTREF(__pyx_t_4); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_6(__pyx_t_5), 3) < 0) __PYX_ERR(0, 530, __pyx_L1_error) + __pyx_t_6 = NULL; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + goto __pyx_L4_unpacking_done; + __pyx_L3_unpacking_failed:; + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_6 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(0, 530, __pyx_L1_error) + __pyx_L4_unpacking_done:; + } + if ((likely(PyTuple_CheckExact(__pyx_t_2))) || (PyList_CheckExact(__pyx_t_2))) { + PyObject* sequence = __pyx_t_2; + Py_ssize_t size = __Pyx_PySequence_SIZE(sequence); + if (unlikely(size != 2)) { + if (size > 2) __Pyx_RaiseTooManyValuesError(2); + else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); + __PYX_ERR(0, 530, __pyx_L1_error) + } + #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS + if (likely(PyTuple_CheckExact(sequence))) { + __pyx_t_5 = PyTuple_GET_ITEM(sequence, 0); + __pyx_t_7 = PyTuple_GET_ITEM(sequence, 1); + } else { + __pyx_t_5 = PyList_GET_ITEM(sequence, 0); + __pyx_t_7 = PyList_GET_ITEM(sequence, 1); + } + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(__pyx_t_7); + #else + __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_7 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_7); + #endif + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + } else { + Py_ssize_t index = -1; + __pyx_t_8 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 530, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_6 = Py_TYPE(__pyx_t_8)->tp_iternext; + index = 0; __pyx_t_5 = __pyx_t_6(__pyx_t_8); if (unlikely(!__pyx_t_5)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_5); + index = 1; __pyx_t_7 = __pyx_t_6(__pyx_t_8); if (unlikely(!__pyx_t_7)) goto __pyx_L5_unpacking_failed; + __Pyx_GOTREF(__pyx_t_7); + if (__Pyx_IternextUnpackEndCheck(__pyx_t_6(__pyx_t_8), 2) < 0) __PYX_ERR(0, 530, __pyx_L1_error) + __pyx_t_6 = NULL; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + goto __pyx_L6_unpacking_done; + __pyx_L5_unpacking_failed:; + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_6 = NULL; + if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); + __PYX_ERR(0, 530, __pyx_L1_error) + __pyx_L6_unpacking_done:; + } + __pyx_v_future_result = __pyx_t_5; + __pyx_t_5 = 0; + __pyx_v_call = __pyx_t_7; + __pyx_t_7 = 0; + __pyx_v_args = __pyx_t_3; + __pyx_t_3 = 0; + __pyx_v_kwargs = __pyx_t_4; + __pyx_t_4 = 0; + + /* "dependency_injector/providers.pxd":531 + * cdef inline void __async_call_callback(object future): + * (future_result, call), args, kwargs = future.result() + * result = call(*args, **kwargs) # <<<<<<<<<<<<<< + * future_result.set_result(result) + * + */ + __pyx_t_1 = __Pyx_PySequence_Tuple(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 531, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (unlikely(__pyx_v_kwargs == Py_None)) { + PyErr_SetString(PyExc_TypeError, "argument after ** must be a mapping, not NoneType"); + __PYX_ERR(0, 531, __pyx_L1_error) + } + if (likely(PyDict_CheckExact(__pyx_v_kwargs))) { + __pyx_t_4 = PyDict_Copy(__pyx_v_kwargs); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 531, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + } else { + __pyx_t_4 = PyObject_CallFunctionObjArgs((PyObject*)&PyDict_Type, __pyx_v_kwargs, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 531, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + } + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_v_call, __pyx_t_1, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 531, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_v_result = __pyx_t_3; + __pyx_t_3 = 0; + + /* "dependency_injector/providers.pxd":532 + * (future_result, call), args, kwargs = future.result() + * result = call(*args, **kwargs) + * future_result.set_result(result) # <<<<<<<<<<<<<< + * + * + */ + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_future_result, __pyx_n_s_set_result); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 532, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_1 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_1 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_1)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_1); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_3 = (__pyx_t_1) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_1, __pyx_v_result) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_result); + __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 532, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + + /* "dependency_injector/providers.pxd":529 + * + * + * cdef inline void __async_call_callback(object future): # <<<<<<<<<<<<<< + * (future_result, call), args, kwargs = future.result() + * result = call(*args, **kwargs) + */ + + /* function exit code */ + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_XDECREF(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_7); + __Pyx_XDECREF(__pyx_t_8); + __Pyx_WriteUnraisable("dependency_injector.providers.__async_call_callback", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_future_result); + __Pyx_XDECREF(__pyx_v_call); + __Pyx_XDECREF(__pyx_v_args); + __Pyx_XDECREF(__pyx_v_kwargs); + __Pyx_XDECREF(__pyx_v_result); + __Pyx_RefNannyFinishContext(); +} + +/* "dependency_injector/providers.pxd":535 * * * cdef inline object __callable_call(Callable self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -83813,7 +94320,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__callable_call", 0); - /* "dependency_injector/providers.pxd":436 + /* "dependency_injector/providers.pxd":536 * * cdef inline object __callable_call(Callable self, tuple args, dict kwargs): * return __call( # <<<<<<<<<<<<<< @@ -83822,7 +94329,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab */ __Pyx_XDECREF(__pyx_r); - /* "dependency_injector/providers.pxd":437 + /* "dependency_injector/providers.pxd":537 * cdef inline object __callable_call(Callable self, tuple args, dict kwargs): * return __call( * self.__provides, # <<<<<<<<<<<<<< @@ -83832,7 +94339,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab __pyx_t_1 = __pyx_v_self->__pyx___provides; __Pyx_INCREF(__pyx_t_1); - /* "dependency_injector/providers.pxd":439 + /* "dependency_injector/providers.pxd":539 * self.__provides, * args, * self.__args, # <<<<<<<<<<<<<< @@ -83842,7 +94349,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab __pyx_t_2 = __pyx_v_self->__pyx___args; __Pyx_INCREF(__pyx_t_2); - /* "dependency_injector/providers.pxd":442 + /* "dependency_injector/providers.pxd":542 * self.__args_len, * kwargs, * self.__kwargs, # <<<<<<<<<<<<<< @@ -83852,14 +94359,14 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab __pyx_t_3 = __pyx_v_self->__pyx___kwargs; __Pyx_INCREF(__pyx_t_3); - /* "dependency_injector/providers.pxd":436 + /* "dependency_injector/providers.pxd":536 * * cdef inline object __callable_call(Callable self, tuple args, dict kwargs): * return __call( # <<<<<<<<<<<<<< * self.__provides, * args, */ - __pyx_t_4 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_1, __pyx_v_args, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_3), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 436, __pyx_L1_error) + __pyx_t_4 = __pyx_f_19dependency_injector_9providers___call(__pyx_t_1, __pyx_v_args, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___args_len, __pyx_v_kwargs, ((PyObject*)__pyx_t_3), __pyx_v_self->__pyx___kwargs_len); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 536, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -83868,7 +94375,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab __pyx_t_4 = 0; goto __pyx_L0; - /* "dependency_injector/providers.pxd":435 + /* "dependency_injector/providers.pxd":535 * * * cdef inline object __callable_call(Callable self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -83890,7 +94397,7 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab return __pyx_r; } -/* "dependency_injector/providers.pxd":447 +/* "dependency_injector/providers.pxd":547 * * * cdef inline object __factory_call(Factory self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -83900,17 +94407,23 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___callab static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___factory_call(struct __pyx_obj_19dependency_injector_9providers_Factory *__pyx_v_self, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs) { PyObject *__pyx_v_instance = 0; + PyObject *__pyx_v_attributes = NULL; + int __pyx_v_instance_awaitable; + int __pyx_v_attributes_awaitable; + PyObject *__pyx_v_future = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; int __pyx_t_3; + int __pyx_t_4; + PyObject *__pyx_t_5 = NULL; int __pyx_lineno = 0; const char *__pyx_filename = NULL; int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__factory_call", 0); - /* "dependency_injector/providers.pxd":450 + /* "dependency_injector/providers.pxd":550 * cdef object instance * * instance = __callable_call(self.__instantiator, args, kwargs) # <<<<<<<<<<<<<< @@ -83919,64 +94432,298 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___factor */ __pyx_t_1 = ((PyObject *)__pyx_v_self->__pyx___instantiator); __Pyx_INCREF(__pyx_t_1); - __pyx_t_2 = __pyx_f_19dependency_injector_9providers___callable_call(((struct __pyx_obj_19dependency_injector_9providers_Callable *)__pyx_t_1), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 450, __pyx_L1_error) + __pyx_t_2 = __pyx_f_19dependency_injector_9providers___callable_call(((struct __pyx_obj_19dependency_injector_9providers_Callable *)__pyx_t_1), __pyx_v_args, __pyx_v_kwargs); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 550, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_instance = __pyx_t_2; __pyx_t_2 = 0; - /* "dependency_injector/providers.pxd":452 + /* "dependency_injector/providers.pxd":552 * instance = __callable_call(self.__instantiator, args, kwargs) * * if self.__attributes_len > 0: # <<<<<<<<<<<<<< - * __inject_attributes(instance, - * self.__attributes, + * attributes = __provide_attributes(self.__attributes, self.__attributes_len) + * */ __pyx_t_3 = ((__pyx_v_self->__pyx___attributes_len > 0) != 0); if (__pyx_t_3) { - /* "dependency_injector/providers.pxd":454 - * if self.__attributes_len > 0: - * __inject_attributes(instance, - * self.__attributes, # <<<<<<<<<<<<<< - * self.__attributes_len) + /* "dependency_injector/providers.pxd":553 * + * if self.__attributes_len > 0: + * attributes = __provide_attributes(self.__attributes, self.__attributes_len) # <<<<<<<<<<<<<< + * + * instance_awaitable = __isawaitable(instance) */ __pyx_t_2 = __pyx_v_self->__pyx___attributes; __Pyx_INCREF(__pyx_t_2); - - /* "dependency_injector/providers.pxd":453 - * - * if self.__attributes_len > 0: - * __inject_attributes(instance, # <<<<<<<<<<<<<< - * self.__attributes, - * self.__attributes_len) - */ - __pyx_t_1 = __pyx_f_19dependency_injector_9providers___inject_attributes(__pyx_v_instance, ((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___attributes_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 453, __pyx_L1_error) + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___provide_attributes(((PyObject*)__pyx_t_2), __pyx_v_self->__pyx___attributes_len); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 553, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + __pyx_v_attributes = __pyx_t_1; + __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":452 + /* "dependency_injector/providers.pxd":555 + * attributes = __provide_attributes(self.__attributes, self.__attributes_len) + * + * instance_awaitable = __isawaitable(instance) # <<<<<<<<<<<<<< + * attributes_awaitable = __isawaitable(attributes) + * + */ + __pyx_v_instance_awaitable = __pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_instance); + + /* "dependency_injector/providers.pxd":556 + * + * instance_awaitable = __isawaitable(instance) + * attributes_awaitable = __isawaitable(attributes) # <<<<<<<<<<<<<< + * + * if instance_awaitable or attributes_awaitable: + */ + __pyx_v_attributes_awaitable = __pyx_f_19dependency_injector_9providers___isawaitable(__pyx_v_attributes); + + /* "dependency_injector/providers.pxd":558 + * attributes_awaitable = __isawaitable(attributes) + * + * if instance_awaitable or attributes_awaitable: # <<<<<<<<<<<<<< + * if not instance_awaitable: + * future = asyncio.Future() + */ + __pyx_t_4 = (__pyx_v_instance_awaitable != 0); + if (!__pyx_t_4) { + } else { + __pyx_t_3 = __pyx_t_4; + goto __pyx_L5_bool_binop_done; + } + __pyx_t_4 = (__pyx_v_attributes_awaitable != 0); + __pyx_t_3 = __pyx_t_4; + __pyx_L5_bool_binop_done:; + if (__pyx_t_3) { + + /* "dependency_injector/providers.pxd":559 + * + * if instance_awaitable or attributes_awaitable: + * if not instance_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(instance) + */ + __pyx_t_3 = ((!(__pyx_v_instance_awaitable != 0)) != 0); + if (__pyx_t_3) { + + /* "dependency_injector/providers.pxd":560 + * if instance_awaitable or attributes_awaitable: + * if not instance_awaitable: + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result(instance) + * instance = future + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 560, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_Future); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 560, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_5); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 560, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_v_future = __pyx_t_1; + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":561 + * if not instance_awaitable: + * future = asyncio.Future() + * future.set_result(instance) # <<<<<<<<<<<<<< + * instance = future + * + */ + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 561, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_2 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) { + __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_5); + if (likely(__pyx_t_2)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); + __Pyx_INCREF(__pyx_t_2); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_5, function); + } + } + __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_2, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 561, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":562 + * future = asyncio.Future() + * future.set_result(instance) + * instance = future # <<<<<<<<<<<<<< + * + * if not attributes_awaitable: + */ + __Pyx_INCREF(__pyx_v_future); + __Pyx_DECREF_SET(__pyx_v_instance, __pyx_v_future); + + /* "dependency_injector/providers.pxd":559 + * + * if instance_awaitable or attributes_awaitable: + * if not instance_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(instance) + */ + } + + /* "dependency_injector/providers.pxd":564 + * instance = future + * + * if not attributes_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(attributes) + */ + __pyx_t_3 = ((!(__pyx_v_attributes_awaitable != 0)) != 0); + if (__pyx_t_3) { + + /* "dependency_injector/providers.pxd":565 + * + * if not attributes_awaitable: + * future = asyncio.Future() # <<<<<<<<<<<<<< + * future.set_result(attributes) + * attributes = future + */ + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 565, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_5); + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_Future); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 565, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 565, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_XDECREF_SET(__pyx_v_future, __pyx_t_1); + __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":566 + * if not attributes_awaitable: + * future = asyncio.Future() + * future.set_result(attributes) # <<<<<<<<<<<<<< + * attributes = future + * + */ + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_future, __pyx_n_s_set_result); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 566, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_5 = NULL; + if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { + __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2); + if (likely(__pyx_t_5)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); + __Pyx_INCREF(__pyx_t_5); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_2, function); + } + } + __pyx_t_1 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_5, __pyx_v_attributes) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_attributes); + __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 566, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pxd":567 + * future = asyncio.Future() + * future.set_result(attributes) + * attributes = future # <<<<<<<<<<<<<< + * + * return __async_inject_attributes(instance, attributes) + */ + __Pyx_INCREF(__pyx_v_future); + __Pyx_DECREF_SET(__pyx_v_attributes, __pyx_v_future); + + /* "dependency_injector/providers.pxd":564 + * instance = future + * + * if not attributes_awaitable: # <<<<<<<<<<<<<< + * future = asyncio.Future() + * future.set_result(attributes) + */ + } + + /* "dependency_injector/providers.pxd":569 + * attributes = future + * + * return __async_inject_attributes(instance, attributes) # <<<<<<<<<<<<<< + * + * __inject_attributes(instance, attributes) + */ + __Pyx_XDECREF(__pyx_r); + __pyx_t_1 = __pyx_f_19dependency_injector_9providers___async_inject_attributes(__pyx_v_instance, __pyx_v_attributes); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 569, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_r = __pyx_t_1; + __pyx_t_1 = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":558 + * attributes_awaitable = __isawaitable(attributes) + * + * if instance_awaitable or attributes_awaitable: # <<<<<<<<<<<<<< + * if not instance_awaitable: + * future = asyncio.Future() + */ + } + + /* "dependency_injector/providers.pxd":571 + * return __async_inject_attributes(instance, attributes) + * + * __inject_attributes(instance, attributes) # <<<<<<<<<<<<<< + * + * return instance + */ + if (!(likely(PyDict_CheckExact(__pyx_v_attributes))||((__pyx_v_attributes) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_attributes)->tp_name), 0))) __PYX_ERR(0, 571, __pyx_L1_error) + __pyx_f_19dependency_injector_9providers___inject_attributes(__pyx_v_instance, ((PyObject*)__pyx_v_attributes)); + + /* "dependency_injector/providers.pxd":552 * instance = __callable_call(self.__instantiator, args, kwargs) * * if self.__attributes_len > 0: # <<<<<<<<<<<<<< - * __inject_attributes(instance, - * self.__attributes, + * attributes = __provide_attributes(self.__attributes, self.__attributes_len) + * */ } - /* "dependency_injector/providers.pxd":457 - * self.__attributes_len) + /* "dependency_injector/providers.pxd":573 + * __inject_attributes(instance, attributes) * * return instance # <<<<<<<<<<<<<< + * + * */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_instance); __pyx_r = __pyx_v_instance; goto __pyx_L0; - /* "dependency_injector/providers.pxd":447 + /* "dependency_injector/providers.pxd":547 * * * cdef inline object __factory_call(Factory self, tuple args, dict kwargs): # <<<<<<<<<<<<<< @@ -83988,10 +94735,314 @@ static CYTHON_INLINE PyObject *__pyx_f_19dependency_injector_9providers___factor __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_5); __Pyx_AddTraceback("dependency_injector.providers.__factory_call", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_instance); + __Pyx_XDECREF(__pyx_v_attributes); + __Pyx_XDECREF(__pyx_v_future); + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "dependency_injector/providers.pxd":579 + * + * + * cdef inline bint __isawaitable(object instance): # <<<<<<<<<<<<<< + * global __has_isawaitable + * + */ + +static CYTHON_INLINE int __pyx_f_19dependency_injector_9providers___isawaitable(PyObject *__pyx_v_instance) { + int __pyx_r; + __Pyx_RefNannyDeclarations + int __pyx_t_1; + PyObject *__pyx_t_2 = NULL; + PyObject *__pyx_t_3 = NULL; + PyObject *__pyx_t_4 = NULL; + int __pyx_t_5; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__isawaitable", 0); + + /* "dependency_injector/providers.pxd":582 + * global __has_isawaitable + * + * if __has_isawaitable is True: # <<<<<<<<<<<<<< + * return inspect.isawaitable(instance) + * + */ + __pyx_t_1 = ((__pyx_v_19dependency_injector_9providers___has_isawaitable == 1) != 0); + if (__pyx_t_1) { + + /* "dependency_injector/providers.pxd":583 + * + * if __has_isawaitable is True: + * return inspect.isawaitable(instance) # <<<<<<<<<<<<<< + * + * if hasattr(inspect, 'isawaitable'): + */ + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_inspect); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 583, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_isawaitable); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 583, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_3 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { + __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4); + if (likely(__pyx_t_3)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); + __Pyx_INCREF(__pyx_t_3); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_4, function); + } + } + __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_3, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 583, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 583, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_r = __pyx_t_1; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":582 + * global __has_isawaitable + * + * if __has_isawaitable is True: # <<<<<<<<<<<<<< + * return inspect.isawaitable(instance) + * + */ + } + + /* "dependency_injector/providers.pxd":585 + * return inspect.isawaitable(instance) + * + * if hasattr(inspect, 'isawaitable'): # <<<<<<<<<<<<<< + * __has_isawaitable = True + * return inspect.isawaitable(instance) + */ + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_inspect); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 585, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __pyx_t_1 = __Pyx_HasAttr(__pyx_t_2, __pyx_n_s_isawaitable); if (unlikely(__pyx_t_1 == ((int)-1))) __PYX_ERR(0, 585, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_t_5 = (__pyx_t_1 != 0); + if (__pyx_t_5) { + + /* "dependency_injector/providers.pxd":586 + * + * if hasattr(inspect, 'isawaitable'): + * __has_isawaitable = True # <<<<<<<<<<<<<< + * return inspect.isawaitable(instance) + * + */ + __pyx_v_19dependency_injector_9providers___has_isawaitable = 1; + + /* "dependency_injector/providers.pxd":587 + * if hasattr(inspect, 'isawaitable'): + * __has_isawaitable = True + * return inspect.isawaitable(instance) # <<<<<<<<<<<<<< + * + * return False + */ + __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_inspect); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 587, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_4); + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_isawaitable); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 587, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_3); + __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; + __pyx_t_4 = NULL; + if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { + __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3); + if (likely(__pyx_t_4)) { + PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); + __Pyx_INCREF(__pyx_t_4); + __Pyx_INCREF(function); + __Pyx_DECREF_SET(__pyx_t_3, function); + } + } + __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_v_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_instance); + __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; + if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 587, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_2); + __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; + __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 587, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; + __pyx_r = __pyx_t_5; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":585 + * return inspect.isawaitable(instance) + * + * if hasattr(inspect, 'isawaitable'): # <<<<<<<<<<<<<< + * __has_isawaitable = True + * return inspect.isawaitable(instance) + */ + } + + /* "dependency_injector/providers.pxd":589 + * return inspect.isawaitable(instance) + * + * return False # <<<<<<<<<<<<<< + */ + __pyx_r = 0; + goto __pyx_L0; + + /* "dependency_injector/providers.pxd":579 + * + * + * cdef inline bint __isawaitable(object instance): # <<<<<<<<<<<<<< + * global __has_isawaitable + * + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_2); + __Pyx_XDECREF(__pyx_t_3); + __Pyx_XDECREF(__pyx_t_4); + __Pyx_WriteUnraisable("dependency_injector.providers.__isawaitable", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0); + __pyx_r = 0; + __pyx_L0:; + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "cfunc.to_py":65 + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): + * def wrap(object future): # <<<<<<<<<<<<<< + * """wrap(future) -> 'void'""" + * f(future) + */ + +/* Python wrapper */ +static PyObject *__pyx_pw_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_1wrap(PyObject *__pyx_self, PyObject *__pyx_v_future); /*proto*/ +static char __pyx_doc_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_wrap[] = "wrap(future) -> 'void'"; +static PyMethodDef __pyx_mdef_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_1wrap = {"wrap", (PyCFunction)__pyx_pw_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_1wrap, METH_O, __pyx_doc_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_wrap}; +static PyObject *__pyx_pw_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_1wrap(PyObject *__pyx_self, PyObject *__pyx_v_future) { + PyObject *__pyx_r = 0; + __Pyx_RefNannyDeclarations + __Pyx_RefNannySetupContext("wrap (wrapper)", 0); + __pyx_r = __pyx_pf_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_wrap(__pyx_self, ((PyObject *)__pyx_v_future)); + + /* function exit code */ + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +static PyObject *__pyx_pf_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_wrap(PyObject *__pyx_self, PyObject *__pyx_v_future) { + struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *__pyx_cur_scope; + struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *__pyx_outer_scope; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("wrap", 0); + __pyx_outer_scope = (struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *) __Pyx_CyFunction_GetClosure(__pyx_self); + __pyx_cur_scope = __pyx_outer_scope; + + /* "cfunc.to_py":67 + * def wrap(object future): + * """wrap(future) -> 'void'""" + * f(future) # <<<<<<<<<<<<<< + * return wrap + * + */ + __pyx_cur_scope->__pyx_v_f(__pyx_v_future); if (unlikely(PyErr_Occurred())) __PYX_ERR(2, 67, __pyx_L1_error) + + /* "cfunc.to_py":65 + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): + * def wrap(object future): # <<<<<<<<<<<<<< + * """wrap(future) -> 'void'""" + * f(future) + */ + + /* function exit code */ + __pyx_r = Py_None; __Pyx_INCREF(Py_None); + goto __pyx_L0; + __pyx_L1_error:; + __Pyx_AddTraceback("cfunc.to_py.__Pyx_CFunc_void____object___to_py.wrap", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = NULL; + __pyx_L0:; + __Pyx_XGIVEREF(__pyx_r); + __Pyx_RefNannyFinishContext(); + return __pyx_r; +} + +/* "cfunc.to_py":64 + * + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): # <<<<<<<<<<<<<< + * def wrap(object future): + * """wrap(future) -> 'void'""" + */ + +static PyObject *__Pyx_CFunc_void____object___to_py(void (*__pyx_v_f)(PyObject *)) { + struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *__pyx_cur_scope; + PyObject *__pyx_v_wrap = 0; + PyObject *__pyx_r = NULL; + __Pyx_RefNannyDeclarations + PyObject *__pyx_t_1 = NULL; + int __pyx_lineno = 0; + const char *__pyx_filename = NULL; + int __pyx_clineno = 0; + __Pyx_RefNannySetupContext("__Pyx_CFunc_void____object___to_py", 0); + __pyx_cur_scope = (struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *)__pyx_tp_new___pyx_scope_struct____Pyx_CFunc_void____object___to_py(__pyx_ptype___pyx_scope_struct____Pyx_CFunc_void____object___to_py, __pyx_empty_tuple, NULL); + if (unlikely(!__pyx_cur_scope)) { + __pyx_cur_scope = ((struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *)Py_None); + __Pyx_INCREF(Py_None); + __PYX_ERR(2, 64, __pyx_L1_error) + } else { + __Pyx_GOTREF(__pyx_cur_scope); + } + __pyx_cur_scope->__pyx_v_f = __pyx_v_f; + + /* "cfunc.to_py":65 + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): + * def wrap(object future): # <<<<<<<<<<<<<< + * """wrap(future) -> 'void'""" + * f(future) + */ + __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_11cfunc_dot_to_py_34__Pyx_CFunc_void____object___to_py_1wrap, 0, __pyx_n_s_Pyx_CFunc_void____object___to, ((PyObject*)__pyx_cur_scope), __pyx_n_s_cfunc_to_py, __pyx_d, ((PyObject *)__pyx_codeobj__17)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 65, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __pyx_v_wrap = __pyx_t_1; + __pyx_t_1 = 0; + + /* "cfunc.to_py":68 + * """wrap(future) -> 'void'""" + * f(future) + * return wrap # <<<<<<<<<<<<<< + * + * + */ + __Pyx_XDECREF(__pyx_r); + __Pyx_INCREF(__pyx_v_wrap); + __pyx_r = __pyx_v_wrap; + goto __pyx_L0; + + /* "cfunc.to_py":64 + * + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): # <<<<<<<<<<<<<< + * def wrap(object future): + * """wrap(future) -> 'void'""" + */ + + /* function exit code */ + __pyx_L1_error:; + __Pyx_XDECREF(__pyx_t_1); + __Pyx_AddTraceback("cfunc.to_py.__Pyx_CFunc_void____object___to_py", __pyx_clineno, __pyx_lineno, __pyx_filename); + __pyx_r = 0; + __pyx_L0:; + __Pyx_XDECREF(__pyx_v_wrap); + __Pyx_DECREF(((PyObject *)__pyx_cur_scope)); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; @@ -84073,11 +95124,18 @@ static PyMethodDef __pyx_methods_19dependency_injector_9providers_Provider[] = { {"override", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_13override, METH_O, __pyx_doc_19dependency_injector_9providers_8Provider_12override}, {"reset_last_overriding", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_15reset_last_overriding, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Provider_14reset_last_overriding}, {"reset_override", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_17reset_override, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Provider_16reset_override}, - {"delegate", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_19delegate, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Provider_18delegate}, - {"_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Provider_21_provide, METH_VARARGS|METH_KEYWORDS, __pyx_doc_19dependency_injector_9providers_8Provider_20_provide}, - {"_copy_overridings", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Provider_23_copy_overridings, METH_VARARGS|METH_KEYWORDS, __pyx_doc_19dependency_injector_9providers_8Provider_22_copy_overridings}, - {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_25__reduce_cython__, METH_NOARGS, 0}, - {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_27__setstate_cython__, METH_O, 0}, + {"async_", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Provider_19async_, METH_VARARGS|METH_KEYWORDS, __pyx_doc_19dependency_injector_9providers_8Provider_18async_}, + {"delegate", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_21delegate, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Provider_20delegate}, + {"enable_async_mode", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_23enable_async_mode, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Provider_22enable_async_mode}, + {"disable_async_mode", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_25disable_async_mode, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Provider_24disable_async_mode}, + {"reset_async_mode", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_27reset_async_mode, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Provider_26reset_async_mode}, + {"is_async_mode_enabled", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_29is_async_mode_enabled, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Provider_28is_async_mode_enabled}, + {"is_async_mode_disabled", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_31is_async_mode_disabled, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Provider_30is_async_mode_disabled}, + {"is_async_mode_undefined", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_33is_async_mode_undefined, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Provider_32is_async_mode_undefined}, + {"_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Provider_35_provide, METH_VARARGS|METH_KEYWORDS, __pyx_doc_19dependency_injector_9providers_8Provider_34_provide}, + {"_copy_overridings", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Provider_37_copy_overridings, METH_VARARGS|METH_KEYWORDS, __pyx_doc_19dependency_injector_9providers_8Provider_36_copy_overridings}, + {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_39__reduce_cython__, METH_NOARGS, 0}, + {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Provider_41__setstate_cython__, METH_O, 0}, {0, 0, 0, 0} }; @@ -84468,8 +95526,10 @@ static PyObject *__pyx_getprop_19dependency_injector_9providers_10Dependency_ins static PyMethodDef __pyx_methods_19dependency_injector_9providers_Dependency[] = { {"__deepcopy__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10Dependency_3__deepcopy__, METH_O, __pyx_doc_19dependency_injector_9providers_10Dependency_2__deepcopy__}, {"provided_by", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10Dependency_11provided_by, METH_O, __pyx_doc_19dependency_injector_9providers_10Dependency_10provided_by}, - {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10Dependency_13__reduce_cython__, METH_NOARGS, 0}, - {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10Dependency_15__setstate_cython__, METH_O, 0}, + {"_async_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_10Dependency_13_async_provide, METH_VARARGS|METH_KEYWORDS, 0}, + {"_check_instance_type", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10Dependency_15_check_instance_type, METH_O, 0}, + {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10Dependency_17__reduce_cython__, METH_NOARGS, 0}, + {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10Dependency_19__setstate_cython__, METH_O, 0}, {0, 0, 0, 0} }; @@ -86815,7 +97875,7 @@ static PyObject *__pyx_tp_getattro_19dependency_injector_9providers_FactoryAggre PyObject *v = __Pyx_PyObject_GenericGetAttr(o, n); if (!v && PyErr_ExceptionMatches(PyExc_AttributeError)) { PyErr_Clear(); - v = __pyx_pw_19dependency_injector_9providers_16FactoryAggregate_7__getattr__(o, n); + v = __pyx_pw_19dependency_injector_9providers_16FactoryAggregate_5__getattr__(o, n); } return v; } @@ -86826,8 +97886,9 @@ static PyObject *__pyx_getprop_19dependency_injector_9providers_16FactoryAggrega static PyMethodDef __pyx_methods_19dependency_injector_9providers_FactoryAggregate[] = { {"__deepcopy__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_3__deepcopy__, METH_O, __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_2__deepcopy__}, - {"__getattr__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_7__getattr__, METH_O|METH_COEXIST, __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_6__getattr__}, - {"override", (PyCFunction)__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_11override, METH_O, __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_10override}, + {"__getattr__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_5__getattr__, METH_O|METH_COEXIST, __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_4__getattr__}, + {"override", (PyCFunction)__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_9override, METH_O, __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_8override}, + {"_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_11_provide, METH_VARARGS|METH_KEYWORDS, 0}, {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_13__reduce_cython__, METH_NOARGS, 0}, {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_16FactoryAggregate_15__setstate_cython__, METH_O, 0}, {0, 0, 0, 0} @@ -86867,8 +97928,12 @@ static PyTypeObject __pyx_type_19dependency_injector_9providers_FactoryAggregate 0, /*tp_as_sequence*/ 0, /*tp_as_mapping*/ 0, /*tp_hash*/ - __pyx_pw_19dependency_injector_9providers_16FactoryAggregate_5__call__, /*tp_call*/ - __pyx_pw_19dependency_injector_9providers_16FactoryAggregate_9__str__, /*tp_str*/ + #if CYTHON_COMPILING_IN_PYPY + __pyx_pw_19dependency_injector_9providers_8Provider_3__call__, /*tp_call*/ + #else + 0, /*tp_call*/ + #endif + __pyx_pw_19dependency_injector_9providers_16FactoryAggregate_7__str__, /*tp_str*/ __pyx_tp_getattro_19dependency_injector_9providers_FactoryAggregate, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ @@ -86919,6 +97984,7 @@ static PyObject *__pyx_tp_new_19dependency_injector_9providers_BaseSingleton(PyT p = ((struct __pyx_obj_19dependency_injector_9providers_BaseSingleton *)o); p->__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_19dependency_injector_9providers_Provider*)__pyx_vtabptr_19dependency_injector_9providers_BaseSingleton; p->__pyx___instantiator = ((struct __pyx_obj_19dependency_injector_9providers_Factory *)Py_None); Py_INCREF(Py_None); + p->__pyx___storage = Py_None; Py_INCREF(Py_None); return o; } @@ -86931,6 +97997,7 @@ static void __pyx_tp_dealloc_19dependency_injector_9providers_BaseSingleton(PyOb #endif PyObject_GC_UnTrack(o); Py_CLEAR(p->__pyx___instantiator); + Py_CLEAR(p->__pyx___storage); PyObject_GC_Track(o); __pyx_tp_dealloc_19dependency_injector_9providers_Provider(o); } @@ -86942,6 +98009,9 @@ static int __pyx_tp_traverse_19dependency_injector_9providers_BaseSingleton(PyOb if (p->__pyx___instantiator) { e = (*v)(((PyObject *)p->__pyx___instantiator), a); if (e) return e; } + if (p->__pyx___storage) { + e = (*v)(p->__pyx___storage, a); if (e) return e; + } return 0; } @@ -86952,6 +98022,9 @@ static int __pyx_tp_clear_19dependency_injector_9providers_BaseSingleton(PyObjec tmp = ((PyObject*)p->__pyx___instantiator); p->__pyx___instantiator = ((struct __pyx_obj_19dependency_injector_9providers_Factory *)Py_None); Py_INCREF(Py_None); Py_XDECREF(tmp); + tmp = ((PyObject*)p->__pyx___storage); + p->__pyx___storage = Py_None; Py_INCREF(Py_None); + Py_XDECREF(tmp); return 0; } @@ -86983,8 +98056,9 @@ static PyMethodDef __pyx_methods_19dependency_injector_9providers_BaseSingleton[ {"set_attributes", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_13BaseSingleton_21set_attributes, METH_VARARGS|METH_KEYWORDS, __pyx_doc_19dependency_injector_9providers_13BaseSingleton_20set_attributes}, {"clear_attributes", (PyCFunction)__pyx_pw_19dependency_injector_9providers_13BaseSingleton_23clear_attributes, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_13BaseSingleton_22clear_attributes}, {"reset", (PyCFunction)__pyx_pw_19dependency_injector_9providers_13BaseSingleton_25reset, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_13BaseSingleton_24reset}, - {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_13BaseSingleton_27__reduce_cython__, METH_NOARGS, 0}, - {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_13BaseSingleton_29__setstate_cython__, METH_O, 0}, + {"_async_init_instance", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_13BaseSingleton_27_async_init_instance, METH_VARARGS|METH_KEYWORDS, 0}, + {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_13BaseSingleton_29__reduce_cython__, METH_NOARGS, 0}, + {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_13BaseSingleton_31__setstate_cython__, METH_O, 0}, {0, 0, 0, 0} }; @@ -87080,43 +98154,9 @@ static PyObject *__pyx_tp_new_19dependency_injector_9providers_Singleton(PyTypeO if (unlikely(!o)) return 0; p = ((struct __pyx_obj_19dependency_injector_9providers_Singleton *)o); p->__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_19dependency_injector_9providers_Provider*)__pyx_vtabptr_19dependency_injector_9providers_Singleton; - p->__pyx___storage = Py_None; Py_INCREF(Py_None); return o; } -static void __pyx_tp_dealloc_19dependency_injector_9providers_Singleton(PyObject *o) { - struct __pyx_obj_19dependency_injector_9providers_Singleton *p = (struct __pyx_obj_19dependency_injector_9providers_Singleton *)o; - #if CYTHON_USE_TP_FINALIZE - if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) { - if (PyObject_CallFinalizerFromDealloc(o)) return; - } - #endif - PyObject_GC_UnTrack(o); - Py_CLEAR(p->__pyx___storage); - PyObject_GC_Track(o); - __pyx_tp_dealloc_19dependency_injector_9providers_BaseSingleton(o); -} - -static int __pyx_tp_traverse_19dependency_injector_9providers_Singleton(PyObject *o, visitproc v, void *a) { - int e; - struct __pyx_obj_19dependency_injector_9providers_Singleton *p = (struct __pyx_obj_19dependency_injector_9providers_Singleton *)o; - e = __pyx_tp_traverse_19dependency_injector_9providers_BaseSingleton(o, v, a); if (e) return e; - if (p->__pyx___storage) { - e = (*v)(p->__pyx___storage, a); if (e) return e; - } - return 0; -} - -static int __pyx_tp_clear_19dependency_injector_9providers_Singleton(PyObject *o) { - PyObject* tmp; - struct __pyx_obj_19dependency_injector_9providers_Singleton *p = (struct __pyx_obj_19dependency_injector_9providers_Singleton *)o; - __pyx_tp_clear_19dependency_injector_9providers_BaseSingleton(o); - tmp = ((PyObject*)p->__pyx___storage); - p->__pyx___storage = Py_None; Py_INCREF(Py_None); - Py_XDECREF(tmp); - return 0; -} - static PyMethodDef __pyx_methods_19dependency_injector_9providers_Singleton[] = { {"reset", (PyCFunction)__pyx_pw_19dependency_injector_9providers_9Singleton_3reset, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_9Singleton_2reset}, {"_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_9Singleton_5_provide, METH_VARARGS|METH_KEYWORDS, __pyx_doc_19dependency_injector_9providers_9Singleton_4_provide}, @@ -87130,7 +98170,7 @@ static PyTypeObject __pyx_type_19dependency_injector_9providers_Singleton = { "dependency_injector.providers.Singleton", /*tp_name*/ sizeof(struct __pyx_obj_19dependency_injector_9providers_Singleton), /*tp_basicsize*/ 0, /*tp_itemsize*/ - __pyx_tp_dealloc_19dependency_injector_9providers_Singleton, /*tp_dealloc*/ + __pyx_tp_dealloc_19dependency_injector_9providers_BaseSingleton, /*tp_dealloc*/ #if PY_VERSION_HEX < 0x030800b4 0, /*tp_print*/ #endif @@ -87169,8 +98209,8 @@ static PyTypeObject __pyx_type_19dependency_injector_9providers_Singleton = { 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/ "Singleton provider returns same instance on every call.\n\n :py:class:`Singleton` provider creates instance once and returns it on\n every call. :py:class:`Singleton` extends :py:class:`Factory`, so, please\n follow :py:class:`Factory` documentation for getting familiar with\n injections syntax.\n\n Retrieving of provided instance can be performed via calling\n :py:class:`Singleton` object:\n\n .. code-block:: python\n\n singleton = Singleton(SomeClass)\n some_object = singleton()\n\n .. py:attribute:: provided_type\n\n If provided type is defined, provider checks that providing class is\n its subclass.\n\n :type: type | None\n\n .. py:attribute:: cls\n :noindex:\n\n Class that provides object.\n Alias for :py:attr:`provides`.\n\n :type: type\n ", /*tp_doc*/ - __pyx_tp_traverse_19dependency_injector_9providers_Singleton, /*tp_traverse*/ - __pyx_tp_clear_19dependency_injector_9providers_Singleton, /*tp_clear*/ + __pyx_tp_traverse_19dependency_injector_9providers_BaseSingleton, /*tp_traverse*/ + __pyx_tp_clear_19dependency_injector_9providers_BaseSingleton, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ @@ -87227,7 +98267,7 @@ static PyTypeObject __pyx_type_19dependency_injector_9providers_DelegatedSinglet "dependency_injector.providers.DelegatedSingleton", /*tp_name*/ sizeof(struct __pyx_obj_19dependency_injector_9providers_DelegatedSingleton), /*tp_basicsize*/ 0, /*tp_itemsize*/ - __pyx_tp_dealloc_19dependency_injector_9providers_Singleton, /*tp_dealloc*/ + __pyx_tp_dealloc_19dependency_injector_9providers_BaseSingleton, /*tp_dealloc*/ #if PY_VERSION_HEX < 0x030800b4 0, /*tp_print*/ #endif @@ -87266,8 +98306,8 @@ static PyTypeObject __pyx_type_19dependency_injector_9providers_DelegatedSinglet 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/ "Delegated singleton is injected \"as is\".\n\n .. py:attribute:: provided_type\n\n If provided type is defined, provider checks that providing class is\n its subclass.\n\n :type: type | None\n\n .. py:attribute:: cls\n :noindex:\n\n Class that provides object.\n Alias for :py:attr:`provides`.\n\n :type: type\n ", /*tp_doc*/ - __pyx_tp_traverse_19dependency_injector_9providers_Singleton, /*tp_traverse*/ - __pyx_tp_clear_19dependency_injector_9providers_Singleton, /*tp_clear*/ + __pyx_tp_traverse_19dependency_injector_9providers_BaseSingleton, /*tp_traverse*/ + __pyx_tp_clear_19dependency_injector_9providers_BaseSingleton, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ @@ -87314,7 +98354,6 @@ static PyObject *__pyx_tp_new_19dependency_injector_9providers_ThreadSafeSinglet if (unlikely(!o)) return 0; p = ((struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton *)o); p->__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_19dependency_injector_9providers_Provider*)__pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton; - p->__pyx___storage = Py_None; Py_INCREF(Py_None); p->__pyx___storage_lock = Py_None; Py_INCREF(Py_None); return o; } @@ -87327,7 +98366,6 @@ static void __pyx_tp_dealloc_19dependency_injector_9providers_ThreadSafeSingleto } #endif PyObject_GC_UnTrack(o); - Py_CLEAR(p->__pyx___storage); Py_CLEAR(p->__pyx___storage_lock); PyObject_GC_Track(o); __pyx_tp_dealloc_19dependency_injector_9providers_BaseSingleton(o); @@ -87337,9 +98375,6 @@ static int __pyx_tp_traverse_19dependency_injector_9providers_ThreadSafeSingleto int e; struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton *p = (struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton *)o; e = __pyx_tp_traverse_19dependency_injector_9providers_BaseSingleton(o, v, a); if (e) return e; - if (p->__pyx___storage) { - e = (*v)(p->__pyx___storage, a); if (e) return e; - } if (p->__pyx___storage_lock) { e = (*v)(p->__pyx___storage_lock, a); if (e) return e; } @@ -87350,9 +98385,6 @@ static int __pyx_tp_clear_19dependency_injector_9providers_ThreadSafeSingleton(P PyObject* tmp; struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton *p = (struct __pyx_obj_19dependency_injector_9providers_ThreadSafeSingleton *)o; __pyx_tp_clear_19dependency_injector_9providers_BaseSingleton(o); - tmp = ((PyObject*)p->__pyx___storage); - p->__pyx___storage = Py_None; Py_INCREF(Py_None); - Py_XDECREF(tmp); tmp = ((PyObject*)p->__pyx___storage_lock); p->__pyx___storage_lock = Py_None; Py_INCREF(Py_None); Py_XDECREF(tmp); @@ -87556,48 +98588,15 @@ static PyObject *__pyx_tp_new_19dependency_injector_9providers_ThreadLocalSingle if (unlikely(!o)) return 0; p = ((struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *)o); p->__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_19dependency_injector_9providers_Provider*)__pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton; - p->__pyx___storage = Py_None; Py_INCREF(Py_None); return o; } -static void __pyx_tp_dealloc_19dependency_injector_9providers_ThreadLocalSingleton(PyObject *o) { - struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *p = (struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *)o; - #if CYTHON_USE_TP_FINALIZE - if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) { - if (PyObject_CallFinalizerFromDealloc(o)) return; - } - #endif - PyObject_GC_UnTrack(o); - Py_CLEAR(p->__pyx___storage); - PyObject_GC_Track(o); - __pyx_tp_dealloc_19dependency_injector_9providers_BaseSingleton(o); -} - -static int __pyx_tp_traverse_19dependency_injector_9providers_ThreadLocalSingleton(PyObject *o, visitproc v, void *a) { - int e; - struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *p = (struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *)o; - e = __pyx_tp_traverse_19dependency_injector_9providers_BaseSingleton(o, v, a); if (e) return e; - if (p->__pyx___storage) { - e = (*v)(p->__pyx___storage, a); if (e) return e; - } - return 0; -} - -static int __pyx_tp_clear_19dependency_injector_9providers_ThreadLocalSingleton(PyObject *o) { - PyObject* tmp; - struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *p = (struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton *)o; - __pyx_tp_clear_19dependency_injector_9providers_BaseSingleton(o); - tmp = ((PyObject*)p->__pyx___storage); - p->__pyx___storage = Py_None; Py_INCREF(Py_None); - Py_XDECREF(tmp); - return 0; -} - static PyMethodDef __pyx_methods_19dependency_injector_9providers_ThreadLocalSingleton[] = { {"reset", (PyCFunction)__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_3reset, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_20ThreadLocalSingleton_2reset}, {"_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_5_provide, METH_VARARGS|METH_KEYWORDS, __pyx_doc_19dependency_injector_9providers_20ThreadLocalSingleton_4_provide}, - {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_7__reduce_cython__, METH_NOARGS, 0}, - {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_9__setstate_cython__, METH_O, 0}, + {"_async_init_instance", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_7_async_init_instance, METH_VARARGS|METH_KEYWORDS, 0}, + {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_9__reduce_cython__, METH_NOARGS, 0}, + {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_20ThreadLocalSingleton_11__setstate_cython__, METH_O, 0}, {0, 0, 0, 0} }; @@ -87606,7 +98605,7 @@ static PyTypeObject __pyx_type_19dependency_injector_9providers_ThreadLocalSingl "dependency_injector.providers.ThreadLocalSingleton", /*tp_name*/ sizeof(struct __pyx_obj_19dependency_injector_9providers_ThreadLocalSingleton), /*tp_basicsize*/ 0, /*tp_itemsize*/ - __pyx_tp_dealloc_19dependency_injector_9providers_ThreadLocalSingleton, /*tp_dealloc*/ + __pyx_tp_dealloc_19dependency_injector_9providers_BaseSingleton, /*tp_dealloc*/ #if PY_VERSION_HEX < 0x030800b4 0, /*tp_print*/ #endif @@ -87645,8 +98644,8 @@ static PyTypeObject __pyx_type_19dependency_injector_9providers_ThreadLocalSingl 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/ "Thread-local singleton provides single objects in scope of thread.\n\n .. py:attribute:: provided_type\n\n If provided type is defined, provider checks that providing class is\n its subclass.\n\n :type: type | None\n\n .. py:attribute:: cls\n :noindex:\n\n Class that provides object.\n Alias for :py:attr:`provides`.\n\n :type: type\n ", /*tp_doc*/ - __pyx_tp_traverse_19dependency_injector_9providers_ThreadLocalSingleton, /*tp_traverse*/ - __pyx_tp_clear_19dependency_injector_9providers_ThreadLocalSingleton, /*tp_clear*/ + __pyx_tp_traverse_19dependency_injector_9providers_BaseSingleton, /*tp_traverse*/ + __pyx_tp_clear_19dependency_injector_9providers_BaseSingleton, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ @@ -87703,7 +98702,7 @@ static PyTypeObject __pyx_type_19dependency_injector_9providers_DelegatedThreadL "dependency_injector.providers.DelegatedThreadLocalSingleton", /*tp_name*/ sizeof(struct __pyx_obj_19dependency_injector_9providers_DelegatedThreadLocalSingleton), /*tp_basicsize*/ 0, /*tp_itemsize*/ - __pyx_tp_dealloc_19dependency_injector_9providers_ThreadLocalSingleton, /*tp_dealloc*/ + __pyx_tp_dealloc_19dependency_injector_9providers_BaseSingleton, /*tp_dealloc*/ #if PY_VERSION_HEX < 0x030800b4 0, /*tp_print*/ #endif @@ -87742,8 +98741,8 @@ static PyTypeObject __pyx_type_19dependency_injector_9providers_DelegatedThreadL 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/ "Delegated thread-local singleton is injected \"as is\".\n\n .. py:attribute:: provided_type\n\n If provided type is defined, provider checks that providing class is\n its subclass.\n\n :type: type | None\n\n .. py:attribute:: cls\n :noindex:\n\n Class that provides object.\n Alias for :py:attr:`provides`.\n\n :type: type\n ", /*tp_doc*/ - __pyx_tp_traverse_19dependency_injector_9providers_ThreadLocalSingleton, /*tp_traverse*/ - __pyx_tp_clear_19dependency_injector_9providers_ThreadLocalSingleton, /*tp_clear*/ + __pyx_tp_traverse_19dependency_injector_9providers_BaseSingleton, /*tp_traverse*/ + __pyx_tp_clear_19dependency_injector_9providers_BaseSingleton, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ @@ -88360,9 +99359,14 @@ static PyMethodDef __pyx_methods_19dependency_injector_9providers_Resource[] = { {"init", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Resource_19init, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Resource_18init}, {"shutdown", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Resource_21shutdown, METH_NOARGS, __pyx_doc_19dependency_injector_9providers_8Resource_20shutdown}, {"_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Resource_23_provide, METH_VARARGS|METH_KEYWORDS, 0}, - {"_is_resource_subclass", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Resource_25_is_resource_subclass, METH_VARARGS|METH_KEYWORDS, 0}, - {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Resource_27__reduce_cython__, METH_NOARGS, 0}, - {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Resource_29__setstate_cython__, METH_O, 0}, + {"_create_init_future", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Resource_25_create_init_future, METH_VARARGS|METH_KEYWORDS, 0}, + {"_async_init_callback", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Resource_27_async_init_callback, METH_VARARGS|METH_KEYWORDS, 0}, + {"_create_shutdown_future", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Resource_29_create_shutdown_future, METH_O, 0}, + {"_async_shutdown_callback", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Resource_31_async_shutdown_callback, METH_VARARGS|METH_KEYWORDS, 0}, + {"_is_resource_subclass", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Resource_33_is_resource_subclass, METH_VARARGS|METH_KEYWORDS, 0}, + {"_is_async_resource_subclass", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_8Resource_35_is_async_resource_subclass, METH_VARARGS|METH_KEYWORDS, 0}, + {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Resource_37__reduce_cython__, METH_NOARGS, 0}, + {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_8Resource_39__setstate_cython__, METH_O, 0}, {0, 0, 0, 0} }; @@ -89031,8 +100035,9 @@ static PyMethodDef __pyx_methods_19dependency_injector_9providers_AttributeGette {"__getattr__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_15AttributeGetter_7__getattr__, METH_O|METH_COEXIST, 0}, {"call", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_15AttributeGetter_11call, METH_VARARGS|METH_KEYWORDS, 0}, {"_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_15AttributeGetter_13_provide, METH_VARARGS|METH_KEYWORDS, 0}, - {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_15AttributeGetter_15__reduce_cython__, METH_NOARGS, 0}, - {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_15AttributeGetter_17__setstate_cython__, METH_O, 0}, + {"_async_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_15AttributeGetter_15_async_provide, METH_VARARGS|METH_KEYWORDS, 0}, + {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_15AttributeGetter_17__reduce_cython__, METH_NOARGS, 0}, + {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_15AttributeGetter_19__setstate_cython__, METH_O, 0}, {0, 0, 0, 0} }; @@ -89219,8 +100224,9 @@ static PyMethodDef __pyx_methods_19dependency_injector_9providers_ItemGetter[] = {"__getattr__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10ItemGetter_7__getattr__, METH_O|METH_COEXIST, 0}, {"call", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_10ItemGetter_11call, METH_VARARGS|METH_KEYWORDS, 0}, {"_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_10ItemGetter_13_provide, METH_VARARGS|METH_KEYWORDS, 0}, - {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10ItemGetter_15__reduce_cython__, METH_NOARGS, 0}, - {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10ItemGetter_17__setstate_cython__, METH_O, 0}, + {"_async_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_10ItemGetter_15_async_provide, METH_VARARGS|METH_KEYWORDS, 0}, + {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10ItemGetter_17__reduce_cython__, METH_NOARGS, 0}, + {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_10ItemGetter_19__setstate_cython__, METH_O, 0}, {0, 0, 0, 0} }; @@ -89419,8 +100425,9 @@ static PyMethodDef __pyx_methods_19dependency_injector_9providers_MethodCaller[] {"__getattr__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_12MethodCaller_7__getattr__, METH_O|METH_COEXIST, 0}, {"call", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_12MethodCaller_11call, METH_VARARGS|METH_KEYWORDS, 0}, {"_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_12MethodCaller_13_provide, METH_VARARGS|METH_KEYWORDS, 0}, - {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_12MethodCaller_15__reduce_cython__, METH_NOARGS, 0}, - {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_12MethodCaller_17__setstate_cython__, METH_O, 0}, + {"_async_provide", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_19dependency_injector_9providers_12MethodCaller_15_async_provide, METH_VARARGS|METH_KEYWORDS, 0}, + {"__reduce_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_12MethodCaller_17__reduce_cython__, METH_NOARGS, 0}, + {"__setstate_cython__", (PyCFunction)__pyx_pw_19dependency_injector_9providers_12MethodCaller_19__setstate_cython__, METH_O, 0}, {0, 0, 0, 0} }; @@ -90313,6 +101320,99 @@ static PyTypeObject __pyx_type_19dependency_injector_9providers___pyx_scope_stru #endif }; +static struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *__pyx_freelist___pyx_scope_struct____Pyx_CFunc_void____object___to_py[8]; +static int __pyx_freecount___pyx_scope_struct____Pyx_CFunc_void____object___to_py = 0; + +static PyObject *__pyx_tp_new___pyx_scope_struct____Pyx_CFunc_void____object___to_py(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) { + PyObject *o; + if (CYTHON_COMPILING_IN_CPYTHON && likely((__pyx_freecount___pyx_scope_struct____Pyx_CFunc_void____object___to_py > 0) & (t->tp_basicsize == sizeof(struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py)))) { + o = (PyObject*)__pyx_freelist___pyx_scope_struct____Pyx_CFunc_void____object___to_py[--__pyx_freecount___pyx_scope_struct____Pyx_CFunc_void____object___to_py]; + memset(o, 0, sizeof(struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py)); + (void) PyObject_INIT(o, t); + } else { + o = (*t->tp_alloc)(t, 0); + if (unlikely(!o)) return 0; + } + return o; +} + +static void __pyx_tp_dealloc___pyx_scope_struct____Pyx_CFunc_void____object___to_py(PyObject *o) { + if (CYTHON_COMPILING_IN_CPYTHON && ((__pyx_freecount___pyx_scope_struct____Pyx_CFunc_void____object___to_py < 8) & (Py_TYPE(o)->tp_basicsize == sizeof(struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py)))) { + __pyx_freelist___pyx_scope_struct____Pyx_CFunc_void____object___to_py[__pyx_freecount___pyx_scope_struct____Pyx_CFunc_void____object___to_py++] = ((struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py *)o); + } else { + (*Py_TYPE(o)->tp_free)(o); + } +} + +static PyTypeObject __pyx_scope_struct____Pyx_CFunc_void____object___to_py = { + PyVarObject_HEAD_INIT(0, 0) + "dependency_injector.providers.__pyx_scope_struct____Pyx_CFunc_void____object___to_py", /*tp_name*/ + sizeof(struct __pyx_obj___pyx_scope_struct____Pyx_CFunc_void____object___to_py), /*tp_basicsize*/ + 0, /*tp_itemsize*/ + __pyx_tp_dealloc___pyx_scope_struct____Pyx_CFunc_void____object___to_py, /*tp_dealloc*/ + #if PY_VERSION_HEX < 0x030800b4 + 0, /*tp_print*/ + #endif + #if PY_VERSION_HEX >= 0x030800b4 + 0, /*tp_vectorcall_offset*/ + #endif + 0, /*tp_getattr*/ + 0, /*tp_setattr*/ + #if PY_MAJOR_VERSION < 3 + 0, /*tp_compare*/ + #endif + #if PY_MAJOR_VERSION >= 3 + 0, /*tp_as_async*/ + #endif + 0, /*tp_repr*/ + 0, /*tp_as_number*/ + 0, /*tp_as_sequence*/ + 0, /*tp_as_mapping*/ + 0, /*tp_hash*/ + 0, /*tp_call*/ + 0, /*tp_str*/ + 0, /*tp_getattro*/ + 0, /*tp_setattro*/ + 0, /*tp_as_buffer*/ + Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER, /*tp_flags*/ + 0, /*tp_doc*/ + 0, /*tp_traverse*/ + 0, /*tp_clear*/ + 0, /*tp_richcompare*/ + 0, /*tp_weaklistoffset*/ + 0, /*tp_iter*/ + 0, /*tp_iternext*/ + 0, /*tp_methods*/ + 0, /*tp_members*/ + 0, /*tp_getset*/ + 0, /*tp_base*/ + 0, /*tp_dict*/ + 0, /*tp_descr_get*/ + 0, /*tp_descr_set*/ + 0, /*tp_dictoffset*/ + 0, /*tp_init*/ + 0, /*tp_alloc*/ + __pyx_tp_new___pyx_scope_struct____Pyx_CFunc_void____object___to_py, /*tp_new*/ + 0, /*tp_free*/ + 0, /*tp_is_gc*/ + 0, /*tp_bases*/ + 0, /*tp_mro*/ + 0, /*tp_cache*/ + 0, /*tp_subclasses*/ + 0, /*tp_weaklist*/ + 0, /*tp_del*/ + 0, /*tp_version_tag*/ + #if PY_VERSION_HEX >= 0x030400a1 + 0, /*tp_finalize*/ + #endif + #if PY_VERSION_HEX >= 0x030800b1 + 0, /*tp_vectorcall*/ + #endif + #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000 + 0, /*tp_print*/ + #endif +}; + static PyMethodDef __pyx_methods[] = { {"parse_positional_injections", (PyCFunction)__pyx_pw_19dependency_injector_9providers_7parse_positional_injections, METH_O, __pyx_doc_19dependency_injector_9providers_6parse_positional_injections}, {"parse_named_injections", (PyCFunction)__pyx_pw_19dependency_injector_9providers_9parse_named_injections, METH_O, __pyx_doc_19dependency_injector_9providers_8parse_named_injections}, @@ -90372,7 +101472,7 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_kp_s_0_can_provide_only_1_instances, __pyx_k_0_can_provide_only_1_instances, sizeof(__pyx_k_0_can_provide_only_1_instances), 0, 0, 1, 0}, {&__pyx_kp_s_0_can_wrap_only_1_providers, __pyx_k_0_can_wrap_only_1_providers, sizeof(__pyx_k_0_can_wrap_only_1_providers), 0, 0, 1, 0}, {&__pyx_kp_s_0_does_not_contain_factory_with, __pyx_k_0_does_not_contain_factory_with, sizeof(__pyx_k_0_does_not_contain_factory_with), 0, 0, 1, 0}, - {&__pyx_kp_s_0_is_not_an, __pyx_k_0_is_not_an, sizeof(__pyx_k_0_is_not_an), 0, 0, 1, 0}, + {&__pyx_kp_s_0_is_not_an_instance_of_1, __pyx_k_0_is_not_an_instance_of_1, sizeof(__pyx_k_0_is_not_an_instance_of_1), 0, 0, 1, 0}, {&__pyx_kp_s_0_must_be_overridden_before_cal, __pyx_k_0_must_be_overridden_before_cal, sizeof(__pyx_k_0_must_be_overridden_before_cal), 0, 0, 1, 0}, {&__pyx_kp_s_0_must_be_overridden_only_by_1, __pyx_k_0_must_be_overridden_only_by_1, sizeof(__pyx_k_0_must_be_overridden_only_by_1), 0, 0, 1, 0}, {&__pyx_kp_s_0_providers_could_not_be_overri, __pyx_k_0_providers_could_not_be_overri, sizeof(__pyx_k_0_providers_could_not_be_overri), 0, 0, 1, 0}, @@ -90382,6 +101482,7 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_AbstractSingleton, __pyx_k_AbstractSingleton, sizeof(__pyx_k_AbstractSingleton), 0, 0, 1, 1}, {&__pyx_kp_s_Abstract_provider_forward_provid, __pyx_k_Abstract_provider_forward_provid, sizeof(__pyx_k_Abstract_provider_forward_provid), 0, 0, 1, 0}, {&__pyx_kp_s_Argument_instance_of_has_incorre, __pyx_k_Argument_instance_of_has_incorre, sizeof(__pyx_k_Argument_instance_of_has_incorre), 0, 0, 1, 0}, + {&__pyx_n_s_AsyncResource, __pyx_k_AsyncResource, sizeof(__pyx_k_AsyncResource), 0, 0, 1, 1}, {&__pyx_n_s_AttributeError, __pyx_k_AttributeError, sizeof(__pyx_k_AttributeError), 0, 0, 1, 1}, {&__pyx_n_s_AttributeGetter, __pyx_k_AttributeGetter, sizeof(__pyx_k_AttributeGetter), 0, 0, 1, 1}, {&__pyx_n_s_BaseSingleton, __pyx_k_BaseSingleton, sizeof(__pyx_k_BaseSingleton), 0, 0, 1, 1}, @@ -90420,39 +101521,41 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_Factory, __pyx_k_Factory, sizeof(__pyx_k_Factory), 0, 0, 1, 1}, {&__pyx_n_s_FactoryAggregate, __pyx_k_FactoryAggregate, sizeof(__pyx_k_FactoryAggregate), 0, 0, 1, 1}, {&__pyx_n_s_FactoryDelegate, __pyx_k_FactoryDelegate, sizeof(__pyx_k_FactoryDelegate), 0, 0, 1, 1}, + {&__pyx_kp_s_Factory_missing_1_required_posit, __pyx_k_Factory_missing_1_required_posit, sizeof(__pyx_k_Factory_missing_1_required_posit), 0, 0, 1, 0}, {&__pyx_n_u_False, __pyx_k_False, sizeof(__pyx_k_False), 0, 1, 0, 1}, + {&__pyx_n_s_Future, __pyx_k_Future, sizeof(__pyx_k_Future), 0, 0, 1, 1}, {&__pyx_n_s_IOError, __pyx_k_IOError, sizeof(__pyx_k_IOError), 0, 0, 1, 1}, {&__pyx_n_s_IS_DELEGATED, __pyx_k_IS_DELEGATED, sizeof(__pyx_k_IS_DELEGATED), 0, 0, 1, 1}, {&__pyx_n_s_IS_PROVIDER, __pyx_k_IS_PROVIDER, sizeof(__pyx_k_IS_PROVIDER), 0, 0, 1, 1}, {&__pyx_n_s_ImportError, __pyx_k_ImportError, sizeof(__pyx_k_ImportError), 0, 0, 1, 1}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x03, __pyx_k_Incompatible_checksums_s_vs_0x03, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x03), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x04, __pyx_k_Incompatible_checksums_s_vs_0x04, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x04), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x0c, __pyx_k_Incompatible_checksums_s_vs_0x0c, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x0c), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x0d, __pyx_k_Incompatible_checksums_s_vs_0x0d, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x0d), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x0f, __pyx_k_Incompatible_checksums_s_vs_0x0f, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x0f), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x1b, __pyx_k_Incompatible_checksums_s_vs_0x1b, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x1b), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x1c, __pyx_k_Incompatible_checksums_s_vs_0x1c, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x1c), 0, 0, 1, 0}, {&__pyx_kp_s_Incompatible_checksums_s_vs_0x20, __pyx_k_Incompatible_checksums_s_vs_0x20, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x20), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x20_2, __pyx_k_Incompatible_checksums_s_vs_0x20_2, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x20_2), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x2a, __pyx_k_Incompatible_checksums_s_vs_0x2a, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x2a), 0, 0, 1, 0}, {&__pyx_kp_s_Incompatible_checksums_s_vs_0x2e, __pyx_k_Incompatible_checksums_s_vs_0x2e, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x2e), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x3f, __pyx_k_Incompatible_checksums_s_vs_0x3f, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x3f), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x57, __pyx_k_Incompatible_checksums_s_vs_0x57, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x57), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x58, __pyx_k_Incompatible_checksums_s_vs_0x58, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x58), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x63, __pyx_k_Incompatible_checksums_s_vs_0x63, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x63), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x32, __pyx_k_Incompatible_checksums_s_vs_0x32, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x32), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x34, __pyx_k_Incompatible_checksums_s_vs_0x34, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x34), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x3e, __pyx_k_Incompatible_checksums_s_vs_0x3e, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x3e), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x42, __pyx_k_Incompatible_checksums_s_vs_0x42, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x42), 0, 0, 1, 0}, {&__pyx_kp_s_Incompatible_checksums_s_vs_0x64, __pyx_k_Incompatible_checksums_s_vs_0x64, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x64), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x76, __pyx_k_Incompatible_checksums_s_vs_0x76, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x76), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0x97, __pyx_k_Incompatible_checksums_s_vs_0x97, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x97), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0xa5, __pyx_k_Incompatible_checksums_s_vs_0xa5, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xa5), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0xa6, __pyx_k_Incompatible_checksums_s_vs_0xa6, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xa6), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0xa7, __pyx_k_Incompatible_checksums_s_vs_0xa7, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xa7), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0xa7_2, __pyx_k_Incompatible_checksums_s_vs_0xa7_2, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xa7_2), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0xb2, __pyx_k_Incompatible_checksums_s_vs_0xb2, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xb2), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0xd8, __pyx_k_Incompatible_checksums_s_vs_0xd8, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xd8), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0xe0, __pyx_k_Incompatible_checksums_s_vs_0xe0, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xe0), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0xe8, __pyx_k_Incompatible_checksums_s_vs_0xe8, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xe8), 0, 0, 1, 0}, - {&__pyx_kp_s_Incompatible_checksums_s_vs_0xf1, __pyx_k_Incompatible_checksums_s_vs_0xf1, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xf1), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x66, __pyx_k_Incompatible_checksums_s_vs_0x66, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x66), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x6a, __pyx_k_Incompatible_checksums_s_vs_0x6a, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x6a), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x73, __pyx_k_Incompatible_checksums_s_vs_0x73, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x73), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x75, __pyx_k_Incompatible_checksums_s_vs_0x75, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x75), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0x7e, __pyx_k_Incompatible_checksums_s_vs_0x7e, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x7e), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0xa0, __pyx_k_Incompatible_checksums_s_vs_0xa0, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xa0), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0xa2, __pyx_k_Incompatible_checksums_s_vs_0xa2, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xa2), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0xce, __pyx_k_Incompatible_checksums_s_vs_0xce, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xce), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0xd5, __pyx_k_Incompatible_checksums_s_vs_0xd5, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xd5), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0xe5, __pyx_k_Incompatible_checksums_s_vs_0xe5, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xe5), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0xfd, __pyx_k_Incompatible_checksums_s_vs_0xfd, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xfd), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0xfe, __pyx_k_Incompatible_checksums_s_vs_0xfe, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xfe), 0, 0, 1, 0}, + {&__pyx_kp_s_Incompatible_checksums_s_vs_0xff, __pyx_k_Incompatible_checksums_s_vs_0xff, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xff), 0, 0, 1, 0}, {&__pyx_n_s_IndexError, __pyx_k_IndexError, sizeof(__pyx_k_IndexError), 0, 0, 1, 1}, {&__pyx_n_s_Injection, __pyx_k_Injection, sizeof(__pyx_k_Injection), 0, 0, 1, 1}, {&__pyx_kp_s_Interpolation_which_expands_envi, __pyx_k_Interpolation_which_expands_envi, sizeof(__pyx_k_Interpolation_which_expands_envi), 0, 0, 1, 0}, {&__pyx_n_s_ItemGetter, __pyx_k_ItemGetter, sizeof(__pyx_k_ItemGetter), 0, 0, 1, 1}, + {&__pyx_n_s_KeyError, __pyx_k_KeyError, sizeof(__pyx_k_KeyError), 0, 0, 1, 1}, {&__pyx_n_s_List, __pyx_k_List, sizeof(__pyx_k_List), 0, 0, 1, 1}, {&__pyx_n_s_Loader, __pyx_k_Loader, sizeof(__pyx_k_Loader), 0, 0, 1, 1}, {&__pyx_n_s_MethodCaller, __pyx_k_MethodCaller, sizeof(__pyx_k_MethodCaller), 0, 0, 1, 1}, @@ -90473,6 +101576,7 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_kp_s_Provider_0_expected_to_get_calla, __pyx_k_Provider_0_expected_to_get_calla, sizeof(__pyx_k_Provider_0_expected_to_get_calla), 0, 0, 1, 0}, {&__pyx_kp_s_Provider_0_expected_to_get_corou, __pyx_k_Provider_0_expected_to_get_corou, sizeof(__pyx_k_Provider_0_expected_to_get_corou), 0, 0, 1, 0}, {&__pyx_kp_s_Provider_0_is_not_overridden, __pyx_k_Provider_0_is_not_overridden, sizeof(__pyx_k_Provider_0_is_not_overridden), 0, 0, 1, 0}, + {&__pyx_n_s_Pyx_CFunc_void____object___to, __pyx_k_Pyx_CFunc_void____object___to, sizeof(__pyx_k_Pyx_CFunc_void____object___to), 0, 0, 1, 1}, {&__pyx_n_s_RLock, __pyx_k_RLock, sizeof(__pyx_k_RLock), 0, 0, 1, 1}, {&__pyx_n_s_Resource, __pyx_k_Resource, sizeof(__pyx_k_Resource), 0, 0, 1, 1}, {&__pyx_n_s_Selector, __pyx_k_Selector, sizeof(__pyx_k_Selector), 0, 0, 1, 1}, @@ -90490,23 +101594,30 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_UNDEFINED, __pyx_k_UNDEFINED, sizeof(__pyx_k_UNDEFINED), 0, 0, 1, 1}, {&__pyx_kp_s_Unable_to_load_yaml_configuratio, __pyx_k_Unable_to_load_yaml_configuratio, sizeof(__pyx_k_Unable_to_load_yaml_configuratio), 0, 0, 1, 0}, {&__pyx_kp_s_Unknown_type_of_resource_initial, __pyx_k_Unknown_type_of_resource_initial, sizeof(__pyx_k_Unknown_type_of_resource_initial), 0, 0, 1, 0}, - {&__pyx_n_s__11, __pyx_k__11, sizeof(__pyx_k__11), 0, 0, 1, 1}, - {&__pyx_kp_s__12, __pyx_k__12, sizeof(__pyx_k__12), 0, 0, 1, 0}, - {&__pyx_kp_u__13, __pyx_k__13, sizeof(__pyx_k__13), 0, 1, 0, 0}, + {&__pyx_kp_u__10, __pyx_k__10, sizeof(__pyx_k__10), 0, 1, 0, 0}, + {&__pyx_n_s__12, __pyx_k__12, sizeof(__pyx_k__12), 0, 0, 1, 1}, + {&__pyx_kp_s__13, __pyx_k__13, sizeof(__pyx_k__13), 0, 0, 1, 0}, {&__pyx_kp_u__14, __pyx_k__14, sizeof(__pyx_k__14), 0, 1, 0, 0}, - {&__pyx_kp_s__16, __pyx_k__16, sizeof(__pyx_k__16), 0, 0, 1, 0}, + {&__pyx_kp_u__15, __pyx_k__15, sizeof(__pyx_k__15), 0, 1, 0, 0}, + {&__pyx_kp_s__19, __pyx_k__19, sizeof(__pyx_k__19), 0, 0, 1, 0}, {&__pyx_n_s__4, __pyx_k__4, sizeof(__pyx_k__4), 0, 0, 1, 1}, {&__pyx_kp_s__5, __pyx_k__5, sizeof(__pyx_k__5), 0, 0, 1, 0}, - {&__pyx_kp_u__8, __pyx_k__8, sizeof(__pyx_k__8), 0, 1, 0, 0}, {&__pyx_kp_u__9, __pyx_k__9, sizeof(__pyx_k__9), 0, 1, 0, 0}, {&__pyx_n_s_add_args, __pyx_k_add_args, sizeof(__pyx_k_add_args), 0, 0, 1, 1}, {&__pyx_n_s_add_attributes, __pyx_k_add_attributes, sizeof(__pyx_k_add_attributes), 0, 0, 1, 1}, {&__pyx_n_s_add_constructor, __pyx_k_add_constructor, sizeof(__pyx_k_add_constructor), 0, 0, 1, 1}, + {&__pyx_n_s_add_done_callback, __pyx_k_add_done_callback, sizeof(__pyx_k_add_done_callback), 0, 0, 1, 1}, {&__pyx_n_s_add_implicit_resolver, __pyx_k_add_implicit_resolver, sizeof(__pyx_k_add_implicit_resolver), 0, 0, 1, 1}, {&__pyx_n_s_add_kwargs, __pyx_k_add_kwargs, sizeof(__pyx_k_add_kwargs), 0, 0, 1, 1}, {&__pyx_n_s_add_sys_streams, __pyx_k_add_sys_streams, sizeof(__pyx_k_add_sys_streams), 0, 0, 1, 1}, {&__pyx_n_s_address, __pyx_k_address, sizeof(__pyx_k_address), 0, 0, 1, 1}, + {&__pyx_n_s_anext, __pyx_k_anext, sizeof(__pyx_k_anext), 0, 0, 1, 1}, {&__pyx_n_s_args, __pyx_k_args, sizeof(__pyx_k_args), 0, 0, 1, 1}, + {&__pyx_n_s_asend, __pyx_k_asend, sizeof(__pyx_k_asend), 0, 0, 1, 1}, + {&__pyx_n_s_async_init_callback, __pyx_k_async_init_callback, sizeof(__pyx_k_async_init_callback), 0, 0, 1, 1}, + {&__pyx_n_s_async_init_instance, __pyx_k_async_init_instance, sizeof(__pyx_k_async_init_instance), 0, 0, 1, 1}, + {&__pyx_n_s_async_provide, __pyx_k_async_provide, sizeof(__pyx_k_async_provide), 0, 0, 1, 1}, + {&__pyx_n_s_async_shutdown_callback, __pyx_k_async_shutdown_callback, sizeof(__pyx_k_async_shutdown_callback), 0, 0, 1, 1}, {&__pyx_n_s_asyncio, __pyx_k_asyncio, sizeof(__pyx_k_asyncio), 0, 0, 1, 1}, {&__pyx_n_s_asyncio_coroutines, __pyx_k_asyncio_coroutines, sizeof(__pyx_k_asyncio_coroutines), 0, 0, 1, 1}, {&__pyx_n_s_asyncio_tasks, __pyx_k_asyncio_tasks, sizeof(__pyx_k_asyncio_tasks), 0, 0, 1, 1}, @@ -90517,7 +101628,10 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_call, __pyx_k_call, sizeof(__pyx_k_call), 0, 0, 1, 1}, {&__pyx_n_s_callable, __pyx_k_callable, sizeof(__pyx_k_callable), 0, 0, 1, 1}, {&__pyx_n_s_callback, __pyx_k_callback, sizeof(__pyx_k_callback), 0, 0, 1, 1}, + {&__pyx_n_s_cancel, __pyx_k_cancel, sizeof(__pyx_k_cancel), 0, 0, 1, 1}, {&__pyx_n_s_category, __pyx_k_category, sizeof(__pyx_k_category), 0, 0, 1, 1}, + {&__pyx_n_s_cfunc_to_py, __pyx_k_cfunc_to_py, sizeof(__pyx_k_cfunc_to_py), 0, 0, 1, 1}, + {&__pyx_n_s_check_instance_type, __pyx_k_check_instance_type, sizeof(__pyx_k_check_instance_type), 0, 0, 1, 1}, {&__pyx_n_s_class, __pyx_k_class, sizeof(__pyx_k_class), 0, 0, 1, 1}, {&__pyx_n_s_class_getitem, __pyx_k_class_getitem, sizeof(__pyx_k_class_getitem), 0, 0, 1, 1}, {&__pyx_n_s_clear_args, __pyx_k_clear_args, sizeof(__pyx_k_clear_args), 0, 0, 1, 1}, @@ -90539,6 +101653,8 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_copy_overridings, __pyx_k_copy_overridings, sizeof(__pyx_k_copy_overridings), 0, 0, 1, 1}, {&__pyx_n_s_coroutine, __pyx_k_coroutine, sizeof(__pyx_k_coroutine), 0, 0, 1, 1}, {&__pyx_n_s_coroutines, __pyx_k_coroutines, sizeof(__pyx_k_coroutines), 0, 0, 1, 1}, + {&__pyx_n_s_create_init_future, __pyx_k_create_init_future, sizeof(__pyx_k_create_init_future), 0, 0, 1, 1}, + {&__pyx_n_s_create_shutdown_future, __pyx_k_create_shutdown_future, sizeof(__pyx_k_create_shutdown_future), 0, 0, 1, 1}, {&__pyx_n_s_deepcopy, __pyx_k_deepcopy, sizeof(__pyx_k_deepcopy), 0, 0, 1, 1}, {&__pyx_n_s_deepcopy_dispatch, __pyx_k_deepcopy_dispatch, sizeof(__pyx_k_deepcopy_dispatch), 0, 0, 1, 1}, {&__pyx_n_s_default, __pyx_k_default, sizeof(__pyx_k_default), 0, 0, 1, 1}, @@ -90548,8 +101664,11 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_dict1, __pyx_k_dict1, sizeof(__pyx_k_dict1), 0, 0, 1, 1}, {&__pyx_n_s_dict2, __pyx_k_dict2, sizeof(__pyx_k_dict2), 0, 0, 1, 1}, {&__pyx_n_s_dict_2, __pyx_k_dict_2, sizeof(__pyx_k_dict_2), 0, 0, 1, 1}, + {&__pyx_n_s_disable_async_mode, __pyx_k_disable_async_mode, sizeof(__pyx_k_disable_async_mode), 0, 0, 1, 1}, {&__pyx_n_s_doc, __pyx_k_doc, sizeof(__pyx_k_doc), 0, 0, 1, 1}, + {&__pyx_n_s_enable_async_mode, __pyx_k_enable_async_mode, sizeof(__pyx_k_enable_async_mode), 0, 0, 1, 1}, {&__pyx_n_s_endswith, __pyx_k_endswith, sizeof(__pyx_k_endswith), 0, 0, 1, 1}, + {&__pyx_n_s_ensure_future, __pyx_k_ensure_future, sizeof(__pyx_k_ensure_future), 0, 0, 1, 1}, {&__pyx_n_s_enter, __pyx_k_enter, sizeof(__pyx_k_enter), 0, 0, 1, 1}, {&__pyx_n_s_errors, __pyx_k_errors, sizeof(__pyx_k_errors), 0, 0, 1, 1}, {&__pyx_n_s_exit, __pyx_k_exit, sizeof(__pyx_k_exit), 0, 0, 1, 1}, @@ -90559,6 +101678,10 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_factory_name, __pyx_k_factory_name, sizeof(__pyx_k_factory_name), 0, 0, 1, 1}, {&__pyx_n_s_filepath, __pyx_k_filepath, sizeof(__pyx_k_filepath), 0, 0, 1, 1}, {&__pyx_n_s_format, __pyx_k_format, sizeof(__pyx_k_format), 0, 0, 1, 1}, + {&__pyx_n_s_functools, __pyx_k_functools, sizeof(__pyx_k_functools), 0, 0, 1, 1}, + {&__pyx_n_s_future, __pyx_k_future, sizeof(__pyx_k_future), 0, 0, 1, 1}, + {&__pyx_n_s_future_result, __pyx_k_future_result, sizeof(__pyx_k_future_result), 0, 0, 1, 1}, + {&__pyx_n_s_gather, __pyx_k_gather, sizeof(__pyx_k_gather), 0, 0, 1, 1}, {&__pyx_n_s_genexpr, __pyx_k_genexpr, sizeof(__pyx_k_genexpr), 0, 0, 1, 1}, {&__pyx_n_s_get, __pyx_k_get, sizeof(__pyx_k_get), 0, 0, 1, 1}, {&__pyx_n_s_get_name, __pyx_k_get_name, sizeof(__pyx_k_get_name), 0, 0, 1, 1}, @@ -90566,6 +101689,7 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_get_self_name_locals_genexpr, __pyx_k_get_self_name_locals_genexpr, sizeof(__pyx_k_get_self_name_locals_genexpr), 0, 0, 1, 1}, {&__pyx_n_s_getenv, __pyx_k_getenv, sizeof(__pyx_k_getenv), 0, 0, 1, 1}, {&__pyx_n_s_getstate, __pyx_k_getstate, sizeof(__pyx_k_getstate), 0, 0, 1, 1}, + {&__pyx_n_s_has_isawaitable, __pyx_k_has_isawaitable, sizeof(__pyx_k_has_isawaitable), 0, 0, 1, 1}, {&__pyx_n_s_hex, __pyx_k_hex, sizeof(__pyx_k_hex), 0, 0, 1, 1}, {&__pyx_n_s_id, __pyx_k_id, sizeof(__pyx_k_id), 0, 0, 1, 1}, {&__pyx_n_s_im_class, __pyx_k_im_class, sizeof(__pyx_k_im_class), 0, 0, 1, 1}, @@ -90581,11 +101705,16 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_inspect, __pyx_k_inspect, sizeof(__pyx_k_inspect), 0, 0, 1, 1}, {&__pyx_n_s_instance, __pyx_k_instance, sizeof(__pyx_k_instance), 0, 0, 1, 1}, {&__pyx_n_s_instance_of, __pyx_k_instance_of, sizeof(__pyx_k_instance_of), 0, 0, 1, 1}, - {&__pyx_kp_s_instance_of_0, __pyx_k_instance_of_0, sizeof(__pyx_k_instance_of_0), 0, 0, 1, 0}, {&__pyx_n_s_interpolation, __pyx_k_interpolation, sizeof(__pyx_k_interpolation), 0, 0, 1, 1}, + {&__pyx_n_s_is_async_mode_disabled, __pyx_k_is_async_mode_disabled, sizeof(__pyx_k_is_async_mode_disabled), 0, 0, 1, 1}, + {&__pyx_n_s_is_async_mode_enabled, __pyx_k_is_async_mode_enabled, sizeof(__pyx_k_is_async_mode_enabled), 0, 0, 1, 1}, + {&__pyx_n_s_is_async_mode_undefined, __pyx_k_is_async_mode_undefined, sizeof(__pyx_k_is_async_mode_undefined), 0, 0, 1, 1}, + {&__pyx_n_s_is_async_resource_subclass, __pyx_k_is_async_resource_subclass, sizeof(__pyx_k_is_async_resource_subclass), 0, 0, 1, 1}, {&__pyx_n_s_is_coroutine, __pyx_k_is_coroutine, sizeof(__pyx_k_is_coroutine), 0, 0, 1, 1}, {&__pyx_n_s_is_coroutine_marker, __pyx_k_is_coroutine_marker, sizeof(__pyx_k_is_coroutine_marker), 0, 0, 1, 1}, {&__pyx_n_s_is_resource_subclass, __pyx_k_is_resource_subclass, sizeof(__pyx_k_is_resource_subclass), 0, 0, 1, 1}, + {&__pyx_n_s_isasyncgenfunction, __pyx_k_isasyncgenfunction, sizeof(__pyx_k_isasyncgenfunction), 0, 0, 1, 1}, + {&__pyx_n_s_isawaitable, __pyx_k_isawaitable, sizeof(__pyx_k_isawaitable), 0, 0, 1, 1}, {&__pyx_n_s_iscoroutinefunction, __pyx_k_iscoroutinefunction, sizeof(__pyx_k_iscoroutinefunction), 0, 0, 1, 1}, {&__pyx_n_s_isgeneratorfunction, __pyx_k_isgeneratorfunction, sizeof(__pyx_k_isgeneratorfunction), 0, 0, 1, 1}, {&__pyx_n_s_item, __pyx_k_item, sizeof(__pyx_k_item), 0, 0, 1, 1}, @@ -90619,6 +101748,7 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_overriding_lock, __pyx_k_overriding_lock, sizeof(__pyx_k_overriding_lock), 0, 0, 1, 1}, {&__pyx_n_s_parse_ini_file, __pyx_k_parse_ini_file, sizeof(__pyx_k_parse_ini_file), 0, 0, 1, 1}, {&__pyx_n_s_parser, __pyx_k_parser, sizeof(__pyx_k_parser), 0, 0, 1, 1}, + {&__pyx_n_s_partial, __pyx_k_partial, sizeof(__pyx_k_partial), 0, 0, 1, 1}, {&__pyx_n_s_path, __pyx_k_path, sizeof(__pyx_k_path), 0, 0, 1, 1}, {&__pyx_kp_s_path_2, __pyx_k_path_2, sizeof(__pyx_k_path_2), 0, 0, 1, 0}, {&__pyx_n_s_pickle, __pyx_k_pickle, sizeof(__pyx_k_pickle), 0, 0, 1, 1}, @@ -90706,10 +101836,13 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_set, __pyx_k_set, sizeof(__pyx_k_set), 0, 0, 1, 1}, {&__pyx_n_s_set_args, __pyx_k_set_args, sizeof(__pyx_k_set_args), 0, 0, 1, 1}, {&__pyx_n_s_set_attributes, __pyx_k_set_attributes, sizeof(__pyx_k_set_attributes), 0, 0, 1, 1}, + {&__pyx_n_s_set_exception, __pyx_k_set_exception, sizeof(__pyx_k_set_exception), 0, 0, 1, 1}, {&__pyx_n_s_set_kwargs, __pyx_k_set_kwargs, sizeof(__pyx_k_set_kwargs), 0, 0, 1, 1}, + {&__pyx_n_s_set_result, __pyx_k_set_result, sizeof(__pyx_k_set_result), 0, 0, 1, 1}, {&__pyx_n_s_setstate, __pyx_k_setstate, sizeof(__pyx_k_setstate), 0, 0, 1, 1}, {&__pyx_n_s_setstate_cython, __pyx_k_setstate_cython, sizeof(__pyx_k_setstate_cython), 0, 0, 1, 1}, {&__pyx_n_s_shutdown, __pyx_k_shutdown, sizeof(__pyx_k_shutdown), 0, 0, 1, 1}, + {&__pyx_n_s_shutdowner, __pyx_k_shutdowner, sizeof(__pyx_k_shutdowner), 0, 0, 1, 1}, {&__pyx_n_s_singleton, __pyx_k_singleton, sizeof(__pyx_k_singleton), 0, 0, 1, 1}, {&__pyx_n_s_split, __pyx_k_split, sizeof(__pyx_k_split), 0, 0, 1, 1}, {&__pyx_kp_s_src_dependency_injector_provider, __pyx_k_src_dependency_injector_provider, sizeof(__pyx_k_src_dependency_injector_provider), 0, 0, 1, 0}, @@ -90735,27 +101868,31 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_n_s_warn, __pyx_k_warn, sizeof(__pyx_k_warn), 0, 0, 1, 1}, {&__pyx_n_s_warnings, __pyx_k_warnings, sizeof(__pyx_k_warnings), 0, 0, 1, 1}, {&__pyx_n_s_weakref, __pyx_k_weakref, sizeof(__pyx_k_weakref), 0, 0, 1, 1}, + {&__pyx_n_s_wrap, __pyx_k_wrap, sizeof(__pyx_k_wrap), 0, 0, 1, 1}, {&__pyx_n_s_yaml, __pyx_k_yaml, sizeof(__pyx_k_yaml), 0, 0, 1, 1}, {&__pyx_n_s_yaml_env_marker_constructor, __pyx_k_yaml_env_marker_constructor, sizeof(__pyx_k_yaml_env_marker_constructor), 0, 0, 1, 1}, {&__pyx_n_s_yaml_env_marker_pattern, __pyx_k_yaml_env_marker_pattern, sizeof(__pyx_k_yaml_env_marker_pattern), 0, 0, 1, 1}, + {&__pyx_n_s_zip, __pyx_k_zip, sizeof(__pyx_k_zip), 0, 0, 1, 1}, {0, 0, 0, 0, 0, 0, 0} }; static CYTHON_SMALL_CODE int __Pyx_InitCachedBuiltins(void) { - __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_range) __PYX_ERR(0, 347, __pyx_L1_error) - __pyx_builtin_ImportError = __Pyx_GetBuiltinName(__pyx_n_s_ImportError); if (!__pyx_builtin_ImportError) __PYX_ERR(1, 17, __pyx_L1_error) - __pyx_builtin_object = __Pyx_GetBuiltinName(__pyx_n_s_object); if (!__pyx_builtin_object) __PYX_ERR(1, 443, __pyx_L1_error) - __pyx_builtin_staticmethod = __Pyx_GetBuiltinName(__pyx_n_s_staticmethod); if (!__pyx_builtin_staticmethod) __PYX_ERR(1, 2764, __pyx_L1_error) - __pyx_builtin_super = __Pyx_GetBuiltinName(__pyx_n_s_super); if (!__pyx_builtin_super) __PYX_ERR(1, 69, __pyx_L1_error) - __pyx_builtin_open = __Pyx_GetBuiltinName(__pyx_n_s_open); if (!__pyx_builtin_open) __PYX_ERR(1, 82, __pyx_L1_error) - __pyx_builtin_IOError = __Pyx_GetBuiltinName(__pyx_n_s_IOError); if (!__pyx_builtin_IOError) __PYX_ERR(1, 84, __pyx_L1_error) - __pyx_builtin_id = __Pyx_GetBuiltinName(__pyx_n_s_id); if (!__pyx_builtin_id) __PYX_ERR(1, 164, __pyx_L1_error) - __pyx_builtin_IndexError = __Pyx_GetBuiltinName(__pyx_n_s_IndexError); if (!__pyx_builtin_IndexError) __PYX_ERR(1, 245, __pyx_L1_error) - __pyx_builtin_DeprecationWarning = __Pyx_GetBuiltinName(__pyx_n_s_DeprecationWarning); if (!__pyx_builtin_DeprecationWarning) __PYX_ERR(1, 265, __pyx_L1_error) - __pyx_builtin_NotImplementedError = __Pyx_GetBuiltinName(__pyx_n_s_NotImplementedError); if (!__pyx_builtin_NotImplementedError) __PYX_ERR(1, 289, __pyx_L1_error) - __pyx_builtin_TypeError = __Pyx_GetBuiltinName(__pyx_n_s_TypeError); if (!__pyx_builtin_TypeError) __PYX_ERR(1, 446, __pyx_L1_error) - __pyx_builtin_AttributeError = __Pyx_GetBuiltinName(__pyx_n_s_AttributeError); if (!__pyx_builtin_AttributeError) __PYX_ERR(1, 604, __pyx_L1_error) - __pyx_builtin_StopIteration = __Pyx_GetBuiltinName(__pyx_n_s_StopIteration); if (!__pyx_builtin_StopIteration) __PYX_ERR(1, 2713, __pyx_L1_error) - __pyx_builtin_hex = __Pyx_GetBuiltinName(__pyx_n_s_hex); if (!__pyx_builtin_hex) __PYX_ERR(1, 2905, __pyx_L1_error) + __pyx_builtin_ImportError = __Pyx_GetBuiltinName(__pyx_n_s_ImportError); if (!__pyx_builtin_ImportError) __PYX_ERR(0, 5, __pyx_L1_error) + __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_range) __PYX_ERR(0, 353, __pyx_L1_error) + __pyx_builtin_zip = __Pyx_GetBuiltinName(__pyx_n_s_zip); if (!__pyx_builtin_zip) __PYX_ERR(0, 432, __pyx_L1_error) + __pyx_builtin_object = __Pyx_GetBuiltinName(__pyx_n_s_object); if (!__pyx_builtin_object) __PYX_ERR(1, 510, __pyx_L1_error) + __pyx_builtin_staticmethod = __Pyx_GetBuiltinName(__pyx_n_s_staticmethod); if (!__pyx_builtin_staticmethod) __PYX_ERR(1, 3011, __pyx_L1_error) + __pyx_builtin_super = __Pyx_GetBuiltinName(__pyx_n_s_super); if (!__pyx_builtin_super) __PYX_ERR(1, 70, __pyx_L1_error) + __pyx_builtin_open = __Pyx_GetBuiltinName(__pyx_n_s_open); if (!__pyx_builtin_open) __PYX_ERR(1, 83, __pyx_L1_error) + __pyx_builtin_IOError = __Pyx_GetBuiltinName(__pyx_n_s_IOError); if (!__pyx_builtin_IOError) __PYX_ERR(1, 85, __pyx_L1_error) + __pyx_builtin_id = __Pyx_GetBuiltinName(__pyx_n_s_id); if (!__pyx_builtin_id) __PYX_ERR(1, 187, __pyx_L1_error) + __pyx_builtin_IndexError = __Pyx_GetBuiltinName(__pyx_n_s_IndexError); if (!__pyx_builtin_IndexError) __PYX_ERR(1, 268, __pyx_L1_error) + __pyx_builtin_DeprecationWarning = __Pyx_GetBuiltinName(__pyx_n_s_DeprecationWarning); if (!__pyx_builtin_DeprecationWarning) __PYX_ERR(1, 305, __pyx_L1_error) + __pyx_builtin_NotImplementedError = __Pyx_GetBuiltinName(__pyx_n_s_NotImplementedError); if (!__pyx_builtin_NotImplementedError) __PYX_ERR(1, 356, __pyx_L1_error) + __pyx_builtin_TypeError = __Pyx_GetBuiltinName(__pyx_n_s_TypeError); if (!__pyx_builtin_TypeError) __PYX_ERR(1, 513, __pyx_L1_error) + __pyx_builtin_AttributeError = __Pyx_GetBuiltinName(__pyx_n_s_AttributeError); if (!__pyx_builtin_AttributeError) __PYX_ERR(1, 704, __pyx_L1_error) + __pyx_builtin_KeyError = __Pyx_GetBuiltinName(__pyx_n_s_KeyError); if (!__pyx_builtin_KeyError) __PYX_ERR(1, 2017, __pyx_L1_error) + __pyx_builtin_StopIteration = __Pyx_GetBuiltinName(__pyx_n_s_StopIteration); if (!__pyx_builtin_StopIteration) __PYX_ERR(1, 2876, __pyx_L1_error) + __pyx_builtin_hex = __Pyx_GetBuiltinName(__pyx_n_s_hex); if (!__pyx_builtin_hex) __PYX_ERR(1, 3161, __pyx_L1_error) return 0; __pyx_L1_error:; return -1; @@ -90765,337 +101902,408 @@ static CYTHON_SMALL_CODE int __Pyx_InitCachedConstants(void) { __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0); - /* "dependency_injector/providers.pyx":82 + /* "dependency_injector/providers.pyx":83 * parser = iniconfigparser.ConfigParser() * try: * with open(filepath) as config_file: # <<<<<<<<<<<<<< * config_string = os.path.expandvars(config_file.read()) * except IOError: */ - __pyx_tuple__2 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__2)) __PYX_ERR(1, 82, __pyx_L1_error) + __pyx_tuple__2 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__2)) __PYX_ERR(1, 83, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__2); __Pyx_GIVEREF(__pyx_tuple__2); - /* "dependency_injector/providers.pyx":262 + /* "dependency_injector/providers.pyx":302 * :rtype: :py:class:`Delegate` * """ * warnings.warn( # <<<<<<<<<<<<<< * 'Method ".delegate()" is deprecated since version 4.0.0. ' * 'Use ".provider" attribute instead.', */ - __pyx_tuple__3 = PyTuple_Pack(1, __pyx_kp_s_Method_delegate_is_deprecated_si); if (unlikely(!__pyx_tuple__3)) __PYX_ERR(1, 262, __pyx_L1_error) + __pyx_tuple__3 = PyTuple_Pack(1, __pyx_kp_s_Method_delegate_is_deprecated_si); if (unlikely(!__pyx_tuple__3)) __PYX_ERR(1, 302, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__3); __Pyx_GIVEREF(__pyx_tuple__3); - /* "dependency_injector/providers.pyx":927 + /* "dependency_injector/providers.pyx":1027 * cpdef object _provide(self, tuple args, dict kwargs): * """Return result of provided callable's call.""" * raise NotImplementedError('Abstract provider forward providing logic ' # <<<<<<<<<<<<<< * 'to overriding provider') * */ - __pyx_tuple__6 = PyTuple_Pack(1, __pyx_kp_s_Abstract_provider_forward_provid); if (unlikely(!__pyx_tuple__6)) __PYX_ERR(1, 927, __pyx_L1_error) + __pyx_tuple__6 = PyTuple_Pack(1, __pyx_kp_s_Abstract_provider_forward_provid); if (unlikely(!__pyx_tuple__6)) __PYX_ERR(1, 1027, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__6); __Pyx_GIVEREF(__pyx_tuple__6); - /* "dependency_injector/providers.pyx":2766 + /* "dependency_injector/providers.pyx":2018 + * factory_name = kwargs.pop('factory_name') + * except KeyError: + * raise TypeError('Factory missing 1 required positional argument: \'factory_name\'') # <<<<<<<<<<<<<< + * else: + * args = args[1:] + */ + __pyx_tuple__8 = PyTuple_Pack(1, __pyx_kp_s_Factory_missing_1_required_posit); if (unlikely(!__pyx_tuple__8)) __PYX_ERR(1, 2018, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__8); + __Pyx_GIVEREF(__pyx_tuple__8); + + /* "dependency_injector/providers.pyx":3013 * @staticmethod * def _is_resource_subclass(instance): * if sys.version_info < (3, 5): # <<<<<<<<<<<<<< * return False * if not isinstance(instance, CLASS_TYPES): */ - __pyx_tuple__10 = PyTuple_Pack(2, __pyx_int_3, __pyx_int_5); if (unlikely(!__pyx_tuple__10)) __PYX_ERR(1, 2766, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__10); - __Pyx_GIVEREF(__pyx_tuple__10); + __pyx_tuple__11 = PyTuple_Pack(2, __pyx_int_3, __pyx_int_5); if (unlikely(!__pyx_tuple__11)) __PYX_ERR(1, 3013, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__11); + __Pyx_GIVEREF(__pyx_tuple__11); - /* "dependency_injector/providers.pyx":21 + /* "cfunc.to_py":65 + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): + * def wrap(object future): # <<<<<<<<<<<<<< + * """wrap(future) -> 'void'""" + * f(future) + */ + __pyx_tuple__16 = PyTuple_Pack(1, __pyx_n_s_future); if (unlikely(!__pyx_tuple__16)) __PYX_ERR(2, 65, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__16); + __Pyx_GIVEREF(__pyx_tuple__16); + __pyx_codeobj__17 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__16, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_wrap, 65, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__17)) __PYX_ERR(2, 65, __pyx_L1_error) + + /* "dependency_injector/providers.pyx":22 * _is_coroutine_marker = None * else: * if sys.version_info >= (3, 5, 3): # <<<<<<<<<<<<<< * import asyncio.coroutines * _is_coroutine_marker = asyncio.coroutines._is_coroutine */ - __pyx_tuple__15 = PyTuple_Pack(3, __pyx_int_3, __pyx_int_5, __pyx_int_3); if (unlikely(!__pyx_tuple__15)) __PYX_ERR(1, 21, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__15); - __Pyx_GIVEREF(__pyx_tuple__15); + __pyx_tuple__18 = PyTuple_Pack(3, __pyx_int_3, __pyx_int_5, __pyx_int_3); if (unlikely(!__pyx_tuple__18)) __PYX_ERR(1, 22, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__18); + __Pyx_GIVEREF(__pyx_tuple__18); - /* "dependency_injector/providers.pyx":56 + /* "dependency_injector/providers.pyx":57 * * if yaml: * yaml_env_marker_pattern = re.compile(r'\$\{([^}^{]+)\}') # <<<<<<<<<<<<<< * def yaml_env_marker_constructor(_, node): * """"Replace environment variable marker with its value.""" */ - __pyx_tuple__17 = PyTuple_Pack(1, __pyx_kp_s__16); if (unlikely(!__pyx_tuple__17)) __PYX_ERR(1, 56, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__17); - __Pyx_GIVEREF(__pyx_tuple__17); + __pyx_tuple__20 = PyTuple_Pack(1, __pyx_kp_s__19); if (unlikely(!__pyx_tuple__20)) __PYX_ERR(1, 57, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__20); + __Pyx_GIVEREF(__pyx_tuple__20); - /* "dependency_injector/providers.pyx":57 + /* "dependency_injector/providers.pyx":58 * if yaml: * yaml_env_marker_pattern = re.compile(r'\$\{([^}^{]+)\}') * def yaml_env_marker_constructor(_, node): # <<<<<<<<<<<<<< * """"Replace environment variable marker with its value.""" * return os.path.expandvars(node.value) */ - __pyx_tuple__18 = PyTuple_Pack(2, __pyx_n_s_, __pyx_n_s_node); if (unlikely(!__pyx_tuple__18)) __PYX_ERR(1, 57, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__18); - __Pyx_GIVEREF(__pyx_tuple__18); - __pyx_codeobj__19 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__18, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_yaml_env_marker_constructor, 57, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__19)) __PYX_ERR(1, 57, __pyx_L1_error) + __pyx_tuple__21 = PyTuple_Pack(2, __pyx_n_s_, __pyx_n_s_node); if (unlikely(!__pyx_tuple__21)) __PYX_ERR(1, 58, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__21); + __Pyx_GIVEREF(__pyx_tuple__21); + __pyx_codeobj__22 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__21, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_yaml_env_marker_constructor, 58, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__22)) __PYX_ERR(1, 58, __pyx_L1_error) - /* "dependency_injector/providers.pyx":68 + /* "dependency_injector/providers.pyx":69 * """Interpolation which expands environment variables in values.""" * * def before_get(self, parser, section, option, value, defaults): # <<<<<<<<<<<<<< * value = super().before_get(parser, section, option, value, defaults) * return os.path.expandvars(value) */ - __pyx_tuple__20 = PyTuple_Pack(6, __pyx_n_s_self, __pyx_n_s_parser, __pyx_n_s_section, __pyx_n_s_option, __pyx_n_s_value, __pyx_n_s_defaults); if (unlikely(!__pyx_tuple__20)) __PYX_ERR(1, 68, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__20); - __Pyx_GIVEREF(__pyx_tuple__20); - __pyx_codeobj__21 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__20, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_before_get, 68, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__21)) __PYX_ERR(1, 68, __pyx_L1_error) + __pyx_tuple__23 = PyTuple_Pack(6, __pyx_n_s_self, __pyx_n_s_parser, __pyx_n_s_section, __pyx_n_s_option, __pyx_n_s_value, __pyx_n_s_defaults); if (unlikely(!__pyx_tuple__23)) __PYX_ERR(1, 69, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__23); + __Pyx_GIVEREF(__pyx_tuple__23); + __pyx_codeobj__24 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__23, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_before_get, 69, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__24)) __PYX_ERR(1, 69, __pyx_L1_error) - /* "dependency_injector/providers.pyx":72 + /* "dependency_injector/providers.pyx":73 * return os.path.expandvars(value) * * def _parse_ini_file(filepath): # <<<<<<<<<<<<<< * parser = iniconfigparser.ConfigParser(interpolation=EnvInterpolation()) * parser.read(filepath) */ - __pyx_tuple__22 = PyTuple_Pack(2, __pyx_n_s_filepath, __pyx_n_s_parser); if (unlikely(!__pyx_tuple__22)) __PYX_ERR(1, 72, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__22); - __Pyx_GIVEREF(__pyx_tuple__22); - __pyx_codeobj__23 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__22, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_parse_ini_file, 72, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__23)) __PYX_ERR(1, 72, __pyx_L1_error) + __pyx_tuple__25 = PyTuple_Pack(2, __pyx_n_s_filepath, __pyx_n_s_parser); if (unlikely(!__pyx_tuple__25)) __PYX_ERR(1, 73, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__25); + __Pyx_GIVEREF(__pyx_tuple__25); + __pyx_codeobj__26 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__25, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_parse_ini_file, 73, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__26)) __PYX_ERR(1, 73, __pyx_L1_error) - /* "dependency_injector/providers.pyx":79 + /* "dependency_injector/providers.pyx":80 * import StringIO * * def _parse_ini_file(filepath): # <<<<<<<<<<<<<< * parser = iniconfigparser.ConfigParser() * try: */ - __pyx_tuple__24 = PyTuple_Pack(4, __pyx_n_s_filepath, __pyx_n_s_parser, __pyx_n_s_config_file, __pyx_n_s_config_string); if (unlikely(!__pyx_tuple__24)) __PYX_ERR(1, 79, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__24); - __Pyx_GIVEREF(__pyx_tuple__24); - __pyx_codeobj__25 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__24, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_parse_ini_file, 79, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__25)) __PYX_ERR(1, 79, __pyx_L1_error) + __pyx_tuple__27 = PyTuple_Pack(4, __pyx_n_s_filepath, __pyx_n_s_parser, __pyx_n_s_config_file, __pyx_n_s_config_string); if (unlikely(!__pyx_tuple__27)) __PYX_ERR(1, 80, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__27); + __Pyx_GIVEREF(__pyx_tuple__27); + __pyx_codeobj__28 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__27, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_parse_ini_file, 80, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__28)) __PYX_ERR(1, 80, __pyx_L1_error) - /* "dependency_injector/providers.pyx":2765 + /* "dependency_injector/providers.pyx":3012 * * @staticmethod * def _is_resource_subclass(instance): # <<<<<<<<<<<<<< * if sys.version_info < (3, 5): * return False */ - __pyx_tuple__26 = PyTuple_Pack(2, __pyx_n_s_instance, __pyx_n_s_resources); if (unlikely(!__pyx_tuple__26)) __PYX_ERR(1, 2765, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__26); - __Pyx_GIVEREF(__pyx_tuple__26); - __pyx_codeobj__27 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__26, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_is_resource_subclass, 2765, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__27)) __PYX_ERR(1, 2765, __pyx_L1_error) + __pyx_tuple__29 = PyTuple_Pack(2, __pyx_n_s_instance, __pyx_n_s_resources); if (unlikely(!__pyx_tuple__29)) __PYX_ERR(1, 3012, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__29); + __Pyx_GIVEREF(__pyx_tuple__29); + __pyx_codeobj__30 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__29, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_is_resource_subclass, 3012, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__30)) __PYX_ERR(1, 3012, __pyx_L1_error) - /* "dependency_injector/providers.pyx":3354 + /* "dependency_injector/providers.pyx":3021 + * + * @staticmethod + * def _is_async_resource_subclass(instance): # <<<<<<<<<<<<<< + * if sys.version_info < (3, 5): + * return False + */ + __pyx_tuple__31 = PyTuple_Pack(2, __pyx_n_s_instance, __pyx_n_s_resources); if (unlikely(!__pyx_tuple__31)) __PYX_ERR(1, 3021, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__31); + __Pyx_GIVEREF(__pyx_tuple__31); + __pyx_codeobj__32 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__31, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_is_async_resource_subclass, 3021, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__32)) __PYX_ERR(1, 3021, __pyx_L1_error) + + /* "dependency_injector/providers.pyx":3648 * return copy.deepcopy(instance, memo) * * def __add_sys_streams(memo): # <<<<<<<<<<<<<< * """Add system streams to memo dictionary. * */ - __pyx_tuple__28 = PyTuple_Pack(1, __pyx_n_s_memo); if (unlikely(!__pyx_tuple__28)) __PYX_ERR(1, 3354, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__28); - __Pyx_GIVEREF(__pyx_tuple__28); - __pyx_codeobj__29 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__28, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_add_sys_streams, 3354, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__29)) __PYX_ERR(1, 3354, __pyx_L1_error) + __pyx_tuple__33 = PyTuple_Pack(1, __pyx_n_s_memo); if (unlikely(!__pyx_tuple__33)) __PYX_ERR(1, 3648, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__33); + __Pyx_GIVEREF(__pyx_tuple__33); + __pyx_codeobj__34 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__33, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_add_sys_streams, 3648, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__34)) __PYX_ERR(1, 3648, __pyx_L1_error) - /* "dependency_injector/providers.pyx":3365 + /* "dependency_injector/providers.pyx":3659 * * * def merge_dicts(dict1, dict2): # <<<<<<<<<<<<<< * """Merge dictionaries recursively. * */ - __pyx_tuple__30 = PyTuple_Pack(5, __pyx_n_s_dict1, __pyx_n_s_dict2, __pyx_n_s_key, __pyx_n_s_value, __pyx_n_s_result); if (unlikely(!__pyx_tuple__30)) __PYX_ERR(1, 3365, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__30); - __Pyx_GIVEREF(__pyx_tuple__30); - __pyx_codeobj__31 = (PyObject*)__Pyx_PyCode_New(2, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__30, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_merge_dicts, 3365, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__31)) __PYX_ERR(1, 3365, __pyx_L1_error) + __pyx_tuple__35 = PyTuple_Pack(5, __pyx_n_s_dict1, __pyx_n_s_dict2, __pyx_n_s_key, __pyx_n_s_value, __pyx_n_s_result); if (unlikely(!__pyx_tuple__35)) __PYX_ERR(1, 3659, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__35); + __Pyx_GIVEREF(__pyx_tuple__35); + __pyx_codeobj__36 = (PyObject*)__Pyx_PyCode_New(2, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__35, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_merge_dicts, 3659, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__36)) __PYX_ERR(1, 3659, __pyx_L1_error) + + /* "dependency_injector/providers.pyx":3680 + * + * + * def isawaitable(obj): # <<<<<<<<<<<<<< + * """Check if object is a coroutine function. + * + */ + __pyx_tuple__37 = PyTuple_Pack(1, __pyx_n_s_obj); if (unlikely(!__pyx_tuple__37)) __PYX_ERR(1, 3680, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__37); + __Pyx_GIVEREF(__pyx_tuple__37); + __pyx_codeobj__38 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__37, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_isawaitable, 3680, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__38)) __PYX_ERR(1, 3680, __pyx_L1_error) + + /* "dependency_injector/providers.pyx":3691 + * + * + * def iscoroutinefunction(obj): # <<<<<<<<<<<<<< + * """Check if object is a coroutine function. + * + */ + __pyx_tuple__39 = PyTuple_Pack(1, __pyx_n_s_obj); if (unlikely(!__pyx_tuple__39)) __PYX_ERR(1, 3691, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__39); + __Pyx_GIVEREF(__pyx_tuple__39); + __pyx_codeobj__40 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__39, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_iscoroutinefunction, 3691, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__40)) __PYX_ERR(1, 3691, __pyx_L1_error) + + /* "dependency_injector/providers.pyx":3702 + * + * + * def isasyncgenfunction(obj): # <<<<<<<<<<<<<< + * """Check if object is an asynchronous generator function. + * + */ + __pyx_tuple__41 = PyTuple_Pack(1, __pyx_n_s_obj); if (unlikely(!__pyx_tuple__41)) __PYX_ERR(1, 3702, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__41); + __Pyx_GIVEREF(__pyx_tuple__41); + __pyx_codeobj__42 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__41, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_src_dependency_injector_provider, __pyx_n_s_isasyncgenfunction, 3702, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__42)) __PYX_ERR(1, 3702, __pyx_L1_error) /* "(tree fragment)":1 * def __pyx_unpickle_Provider(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_tuple__32 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__32)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__32); - __Pyx_GIVEREF(__pyx_tuple__32); - __pyx_codeobj__33 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__32, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Provider, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__33)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__34 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__34)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__34); - __Pyx_GIVEREF(__pyx_tuple__34); - __pyx_codeobj__35 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__34, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Object, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__35)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__36 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__36)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__36); - __Pyx_GIVEREF(__pyx_tuple__36); - __pyx_codeobj__37 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__36, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Delegate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__37)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__38 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__38)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__38); - __Pyx_GIVEREF(__pyx_tuple__38); - __pyx_codeobj__39 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__38, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Dependency, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__39)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__40 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__40)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__40); - __Pyx_GIVEREF(__pyx_tuple__40); - __pyx_codeobj__41 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__40, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ExternalDependenc, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__41)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__42 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__42)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__42); - __Pyx_GIVEREF(__pyx_tuple__42); - __pyx_codeobj__43 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__42, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DependenciesConta, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__43)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__44 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__44)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__44); - __Pyx_GIVEREF(__pyx_tuple__44); - __pyx_codeobj__45 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__44, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_OverridingContext, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__45)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__46 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__46)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__46); - __Pyx_GIVEREF(__pyx_tuple__46); - __pyx_codeobj__47 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__46, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Callable, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__47)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__48 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__48)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__48); - __Pyx_GIVEREF(__pyx_tuple__48); - __pyx_codeobj__49 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__48, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedCallable, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__49)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__50 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__50)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__50); - __Pyx_GIVEREF(__pyx_tuple__50); - __pyx_codeobj__51 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__50, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_AbstractCallable, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__51)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__52 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__52)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__52); - __Pyx_GIVEREF(__pyx_tuple__52); - __pyx_codeobj__53 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__52, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_CallableDelegate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__53)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__54 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__54)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__54); - __Pyx_GIVEREF(__pyx_tuple__54); - __pyx_codeobj__55 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__54, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Coroutine, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__55)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__56 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__56)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__56); - __Pyx_GIVEREF(__pyx_tuple__56); - __pyx_codeobj__57 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__56, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedCoroutin, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__57)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__58 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__58)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__58); - __Pyx_GIVEREF(__pyx_tuple__58); - __pyx_codeobj__59 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__58, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_AbstractCoroutine, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__59)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__60 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__60)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__60); - __Pyx_GIVEREF(__pyx_tuple__60); - __pyx_codeobj__61 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__60, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_CoroutineDelegate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__61)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__62 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__62)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__62); - __Pyx_GIVEREF(__pyx_tuple__62); - __pyx_codeobj__63 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__62, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ConfigurationOpti, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__63)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__64 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__64)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__64); - __Pyx_GIVEREF(__pyx_tuple__64); - __pyx_codeobj__65 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__64, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_TypedConfiguratio, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__65)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__66 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__66)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__66); - __Pyx_GIVEREF(__pyx_tuple__66); - __pyx_codeobj__67 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__66, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Configuration, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__67)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__68 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__68)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__68); - __Pyx_GIVEREF(__pyx_tuple__68); - __pyx_codeobj__69 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__68, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Factory, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__69)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__70 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__70)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__70); - __Pyx_GIVEREF(__pyx_tuple__70); - __pyx_codeobj__71 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__70, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedFactory, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__71)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__72 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__72)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__72); - __Pyx_GIVEREF(__pyx_tuple__72); - __pyx_codeobj__73 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__72, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_AbstractFactory, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__73)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__74 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__74)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__74); - __Pyx_GIVEREF(__pyx_tuple__74); - __pyx_codeobj__75 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__74, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_FactoryDelegate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__75)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__76 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__76)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__76); - __Pyx_GIVEREF(__pyx_tuple__76); - __pyx_codeobj__77 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__76, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_FactoryAggregate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__77)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__78 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__78)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__78); - __Pyx_GIVEREF(__pyx_tuple__78); - __pyx_codeobj__79 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__78, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_BaseSingleton, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__79)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__80 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__80)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__80); - __Pyx_GIVEREF(__pyx_tuple__80); - __pyx_codeobj__81 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__80, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Singleton, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__81)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__82 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__82)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__82); - __Pyx_GIVEREF(__pyx_tuple__82); - __pyx_codeobj__83 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__82, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedSingleto, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__83)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__84 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__84)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__84); - __Pyx_GIVEREF(__pyx_tuple__84); - __pyx_codeobj__85 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__84, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ThreadSafeSinglet, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__85)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__86 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__86)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__86); - __Pyx_GIVEREF(__pyx_tuple__86); - __pyx_codeobj__87 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__86, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedThreadSa, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__87)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__88 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__88)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__88); - __Pyx_GIVEREF(__pyx_tuple__88); - __pyx_codeobj__89 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__88, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ThreadLocalSingle, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__89)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__90 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__90)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__90); - __Pyx_GIVEREF(__pyx_tuple__90); - __pyx_codeobj__91 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__90, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedThreadLo, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__91)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__92 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__92)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__92); - __Pyx_GIVEREF(__pyx_tuple__92); - __pyx_codeobj__93 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__92, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_AbstractSingleton, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__93)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__94 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__94)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__94); - __Pyx_GIVEREF(__pyx_tuple__94); - __pyx_codeobj__95 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__94, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_SingletonDelegate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__95)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__96 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__96)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__96); - __Pyx_GIVEREF(__pyx_tuple__96); - __pyx_codeobj__97 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__96, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_List, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__97)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__98 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__98)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__98); - __Pyx_GIVEREF(__pyx_tuple__98); - __pyx_codeobj__99 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__98, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Dict, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__99)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__100 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__100)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__100); - __Pyx_GIVEREF(__pyx_tuple__100); - __pyx_codeobj__101 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__100, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Resource, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__101)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__102 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__102)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__102); - __Pyx_GIVEREF(__pyx_tuple__102); - __pyx_codeobj__103 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__102, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Container, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__103)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__104 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__104)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__104); - __Pyx_GIVEREF(__pyx_tuple__104); - __pyx_codeobj__105 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__104, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Selector, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__105)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__106 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__106)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__106); - __Pyx_GIVEREF(__pyx_tuple__106); - __pyx_codeobj__107 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__106, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ProvidedInstance, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__107)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__108 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__108)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__108); - __Pyx_GIVEREF(__pyx_tuple__108); - __pyx_codeobj__109 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__108, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_AttributeGetter, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__109)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__110 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__110)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__110); - __Pyx_GIVEREF(__pyx_tuple__110); - __pyx_codeobj__111 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__110, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ItemGetter, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__111)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__112 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__112)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__112); - __Pyx_GIVEREF(__pyx_tuple__112); - __pyx_codeobj__113 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__112, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_MethodCaller, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__113)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__114 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__114)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__114); - __Pyx_GIVEREF(__pyx_tuple__114); - __pyx_codeobj__115 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__114, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Injection, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__115)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__116 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__116)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__116); - __Pyx_GIVEREF(__pyx_tuple__116); - __pyx_codeobj__117 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__116, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_PositionalInjecti, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__117)) __PYX_ERR(2, 1, __pyx_L1_error) - __pyx_tuple__118 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__118)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_tuple__118); - __Pyx_GIVEREF(__pyx_tuple__118); - __pyx_codeobj__119 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__118, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_NamedInjection, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__119)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__43 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__43)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__43); + __Pyx_GIVEREF(__pyx_tuple__43); + __pyx_codeobj__44 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__43, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Provider, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__44)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__45 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__45)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__45); + __Pyx_GIVEREF(__pyx_tuple__45); + __pyx_codeobj__46 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__45, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Object, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__46)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__47 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__47)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__47); + __Pyx_GIVEREF(__pyx_tuple__47); + __pyx_codeobj__48 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__47, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Delegate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__48)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__49 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__49)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__49); + __Pyx_GIVEREF(__pyx_tuple__49); + __pyx_codeobj__50 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__49, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Dependency, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__50)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__51 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__51)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__51); + __Pyx_GIVEREF(__pyx_tuple__51); + __pyx_codeobj__52 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__51, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ExternalDependenc, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__52)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__53 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__53)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__53); + __Pyx_GIVEREF(__pyx_tuple__53); + __pyx_codeobj__54 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__53, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DependenciesConta, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__54)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__55 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__55)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__55); + __Pyx_GIVEREF(__pyx_tuple__55); + __pyx_codeobj__56 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__55, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_OverridingContext, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__56)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__57 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__57)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__57); + __Pyx_GIVEREF(__pyx_tuple__57); + __pyx_codeobj__58 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__57, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Callable, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__58)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__59 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__59)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__59); + __Pyx_GIVEREF(__pyx_tuple__59); + __pyx_codeobj__60 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__59, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedCallable, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__60)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__61 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__61)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__61); + __Pyx_GIVEREF(__pyx_tuple__61); + __pyx_codeobj__62 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__61, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_AbstractCallable, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__62)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__63 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__63)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__63); + __Pyx_GIVEREF(__pyx_tuple__63); + __pyx_codeobj__64 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__63, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_CallableDelegate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__64)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__65 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__65)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__65); + __Pyx_GIVEREF(__pyx_tuple__65); + __pyx_codeobj__66 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__65, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Coroutine, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__66)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__67 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__67)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__67); + __Pyx_GIVEREF(__pyx_tuple__67); + __pyx_codeobj__68 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__67, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedCoroutin, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__68)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__69 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__69)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__69); + __Pyx_GIVEREF(__pyx_tuple__69); + __pyx_codeobj__70 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__69, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_AbstractCoroutine, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__70)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__71 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__71)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__71); + __Pyx_GIVEREF(__pyx_tuple__71); + __pyx_codeobj__72 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__71, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_CoroutineDelegate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__72)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__73 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__73)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__73); + __Pyx_GIVEREF(__pyx_tuple__73); + __pyx_codeobj__74 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__73, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ConfigurationOpti, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__74)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__75 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__75)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__75); + __Pyx_GIVEREF(__pyx_tuple__75); + __pyx_codeobj__76 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__75, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_TypedConfiguratio, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__76)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__77 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__77)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__77); + __Pyx_GIVEREF(__pyx_tuple__77); + __pyx_codeobj__78 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__77, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Configuration, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__78)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__79 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__79)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__79); + __Pyx_GIVEREF(__pyx_tuple__79); + __pyx_codeobj__80 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__79, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Factory, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__80)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__81 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__81)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__81); + __Pyx_GIVEREF(__pyx_tuple__81); + __pyx_codeobj__82 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__81, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedFactory, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__82)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__83 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__83)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__83); + __Pyx_GIVEREF(__pyx_tuple__83); + __pyx_codeobj__84 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__83, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_AbstractFactory, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__84)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__85 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__85)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__85); + __Pyx_GIVEREF(__pyx_tuple__85); + __pyx_codeobj__86 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__85, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_FactoryDelegate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__86)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__87 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__87)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__87); + __Pyx_GIVEREF(__pyx_tuple__87); + __pyx_codeobj__88 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__87, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_FactoryAggregate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__88)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__89 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__89)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__89); + __Pyx_GIVEREF(__pyx_tuple__89); + __pyx_codeobj__90 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__89, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_BaseSingleton, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__90)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__91 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__91)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__91); + __Pyx_GIVEREF(__pyx_tuple__91); + __pyx_codeobj__92 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__91, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Singleton, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__92)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__93 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__93)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__93); + __Pyx_GIVEREF(__pyx_tuple__93); + __pyx_codeobj__94 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__93, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedSingleto, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__94)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__95 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__95)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__95); + __Pyx_GIVEREF(__pyx_tuple__95); + __pyx_codeobj__96 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__95, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ThreadSafeSinglet, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__96)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__97 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__97)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__97); + __Pyx_GIVEREF(__pyx_tuple__97); + __pyx_codeobj__98 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__97, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedThreadSa, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__98)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__99 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__99)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__99); + __Pyx_GIVEREF(__pyx_tuple__99); + __pyx_codeobj__100 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__99, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ThreadLocalSingle, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__100)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__101 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__101)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__101); + __Pyx_GIVEREF(__pyx_tuple__101); + __pyx_codeobj__102 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__101, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_DelegatedThreadLo, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__102)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__103 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__103)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__103); + __Pyx_GIVEREF(__pyx_tuple__103); + __pyx_codeobj__104 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__103, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_AbstractSingleton, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__104)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__105 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__105)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__105); + __Pyx_GIVEREF(__pyx_tuple__105); + __pyx_codeobj__106 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__105, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_SingletonDelegate, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__106)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__107 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__107)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__107); + __Pyx_GIVEREF(__pyx_tuple__107); + __pyx_codeobj__108 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__107, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_List, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__108)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__109 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__109)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__109); + __Pyx_GIVEREF(__pyx_tuple__109); + __pyx_codeobj__110 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__109, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Dict, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__110)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__111 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__111)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__111); + __Pyx_GIVEREF(__pyx_tuple__111); + __pyx_codeobj__112 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__111, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Resource, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__112)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__113 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__113)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__113); + __Pyx_GIVEREF(__pyx_tuple__113); + __pyx_codeobj__114 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__113, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Container, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__114)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__115 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__115)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__115); + __Pyx_GIVEREF(__pyx_tuple__115); + __pyx_codeobj__116 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__115, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Selector, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__116)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__117 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__117)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__117); + __Pyx_GIVEREF(__pyx_tuple__117); + __pyx_codeobj__118 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__117, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ProvidedInstance, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__118)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__119 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__119)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__119); + __Pyx_GIVEREF(__pyx_tuple__119); + __pyx_codeobj__120 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__119, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_AttributeGetter, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__120)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__121 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__121)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__121); + __Pyx_GIVEREF(__pyx_tuple__121); + __pyx_codeobj__122 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__121, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_ItemGetter, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__122)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__123 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__123)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__123); + __Pyx_GIVEREF(__pyx_tuple__123); + __pyx_codeobj__124 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__123, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_MethodCaller, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__124)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__125 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__125)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__125); + __Pyx_GIVEREF(__pyx_tuple__125); + __pyx_codeobj__126 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__125, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Injection, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__126)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__127 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__127)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__127); + __Pyx_GIVEREF(__pyx_tuple__127); + __pyx_codeobj__128 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__127, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_PositionalInjecti, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__128)) __PYX_ERR(2, 1, __pyx_L1_error) + __pyx_tuple__129 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__129)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_tuple__129); + __Pyx_GIVEREF(__pyx_tuple__129); + __pyx_codeobj__130 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__129, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_NamedInjection, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__130)) __PYX_ERR(2, 1, __pyx_L1_error) __Pyx_RefNannyFinishContext(); return 0; __pyx_L1_error:; @@ -91106,36 +102314,36 @@ static CYTHON_SMALL_CODE int __Pyx_InitCachedConstants(void) { static CYTHON_SMALL_CODE int __Pyx_InitGlobals(void) { __pyx_umethod_PyDict_Type_get.type = (PyObject*)&PyDict_Type; __pyx_umethod_PyDict_Type_items.type = (PyObject*)&PyDict_Type; + __pyx_umethod_PyDict_Type_pop.type = (PyObject*)&PyDict_Type; __pyx_umethod_PyDict_Type_values.type = (PyObject*)&PyDict_Type; if (__Pyx_InitStrings(__pyx_string_tab) < 0) __PYX_ERR(1, 1, __pyx_L1_error); __pyx_int_0 = PyInt_FromLong(0); if (unlikely(!__pyx_int_0)) __PYX_ERR(1, 1, __pyx_L1_error) __pyx_int_2 = PyInt_FromLong(2); if (unlikely(!__pyx_int_2)) __PYX_ERR(1, 1, __pyx_L1_error) __pyx_int_3 = PyInt_FromLong(3); if (unlikely(!__pyx_int_3)) __PYX_ERR(1, 1, __pyx_L1_error) __pyx_int_5 = PyInt_FromLong(5); if (unlikely(!__pyx_int_5)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_3297756 = PyInt_FromLong(3297756L); if (unlikely(!__pyx_int_3297756)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_4406536 = PyInt_FromLong(4406536L); if (unlikely(!__pyx_int_4406536)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_12885488 = PyInt_FromLong(12885488L); if (unlikely(!__pyx_int_12885488)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_13664252 = PyInt_FromLong(13664252L); if (unlikely(!__pyx_int_13664252)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_16106973 = PyInt_FromLong(16106973L); if (unlikely(!__pyx_int_16106973)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_33712928 = PyInt_FromLong(33712928L); if (unlikely(!__pyx_int_33712928)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_29181932 = PyInt_FromLong(29181932L); if (unlikely(!__pyx_int_29181932)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_30383981 = PyInt_FromLong(30383981L); if (unlikely(!__pyx_int_30383981)) __PYX_ERR(1, 1, __pyx_L1_error) __pyx_int_34020203 = PyInt_FromLong(34020203L); if (unlikely(!__pyx_int_34020203)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_44395068 = PyInt_FromLong(44395068L); if (unlikely(!__pyx_int_44395068)) __PYX_ERR(1, 1, __pyx_L1_error) __pyx_int_48353679 = PyInt_FromLong(48353679L); if (unlikely(!__pyx_int_48353679)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_66364342 = PyInt_FromLong(66364342L); if (unlikely(!__pyx_int_66364342)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_91273250 = PyInt_FromLong(91273250L); if (unlikely(!__pyx_int_91273250)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_92376750 = PyInt_FromLong(92376750L); if (unlikely(!__pyx_int_92376750)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_103927799 = PyInt_FromLong(103927799L); if (unlikely(!__pyx_int_103927799)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_52983931 = PyInt_FromLong(52983931L); if (unlikely(!__pyx_int_52983931)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_54922531 = PyInt_FromLong(54922531L); if (unlikely(!__pyx_int_54922531)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_65022886 = PyInt_FromLong(65022886L); if (unlikely(!__pyx_int_65022886)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_69951814 = PyInt_FromLong(69951814L); if (unlikely(!__pyx_int_69951814)) __PYX_ERR(1, 1, __pyx_L1_error) __pyx_int_105855327 = PyInt_FromLong(105855327L); if (unlikely(!__pyx_int_105855327)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_124696738 = PyInt_FromLong(124696738L); if (unlikely(!__pyx_int_124696738)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_159160076 = PyInt_FromLong(159160076L); if (unlikely(!__pyx_int_159160076)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_173552623 = PyInt_FromLong(173552623L); if (unlikely(!__pyx_int_173552623)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_174495485 = PyInt_FromLong(174495485L); if (unlikely(!__pyx_int_174495485)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_175356006 = PyInt_FromLong(175356006L); if (unlikely(!__pyx_int_175356006)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_175530959 = PyInt_FromLong(175530959L); if (unlikely(!__pyx_int_175530959)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_186670759 = PyInt_FromLong(186670759L); if (unlikely(!__pyx_int_186670759)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_226841543 = PyInt_FromLong(226841543L); if (unlikely(!__pyx_int_226841543)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_235011912 = PyInt_FromLong(235011912L); if (unlikely(!__pyx_int_235011912)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_244028132 = PyInt_FromLong(244028132L); if (unlikely(!__pyx_int_244028132)) __PYX_ERR(1, 1, __pyx_L1_error) - __pyx_int_253710871 = PyInt_FromLong(253710871L); if (unlikely(!__pyx_int_253710871)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_107726368 = PyInt_FromLong(107726368L); if (unlikely(!__pyx_int_107726368)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_111758699 = PyInt_FromLong(111758699L); if (unlikely(!__pyx_int_111758699)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_120901579 = PyInt_FromLong(120901579L); if (unlikely(!__pyx_int_120901579)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_122966839 = PyInt_FromLong(122966839L); if (unlikely(!__pyx_int_122966839)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_132941027 = PyInt_FromLong(132941027L); if (unlikely(!__pyx_int_132941027)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_168129982 = PyInt_FromLong(168129982L); if (unlikely(!__pyx_int_168129982)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_170282226 = PyInt_FromLong(170282226L); if (unlikely(!__pyx_int_170282226)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_216322617 = PyInt_FromLong(216322617L); if (unlikely(!__pyx_int_216322617)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_223699277 = PyInt_FromLong(223699277L); if (unlikely(!__pyx_int_223699277)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_240604463 = PyInt_FromLong(240604463L); if (unlikely(!__pyx_int_240604463)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_265687189 = PyInt_FromLong(265687189L); if (unlikely(!__pyx_int_265687189)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_267092376 = PyInt_FromLong(267092376L); if (unlikely(!__pyx_int_267092376)) __PYX_ERR(1, 1, __pyx_L1_error) + __pyx_int_267861151 = PyInt_FromLong(267861151L); if (unlikely(!__pyx_int_267861151)) __PYX_ERR(1, 1, __pyx_L1_error) return 0; __pyx_L1_error:; return -1; @@ -91166,6 +102374,7 @@ static int __Pyx_modinit_variable_export_code(void) { __Pyx_RefNannySetupContext("__Pyx_modinit_variable_export_code", 0); /*--- Variable export code ---*/ if (__Pyx_ExportVoidPtr(__pyx_n_s_CLASS_TYPES, (void *)&__pyx_v_19dependency_injector_9providers_CLASS_TYPES, "PyObject *") < 0) __PYX_ERR(1, 1, __pyx_L1_error) + if (__Pyx_ExportVoidPtr(__pyx_n_s_has_isawaitable, (void *)&__pyx_v_19dependency_injector_9providers___has_isawaitable, "int") < 0) __PYX_ERR(1, 1, __pyx_L1_error) __Pyx_RefNannyFinishContext(); return 0; __pyx_L1_error:; @@ -91204,7 +102413,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_vtabptr_19dependency_injector_9providers_Provider = &__pyx_vtable_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_Provider._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_8Provider__provide; __pyx_vtable_19dependency_injector_9providers_Provider._copy_overridings = (void (*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_8Provider__copy_overridings; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Provider) < 0) __PYX_ERR(1, 91, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Provider) < 0) __PYX_ERR(1, 97, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Provider.tp_print = 0; #endif @@ -91213,7 +102422,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Provider, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 91, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Provider, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 97, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Provider___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Provider___init__.doc = __pyx_doc_19dependency_injector_9providers_8Provider___init__; @@ -91223,7 +102432,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Provider, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 91, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Provider, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 97, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Provider_2__call__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Provider_2__call__.doc = __pyx_doc_19dependency_injector_9providers_8Provider_2__call__; @@ -91233,7 +102442,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Provider, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 91, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Provider, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 97, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Provider_8__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Provider_8__str__.doc = __pyx_doc_19dependency_injector_9providers_8Provider_8__str__; @@ -91243,7 +102452,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Provider, "__repr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 91, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Provider, "__repr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 97, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Provider_10__repr__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Provider_10__repr__.doc = __pyx_doc_19dependency_injector_9providers_8Provider_10__repr__; @@ -91251,15 +102460,15 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Provider.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Provider) < 0) __PYX_ERR(1, 91, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Provider, (PyObject *)&__pyx_type_19dependency_injector_9providers_Provider) < 0) __PYX_ERR(1, 91, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Provider) < 0) __PYX_ERR(1, 91, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Provider.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Provider) < 0) __PYX_ERR(1, 97, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Provider, (PyObject *)&__pyx_type_19dependency_injector_9providers_Provider) < 0) __PYX_ERR(1, 97, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Provider) < 0) __PYX_ERR(1, 97, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Provider = &__pyx_type_19dependency_injector_9providers_Provider; __pyx_vtabptr_19dependency_injector_9providers_Object = &__pyx_vtable_19dependency_injector_9providers_Object; __pyx_vtable_19dependency_injector_9providers_Object.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_Object.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_6Object__provide; __pyx_type_19dependency_injector_9providers_Object.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Object) < 0) __PYX_ERR(1, 297, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Object) < 0) __PYX_ERR(1, 364, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Object.tp_print = 0; #endif @@ -91268,7 +102477,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Object, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 297, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Object, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 364, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_6Object___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_6Object___init__.doc = __pyx_doc_19dependency_injector_9providers_6Object___init__; @@ -91278,7 +102487,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Object, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 297, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Object, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 364, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_6Object_4__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_6Object_4__str__.doc = __pyx_doc_19dependency_injector_9providers_6Object_4__str__; @@ -91288,7 +102497,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Object, "__repr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 297, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Object, "__repr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 364, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_6Object_6__repr__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_6Object_6__repr__.doc = __pyx_doc_19dependency_injector_9providers_6Object_6__repr__; @@ -91296,15 +102505,15 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Object.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Object) < 0) __PYX_ERR(1, 297, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Object, (PyObject *)&__pyx_type_19dependency_injector_9providers_Object) < 0) __PYX_ERR(1, 297, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Object) < 0) __PYX_ERR(1, 297, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Object.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Object) < 0) __PYX_ERR(1, 364, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Object, (PyObject *)&__pyx_type_19dependency_injector_9providers_Object) < 0) __PYX_ERR(1, 364, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Object) < 0) __PYX_ERR(1, 364, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Object = &__pyx_type_19dependency_injector_9providers_Object; __pyx_vtabptr_19dependency_injector_9providers_Delegate = &__pyx_vtable_19dependency_injector_9providers_Delegate; __pyx_vtable_19dependency_injector_9providers_Delegate.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_Delegate.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_8Delegate__provide; __pyx_type_19dependency_injector_9providers_Delegate.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Delegate) < 0) __PYX_ERR(1, 356, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Delegate) < 0) __PYX_ERR(1, 423, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Delegate.tp_print = 0; #endif @@ -91313,7 +102522,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Delegate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 356, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Delegate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 423, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Delegate___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Delegate___init__.doc = __pyx_doc_19dependency_injector_9providers_8Delegate___init__; @@ -91323,7 +102532,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Delegate, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 356, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Delegate, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 423, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Delegate_4__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Delegate_4__str__.doc = __pyx_doc_19dependency_injector_9providers_8Delegate_4__str__; @@ -91333,7 +102542,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Delegate, "__repr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 356, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Delegate, "__repr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 423, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Delegate_6__repr__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Delegate_6__repr__.doc = __pyx_doc_19dependency_injector_9providers_8Delegate_6__repr__; @@ -91341,14 +102550,14 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Delegate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Delegate) < 0) __PYX_ERR(1, 356, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Delegate, (PyObject *)&__pyx_type_19dependency_injector_9providers_Delegate) < 0) __PYX_ERR(1, 356, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Delegate) < 0) __PYX_ERR(1, 356, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Delegate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Delegate) < 0) __PYX_ERR(1, 423, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Delegate, (PyObject *)&__pyx_type_19dependency_injector_9providers_Delegate) < 0) __PYX_ERR(1, 423, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Delegate) < 0) __PYX_ERR(1, 423, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Delegate = &__pyx_type_19dependency_injector_9providers_Delegate; __pyx_vtabptr_19dependency_injector_9providers_Dependency = &__pyx_vtable_19dependency_injector_9providers_Dependency; __pyx_vtable_19dependency_injector_9providers_Dependency.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_type_19dependency_injector_9providers_Dependency.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Dependency) < 0) __PYX_ERR(1, 420, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Dependency) < 0) __PYX_ERR(1, 487, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Dependency.tp_print = 0; #endif @@ -91357,7 +102566,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dependency, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 420, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dependency, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 487, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_10Dependency___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_10Dependency___init__.doc = __pyx_doc_19dependency_injector_9providers_10Dependency___init__; @@ -91367,7 +102576,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dependency, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 420, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dependency, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 487, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_10Dependency_4__call__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_10Dependency_4__call__.doc = __pyx_doc_19dependency_injector_9providers_10Dependency_4__call__; @@ -91377,7 +102586,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dependency, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 420, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dependency, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 487, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_10Dependency_6__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_10Dependency_6__str__.doc = __pyx_doc_19dependency_injector_9providers_10Dependency_6__str__; @@ -91387,7 +102596,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dependency, "__repr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 420, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dependency, "__repr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 487, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_10Dependency_8__repr__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_10Dependency_8__repr__.doc = __pyx_doc_19dependency_injector_9providers_10Dependency_8__repr__; @@ -91395,35 +102604,35 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Dependency.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Dependency) < 0) __PYX_ERR(1, 420, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Dependency, (PyObject *)&__pyx_type_19dependency_injector_9providers_Dependency) < 0) __PYX_ERR(1, 420, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Dependency) < 0) __PYX_ERR(1, 420, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Dependency.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Dependency) < 0) __PYX_ERR(1, 487, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Dependency, (PyObject *)&__pyx_type_19dependency_injector_9providers_Dependency) < 0) __PYX_ERR(1, 487, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Dependency) < 0) __PYX_ERR(1, 487, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Dependency = &__pyx_type_19dependency_injector_9providers_Dependency; __pyx_vtabptr_19dependency_injector_9providers_ExternalDependency = &__pyx_vtable_19dependency_injector_9providers_ExternalDependency; __pyx_vtable_19dependency_injector_9providers_ExternalDependency.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Dependency; __pyx_type_19dependency_injector_9providers_ExternalDependency.tp_base = __pyx_ptype_19dependency_injector_9providers_Dependency; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ExternalDependency) < 0) __PYX_ERR(1, 518, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ExternalDependency) < 0) __PYX_ERR(1, 618, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_ExternalDependency.tp_print = 0; #endif if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_19dependency_injector_9providers_ExternalDependency.tp_dictoffset && __pyx_type_19dependency_injector_9providers_ExternalDependency.tp_getattro == PyObject_GenericGetAttr)) { __pyx_type_19dependency_injector_9providers_ExternalDependency.tp_getattro = __Pyx_PyObject_GenericGetAttr; } - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ExternalDependency.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ExternalDependency) < 0) __PYX_ERR(1, 518, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ExternalDependency, (PyObject *)&__pyx_type_19dependency_injector_9providers_ExternalDependency) < 0) __PYX_ERR(1, 518, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ExternalDependency) < 0) __PYX_ERR(1, 518, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ExternalDependency.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ExternalDependency) < 0) __PYX_ERR(1, 618, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ExternalDependency, (PyObject *)&__pyx_type_19dependency_injector_9providers_ExternalDependency) < 0) __PYX_ERR(1, 618, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ExternalDependency) < 0) __PYX_ERR(1, 618, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ExternalDependency = &__pyx_type_19dependency_injector_9providers_ExternalDependency; __pyx_vtabptr_19dependency_injector_9providers_DependenciesContainer = &__pyx_vtable_19dependency_injector_9providers_DependenciesContainer; __pyx_vtable_19dependency_injector_9providers_DependenciesContainer.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Object; __pyx_vtable_19dependency_injector_9providers_DependenciesContainer._override_providers = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_DependenciesContainer *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_21DependenciesContainer__override_providers; __pyx_type_19dependency_injector_9providers_DependenciesContainer.tp_base = __pyx_ptype_19dependency_injector_9providers_Object; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DependenciesContainer) < 0) __PYX_ERR(1, 546, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DependenciesContainer) < 0) __PYX_ERR(1, 646, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_DependenciesContainer.tp_print = 0; #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_DependenciesContainer, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 546, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_DependenciesContainer, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 646, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_21DependenciesContainer___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_21DependenciesContainer___init__.doc = __pyx_doc_19dependency_injector_9providers_21DependenciesContainer___init__; @@ -91433,7 +102642,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_DependenciesContainer, "__getattr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 546, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_DependenciesContainer, "__getattr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 646, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_21DependenciesContainer_4__getattr__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_21DependenciesContainer_4__getattr__.doc = __pyx_doc_19dependency_injector_9providers_21DependenciesContainer_4__getattr__; @@ -91441,11 +102650,11 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DependenciesContainer.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DependenciesContainer) < 0) __PYX_ERR(1, 546, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DependenciesContainer, (PyObject *)&__pyx_type_19dependency_injector_9providers_DependenciesContainer) < 0) __PYX_ERR(1, 546, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DependenciesContainer) < 0) __PYX_ERR(1, 546, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DependenciesContainer.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DependenciesContainer) < 0) __PYX_ERR(1, 646, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DependenciesContainer, (PyObject *)&__pyx_type_19dependency_injector_9providers_DependenciesContainer) < 0) __PYX_ERR(1, 646, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DependenciesContainer) < 0) __PYX_ERR(1, 646, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DependenciesContainer = &__pyx_type_19dependency_injector_9providers_DependenciesContainer; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_OverridingContext) < 0) __PYX_ERR(1, 679, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_OverridingContext) < 0) __PYX_ERR(1, 779, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_OverridingContext.tp_print = 0; #endif @@ -91454,7 +102663,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_OverridingContext, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 679, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_OverridingContext, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 779, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_17OverridingContext___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_17OverridingContext___init__.doc = __pyx_doc_19dependency_injector_9providers_17OverridingContext___init__; @@ -91462,14 +102671,14 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_OverridingContext, (PyObject *)&__pyx_type_19dependency_injector_9providers_OverridingContext) < 0) __PYX_ERR(1, 679, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_OverridingContext) < 0) __PYX_ERR(1, 679, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_OverridingContext, (PyObject *)&__pyx_type_19dependency_injector_9providers_OverridingContext) < 0) __PYX_ERR(1, 779, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_OverridingContext) < 0) __PYX_ERR(1, 779, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_OverridingContext = &__pyx_type_19dependency_injector_9providers_OverridingContext; __pyx_vtabptr_19dependency_injector_9providers_Callable = &__pyx_vtable_19dependency_injector_9providers_Callable; __pyx_vtable_19dependency_injector_9providers_Callable.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_Callable.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_8Callable__provide; __pyx_type_19dependency_injector_9providers_Callable.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Callable) < 0) __PYX_ERR(1, 715, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Callable) < 0) __PYX_ERR(1, 815, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Callable.tp_print = 0; #endif @@ -91478,7 +102687,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Callable, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 715, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Callable, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 815, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Callable___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Callable___init__.doc = __pyx_doc_19dependency_injector_9providers_8Callable___init__; @@ -91488,7 +102697,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Callable, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 715, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Callable, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 815, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Callable_4__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Callable_4__str__.doc = __pyx_doc_19dependency_injector_9providers_8Callable_4__str__; @@ -91496,29 +102705,29 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Callable.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Callable) < 0) __PYX_ERR(1, 715, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Callable, (PyObject *)&__pyx_type_19dependency_injector_9providers_Callable) < 0) __PYX_ERR(1, 715, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Callable) < 0) __PYX_ERR(1, 715, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Callable.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Callable) < 0) __PYX_ERR(1, 815, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Callable, (PyObject *)&__pyx_type_19dependency_injector_9providers_Callable) < 0) __PYX_ERR(1, 815, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Callable) < 0) __PYX_ERR(1, 815, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Callable = &__pyx_type_19dependency_injector_9providers_Callable; __pyx_vtabptr_19dependency_injector_9providers_DelegatedCallable = &__pyx_vtable_19dependency_injector_9providers_DelegatedCallable; __pyx_vtable_19dependency_injector_9providers_DelegatedCallable.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Callable; __pyx_type_19dependency_injector_9providers_DelegatedCallable.tp_base = __pyx_ptype_19dependency_injector_9providers_Callable; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedCallable) < 0) __PYX_ERR(1, 881, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedCallable) < 0) __PYX_ERR(1, 981, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_DelegatedCallable.tp_print = 0; #endif if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_19dependency_injector_9providers_DelegatedCallable.tp_dictoffset && __pyx_type_19dependency_injector_9providers_DelegatedCallable.tp_getattro == PyObject_GenericGetAttr)) { __pyx_type_19dependency_injector_9providers_DelegatedCallable.tp_getattro = __Pyx_PyObject_GenericGetAttr; } - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedCallable.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedCallable) < 0) __PYX_ERR(1, 881, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedCallable, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedCallable) < 0) __PYX_ERR(1, 881, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedCallable) < 0) __PYX_ERR(1, 881, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedCallable.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedCallable) < 0) __PYX_ERR(1, 981, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedCallable, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedCallable) < 0) __PYX_ERR(1, 981, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedCallable) < 0) __PYX_ERR(1, 981, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedCallable = &__pyx_type_19dependency_injector_9providers_DelegatedCallable; __pyx_vtabptr_19dependency_injector_9providers_AbstractCallable = &__pyx_vtable_19dependency_injector_9providers_AbstractCallable; __pyx_vtable_19dependency_injector_9providers_AbstractCallable.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Callable; __pyx_vtable_19dependency_injector_9providers_AbstractCallable.__pyx_base.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_16AbstractCallable__provide; __pyx_type_19dependency_injector_9providers_AbstractCallable.tp_base = __pyx_ptype_19dependency_injector_9providers_Callable; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_AbstractCallable) < 0) __PYX_ERR(1, 890, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_AbstractCallable) < 0) __PYX_ERR(1, 990, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_AbstractCallable.tp_print = 0; #endif @@ -91527,7 +102736,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractCallable, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 890, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractCallable, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 990, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_16AbstractCallable___call__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_16AbstractCallable___call__.doc = __pyx_doc_19dependency_injector_9providers_16AbstractCallable___call__; @@ -91535,14 +102744,14 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_AbstractCallable.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_AbstractCallable) < 0) __PYX_ERR(1, 890, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AbstractCallable, (PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractCallable) < 0) __PYX_ERR(1, 890, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_AbstractCallable) < 0) __PYX_ERR(1, 890, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_AbstractCallable.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_AbstractCallable) < 0) __PYX_ERR(1, 990, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AbstractCallable, (PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractCallable) < 0) __PYX_ERR(1, 990, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_AbstractCallable) < 0) __PYX_ERR(1, 990, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_AbstractCallable = &__pyx_type_19dependency_injector_9providers_AbstractCallable; __pyx_vtabptr_19dependency_injector_9providers_CallableDelegate = &__pyx_vtable_19dependency_injector_9providers_CallableDelegate; __pyx_vtable_19dependency_injector_9providers_CallableDelegate.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Delegate; __pyx_type_19dependency_injector_9providers_CallableDelegate.tp_base = __pyx_ptype_19dependency_injector_9providers_Delegate; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_CallableDelegate) < 0) __PYX_ERR(1, 931, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_CallableDelegate) < 0) __PYX_ERR(1, 1031, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_CallableDelegate.tp_print = 0; #endif @@ -91551,7 +102760,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_CallableDelegate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 931, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_CallableDelegate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1031, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_16CallableDelegate___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_16CallableDelegate___init__.doc = __pyx_doc_19dependency_injector_9providers_16CallableDelegate___init__; @@ -91559,14 +102768,14 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_CallableDelegate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_CallableDelegate) < 0) __PYX_ERR(1, 931, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_CallableDelegate, (PyObject *)&__pyx_type_19dependency_injector_9providers_CallableDelegate) < 0) __PYX_ERR(1, 931, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_CallableDelegate) < 0) __PYX_ERR(1, 931, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_CallableDelegate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_CallableDelegate) < 0) __PYX_ERR(1, 1031, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_CallableDelegate, (PyObject *)&__pyx_type_19dependency_injector_9providers_CallableDelegate) < 0) __PYX_ERR(1, 1031, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_CallableDelegate) < 0) __PYX_ERR(1, 1031, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_CallableDelegate = &__pyx_type_19dependency_injector_9providers_CallableDelegate; __pyx_vtabptr_19dependency_injector_9providers_Coroutine = &__pyx_vtable_19dependency_injector_9providers_Coroutine; __pyx_vtable_19dependency_injector_9providers_Coroutine.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Callable; __pyx_type_19dependency_injector_9providers_Coroutine.tp_base = __pyx_ptype_19dependency_injector_9providers_Callable; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Coroutine) < 0) __PYX_ERR(1, 953, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Coroutine) < 0) __PYX_ERR(1, 1053, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Coroutine.tp_print = 0; #endif @@ -91575,7 +102784,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Coroutine, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 953, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Coroutine, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1053, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_9Coroutine___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_9Coroutine___init__.doc = __pyx_doc_19dependency_injector_9providers_9Coroutine___init__; @@ -91583,29 +102792,29 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Coroutine.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Coroutine) < 0) __PYX_ERR(1, 953, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Coroutine, (PyObject *)&__pyx_type_19dependency_injector_9providers_Coroutine) < 0) __PYX_ERR(1, 953, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Coroutine) < 0) __PYX_ERR(1, 953, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Coroutine.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Coroutine) < 0) __PYX_ERR(1, 1053, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Coroutine, (PyObject *)&__pyx_type_19dependency_injector_9providers_Coroutine) < 0) __PYX_ERR(1, 1053, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Coroutine) < 0) __PYX_ERR(1, 1053, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Coroutine = &__pyx_type_19dependency_injector_9providers_Coroutine; __pyx_vtabptr_19dependency_injector_9providers_DelegatedCoroutine = &__pyx_vtable_19dependency_injector_9providers_DelegatedCoroutine; __pyx_vtable_19dependency_injector_9providers_DelegatedCoroutine.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Coroutine; __pyx_type_19dependency_injector_9providers_DelegatedCoroutine.tp_base = __pyx_ptype_19dependency_injector_9providers_Coroutine; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedCoroutine) < 0) __PYX_ERR(1, 997, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedCoroutine) < 0) __PYX_ERR(1, 1097, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_DelegatedCoroutine.tp_print = 0; #endif if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_19dependency_injector_9providers_DelegatedCoroutine.tp_dictoffset && __pyx_type_19dependency_injector_9providers_DelegatedCoroutine.tp_getattro == PyObject_GenericGetAttr)) { __pyx_type_19dependency_injector_9providers_DelegatedCoroutine.tp_getattro = __Pyx_PyObject_GenericGetAttr; } - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedCoroutine.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedCoroutine) < 0) __PYX_ERR(1, 997, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedCoroutine, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedCoroutine) < 0) __PYX_ERR(1, 997, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedCoroutine) < 0) __PYX_ERR(1, 997, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedCoroutine.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedCoroutine) < 0) __PYX_ERR(1, 1097, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedCoroutine, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedCoroutine) < 0) __PYX_ERR(1, 1097, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedCoroutine) < 0) __PYX_ERR(1, 1097, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedCoroutine = &__pyx_type_19dependency_injector_9providers_DelegatedCoroutine; __pyx_vtabptr_19dependency_injector_9providers_AbstractCoroutine = &__pyx_vtable_19dependency_injector_9providers_AbstractCoroutine; __pyx_vtable_19dependency_injector_9providers_AbstractCoroutine.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Coroutine; __pyx_vtable_19dependency_injector_9providers_AbstractCoroutine.__pyx_base.__pyx_base.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_17AbstractCoroutine__provide; __pyx_type_19dependency_injector_9providers_AbstractCoroutine.tp_base = __pyx_ptype_19dependency_injector_9providers_Coroutine; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_AbstractCoroutine) < 0) __PYX_ERR(1, 1006, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_AbstractCoroutine) < 0) __PYX_ERR(1, 1106, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_AbstractCoroutine.tp_print = 0; #endif @@ -91614,7 +102823,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractCoroutine, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1006, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractCoroutine, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1106, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_17AbstractCoroutine___call__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_17AbstractCoroutine___call__.doc = __pyx_doc_19dependency_injector_9providers_17AbstractCoroutine___call__; @@ -91622,14 +102831,14 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_AbstractCoroutine.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_AbstractCoroutine) < 0) __PYX_ERR(1, 1006, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AbstractCoroutine, (PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractCoroutine) < 0) __PYX_ERR(1, 1006, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_AbstractCoroutine) < 0) __PYX_ERR(1, 1006, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_AbstractCoroutine.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_AbstractCoroutine) < 0) __PYX_ERR(1, 1106, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AbstractCoroutine, (PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractCoroutine) < 0) __PYX_ERR(1, 1106, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_AbstractCoroutine) < 0) __PYX_ERR(1, 1106, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_AbstractCoroutine = &__pyx_type_19dependency_injector_9providers_AbstractCoroutine; __pyx_vtabptr_19dependency_injector_9providers_CoroutineDelegate = &__pyx_vtable_19dependency_injector_9providers_CoroutineDelegate; __pyx_vtable_19dependency_injector_9providers_CoroutineDelegate.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Delegate; __pyx_type_19dependency_injector_9providers_CoroutineDelegate.tp_base = __pyx_ptype_19dependency_injector_9providers_Delegate; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_CoroutineDelegate) < 0) __PYX_ERR(1, 1047, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_CoroutineDelegate) < 0) __PYX_ERR(1, 1147, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_CoroutineDelegate.tp_print = 0; #endif @@ -91638,7 +102847,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_CoroutineDelegate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1047, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_CoroutineDelegate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1147, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_17CoroutineDelegate___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_17CoroutineDelegate___init__.doc = __pyx_doc_19dependency_injector_9providers_17CoroutineDelegate___init__; @@ -91646,53 +102855,53 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_CoroutineDelegate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_CoroutineDelegate) < 0) __PYX_ERR(1, 1047, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_CoroutineDelegate, (PyObject *)&__pyx_type_19dependency_injector_9providers_CoroutineDelegate) < 0) __PYX_ERR(1, 1047, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_CoroutineDelegate) < 0) __PYX_ERR(1, 1047, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_CoroutineDelegate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_CoroutineDelegate) < 0) __PYX_ERR(1, 1147, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_CoroutineDelegate, (PyObject *)&__pyx_type_19dependency_injector_9providers_CoroutineDelegate) < 0) __PYX_ERR(1, 1147, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_CoroutineDelegate) < 0) __PYX_ERR(1, 1147, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_CoroutineDelegate = &__pyx_type_19dependency_injector_9providers_CoroutineDelegate; __pyx_vtabptr_19dependency_injector_9providers_ConfigurationOption = &__pyx_vtable_19dependency_injector_9providers_ConfigurationOption; __pyx_vtable_19dependency_injector_9providers_ConfigurationOption.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_ConfigurationOption.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_19ConfigurationOption__provide; __pyx_type_19dependency_injector_9providers_ConfigurationOption.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ConfigurationOption) < 0) __PYX_ERR(1, 1069, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ConfigurationOption) < 0) __PYX_ERR(1, 1169, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_ConfigurationOption.tp_print = 0; #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ConfigurationOption.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ConfigurationOption) < 0) __PYX_ERR(1, 1069, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ConfigurationOption, (PyObject *)&__pyx_type_19dependency_injector_9providers_ConfigurationOption) < 0) __PYX_ERR(1, 1069, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ConfigurationOption) < 0) __PYX_ERR(1, 1069, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ConfigurationOption.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ConfigurationOption) < 0) __PYX_ERR(1, 1169, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ConfigurationOption, (PyObject *)&__pyx_type_19dependency_injector_9providers_ConfigurationOption) < 0) __PYX_ERR(1, 1169, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ConfigurationOption) < 0) __PYX_ERR(1, 1169, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ConfigurationOption = &__pyx_type_19dependency_injector_9providers_ConfigurationOption; __pyx_vtabptr_19dependency_injector_9providers_TypedConfigurationOption = &__pyx_vtable_19dependency_injector_9providers_TypedConfigurationOption; __pyx_vtable_19dependency_injector_9providers_TypedConfigurationOption.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Callable; __pyx_type_19dependency_injector_9providers_TypedConfigurationOption.tp_base = __pyx_ptype_19dependency_injector_9providers_Callable; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_TypedConfigurationOption) < 0) __PYX_ERR(1, 1274, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_TypedConfigurationOption) < 0) __PYX_ERR(1, 1374, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_TypedConfigurationOption.tp_print = 0; #endif if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_19dependency_injector_9providers_TypedConfigurationOption.tp_dictoffset && __pyx_type_19dependency_injector_9providers_TypedConfigurationOption.tp_getattro == PyObject_GenericGetAttr)) { __pyx_type_19dependency_injector_9providers_TypedConfigurationOption.tp_getattro = __Pyx_PyObject_GenericGetAttr; } - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_TypedConfigurationOption.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_TypedConfigurationOption) < 0) __PYX_ERR(1, 1274, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_TypedConfigurationOption, (PyObject *)&__pyx_type_19dependency_injector_9providers_TypedConfigurationOption) < 0) __PYX_ERR(1, 1274, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_TypedConfigurationOption) < 0) __PYX_ERR(1, 1274, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_TypedConfigurationOption.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_TypedConfigurationOption) < 0) __PYX_ERR(1, 1374, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_TypedConfigurationOption, (PyObject *)&__pyx_type_19dependency_injector_9providers_TypedConfigurationOption) < 0) __PYX_ERR(1, 1374, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_TypedConfigurationOption) < 0) __PYX_ERR(1, 1374, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_TypedConfigurationOption = &__pyx_type_19dependency_injector_9providers_TypedConfigurationOption; __pyx_vtabptr_19dependency_injector_9providers_Configuration = &__pyx_vtable_19dependency_injector_9providers_Configuration; __pyx_vtable_19dependency_injector_9providers_Configuration.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Object; __pyx_type_19dependency_injector_9providers_Configuration.tp_base = __pyx_ptype_19dependency_injector_9providers_Object; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Configuration) < 0) __PYX_ERR(1, 1281, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Configuration) < 0) __PYX_ERR(1, 1381, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Configuration.tp_print = 0; #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Configuration.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Configuration) < 0) __PYX_ERR(1, 1281, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Configuration, (PyObject *)&__pyx_type_19dependency_injector_9providers_Configuration) < 0) __PYX_ERR(1, 1281, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Configuration.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Configuration) < 0) __PYX_ERR(1, 1381, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Configuration, (PyObject *)&__pyx_type_19dependency_injector_9providers_Configuration) < 0) __PYX_ERR(1, 1381, __pyx_L1_error) if (__pyx_type_19dependency_injector_9providers_Configuration.tp_weaklistoffset == 0) __pyx_type_19dependency_injector_9providers_Configuration.tp_weaklistoffset = offsetof(struct __pyx_obj_19dependency_injector_9providers_Configuration, __weakref__); - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Configuration) < 0) __PYX_ERR(1, 1281, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Configuration) < 0) __PYX_ERR(1, 1381, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Configuration = &__pyx_type_19dependency_injector_9providers_Configuration; __pyx_vtabptr_19dependency_injector_9providers_Factory = &__pyx_vtable_19dependency_injector_9providers_Factory; __pyx_vtable_19dependency_injector_9providers_Factory.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_Factory.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_7Factory__provide; __pyx_type_19dependency_injector_9providers_Factory.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Factory) < 0) __PYX_ERR(1, 1537, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Factory) < 0) __PYX_ERR(1, 1637, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Factory.tp_print = 0; #endif @@ -91701,7 +102910,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Factory, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1537, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Factory, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1637, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_7Factory___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_7Factory___init__.doc = __pyx_doc_19dependency_injector_9providers_7Factory___init__; @@ -91711,7 +102920,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Factory, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1537, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Factory, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1637, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_7Factory_4__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_7Factory_4__str__.doc = __pyx_doc_19dependency_injector_9providers_7Factory_4__str__; @@ -91719,29 +102928,29 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Factory.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Factory) < 0) __PYX_ERR(1, 1537, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Factory, (PyObject *)&__pyx_type_19dependency_injector_9providers_Factory) < 0) __PYX_ERR(1, 1537, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Factory) < 0) __PYX_ERR(1, 1537, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Factory.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Factory) < 0) __PYX_ERR(1, 1637, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Factory, (PyObject *)&__pyx_type_19dependency_injector_9providers_Factory) < 0) __PYX_ERR(1, 1637, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Factory) < 0) __PYX_ERR(1, 1637, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Factory = &__pyx_type_19dependency_injector_9providers_Factory; __pyx_vtabptr_19dependency_injector_9providers_DelegatedFactory = &__pyx_vtable_19dependency_injector_9providers_DelegatedFactory; __pyx_vtable_19dependency_injector_9providers_DelegatedFactory.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Factory; __pyx_type_19dependency_injector_9providers_DelegatedFactory.tp_base = __pyx_ptype_19dependency_injector_9providers_Factory; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedFactory) < 0) __PYX_ERR(1, 1754, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedFactory) < 0) __PYX_ERR(1, 1854, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_DelegatedFactory.tp_print = 0; #endif if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_19dependency_injector_9providers_DelegatedFactory.tp_dictoffset && __pyx_type_19dependency_injector_9providers_DelegatedFactory.tp_getattro == PyObject_GenericGetAttr)) { __pyx_type_19dependency_injector_9providers_DelegatedFactory.tp_getattro = __Pyx_PyObject_GenericGetAttr; } - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedFactory.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedFactory) < 0) __PYX_ERR(1, 1754, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedFactory, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedFactory) < 0) __PYX_ERR(1, 1754, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedFactory) < 0) __PYX_ERR(1, 1754, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedFactory.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedFactory) < 0) __PYX_ERR(1, 1854, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedFactory, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedFactory) < 0) __PYX_ERR(1, 1854, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedFactory) < 0) __PYX_ERR(1, 1854, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedFactory = &__pyx_type_19dependency_injector_9providers_DelegatedFactory; __pyx_vtabptr_19dependency_injector_9providers_AbstractFactory = &__pyx_vtable_19dependency_injector_9providers_AbstractFactory; __pyx_vtable_19dependency_injector_9providers_AbstractFactory.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Factory; __pyx_vtable_19dependency_injector_9providers_AbstractFactory.__pyx_base.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_15AbstractFactory__provide; __pyx_type_19dependency_injector_9providers_AbstractFactory.tp_base = __pyx_ptype_19dependency_injector_9providers_Factory; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_AbstractFactory) < 0) __PYX_ERR(1, 1776, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_AbstractFactory) < 0) __PYX_ERR(1, 1876, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_AbstractFactory.tp_print = 0; #endif @@ -91750,7 +102959,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractFactory, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1776, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractFactory, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1876, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_15AbstractFactory___call__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_15AbstractFactory___call__.doc = __pyx_doc_19dependency_injector_9providers_15AbstractFactory___call__; @@ -91758,14 +102967,14 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_AbstractFactory.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_AbstractFactory) < 0) __PYX_ERR(1, 1776, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AbstractFactory, (PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractFactory) < 0) __PYX_ERR(1, 1776, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_AbstractFactory) < 0) __PYX_ERR(1, 1776, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_AbstractFactory.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_AbstractFactory) < 0) __PYX_ERR(1, 1876, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AbstractFactory, (PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractFactory) < 0) __PYX_ERR(1, 1876, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_AbstractFactory) < 0) __PYX_ERR(1, 1876, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_AbstractFactory = &__pyx_type_19dependency_injector_9providers_AbstractFactory; __pyx_vtabptr_19dependency_injector_9providers_FactoryDelegate = &__pyx_vtable_19dependency_injector_9providers_FactoryDelegate; __pyx_vtable_19dependency_injector_9providers_FactoryDelegate.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Delegate; __pyx_type_19dependency_injector_9providers_FactoryDelegate.tp_base = __pyx_ptype_19dependency_injector_9providers_Delegate; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_FactoryDelegate) < 0) __PYX_ERR(1, 1817, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_FactoryDelegate) < 0) __PYX_ERR(1, 1917, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_FactoryDelegate.tp_print = 0; #endif @@ -91774,7 +102983,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryDelegate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1817, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryDelegate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1917, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_15FactoryDelegate___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_15FactoryDelegate___init__.doc = __pyx_doc_19dependency_injector_9providers_15FactoryDelegate___init__; @@ -91782,21 +102991,22 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_FactoryDelegate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_FactoryDelegate) < 0) __PYX_ERR(1, 1817, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_FactoryDelegate, (PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryDelegate) < 0) __PYX_ERR(1, 1817, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_FactoryDelegate) < 0) __PYX_ERR(1, 1817, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_FactoryDelegate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_FactoryDelegate) < 0) __PYX_ERR(1, 1917, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_FactoryDelegate, (PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryDelegate) < 0) __PYX_ERR(1, 1917, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_FactoryDelegate) < 0) __PYX_ERR(1, 1917, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_FactoryDelegate = &__pyx_type_19dependency_injector_9providers_FactoryDelegate; __pyx_vtabptr_19dependency_injector_9providers_FactoryAggregate = &__pyx_vtable_19dependency_injector_9providers_FactoryAggregate; __pyx_vtable_19dependency_injector_9providers_FactoryAggregate.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; + __pyx_vtable_19dependency_injector_9providers_FactoryAggregate.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_16FactoryAggregate__provide; __pyx_vtable_19dependency_injector_9providers_FactoryAggregate.__pyx___get_factory = (struct __pyx_obj_19dependency_injector_9providers_Factory *(*)(struct __pyx_obj_19dependency_injector_9providers_FactoryAggregate *, PyObject *))__pyx_f_19dependency_injector_9providers_16FactoryAggregate___get_factory; __pyx_type_19dependency_injector_9providers_FactoryAggregate.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_FactoryAggregate) < 0) __PYX_ERR(1, 1839, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_FactoryAggregate) < 0) __PYX_ERR(1, 1939, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_FactoryAggregate.tp_print = 0; #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryAggregate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1839, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryAggregate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1939, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate___init__.doc = __pyx_doc_19dependency_injector_9providers_16FactoryAggregate___init__; @@ -91806,42 +103016,32 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryAggregate, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1839, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryAggregate, "__getattr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1939, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { - __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_4__call__ = *((PyWrapperDescrObject *)wrapper)->d_base; - __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_4__call__.doc = __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_4__call__; - ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_4__call__; + __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_4__getattr__ = *((PyWrapperDescrObject *)wrapper)->d_base; + __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_4__getattr__.doc = __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_4__getattr__; + ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_4__getattr__; } } #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryAggregate, "__getattr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1839, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryAggregate, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1939, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { - __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_6__getattr__ = *((PyWrapperDescrObject *)wrapper)->d_base; - __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_6__getattr__.doc = __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_6__getattr__; - ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_6__getattr__; + __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_6__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; + __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_6__str__.doc = __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_6__str__; + ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_6__str__; } } #endif - #if CYTHON_COMPILING_IN_CPYTHON - { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryAggregate, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1839, __pyx_L1_error) - if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { - __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_8__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; - __pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_8__str__.doc = __pyx_doc_19dependency_injector_9providers_16FactoryAggregate_8__str__; - ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_19dependency_injector_9providers_16FactoryAggregate_8__str__; - } - } - #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_FactoryAggregate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_FactoryAggregate) < 0) __PYX_ERR(1, 1839, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_FactoryAggregate, (PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryAggregate) < 0) __PYX_ERR(1, 1839, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_FactoryAggregate) < 0) __PYX_ERR(1, 1839, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_FactoryAggregate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_FactoryAggregate) < 0) __PYX_ERR(1, 1939, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_FactoryAggregate, (PyObject *)&__pyx_type_19dependency_injector_9providers_FactoryAggregate) < 0) __PYX_ERR(1, 1939, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_FactoryAggregate) < 0) __PYX_ERR(1, 1939, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_FactoryAggregate = &__pyx_type_19dependency_injector_9providers_FactoryAggregate; __pyx_vtabptr_19dependency_injector_9providers_BaseSingleton = &__pyx_vtable_19dependency_injector_9providers_BaseSingleton; __pyx_vtable_19dependency_injector_9providers_BaseSingleton.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_type_19dependency_injector_9providers_BaseSingleton.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_BaseSingleton) < 0) __PYX_ERR(1, 1926, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_BaseSingleton) < 0) __PYX_ERR(1, 2032, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_BaseSingleton.tp_print = 0; #endif @@ -91850,7 +103050,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_BaseSingleton, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1926, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_BaseSingleton, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2032, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_13BaseSingleton___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_13BaseSingleton___init__.doc = __pyx_doc_19dependency_injector_9providers_13BaseSingleton___init__; @@ -91860,7 +103060,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_BaseSingleton, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 1926, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_BaseSingleton, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2032, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_13BaseSingleton_2__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_13BaseSingleton_2__str__.doc = __pyx_doc_19dependency_injector_9providers_13BaseSingleton_2__str__; @@ -91868,15 +103068,15 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_BaseSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_BaseSingleton) < 0) __PYX_ERR(1, 1926, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_BaseSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_BaseSingleton) < 0) __PYX_ERR(1, 1926, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_BaseSingleton) < 0) __PYX_ERR(1, 1926, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_BaseSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_BaseSingleton) < 0) __PYX_ERR(1, 2032, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_BaseSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_BaseSingleton) < 0) __PYX_ERR(1, 2032, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_BaseSingleton) < 0) __PYX_ERR(1, 2032, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_BaseSingleton = &__pyx_type_19dependency_injector_9providers_BaseSingleton; __pyx_vtabptr_19dependency_injector_9providers_Singleton = &__pyx_vtable_19dependency_injector_9providers_Singleton; __pyx_vtable_19dependency_injector_9providers_Singleton.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_BaseSingleton; __pyx_vtable_19dependency_injector_9providers_Singleton.__pyx_base.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_9Singleton__provide; __pyx_type_19dependency_injector_9providers_Singleton.tp_base = __pyx_ptype_19dependency_injector_9providers_BaseSingleton; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Singleton) < 0) __PYX_ERR(1, 2079, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Singleton) < 0) __PYX_ERR(1, 2195, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Singleton.tp_print = 0; #endif @@ -91885,7 +103085,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Singleton, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2079, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Singleton, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2195, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_9Singleton___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_9Singleton___init__.doc = __pyx_doc_19dependency_injector_9providers_9Singleton___init__; @@ -91893,29 +103093,29 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Singleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Singleton) < 0) __PYX_ERR(1, 2079, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Singleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_Singleton) < 0) __PYX_ERR(1, 2079, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Singleton) < 0) __PYX_ERR(1, 2079, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Singleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Singleton) < 0) __PYX_ERR(1, 2195, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Singleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_Singleton) < 0) __PYX_ERR(1, 2195, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Singleton) < 0) __PYX_ERR(1, 2195, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Singleton = &__pyx_type_19dependency_injector_9providers_Singleton; __pyx_vtabptr_19dependency_injector_9providers_DelegatedSingleton = &__pyx_vtable_19dependency_injector_9providers_DelegatedSingleton; __pyx_vtable_19dependency_injector_9providers_DelegatedSingleton.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Singleton; __pyx_type_19dependency_injector_9providers_DelegatedSingleton.tp_base = __pyx_ptype_19dependency_injector_9providers_Singleton; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedSingleton) < 0) __PYX_ERR(1, 2135, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedSingleton) < 0) __PYX_ERR(1, 2262, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_DelegatedSingleton.tp_print = 0; #endif if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_19dependency_injector_9providers_DelegatedSingleton.tp_dictoffset && __pyx_type_19dependency_injector_9providers_DelegatedSingleton.tp_getattro == PyObject_GenericGetAttr)) { __pyx_type_19dependency_injector_9providers_DelegatedSingleton.tp_getattro = __Pyx_PyObject_GenericGetAttr; } - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedSingleton) < 0) __PYX_ERR(1, 2135, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedSingleton) < 0) __PYX_ERR(1, 2135, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedSingleton) < 0) __PYX_ERR(1, 2135, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedSingleton) < 0) __PYX_ERR(1, 2262, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedSingleton) < 0) __PYX_ERR(1, 2262, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedSingleton) < 0) __PYX_ERR(1, 2262, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedSingleton = &__pyx_type_19dependency_injector_9providers_DelegatedSingleton; __pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton = &__pyx_vtable_19dependency_injector_9providers_ThreadSafeSingleton; __pyx_vtable_19dependency_injector_9providers_ThreadSafeSingleton.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_BaseSingleton; __pyx_vtable_19dependency_injector_9providers_ThreadSafeSingleton.__pyx_base.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_19ThreadSafeSingleton__provide; __pyx_type_19dependency_injector_9providers_ThreadSafeSingleton.tp_base = __pyx_ptype_19dependency_injector_9providers_BaseSingleton; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton) < 0) __PYX_ERR(1, 2157, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton) < 0) __PYX_ERR(1, 2284, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_ThreadSafeSingleton.tp_print = 0; #endif @@ -91924,7 +103124,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2157, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2284, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_19ThreadSafeSingleton___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_19ThreadSafeSingleton___init__.doc = __pyx_doc_19dependency_injector_9providers_19ThreadSafeSingleton___init__; @@ -91932,29 +103132,29 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton) < 0) __PYX_ERR(1, 2157, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ThreadSafeSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton) < 0) __PYX_ERR(1, 2157, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton) < 0) __PYX_ERR(1, 2157, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton) < 0) __PYX_ERR(1, 2284, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ThreadSafeSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton) < 0) __PYX_ERR(1, 2284, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton) < 0) __PYX_ERR(1, 2284, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton = &__pyx_type_19dependency_injector_9providers_ThreadSafeSingleton; __pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadSafeSingleton = &__pyx_vtable_19dependency_injector_9providers_DelegatedThreadSafeSingleton; __pyx_vtable_19dependency_injector_9providers_DelegatedThreadSafeSingleton.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_ThreadSafeSingleton; __pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton.tp_base = __pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton) < 0) __PYX_ERR(1, 2196, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton) < 0) __PYX_ERR(1, 2335, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton.tp_print = 0; #endif if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton.tp_dictoffset && __pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton.tp_getattro == PyObject_GenericGetAttr)) { __pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton.tp_getattro = __Pyx_PyObject_GenericGetAttr; } - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadSafeSingleton) < 0) __PYX_ERR(1, 2196, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedThreadSafeSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton) < 0) __PYX_ERR(1, 2196, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton) < 0) __PYX_ERR(1, 2196, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadSafeSingleton) < 0) __PYX_ERR(1, 2335, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedThreadSafeSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton) < 0) __PYX_ERR(1, 2335, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton) < 0) __PYX_ERR(1, 2335, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedThreadSafeSingleton = &__pyx_type_19dependency_injector_9providers_DelegatedThreadSafeSingleton; __pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton = &__pyx_vtable_19dependency_injector_9providers_ThreadLocalSingleton; __pyx_vtable_19dependency_injector_9providers_ThreadLocalSingleton.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_BaseSingleton; __pyx_vtable_19dependency_injector_9providers_ThreadLocalSingleton.__pyx_base.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_20ThreadLocalSingleton__provide; __pyx_type_19dependency_injector_9providers_ThreadLocalSingleton.tp_base = __pyx_ptype_19dependency_injector_9providers_BaseSingleton; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton) < 0) __PYX_ERR(1, 2218, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton) < 0) __PYX_ERR(1, 2357, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_ThreadLocalSingleton.tp_print = 0; #endif @@ -91963,7 +103163,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2218, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2357, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_20ThreadLocalSingleton___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_20ThreadLocalSingleton___init__.doc = __pyx_doc_19dependency_injector_9providers_20ThreadLocalSingleton___init__; @@ -91971,28 +103171,28 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton) < 0) __PYX_ERR(1, 2218, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ThreadLocalSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton) < 0) __PYX_ERR(1, 2218, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton) < 0) __PYX_ERR(1, 2218, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton) < 0) __PYX_ERR(1, 2357, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ThreadLocalSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton) < 0) __PYX_ERR(1, 2357, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton) < 0) __PYX_ERR(1, 2357, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ThreadLocalSingleton = &__pyx_type_19dependency_injector_9providers_ThreadLocalSingleton; __pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadLocalSingleton = &__pyx_vtable_19dependency_injector_9providers_DelegatedThreadLocalSingleton; __pyx_vtable_19dependency_injector_9providers_DelegatedThreadLocalSingleton.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_ThreadLocalSingleton; __pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton.tp_base = __pyx_ptype_19dependency_injector_9providers_ThreadLocalSingleton; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton) < 0) __PYX_ERR(1, 2266, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton) < 0) __PYX_ERR(1, 2425, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton.tp_print = 0; #endif if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton.tp_dictoffset && __pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton.tp_getattro == PyObject_GenericGetAttr)) { __pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton.tp_getattro = __Pyx_PyObject_GenericGetAttr; } - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadLocalSingleton) < 0) __PYX_ERR(1, 2266, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedThreadLocalSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton) < 0) __PYX_ERR(1, 2266, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton) < 0) __PYX_ERR(1, 2266, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_DelegatedThreadLocalSingleton) < 0) __PYX_ERR(1, 2425, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_DelegatedThreadLocalSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton) < 0) __PYX_ERR(1, 2425, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton) < 0) __PYX_ERR(1, 2425, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_DelegatedThreadLocalSingleton = &__pyx_type_19dependency_injector_9providers_DelegatedThreadLocalSingleton; __pyx_vtabptr_19dependency_injector_9providers_AbstractSingleton = &__pyx_vtable_19dependency_injector_9providers_AbstractSingleton; __pyx_vtable_19dependency_injector_9providers_AbstractSingleton.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_BaseSingleton; __pyx_type_19dependency_injector_9providers_AbstractSingleton.tp_base = __pyx_ptype_19dependency_injector_9providers_BaseSingleton; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_AbstractSingleton) < 0) __PYX_ERR(1, 2288, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_AbstractSingleton) < 0) __PYX_ERR(1, 2447, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_AbstractSingleton.tp_print = 0; #endif @@ -92001,7 +103201,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractSingleton, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2288, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractSingleton, "__call__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2447, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_17AbstractSingleton___call__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_17AbstractSingleton___call__.doc = __pyx_doc_19dependency_injector_9providers_17AbstractSingleton___call__; @@ -92009,14 +103209,14 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_AbstractSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_AbstractSingleton) < 0) __PYX_ERR(1, 2288, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AbstractSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractSingleton) < 0) __PYX_ERR(1, 2288, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_AbstractSingleton) < 0) __PYX_ERR(1, 2288, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_AbstractSingleton.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_AbstractSingleton) < 0) __PYX_ERR(1, 2447, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AbstractSingleton, (PyObject *)&__pyx_type_19dependency_injector_9providers_AbstractSingleton) < 0) __PYX_ERR(1, 2447, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_AbstractSingleton) < 0) __PYX_ERR(1, 2447, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_AbstractSingleton = &__pyx_type_19dependency_injector_9providers_AbstractSingleton; __pyx_vtabptr_19dependency_injector_9providers_SingletonDelegate = &__pyx_vtable_19dependency_injector_9providers_SingletonDelegate; __pyx_vtable_19dependency_injector_9providers_SingletonDelegate.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Delegate; __pyx_type_19dependency_injector_9providers_SingletonDelegate.tp_base = __pyx_ptype_19dependency_injector_9providers_Delegate; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_SingletonDelegate) < 0) __PYX_ERR(1, 2333, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_SingletonDelegate) < 0) __PYX_ERR(1, 2492, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_SingletonDelegate.tp_print = 0; #endif @@ -92025,7 +103225,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_SingletonDelegate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2333, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_SingletonDelegate, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2492, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_17SingletonDelegate___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_17SingletonDelegate___init__.doc = __pyx_doc_19dependency_injector_9providers_17SingletonDelegate___init__; @@ -92033,15 +103233,15 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_SingletonDelegate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_SingletonDelegate) < 0) __PYX_ERR(1, 2333, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_SingletonDelegate, (PyObject *)&__pyx_type_19dependency_injector_9providers_SingletonDelegate) < 0) __PYX_ERR(1, 2333, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_SingletonDelegate) < 0) __PYX_ERR(1, 2333, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_SingletonDelegate.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_SingletonDelegate) < 0) __PYX_ERR(1, 2492, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_SingletonDelegate, (PyObject *)&__pyx_type_19dependency_injector_9providers_SingletonDelegate) < 0) __PYX_ERR(1, 2492, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_SingletonDelegate) < 0) __PYX_ERR(1, 2492, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_SingletonDelegate = &__pyx_type_19dependency_injector_9providers_SingletonDelegate; __pyx_vtabptr_19dependency_injector_9providers_List = &__pyx_vtable_19dependency_injector_9providers_List; __pyx_vtable_19dependency_injector_9providers_List.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_List.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_4List__provide; __pyx_type_19dependency_injector_9providers_List.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_List) < 0) __PYX_ERR(1, 2355, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_List) < 0) __PYX_ERR(1, 2514, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_List.tp_print = 0; #endif @@ -92050,7 +103250,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_List, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2355, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_List, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2514, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_4List___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_4List___init__.doc = __pyx_doc_19dependency_injector_9providers_4List___init__; @@ -92060,7 +103260,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_List, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2355, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_List, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2514, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_4List_4__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_4List_4__str__.doc = __pyx_doc_19dependency_injector_9providers_4List_4__str__; @@ -92068,15 +103268,15 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_List.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_List) < 0) __PYX_ERR(1, 2355, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_List, (PyObject *)&__pyx_type_19dependency_injector_9providers_List) < 0) __PYX_ERR(1, 2355, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_List) < 0) __PYX_ERR(1, 2355, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_List.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_List) < 0) __PYX_ERR(1, 2514, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_List, (PyObject *)&__pyx_type_19dependency_injector_9providers_List) < 0) __PYX_ERR(1, 2514, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_List) < 0) __PYX_ERR(1, 2514, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_List = &__pyx_type_19dependency_injector_9providers_List; __pyx_vtabptr_19dependency_injector_9providers_Dict = &__pyx_vtable_19dependency_injector_9providers_Dict; __pyx_vtable_19dependency_injector_9providers_Dict.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_Dict.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_4Dict__provide; __pyx_type_19dependency_injector_9providers_Dict.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Dict) < 0) __PYX_ERR(1, 2457, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Dict) < 0) __PYX_ERR(1, 2616, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Dict.tp_print = 0; #endif @@ -92085,7 +103285,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dict, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2457, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dict, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2616, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_4Dict___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_4Dict___init__.doc = __pyx_doc_19dependency_injector_9providers_4Dict___init__; @@ -92095,7 +103295,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dict, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2457, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Dict, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2616, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_4Dict_4__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_4Dict_4__str__.doc = __pyx_doc_19dependency_injector_9providers_4Dict_4__str__; @@ -92103,36 +103303,36 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Dict.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Dict) < 0) __PYX_ERR(1, 2457, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Dict, (PyObject *)&__pyx_type_19dependency_injector_9providers_Dict) < 0) __PYX_ERR(1, 2457, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Dict) < 0) __PYX_ERR(1, 2457, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Dict.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Dict) < 0) __PYX_ERR(1, 2616, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Dict, (PyObject *)&__pyx_type_19dependency_injector_9providers_Dict) < 0) __PYX_ERR(1, 2616, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Dict) < 0) __PYX_ERR(1, 2616, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Dict = &__pyx_type_19dependency_injector_9providers_Dict; __pyx_vtabptr_19dependency_injector_9providers_Resource = &__pyx_vtable_19dependency_injector_9providers_Resource; __pyx_vtable_19dependency_injector_9providers_Resource.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_Resource.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_8Resource__provide; __pyx_type_19dependency_injector_9providers_Resource.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Resource) < 0) __PYX_ERR(1, 2569, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Resource) < 0) __PYX_ERR(1, 2728, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Resource.tp_print = 0; #endif if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_19dependency_injector_9providers_Resource.tp_dictoffset && __pyx_type_19dependency_injector_9providers_Resource.tp_getattro == PyObject_GenericGetAttr)) { __pyx_type_19dependency_injector_9providers_Resource.tp_getattro = __Pyx_PyObject_GenericGetAttr; } - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Resource.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Resource) < 0) __PYX_ERR(1, 2569, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Resource, (PyObject *)&__pyx_type_19dependency_injector_9providers_Resource) < 0) __PYX_ERR(1, 2569, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Resource) < 0) __PYX_ERR(1, 2569, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Resource.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Resource) < 0) __PYX_ERR(1, 2728, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Resource, (PyObject *)&__pyx_type_19dependency_injector_9providers_Resource) < 0) __PYX_ERR(1, 2728, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Resource) < 0) __PYX_ERR(1, 2728, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Resource = &__pyx_type_19dependency_injector_9providers_Resource; __pyx_vtabptr_19dependency_injector_9providers_Container = &__pyx_vtable_19dependency_injector_9providers_Container; __pyx_vtable_19dependency_injector_9providers_Container.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_Container.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_9Container__provide; __pyx_type_19dependency_injector_9providers_Container.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Container) < 0) __PYX_ERR(1, 2774, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Container) < 0) __PYX_ERR(1, 3030, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Container.tp_print = 0; #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Container, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2774, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Container, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 3030, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_9Container___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_9Container___init__.doc = __pyx_doc_19dependency_injector_9providers_9Container___init__; @@ -92142,7 +103342,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Container, "__getattr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2774, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Container, "__getattr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 3030, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_9Container_4__getattr__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_9Container_4__getattr__.doc = __pyx_doc_19dependency_injector_9providers_9Container_4__getattr__; @@ -92150,21 +103350,21 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Container.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Container) < 0) __PYX_ERR(1, 2774, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Container, (PyObject *)&__pyx_type_19dependency_injector_9providers_Container) < 0) __PYX_ERR(1, 2774, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Container) < 0) __PYX_ERR(1, 2774, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Container.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Container) < 0) __PYX_ERR(1, 3030, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Container, (PyObject *)&__pyx_type_19dependency_injector_9providers_Container) < 0) __PYX_ERR(1, 3030, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Container) < 0) __PYX_ERR(1, 3030, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Container = &__pyx_type_19dependency_injector_9providers_Container; __pyx_vtabptr_19dependency_injector_9providers_Selector = &__pyx_vtable_19dependency_injector_9providers_Selector; __pyx_vtable_19dependency_injector_9providers_Selector.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_Selector.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_8Selector__provide; __pyx_type_19dependency_injector_9providers_Selector.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Selector) < 0) __PYX_ERR(1, 2829, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Selector) < 0) __PYX_ERR(1, 3085, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Selector.tp_print = 0; #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Selector, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2829, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Selector, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 3085, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Selector___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Selector___init__.doc = __pyx_doc_19dependency_injector_9providers_8Selector___init__; @@ -92174,7 +103374,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Selector, "__getattr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2829, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Selector, "__getattr__"); if (unlikely(!wrapper)) __PYX_ERR(1, 3085, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Selector_4__getattr__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Selector_4__getattr__.doc = __pyx_doc_19dependency_injector_9providers_8Selector_4__getattr__; @@ -92184,7 +103384,7 @@ static int __Pyx_modinit_type_init_code(void) { #endif #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Selector, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 2829, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_Selector, "__str__"); if (unlikely(!wrapper)) __PYX_ERR(1, 3085, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_8Selector_6__str__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_8Selector_6__str__.doc = __pyx_doc_19dependency_injector_9providers_8Selector_6__str__; @@ -92192,70 +103392,70 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Selector.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Selector) < 0) __PYX_ERR(1, 2829, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Selector, (PyObject *)&__pyx_type_19dependency_injector_9providers_Selector) < 0) __PYX_ERR(1, 2829, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Selector) < 0) __PYX_ERR(1, 2829, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_Selector.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_Selector) < 0) __PYX_ERR(1, 3085, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Selector, (PyObject *)&__pyx_type_19dependency_injector_9providers_Selector) < 0) __PYX_ERR(1, 3085, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Selector) < 0) __PYX_ERR(1, 3085, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Selector = &__pyx_type_19dependency_injector_9providers_Selector; __pyx_vtabptr_19dependency_injector_9providers_ProvidedInstance = &__pyx_vtable_19dependency_injector_9providers_ProvidedInstance; __pyx_vtable_19dependency_injector_9providers_ProvidedInstance.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_ProvidedInstance.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_16ProvidedInstance__provide; __pyx_type_19dependency_injector_9providers_ProvidedInstance.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ProvidedInstance) < 0) __PYX_ERR(1, 2926, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ProvidedInstance) < 0) __PYX_ERR(1, 3182, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_ProvidedInstance.tp_print = 0; #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ProvidedInstance.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ProvidedInstance) < 0) __PYX_ERR(1, 2926, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ProvidedInstance, (PyObject *)&__pyx_type_19dependency_injector_9providers_ProvidedInstance) < 0) __PYX_ERR(1, 2926, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ProvidedInstance) < 0) __PYX_ERR(1, 2926, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ProvidedInstance.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ProvidedInstance) < 0) __PYX_ERR(1, 3182, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ProvidedInstance, (PyObject *)&__pyx_type_19dependency_injector_9providers_ProvidedInstance) < 0) __PYX_ERR(1, 3182, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ProvidedInstance) < 0) __PYX_ERR(1, 3182, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ProvidedInstance = &__pyx_type_19dependency_injector_9providers_ProvidedInstance; __pyx_vtabptr_19dependency_injector_9providers_AttributeGetter = &__pyx_vtable_19dependency_injector_9providers_AttributeGetter; __pyx_vtable_19dependency_injector_9providers_AttributeGetter.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_AttributeGetter.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_15AttributeGetter__provide; __pyx_type_19dependency_injector_9providers_AttributeGetter.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_AttributeGetter) < 0) __PYX_ERR(1, 2993, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_AttributeGetter) < 0) __PYX_ERR(1, 3249, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_AttributeGetter.tp_print = 0; #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_AttributeGetter.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_AttributeGetter) < 0) __PYX_ERR(1, 2993, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AttributeGetter, (PyObject *)&__pyx_type_19dependency_injector_9providers_AttributeGetter) < 0) __PYX_ERR(1, 2993, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_AttributeGetter) < 0) __PYX_ERR(1, 2993, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_AttributeGetter.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_AttributeGetter) < 0) __PYX_ERR(1, 3249, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AttributeGetter, (PyObject *)&__pyx_type_19dependency_injector_9providers_AttributeGetter) < 0) __PYX_ERR(1, 3249, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_AttributeGetter) < 0) __PYX_ERR(1, 3249, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_AttributeGetter = &__pyx_type_19dependency_injector_9providers_AttributeGetter; __pyx_vtabptr_19dependency_injector_9providers_ItemGetter = &__pyx_vtable_19dependency_injector_9providers_ItemGetter; __pyx_vtable_19dependency_injector_9providers_ItemGetter.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_ItemGetter.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_10ItemGetter__provide; __pyx_type_19dependency_injector_9providers_ItemGetter.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ItemGetter) < 0) __PYX_ERR(1, 3043, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_ItemGetter) < 0) __PYX_ERR(1, 3309, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_ItemGetter.tp_print = 0; #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ItemGetter.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ItemGetter) < 0) __PYX_ERR(1, 3043, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ItemGetter, (PyObject *)&__pyx_type_19dependency_injector_9providers_ItemGetter) < 0) __PYX_ERR(1, 3043, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ItemGetter) < 0) __PYX_ERR(1, 3043, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_ItemGetter.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_ItemGetter) < 0) __PYX_ERR(1, 3309, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_ItemGetter, (PyObject *)&__pyx_type_19dependency_injector_9providers_ItemGetter) < 0) __PYX_ERR(1, 3309, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_ItemGetter) < 0) __PYX_ERR(1, 3309, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_ItemGetter = &__pyx_type_19dependency_injector_9providers_ItemGetter; __pyx_vtabptr_19dependency_injector_9providers_MethodCaller = &__pyx_vtable_19dependency_injector_9providers_MethodCaller; __pyx_vtable_19dependency_injector_9providers_MethodCaller.__pyx_base = *__pyx_vtabptr_19dependency_injector_9providers_Provider; __pyx_vtable_19dependency_injector_9providers_MethodCaller.__pyx_base._provide = (PyObject *(*)(struct __pyx_obj_19dependency_injector_9providers_Provider *, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_19dependency_injector_9providers_12MethodCaller__provide; __pyx_type_19dependency_injector_9providers_MethodCaller.tp_base = __pyx_ptype_19dependency_injector_9providers_Provider; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_MethodCaller) < 0) __PYX_ERR(1, 3093, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_MethodCaller) < 0) __PYX_ERR(1, 3369, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_MethodCaller.tp_print = 0; #endif - if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_MethodCaller.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_MethodCaller) < 0) __PYX_ERR(1, 3093, __pyx_L1_error) - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_MethodCaller, (PyObject *)&__pyx_type_19dependency_injector_9providers_MethodCaller) < 0) __PYX_ERR(1, 3093, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_MethodCaller) < 0) __PYX_ERR(1, 3093, __pyx_L1_error) + if (__Pyx_SetVtable(__pyx_type_19dependency_injector_9providers_MethodCaller.tp_dict, __pyx_vtabptr_19dependency_injector_9providers_MethodCaller) < 0) __PYX_ERR(1, 3369, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_MethodCaller, (PyObject *)&__pyx_type_19dependency_injector_9providers_MethodCaller) < 0) __PYX_ERR(1, 3369, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_MethodCaller) < 0) __PYX_ERR(1, 3369, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_MethodCaller = &__pyx_type_19dependency_injector_9providers_MethodCaller; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Injection) < 0) __PYX_ERR(1, 3183, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_Injection) < 0) __PYX_ERR(1, 3477, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_Injection.tp_print = 0; #endif if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_19dependency_injector_9providers_Injection.tp_dictoffset && __pyx_type_19dependency_injector_9providers_Injection.tp_getattro == PyObject_GenericGetAttr)) { __pyx_type_19dependency_injector_9providers_Injection.tp_getattro = __Pyx_PyObject_GenericGetAttr; } - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Injection, (PyObject *)&__pyx_type_19dependency_injector_9providers_Injection) < 0) __PYX_ERR(1, 3183, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Injection) < 0) __PYX_ERR(1, 3183, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Injection, (PyObject *)&__pyx_type_19dependency_injector_9providers_Injection) < 0) __PYX_ERR(1, 3477, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_Injection) < 0) __PYX_ERR(1, 3477, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_Injection = &__pyx_type_19dependency_injector_9providers_Injection; __pyx_type_19dependency_injector_9providers_PositionalInjection.tp_base = __pyx_ptype_19dependency_injector_9providers_Injection; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_PositionalInjection) < 0) __PYX_ERR(1, 3187, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_PositionalInjection) < 0) __PYX_ERR(1, 3481, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_PositionalInjection.tp_print = 0; #endif @@ -92264,7 +103464,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_PositionalInjection, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 3187, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_PositionalInjection, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 3481, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_19PositionalInjection___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_19PositionalInjection___init__.doc = __pyx_doc_19dependency_injector_9providers_19PositionalInjection___init__; @@ -92272,11 +103472,11 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_PositionalInjection, (PyObject *)&__pyx_type_19dependency_injector_9providers_PositionalInjection) < 0) __PYX_ERR(1, 3187, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_PositionalInjection) < 0) __PYX_ERR(1, 3187, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_PositionalInjection, (PyObject *)&__pyx_type_19dependency_injector_9providers_PositionalInjection) < 0) __PYX_ERR(1, 3481, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_PositionalInjection) < 0) __PYX_ERR(1, 3481, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_PositionalInjection = &__pyx_type_19dependency_injector_9providers_PositionalInjection; __pyx_type_19dependency_injector_9providers_NamedInjection.tp_base = __pyx_ptype_19dependency_injector_9providers_Injection; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_NamedInjection) < 0) __PYX_ERR(1, 3215, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers_NamedInjection) < 0) __PYX_ERR(1, 3509, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers_NamedInjection.tp_print = 0; #endif @@ -92285,7 +103485,7 @@ static int __Pyx_modinit_type_init_code(void) { } #if CYTHON_COMPILING_IN_CPYTHON { - PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_NamedInjection, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 3215, __pyx_L1_error) + PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_19dependency_injector_9providers_NamedInjection, "__init__"); if (unlikely(!wrapper)) __PYX_ERR(1, 3509, __pyx_L1_error) if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) { __pyx_wrapperbase_19dependency_injector_9providers_14NamedInjection___init__ = *((PyWrapperDescrObject *)wrapper)->d_base; __pyx_wrapperbase_19dependency_injector_9providers_14NamedInjection___init__.doc = __pyx_doc_19dependency_injector_9providers_14NamedInjection___init__; @@ -92293,10 +103493,10 @@ static int __Pyx_modinit_type_init_code(void) { } } #endif - if (PyObject_SetAttr(__pyx_m, __pyx_n_s_NamedInjection, (PyObject *)&__pyx_type_19dependency_injector_9providers_NamedInjection) < 0) __PYX_ERR(1, 3215, __pyx_L1_error) - if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_NamedInjection) < 0) __PYX_ERR(1, 3215, __pyx_L1_error) + if (PyObject_SetAttr(__pyx_m, __pyx_n_s_NamedInjection, (PyObject *)&__pyx_type_19dependency_injector_9providers_NamedInjection) < 0) __PYX_ERR(1, 3509, __pyx_L1_error) + if (__Pyx_setup_reduce((PyObject*)&__pyx_type_19dependency_injector_9providers_NamedInjection) < 0) __PYX_ERR(1, 3509, __pyx_L1_error) __pyx_ptype_19dependency_injector_9providers_NamedInjection = &__pyx_type_19dependency_injector_9providers_NamedInjection; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers___pyx_scope_struct___get_self_name) < 0) __PYX_ERR(1, 1139, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers___pyx_scope_struct___get_self_name) < 0) __PYX_ERR(1, 1239, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers___pyx_scope_struct___get_self_name.tp_print = 0; #endif @@ -92304,7 +103504,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_19dependency_injector_9providers___pyx_scope_struct___get_self_name.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_19dependency_injector_9providers___pyx_scope_struct___get_self_name = &__pyx_type_19dependency_injector_9providers___pyx_scope_struct___get_self_name; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers___pyx_scope_struct_1_genexpr) < 0) __PYX_ERR(1, 1141, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers___pyx_scope_struct_1_genexpr) < 0) __PYX_ERR(1, 1241, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers___pyx_scope_struct_1_genexpr.tp_print = 0; #endif @@ -92312,7 +103512,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_19dependency_injector_9providers___pyx_scope_struct_1_genexpr.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_19dependency_injector_9providers___pyx_scope_struct_1_genexpr = &__pyx_type_19dependency_injector_9providers___pyx_scope_struct_1_genexpr; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers___pyx_scope_struct_2___str__) < 0) __PYX_ERR(1, 2892, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers___pyx_scope_struct_2___str__) < 0) __PYX_ERR(1, 3148, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers___pyx_scope_struct_2___str__.tp_print = 0; #endif @@ -92320,7 +103520,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_19dependency_injector_9providers___pyx_scope_struct_2___str__.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_19dependency_injector_9providers___pyx_scope_struct_2___str__ = &__pyx_type_19dependency_injector_9providers___pyx_scope_struct_2___str__; - if (PyType_Ready(&__pyx_type_19dependency_injector_9providers___pyx_scope_struct_3_genexpr) < 0) __PYX_ERR(1, 2902, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_19dependency_injector_9providers___pyx_scope_struct_3_genexpr) < 0) __PYX_ERR(1, 3158, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_19dependency_injector_9providers___pyx_scope_struct_3_genexpr.tp_print = 0; #endif @@ -92328,6 +103528,14 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_19dependency_injector_9providers___pyx_scope_struct_3_genexpr.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_19dependency_injector_9providers___pyx_scope_struct_3_genexpr = &__pyx_type_19dependency_injector_9providers___pyx_scope_struct_3_genexpr; + if (PyType_Ready(&__pyx_scope_struct____Pyx_CFunc_void____object___to_py) < 0) __PYX_ERR(2, 64, __pyx_L1_error) + #if PY_VERSION_HEX < 0x030800B1 + __pyx_scope_struct____Pyx_CFunc_void____object___to_py.tp_print = 0; + #endif + if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_scope_struct____Pyx_CFunc_void____object___to_py.tp_dictoffset && __pyx_scope_struct____Pyx_CFunc_void____object___to_py.tp_getattro == PyObject_GenericGetAttr)) { + __pyx_scope_struct____Pyx_CFunc_void____object___to_py.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; + } + __pyx_ptype___pyx_scope_struct____Pyx_CFunc_void____object___to_py = &__pyx_scope_struct____Pyx_CFunc_void____object___to_py; __Pyx_RefNannyFinishContext(); return 0; __pyx_L1_error:; @@ -92574,8 +103782,8 @@ if (!__Pyx_RefNanny) { * from __future__ import absolute_import * * import copy # <<<<<<<<<<<<<< + * import functools * import inspect - * import os */ __pyx_t_1 = __Pyx_Import(__pyx_n_s_copy, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 5, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); @@ -92585,100 +103793,112 @@ if (!__Pyx_RefNanny) { /* "dependency_injector/providers.pyx":6 * * import copy - * import inspect # <<<<<<<<<<<<<< + * import functools # <<<<<<<<<<<<<< + * import inspect * import os - * import re */ - __pyx_t_1 = __Pyx_patch_inspect(__Pyx_Import(__pyx_n_s_inspect, 0, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 6, __pyx_L1_error) + __pyx_t_1 = __Pyx_Import(__pyx_n_s_functools, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 6, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_inspect, __pyx_t_1) < 0) __PYX_ERR(1, 6, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_functools, __pyx_t_1) < 0) __PYX_ERR(1, 6, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "dependency_injector/providers.pyx":7 * import copy + * import functools + * import inspect # <<<<<<<<<<<<<< + * import os + * import re + */ + __pyx_t_1 = __Pyx_patch_inspect(__Pyx_Import(__pyx_n_s_inspect, 0, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 7, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_inspect, __pyx_t_1) < 0) __PYX_ERR(1, 7, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":8 + * import functools * import inspect * import os # <<<<<<<<<<<<<< * import re * import sys */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_os, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 7, __pyx_L1_error) + __pyx_t_1 = __Pyx_Import(__pyx_n_s_os, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 8, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_os, __pyx_t_1) < 0) __PYX_ERR(1, 7, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_os, __pyx_t_1) < 0) __PYX_ERR(1, 8, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":8 + /* "dependency_injector/providers.pyx":9 * import inspect * import os * import re # <<<<<<<<<<<<<< * import sys * import types */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_re, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 8, __pyx_L1_error) + __pyx_t_1 = __Pyx_Import(__pyx_n_s_re, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 9, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_re, __pyx_t_1) < 0) __PYX_ERR(1, 8, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_re, __pyx_t_1) < 0) __PYX_ERR(1, 9, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":9 + /* "dependency_injector/providers.pyx":10 * import os * import re * import sys # <<<<<<<<<<<<<< * import types * import threading */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_sys, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 9, __pyx_L1_error) + __pyx_t_1 = __Pyx_Import(__pyx_n_s_sys, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_sys, __pyx_t_1) < 0) __PYX_ERR(1, 9, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_sys, __pyx_t_1) < 0) __PYX_ERR(1, 10, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":10 + /* "dependency_injector/providers.pyx":11 * import re * import sys * import types # <<<<<<<<<<<<<< * import threading * import warnings */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_types, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error) + __pyx_t_1 = __Pyx_Import(__pyx_n_s_types, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 11, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_types, __pyx_t_1) < 0) __PYX_ERR(1, 10, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_types, __pyx_t_1) < 0) __PYX_ERR(1, 11, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":11 + /* "dependency_injector/providers.pyx":12 * import sys * import types * import threading # <<<<<<<<<<<<<< * import warnings * import weakref */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_threading, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 11, __pyx_L1_error) + __pyx_t_1 = __Pyx_Import(__pyx_n_s_threading, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_threading, __pyx_t_1) < 0) __PYX_ERR(1, 11, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_threading, __pyx_t_1) < 0) __PYX_ERR(1, 12, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":12 + /* "dependency_injector/providers.pyx":13 * import types * import threading * import warnings # <<<<<<<<<<<<<< * import weakref * */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_warnings, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error) + __pyx_t_1 = __Pyx_Import(__pyx_n_s_warnings, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 13, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_warnings, __pyx_t_1) < 0) __PYX_ERR(1, 12, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_warnings, __pyx_t_1) < 0) __PYX_ERR(1, 13, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":13 + /* "dependency_injector/providers.pyx":14 * import threading * import warnings * import weakref # <<<<<<<<<<<<<< * * try: */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_weakref, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 13, __pyx_L1_error) + __pyx_t_1 = __Pyx_Import(__pyx_n_s_weakref, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_weakref, __pyx_t_1) < 0) __PYX_ERR(1, 13, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_weakref, __pyx_t_1) < 0) __PYX_ERR(1, 14, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":15 + /* "dependency_injector/providers.pyx":16 * import weakref * * try: # <<<<<<<<<<<<<< @@ -92694,19 +103914,19 @@ if (!__Pyx_RefNanny) { __Pyx_XGOTREF(__pyx_t_4); /*try:*/ { - /* "dependency_injector/providers.pyx":16 + /* "dependency_injector/providers.pyx":17 * * try: * import asyncio # <<<<<<<<<<<<<< * except ImportError: * asyncio = None */ - __pyx_t_1 = __Pyx_patch_asyncio(__Pyx_Import(__pyx_n_s_asyncio, 0, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 16, __pyx_L2_error) + __pyx_t_1 = __Pyx_patch_asyncio(__Pyx_Import(__pyx_n_s_asyncio, 0, 0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 17, __pyx_L2_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_asyncio, __pyx_t_1) < 0) __PYX_ERR(1, 16, __pyx_L2_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_asyncio, __pyx_t_1) < 0) __PYX_ERR(1, 17, __pyx_L2_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":15 + /* "dependency_injector/providers.pyx":16 * import weakref * * try: # <<<<<<<<<<<<<< @@ -92715,7 +103935,7 @@ if (!__Pyx_RefNanny) { */ } - /* "dependency_injector/providers.pyx":21 + /* "dependency_injector/providers.pyx":22 * _is_coroutine_marker = None * else: * if sys.version_info >= (3, 5, 3): # <<<<<<<<<<<<<< @@ -92723,48 +103943,48 @@ if (!__Pyx_RefNanny) { * _is_coroutine_marker = asyncio.coroutines._is_coroutine */ /*else:*/ { - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 21, __pyx_L4_except_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 22, __pyx_L4_except_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_version_info); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 21, __pyx_L4_except_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_version_info); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 22, __pyx_L4_except_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyObject_RichCompare(__pyx_t_5, __pyx_tuple__15, Py_GE); __Pyx_XGOTREF(__pyx_t_1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 21, __pyx_L4_except_error) + __pyx_t_1 = PyObject_RichCompare(__pyx_t_5, __pyx_tuple__18, Py_GE); __Pyx_XGOTREF(__pyx_t_1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 22, __pyx_L4_except_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 21, __pyx_L4_except_error) + __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 22, __pyx_L4_except_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":22 + /* "dependency_injector/providers.pyx":23 * else: * if sys.version_info >= (3, 5, 3): * import asyncio.coroutines # <<<<<<<<<<<<<< * _is_coroutine_marker = asyncio.coroutines._is_coroutine * else: */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_asyncio_coroutines, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 22, __pyx_L4_except_error) + __pyx_t_1 = __Pyx_Import(__pyx_n_s_asyncio_coroutines, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 23, __pyx_L4_except_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_asyncio, __pyx_t_1) < 0) __PYX_ERR(1, 22, __pyx_L4_except_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_asyncio, __pyx_t_1) < 0) __PYX_ERR(1, 23, __pyx_L4_except_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":23 + /* "dependency_injector/providers.pyx":24 * if sys.version_info >= (3, 5, 3): * import asyncio.coroutines * _is_coroutine_marker = asyncio.coroutines._is_coroutine # <<<<<<<<<<<<<< * else: * _is_coroutine_marker = True */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 23, __pyx_L4_except_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_asyncio); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 24, __pyx_L4_except_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_coroutines); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 23, __pyx_L4_except_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_coroutines); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 24, __pyx_L4_except_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_is_coroutine); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 23, __pyx_L4_except_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_is_coroutine); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 24, __pyx_L4_except_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (PyDict_SetItem(__pyx_d, __pyx_n_s_is_coroutine_marker, __pyx_t_1) < 0) __PYX_ERR(1, 23, __pyx_L4_except_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_is_coroutine_marker, __pyx_t_1) < 0) __PYX_ERR(1, 24, __pyx_L4_except_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":21 + /* "dependency_injector/providers.pyx":22 * _is_coroutine_marker = None * else: * if sys.version_info >= (3, 5, 3): # <<<<<<<<<<<<<< @@ -92774,7 +103994,7 @@ if (!__Pyx_RefNanny) { goto __pyx_L8; } - /* "dependency_injector/providers.pyx":25 + /* "dependency_injector/providers.pyx":26 * _is_coroutine_marker = asyncio.coroutines._is_coroutine * else: * _is_coroutine_marker = True # <<<<<<<<<<<<<< @@ -92782,7 +104002,7 @@ if (!__Pyx_RefNanny) { * try: */ /*else*/ { - if (PyDict_SetItem(__pyx_d, __pyx_n_s_is_coroutine_marker, Py_True) < 0) __PYX_ERR(1, 25, __pyx_L4_except_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_is_coroutine_marker, Py_True) < 0) __PYX_ERR(1, 26, __pyx_L4_except_error) } __pyx_L8:; } @@ -92793,7 +104013,7 @@ if (!__Pyx_RefNanny) { __pyx_L2_error:; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":17 + /* "dependency_injector/providers.pyx":18 * try: * import asyncio * except ImportError: # <<<<<<<<<<<<<< @@ -92803,28 +104023,28 @@ if (!__Pyx_RefNanny) { __pyx_t_7 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_ImportError); if (__pyx_t_7) { __Pyx_AddTraceback("dependency_injector.providers", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_5, &__pyx_t_8) < 0) __PYX_ERR(1, 17, __pyx_L4_except_error) + if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_5, &__pyx_t_8) < 0) __PYX_ERR(1, 18, __pyx_L4_except_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_5); __Pyx_GOTREF(__pyx_t_8); - /* "dependency_injector/providers.pyx":18 + /* "dependency_injector/providers.pyx":19 * import asyncio * except ImportError: * asyncio = None # <<<<<<<<<<<<<< * _is_coroutine_marker = None * else: */ - if (PyDict_SetItem(__pyx_d, __pyx_n_s_asyncio, Py_None) < 0) __PYX_ERR(1, 18, __pyx_L4_except_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_asyncio, Py_None) < 0) __PYX_ERR(1, 19, __pyx_L4_except_error) - /* "dependency_injector/providers.pyx":19 + /* "dependency_injector/providers.pyx":20 * except ImportError: * asyncio = None * _is_coroutine_marker = None # <<<<<<<<<<<<<< * else: * if sys.version_info >= (3, 5, 3): */ - if (PyDict_SetItem(__pyx_d, __pyx_n_s_is_coroutine_marker, Py_None) < 0) __PYX_ERR(1, 19, __pyx_L4_except_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_is_coroutine_marker, Py_None) < 0) __PYX_ERR(1, 20, __pyx_L4_except_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; @@ -92833,7 +104053,7 @@ if (!__Pyx_RefNanny) { goto __pyx_L4_except_error; __pyx_L4_except_error:; - /* "dependency_injector/providers.pyx":15 + /* "dependency_injector/providers.pyx":16 * import weakref * * try: # <<<<<<<<<<<<<< @@ -92853,7 +104073,7 @@ if (!__Pyx_RefNanny) { __pyx_L7_try_end:; } - /* "dependency_injector/providers.pyx":27 + /* "dependency_injector/providers.pyx":28 * _is_coroutine_marker = True * * try: # <<<<<<<<<<<<<< @@ -92869,19 +104089,19 @@ if (!__Pyx_RefNanny) { __Pyx_XGOTREF(__pyx_t_2); /*try:*/ { - /* "dependency_injector/providers.pyx":28 + /* "dependency_injector/providers.pyx":29 * * try: * import ConfigParser as iniconfigparser # <<<<<<<<<<<<<< * except ImportError: * import configparser as iniconfigparser */ - __pyx_t_8 = __Pyx_Import(__pyx_n_s_ConfigParser, 0, 0); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 28, __pyx_L11_error) + __pyx_t_8 = __Pyx_Import(__pyx_n_s_ConfigParser, 0, 0); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 29, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_iniconfigparser, __pyx_t_8) < 0) __PYX_ERR(1, 28, __pyx_L11_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_iniconfigparser, __pyx_t_8) < 0) __PYX_ERR(1, 29, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":27 + /* "dependency_injector/providers.pyx":28 * _is_coroutine_marker = True * * try: # <<<<<<<<<<<<<< @@ -92898,7 +104118,7 @@ if (!__Pyx_RefNanny) { __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":29 + /* "dependency_injector/providers.pyx":30 * try: * import ConfigParser as iniconfigparser * except ImportError: # <<<<<<<<<<<<<< @@ -92908,21 +104128,21 @@ if (!__Pyx_RefNanny) { __pyx_t_7 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_ImportError); if (__pyx_t_7) { __Pyx_AddTraceback("dependency_injector.providers", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_8, &__pyx_t_5, &__pyx_t_1) < 0) __PYX_ERR(1, 29, __pyx_L13_except_error) + if (__Pyx_GetException(&__pyx_t_8, &__pyx_t_5, &__pyx_t_1) < 0) __PYX_ERR(1, 30, __pyx_L13_except_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_GOTREF(__pyx_t_5); __Pyx_GOTREF(__pyx_t_1); - /* "dependency_injector/providers.pyx":30 + /* "dependency_injector/providers.pyx":31 * import ConfigParser as iniconfigparser * except ImportError: * import configparser as iniconfigparser # <<<<<<<<<<<<<< * * try: */ - __pyx_t_9 = __Pyx_Import(__pyx_n_s_configparser, 0, 0); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 30, __pyx_L13_except_error) + __pyx_t_9 = __Pyx_Import(__pyx_n_s_configparser, 0, 0); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 31, __pyx_L13_except_error) __Pyx_GOTREF(__pyx_t_9); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_iniconfigparser, __pyx_t_9) < 0) __PYX_ERR(1, 30, __pyx_L13_except_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_iniconfigparser, __pyx_t_9) < 0) __PYX_ERR(1, 31, __pyx_L13_except_error) __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; @@ -92932,7 +104152,7 @@ if (!__Pyx_RefNanny) { goto __pyx_L13_except_error; __pyx_L13_except_error:; - /* "dependency_injector/providers.pyx":27 + /* "dependency_injector/providers.pyx":28 * _is_coroutine_marker = True * * try: # <<<<<<<<<<<<<< @@ -92952,7 +104172,7 @@ if (!__Pyx_RefNanny) { __pyx_L16_try_end:; } - /* "dependency_injector/providers.pyx":32 + /* "dependency_injector/providers.pyx":33 * import configparser as iniconfigparser * * try: # <<<<<<<<<<<<<< @@ -92968,19 +104188,19 @@ if (!__Pyx_RefNanny) { __Pyx_XGOTREF(__pyx_t_4); /*try:*/ { - /* "dependency_injector/providers.pyx":33 + /* "dependency_injector/providers.pyx":34 * * try: * import yaml # <<<<<<<<<<<<<< * except ImportError: * yaml = None */ - __pyx_t_1 = __Pyx_Import(__pyx_n_s_yaml, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 33, __pyx_L19_error) + __pyx_t_1 = __Pyx_Import(__pyx_n_s_yaml, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 34, __pyx_L19_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_yaml, __pyx_t_1) < 0) __PYX_ERR(1, 33, __pyx_L19_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_yaml, __pyx_t_1) < 0) __PYX_ERR(1, 34, __pyx_L19_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":32 + /* "dependency_injector/providers.pyx":33 * import configparser as iniconfigparser * * try: # <<<<<<<<<<<<<< @@ -92998,7 +104218,7 @@ if (!__Pyx_RefNanny) { __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/providers.pyx":34 + /* "dependency_injector/providers.pyx":35 * try: * import yaml * except ImportError: # <<<<<<<<<<<<<< @@ -93008,19 +104228,19 @@ if (!__Pyx_RefNanny) { __pyx_t_7 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_ImportError); if (__pyx_t_7) { __Pyx_AddTraceback("dependency_injector.providers", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_5, &__pyx_t_8) < 0) __PYX_ERR(1, 34, __pyx_L21_except_error) + if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_5, &__pyx_t_8) < 0) __PYX_ERR(1, 35, __pyx_L21_except_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_5); __Pyx_GOTREF(__pyx_t_8); - /* "dependency_injector/providers.pyx":35 + /* "dependency_injector/providers.pyx":36 * import yaml * except ImportError: * yaml = None # <<<<<<<<<<<<<< * * from .errors import ( */ - if (PyDict_SetItem(__pyx_d, __pyx_n_s_yaml, Py_None) < 0) __PYX_ERR(1, 35, __pyx_L21_except_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_yaml, Py_None) < 0) __PYX_ERR(1, 36, __pyx_L21_except_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; @@ -93029,7 +104249,7 @@ if (!__Pyx_RefNanny) { goto __pyx_L21_except_error; __pyx_L21_except_error:; - /* "dependency_injector/providers.pyx":32 + /* "dependency_injector/providers.pyx":33 * import configparser as iniconfigparser * * try: # <<<<<<<<<<<<<< @@ -93049,14 +104269,14 @@ if (!__Pyx_RefNanny) { __pyx_L24_try_end:; } - /* "dependency_injector/providers.pyx":38 + /* "dependency_injector/providers.pyx":39 * * from .errors import ( * Error, # <<<<<<<<<<<<<< * NoSuchProviderError, * ) */ - __pyx_t_8 = PyList_New(2); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 38, __pyx_L1_error) + __pyx_t_8 = PyList_New(2); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 39, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_INCREF(__pyx_n_s_Error); __Pyx_GIVEREF(__pyx_n_s_Error); @@ -93065,56 +104285,56 @@ if (!__Pyx_RefNanny) { __Pyx_GIVEREF(__pyx_n_s_NoSuchProviderError); PyList_SET_ITEM(__pyx_t_8, 1, __pyx_n_s_NoSuchProviderError); - /* "dependency_injector/providers.pyx":37 + /* "dependency_injector/providers.pyx":38 * yaml = None * * from .errors import ( # <<<<<<<<<<<<<< * Error, * NoSuchProviderError, */ - __pyx_t_5 = __Pyx_Import(__pyx_n_s_errors, __pyx_t_8, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 37, __pyx_L1_error) + __pyx_t_5 = __Pyx_Import(__pyx_n_s_errors, __pyx_t_8, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 38, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - __pyx_t_8 = __Pyx_ImportFrom(__pyx_t_5, __pyx_n_s_Error); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 37, __pyx_L1_error) + __pyx_t_8 = __Pyx_ImportFrom(__pyx_t_5, __pyx_n_s_Error); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 38, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_Error, __pyx_t_8) < 0) __PYX_ERR(1, 38, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_Error, __pyx_t_8) < 0) __PYX_ERR(1, 39, __pyx_L1_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - __pyx_t_8 = __Pyx_ImportFrom(__pyx_t_5, __pyx_n_s_NoSuchProviderError); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 37, __pyx_L1_error) + __pyx_t_8 = __Pyx_ImportFrom(__pyx_t_5, __pyx_n_s_NoSuchProviderError); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 38, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_NoSuchProviderError, __pyx_t_8) < 0) __PYX_ERR(1, 39, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_NoSuchProviderError, __pyx_t_8) < 0) __PYX_ERR(1, 40, __pyx_L1_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - /* "dependency_injector/providers.pyx":45 + /* "dependency_injector/providers.pyx":46 * * * if sys.version_info[0] == 3: # pragma: no cover # <<<<<<<<<<<<<< * CLASS_TYPES = (type,) * else: # pragma: no cover */ - __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_sys); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 45, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_sys); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 46, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_version_info); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 45, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_version_info); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 46, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __pyx_t_5 = __Pyx_GetItemInt(__pyx_t_8, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 45, __pyx_L1_error) + __pyx_t_5 = __Pyx_GetItemInt(__pyx_t_8, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 46, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - __pyx_t_8 = __Pyx_PyInt_EqObjC(__pyx_t_5, __pyx_int_3, 3, 0); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 45, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyInt_EqObjC(__pyx_t_5, __pyx_int_3, 3, 0); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 46, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_8); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 45, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_8); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 46, __pyx_L1_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":46 + /* "dependency_injector/providers.pyx":47 * * if sys.version_info[0] == 3: # pragma: no cover * CLASS_TYPES = (type,) # <<<<<<<<<<<<<< * else: # pragma: no cover * CLASS_TYPES = (type, types.ClassType) */ - __pyx_t_8 = PyTuple_New(1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 46, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 47, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_INCREF(((PyObject *)(&PyType_Type))); __Pyx_GIVEREF(((PyObject *)(&PyType_Type))); @@ -93124,7 +104344,7 @@ if (!__Pyx_RefNanny) { __Pyx_GIVEREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":45 + /* "dependency_injector/providers.pyx":46 * * * if sys.version_info[0] == 3: # pragma: no cover # <<<<<<<<<<<<<< @@ -93134,7 +104354,7 @@ if (!__Pyx_RefNanny) { goto __pyx_L27; } - /* "dependency_injector/providers.pyx":48 + /* "dependency_injector/providers.pyx":49 * CLASS_TYPES = (type,) * else: # pragma: no cover * CLASS_TYPES = (type, types.ClassType) # <<<<<<<<<<<<<< @@ -93142,12 +104362,12 @@ if (!__Pyx_RefNanny) { * copy._deepcopy_dispatch[types.MethodType] = \ */ /*else*/ { - __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_types); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 48, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_types); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 49, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_ClassType); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 48, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_ClassType); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 49, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - __pyx_t_8 = PyTuple_New(2); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 48, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(2); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 49, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_INCREF(((PyObject *)(&PyType_Type))); __Pyx_GIVEREF(((PyObject *)(&PyType_Type))); @@ -93160,98 +104380,98 @@ if (!__Pyx_RefNanny) { __Pyx_GIVEREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":51 + /* "dependency_injector/providers.pyx":52 * * copy._deepcopy_dispatch[types.MethodType] = \ * lambda obj, memo: type(obj)(obj.im_func, # <<<<<<<<<<<<<< * copy.deepcopy(obj.im_self, memo), * obj.im_class) */ - __pyx_t_8 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_9providers_24lambda, 0, __pyx_n_s_lambda, NULL, __pyx_n_s_dependency_injector_providers, __pyx_d, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 51, __pyx_L1_error) + __pyx_t_8 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_9providers_30lambda, 0, __pyx_n_s_lambda, NULL, __pyx_n_s_dependency_injector_providers, __pyx_d, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 52, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - /* "dependency_injector/providers.pyx":50 + /* "dependency_injector/providers.pyx":51 * CLASS_TYPES = (type, types.ClassType) * * copy._deepcopy_dispatch[types.MethodType] = \ # <<<<<<<<<<<<<< * lambda obj, memo: type(obj)(obj.im_func, * copy.deepcopy(obj.im_self, memo), */ - __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_copy); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 50, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_copy); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 51, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_deepcopy_dispatch); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 50, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_deepcopy_dispatch); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 51, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_types); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 50, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_types); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 51, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_MethodType); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 50, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_MethodType); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 51, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(PyObject_SetItem(__pyx_t_1, __pyx_t_9, __pyx_t_8) < 0)) __PYX_ERR(1, 50, __pyx_L1_error) + if (unlikely(PyObject_SetItem(__pyx_t_1, __pyx_t_9, __pyx_t_8) < 0)) __PYX_ERR(1, 51, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __pyx_L27:; - /* "dependency_injector/providers.pyx":55 + /* "dependency_injector/providers.pyx":56 * obj.im_class) * * if yaml: # <<<<<<<<<<<<<< * yaml_env_marker_pattern = re.compile(r'\$\{([^}^{]+)\}') * def yaml_env_marker_constructor(_, node): */ - __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_yaml); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 55, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_yaml); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 56, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_8); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 55, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_8); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 56, __pyx_L1_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":56 + /* "dependency_injector/providers.pyx":57 * * if yaml: * yaml_env_marker_pattern = re.compile(r'\$\{([^}^{]+)\}') # <<<<<<<<<<<<<< * def yaml_env_marker_constructor(_, node): * """"Replace environment variable marker with its value.""" */ - __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_re); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 56, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_re); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 57, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_compile); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 56, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_compile); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 57, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_tuple__17, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 56, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_tuple__20, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 57, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - if (PyDict_SetItem(__pyx_d, __pyx_n_s_yaml_env_marker_pattern, __pyx_t_8) < 0) __PYX_ERR(1, 56, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_yaml_env_marker_pattern, __pyx_t_8) < 0) __PYX_ERR(1, 57, __pyx_L1_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":57 + /* "dependency_injector/providers.pyx":58 * if yaml: * yaml_env_marker_pattern = re.compile(r'\$\{([^}^{]+)\}') * def yaml_env_marker_constructor(_, node): # <<<<<<<<<<<<<< * """"Replace environment variable marker with its value.""" * return os.path.expandvars(node.value) */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_1yaml_env_marker_constructor, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 57, __pyx_L1_error) + __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_1yaml_env_marker_constructor, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 58, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_yaml_env_marker_constructor, __pyx_t_8) < 0) __PYX_ERR(1, 57, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_yaml_env_marker_constructor, __pyx_t_8) < 0) __PYX_ERR(1, 58, __pyx_L1_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":61 + /* "dependency_injector/providers.pyx":62 * return os.path.expandvars(node.value) * * yaml.add_implicit_resolver('!path', yaml_env_marker_pattern) # <<<<<<<<<<<<<< * yaml.add_constructor('!path', yaml_env_marker_constructor) * */ - __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_yaml); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 61, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_yaml); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 62, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_add_implicit_resolver); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 61, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_add_implicit_resolver); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 62, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_yaml_env_marker_pattern); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 61, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_yaml_env_marker_pattern); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 62, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 61, __pyx_L1_error) + __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 62, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_kp_s_path_2); __Pyx_GIVEREF(__pyx_kp_s_path_2); @@ -93259,27 +104479,27 @@ if (!__Pyx_RefNanny) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_8); __pyx_t_8 = 0; - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_1, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 61, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_1, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 62, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":62 + /* "dependency_injector/providers.pyx":63 * * yaml.add_implicit_resolver('!path', yaml_env_marker_pattern) * yaml.add_constructor('!path', yaml_env_marker_constructor) # <<<<<<<<<<<<<< * * if sys.version_info[0] == 3: */ - __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_yaml); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 62, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_yaml); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 63, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_add_constructor); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 62, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_add_constructor); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 63, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_yaml_env_marker_constructor); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 62, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_yaml_env_marker_constructor); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 63, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_9 = PyTuple_New(2); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 62, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 63, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_INCREF(__pyx_kp_s_path_2); __Pyx_GIVEREF(__pyx_kp_s_path_2); @@ -93287,13 +104507,13 @@ if (!__Pyx_RefNanny) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_9, 1, __pyx_t_8); __pyx_t_8 = 0; - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_9, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 62, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_9, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 63, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - /* "dependency_injector/providers.pyx":55 + /* "dependency_injector/providers.pyx":56 * obj.im_class) * * if yaml: # <<<<<<<<<<<<<< @@ -93302,97 +104522,97 @@ if (!__Pyx_RefNanny) { */ } - /* "dependency_injector/providers.pyx":64 + /* "dependency_injector/providers.pyx":65 * yaml.add_constructor('!path', yaml_env_marker_constructor) * * if sys.version_info[0] == 3: # <<<<<<<<<<<<<< * class EnvInterpolation(iniconfigparser.BasicInterpolation): * """Interpolation which expands environment variables in values.""" */ - __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_sys); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 64, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_sys); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 65, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_version_info); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 64, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_version_info); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 65, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - __pyx_t_8 = __Pyx_GetItemInt(__pyx_t_9, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 64, __pyx_L1_error) + __pyx_t_8 = __Pyx_GetItemInt(__pyx_t_9, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 65, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - __pyx_t_9 = __Pyx_PyInt_EqObjC(__pyx_t_8, __pyx_int_3, 3, 0); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 64, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyInt_EqObjC(__pyx_t_8, __pyx_int_3, 3, 0); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 65, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_9); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 64, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_9); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 65, __pyx_L1_error) __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; if (__pyx_t_6) { - /* "dependency_injector/providers.pyx":65 + /* "dependency_injector/providers.pyx":66 * * if sys.version_info[0] == 3: * class EnvInterpolation(iniconfigparser.BasicInterpolation): # <<<<<<<<<<<<<< * """Interpolation which expands environment variables in values.""" * */ - __Pyx_GetModuleGlobalName(__pyx_t_9, __pyx_n_s_iniconfigparser); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 65, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_9, __pyx_n_s_iniconfigparser); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 66, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_BasicInterpolation); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 65, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_BasicInterpolation); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 66, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - __pyx_t_9 = PyTuple_New(1); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 65, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(1); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 66, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_8); __pyx_t_8 = 0; - __pyx_t_8 = __Pyx_CalculateMetaclass(NULL, __pyx_t_9); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 65, __pyx_L1_error) + __pyx_t_8 = __Pyx_CalculateMetaclass(NULL, __pyx_t_9); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 66, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_1 = __Pyx_Py3MetaclassPrepare(__pyx_t_8, __pyx_t_9, __pyx_n_s_EnvInterpolation, __pyx_n_s_EnvInterpolation, (PyObject *) NULL, __pyx_n_s_dependency_injector_providers, __pyx_kp_s_Interpolation_which_expands_envi); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 65, __pyx_L1_error) + __pyx_t_1 = __Pyx_Py3MetaclassPrepare(__pyx_t_8, __pyx_t_9, __pyx_n_s_EnvInterpolation, __pyx_n_s_EnvInterpolation, (PyObject *) NULL, __pyx_n_s_dependency_injector_providers, __pyx_kp_s_Interpolation_which_expands_envi); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 66, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_5 = PyList_New(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 65, __pyx_L1_error) + __pyx_t_5 = PyList_New(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 66, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - /* "dependency_injector/providers.pyx":68 + /* "dependency_injector/providers.pyx":69 * """Interpolation which expands environment variables in values.""" * * def before_get(self, parser, section, option, value, defaults): # <<<<<<<<<<<<<< * value = super().before_get(parser, section, option, value, defaults) * return os.path.expandvars(value) */ - __pyx_t_10 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_9providers_16EnvInterpolation_1before_get, 0, __pyx_n_s_EnvInterpolation_before_get, NULL, __pyx_n_s_dependency_injector_providers, __pyx_d, ((PyObject *)__pyx_codeobj__21)); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 68, __pyx_L1_error) + __pyx_t_10 = __Pyx_CyFunction_New(&__pyx_mdef_19dependency_injector_9providers_16EnvInterpolation_1before_get, 0, __pyx_n_s_EnvInterpolation_before_get, NULL, __pyx_n_s_dependency_injector_providers, __pyx_d, ((PyObject *)__pyx_codeobj__24)); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 69, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_INCREF(__pyx_t_10); PyList_Append(__pyx_t_5, __pyx_t_10); __Pyx_GIVEREF(__pyx_t_10); - if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_before_get, __pyx_t_10) < 0) __PYX_ERR(1, 68, __pyx_L1_error) + if (__Pyx_SetNameInClass(__pyx_t_1, __pyx_n_s_before_get, __pyx_t_10) < 0) __PYX_ERR(1, 69, __pyx_L1_error) __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; - /* "dependency_injector/providers.pyx":65 + /* "dependency_injector/providers.pyx":66 * * if sys.version_info[0] == 3: * class EnvInterpolation(iniconfigparser.BasicInterpolation): # <<<<<<<<<<<<<< * """Interpolation which expands environment variables in values.""" * */ - __pyx_t_10 = __Pyx_Py3ClassCreate(__pyx_t_8, __pyx_n_s_EnvInterpolation, __pyx_t_9, __pyx_t_1, NULL, 0, 1); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 65, __pyx_L1_error) + __pyx_t_10 = __Pyx_Py3ClassCreate(__pyx_t_8, __pyx_n_s_EnvInterpolation, __pyx_t_9, __pyx_t_1, NULL, 0, 1); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 66, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); - if (__Pyx_CyFunction_InitClassCell(__pyx_t_5, __pyx_t_10) < 0) __PYX_ERR(1, 65, __pyx_L1_error) + if (__Pyx_CyFunction_InitClassCell(__pyx_t_5, __pyx_t_10) < 0) __PYX_ERR(1, 66, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (PyDict_SetItem(__pyx_d, __pyx_n_s_EnvInterpolation, __pyx_t_10) < 0) __PYX_ERR(1, 65, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_EnvInterpolation, __pyx_t_10) < 0) __PYX_ERR(1, 66, __pyx_L1_error) __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/providers.pyx":72 + /* "dependency_injector/providers.pyx":73 * return os.path.expandvars(value) * * def _parse_ini_file(filepath): # <<<<<<<<<<<<<< * parser = iniconfigparser.ConfigParser(interpolation=EnvInterpolation()) * parser.read(filepath) */ - __pyx_t_9 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_3_parse_ini_file, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 72, __pyx_L1_error) + __pyx_t_9 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_3_parse_ini_file, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 73, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_parse_ini_file, __pyx_t_9) < 0) __PYX_ERR(1, 72, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_parse_ini_file, __pyx_t_9) < 0) __PYX_ERR(1, 73, __pyx_L1_error) __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/providers.pyx":64 + /* "dependency_injector/providers.pyx":65 * yaml.add_constructor('!path', yaml_env_marker_constructor) * * if sys.version_info[0] == 3: # <<<<<<<<<<<<<< @@ -93402,7 +104622,7 @@ if (!__Pyx_RefNanny) { goto __pyx_L29; } - /* "dependency_injector/providers.pyx":77 + /* "dependency_injector/providers.pyx":78 * return parser * else: * import StringIO # <<<<<<<<<<<<<< @@ -93410,45 +104630,72 @@ if (!__Pyx_RefNanny) { * def _parse_ini_file(filepath): */ /*else*/ { - __pyx_t_9 = __Pyx_Import(__pyx_n_s_StringIO, 0, 0); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 77, __pyx_L1_error) + __pyx_t_9 = __Pyx_Import(__pyx_n_s_StringIO, 0, 0); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 78, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_StringIO, __pyx_t_9) < 0) __PYX_ERR(1, 77, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_StringIO, __pyx_t_9) < 0) __PYX_ERR(1, 78, __pyx_L1_error) __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - /* "dependency_injector/providers.pyx":79 + /* "dependency_injector/providers.pyx":80 * import StringIO * * def _parse_ini_file(filepath): # <<<<<<<<<<<<<< * parser = iniconfigparser.ConfigParser() * try: */ - __pyx_t_9 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_5_parse_ini_file, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 79, __pyx_L1_error) + __pyx_t_9 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_5_parse_ini_file, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 80, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_parse_ini_file, __pyx_t_9) < 0) __PYX_ERR(1, 79, __pyx_L1_error) + if (PyDict_SetItem(__pyx_d, __pyx_n_s_parse_ini_file, __pyx_t_9) < 0) __PYX_ERR(1, 80, __pyx_L1_error) __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } __pyx_L29:; - /* "dependency_injector/providers.pyx":139 + /* "dependency_injector/providers.pyx":92 + * + * + * cdef int ASYNC_MODE_UNDEFINED = 0 # <<<<<<<<<<<<<< + * cdef int ASYNC_MODE_ENABLED = 1 + * cdef int ASYNC_MODE_DISABLED = 2 + */ + __pyx_v_19dependency_injector_9providers_ASYNC_MODE_UNDEFINED = 0; + + /* "dependency_injector/providers.pyx":93 + * + * cdef int ASYNC_MODE_UNDEFINED = 0 + * cdef int ASYNC_MODE_ENABLED = 1 # <<<<<<<<<<<<<< + * cdef int ASYNC_MODE_DISABLED = 2 + * + */ + __pyx_v_19dependency_injector_9providers_ASYNC_MODE_ENABLED = 1; + + /* "dependency_injector/providers.pyx":94 + * cdef int ASYNC_MODE_UNDEFINED = 0 + * cdef int ASYNC_MODE_ENABLED = 1 + * cdef int ASYNC_MODE_DISABLED = 2 # <<<<<<<<<<<<<< + * + * + */ + __pyx_v_19dependency_injector_9providers_ASYNC_MODE_DISABLED = 2; + + /* "dependency_injector/providers.pyx":145 * """ * * __IS_PROVIDER__ = True # <<<<<<<<<<<<<< * * overriding_lock = threading.RLock() */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider->tp_dict, __pyx_n_s_IS_PROVIDER, Py_True) < 0) __PYX_ERR(1, 139, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider->tp_dict, __pyx_n_s_IS_PROVIDER, Py_True) < 0) __PYX_ERR(1, 145, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_Provider); - /* "dependency_injector/providers.pyx":141 + /* "dependency_injector/providers.pyx":147 * __IS_PROVIDER__ = True * * overriding_lock = threading.RLock() # <<<<<<<<<<<<<< * """Overriding reentrant lock. * */ - __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_threading); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 141, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_threading); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 147, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_RLock); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 141, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_RLock); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 147, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_t_8 = NULL; @@ -93463,166 +104710,166 @@ if (!__Pyx_RefNanny) { } __pyx_t_9 = (__pyx_t_8) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_8) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 141, __pyx_L1_error) + if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 147, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider->tp_dict, __pyx_n_s_overriding_lock, __pyx_t_9) < 0) __PYX_ERR(1, 141, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider->tp_dict, __pyx_n_s_overriding_lock, __pyx_t_9) < 0) __PYX_ERR(1, 147, __pyx_L1_error) __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; PyType_Modified(__pyx_ptype_19dependency_injector_9providers_Provider); - /* "dependency_injector/providers.pyx":175 + /* "dependency_injector/providers.pyx":198 * * @classmethod * def __class_getitem__(cls, item): # <<<<<<<<<<<<<< * return cls * */ - __Pyx_GetNameInClass(__pyx_t_9, (PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider, __pyx_n_s_class_getitem); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 175, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_9, (PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider, __pyx_n_s_class_getitem); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 198, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); - /* "dependency_injector/providers.pyx":174 + /* "dependency_injector/providers.pyx":197 * return copied * * @classmethod # <<<<<<<<<<<<<< * def __class_getitem__(cls, item): * return cls */ - __pyx_t_1 = __Pyx_Method_ClassMethod(__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 174, __pyx_L1_error) + __pyx_t_1 = __Pyx_Method_ClassMethod(__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 197, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider->tp_dict, __pyx_n_s_class_getitem, __pyx_t_1) < 0) __PYX_ERR(1, 175, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Provider->tp_dict, __pyx_n_s_class_getitem, __pyx_t_1) < 0) __PYX_ERR(1, 198, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_19dependency_injector_9providers_Provider); - /* "dependency_injector/providers.pyx":887 + /* "dependency_injector/providers.pyx":987 * """ * * __IS_DELEGATED__ = True # <<<<<<<<<<<<<< * * */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedCallable->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 887, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedCallable->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 987, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_DelegatedCallable); - /* "dependency_injector/providers.pyx":977 + /* "dependency_injector/providers.pyx":1077 * """ * * _is_coroutine = _is_coroutine_marker # <<<<<<<<<<<<<< * * def __init__(self, provides, *args, **kwargs): */ - __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_is_coroutine_marker); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 977, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_is_coroutine_marker); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1077, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Coroutine->tp_dict, __pyx_n_s_is_coroutine, __pyx_t_1) < 0) __PYX_ERR(1, 977, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Coroutine->tp_dict, __pyx_n_s_is_coroutine, __pyx_t_1) < 0) __PYX_ERR(1, 1077, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_19dependency_injector_9providers_Coroutine); - /* "dependency_injector/providers.pyx":1003 + /* "dependency_injector/providers.pyx":1103 * """ * * __IS_DELEGATED__ = True # <<<<<<<<<<<<<< * * */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedCoroutine->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 1003, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedCoroutine->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 1103, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_DelegatedCoroutine); - /* "dependency_injector/providers.pyx":1076 + /* "dependency_injector/providers.pyx":1176 * """ * * UNDEFINED = object() # <<<<<<<<<<<<<< * * def __init__(self, name, root): */ - __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_builtin_object); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1076, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_builtin_object); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1176, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption->tp_dict, __pyx_n_s_UNDEFINED, __pyx_t_1) < 0) __PYX_ERR(1, 1076, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_ConfigurationOption->tp_dict, __pyx_n_s_UNDEFINED, __pyx_t_1) < 0) __PYX_ERR(1, 1176, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_19dependency_injector_9providers_ConfigurationOption); - /* "dependency_injector/providers.pyx":1301 + /* "dependency_injector/providers.pyx":1401 * """ * * DEFAULT_NAME = 'config' # <<<<<<<<<<<<<< * * def __init__(self, name=DEFAULT_NAME, default=None): */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration->tp_dict, __pyx_n_s_DEFAULT_NAME, __pyx_n_s_config) < 0) __PYX_ERR(1, 1301, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration->tp_dict, __pyx_n_s_DEFAULT_NAME, __pyx_n_s_config) < 0) __PYX_ERR(1, 1401, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_Configuration); - /* "dependency_injector/providers.pyx":1303 + /* "dependency_injector/providers.pyx":1403 * DEFAULT_NAME = 'config' * * def __init__(self, name=DEFAULT_NAME, default=None): # <<<<<<<<<<<<<< * self.__name = name * */ - __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration, __pyx_n_s_DEFAULT_NAME); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1303, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_19dependency_injector_9providers_Configuration, __pyx_n_s_DEFAULT_NAME); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1403, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_k__7 = __pyx_t_1; __Pyx_GIVEREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":1588 + /* "dependency_injector/providers.pyx":1688 * """ * * provided_type = None # <<<<<<<<<<<<<< * * def __init__(self, provides, *args, **kwargs): */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory->tp_dict, __pyx_n_s_provided_type, Py_None) < 0) __PYX_ERR(1, 1588, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Factory->tp_dict, __pyx_n_s_provided_type, Py_None) < 0) __PYX_ERR(1, 1688, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_Factory); - /* "dependency_injector/providers.pyx":1773 + /* "dependency_injector/providers.pyx":1873 * """ * * __IS_DELEGATED__ = True # <<<<<<<<<<<<<< * * */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedFactory->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 1773, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedFactory->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 1873, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_DelegatedFactory); - /* "dependency_injector/providers.pyx":1853 + /* "dependency_injector/providers.pyx":1953 * """ * * __IS_DELEGATED__ = True # <<<<<<<<<<<<<< * * def __init__(self, **factories): */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_FactoryAggregate->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 1853, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_FactoryAggregate->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 1953, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_FactoryAggregate); - /* "dependency_injector/providers.pyx":1929 + /* "dependency_injector/providers.pyx":2035 * """Base class of singleton providers.""" * * provided_type = None # <<<<<<<<<<<<<< * * def __init__(self, provides, *args, **kwargs): */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton->tp_dict, __pyx_n_s_provided_type, Py_None) < 0) __PYX_ERR(1, 1929, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_BaseSingleton->tp_dict, __pyx_n_s_provided_type, Py_None) < 0) __PYX_ERR(1, 2035, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_BaseSingleton); - /* "dependency_injector/providers.pyx":2154 + /* "dependency_injector/providers.pyx":2281 * """ * * __IS_DELEGATED__ = True # <<<<<<<<<<<<<< * * */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedSingleton->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 2154, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedSingleton->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 2281, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_DelegatedSingleton); - /* "dependency_injector/providers.pyx":2160 + /* "dependency_injector/providers.pyx":2287 * """Thread-safe singleton provider.""" * * storage_lock = threading.RLock() # <<<<<<<<<<<<<< * """Storage reentrant lock. * */ - __Pyx_GetModuleGlobalName(__pyx_t_9, __pyx_n_s_threading); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2160, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_9, __pyx_n_s_threading); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 2287, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); - __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_RLock); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2160, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_RLock); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2287, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __pyx_t_9 = NULL; @@ -93637,161 +104884,226 @@ if (!__Pyx_RefNanny) { } __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_9) : __Pyx_PyObject_CallNoArg(__pyx_t_8); __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2160, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2287, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton->tp_dict, __pyx_n_s_storage_lock, __pyx_t_1) < 0) __PYX_ERR(1, 2160, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton->tp_dict, __pyx_n_s_storage_lock, __pyx_t_1) < 0) __PYX_ERR(1, 2287, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_19dependency_injector_9providers_ThreadSafeSingleton); - /* "dependency_injector/providers.pyx":2215 + /* "dependency_injector/providers.pyx":2354 * """ * * __IS_DELEGATED__ = True # <<<<<<<<<<<<<< * * */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedThreadSafeSingleton->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 2215, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedThreadSafeSingleton->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 2354, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_DelegatedThreadSafeSingleton); - /* "dependency_injector/providers.pyx":2285 + /* "dependency_injector/providers.pyx":2444 * """ * * __IS_DELEGATED__ = True # <<<<<<<<<<<<<< * * */ - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedThreadLocalSingleton->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 2285, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_DelegatedThreadLocalSingleton->tp_dict, __pyx_n_s_IS_DELEGATED, Py_True) < 0) __PYX_ERR(1, 2444, __pyx_L1_error) PyType_Modified(__pyx_ptype_19dependency_injector_9providers_DelegatedThreadLocalSingleton); - /* "dependency_injector/providers.pyx":2765 + /* "dependency_injector/providers.pyx":3012 * * @staticmethod * def _is_resource_subclass(instance): # <<<<<<<<<<<<<< * if sys.version_info < (3, 5): * return False */ - __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_8Resource_25_is_resource_subclass, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2765, __pyx_L1_error) + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_8Resource_33_is_resource_subclass, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3012, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource->tp_dict, __pyx_n_s_is_resource_subclass, __pyx_t_1) < 0) __PYX_ERR(1, 2765, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource->tp_dict, __pyx_n_s_is_resource_subclass, __pyx_t_1) < 0) __PYX_ERR(1, 3012, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_19dependency_injector_9providers_Resource); - /* "dependency_injector/providers.pyx":2764 - * return self.__resource + /* "dependency_injector/providers.pyx":3011 + * future_result.set_result(None) * * @staticmethod # <<<<<<<<<<<<<< * def _is_resource_subclass(instance): * if sys.version_info < (3, 5): */ - __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource, __pyx_n_s_is_resource_subclass); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2765, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource, __pyx_n_s_is_resource_subclass); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3012, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_8 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 2764, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3011, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource->tp_dict, __pyx_n_s_is_resource_subclass, __pyx_t_8) < 0) __PYX_ERR(1, 2765, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource->tp_dict, __pyx_n_s_is_resource_subclass, __pyx_t_8) < 0) __PYX_ERR(1, 3012, __pyx_L1_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; PyType_Modified(__pyx_ptype_19dependency_injector_9providers_Resource); - /* "dependency_injector/providers.pyx":3354 + /* "dependency_injector/providers.pyx":3021 + * + * @staticmethod + * def _is_async_resource_subclass(instance): # <<<<<<<<<<<<<< + * if sys.version_info < (3, 5): + * return False + */ + __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_8Resource_35_is_async_resource_subclass, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3021, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource->tp_dict, __pyx_n_s_is_async_resource_subclass, __pyx_t_8) < 0) __PYX_ERR(1, 3021, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + PyType_Modified(__pyx_ptype_19dependency_injector_9providers_Resource); + + /* "dependency_injector/providers.pyx":3020 + * return issubclass(instance, resources.Resource) + * + * @staticmethod # <<<<<<<<<<<<<< + * def _is_async_resource_subclass(instance): + * if sys.version_info < (3, 5): + */ + __Pyx_GetNameInClass(__pyx_t_8, (PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource, __pyx_n_s_is_async_resource_subclass); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3021, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_8); + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3020, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + if (PyDict_SetItem((PyObject *)__pyx_ptype_19dependency_injector_9providers_Resource->tp_dict, __pyx_n_s_is_async_resource_subclass, __pyx_t_1) < 0) __PYX_ERR(1, 3021, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + PyType_Modified(__pyx_ptype_19dependency_injector_9providers_Resource); + + /* "dependency_injector/providers.pyx":3648 * return copy.deepcopy(instance, memo) * * def __add_sys_streams(memo): # <<<<<<<<<<<<<< * """Add system streams to memo dictionary. * */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_21__add_sys_streams, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3354, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_add_sys_streams, __pyx_t_8) < 0) __PYX_ERR(1, 3354, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_21__add_sys_streams, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3648, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_add_sys_streams, __pyx_t_1) < 0) __PYX_ERR(1, 3648, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pyx":3365 + /* "dependency_injector/providers.pyx":3659 * * * def merge_dicts(dict1, dict2): # <<<<<<<<<<<<<< * """Merge dictionaries recursively. * */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_23merge_dicts, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 3365, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_merge_dicts, __pyx_t_8) < 0) __PYX_ERR(1, 3365, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_23merge_dicts, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3659, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_merge_dicts, __pyx_t_1) < 0) __PYX_ERR(1, 3659, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3680 + * + * + * def isawaitable(obj): # <<<<<<<<<<<<<< + * """Check if object is a coroutine function. + * + */ + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_25isawaitable, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3680, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_isawaitable, __pyx_t_1) < 0) __PYX_ERR(1, 3680, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3691 + * + * + * def iscoroutinefunction(obj): # <<<<<<<<<<<<<< + * """Check if object is a coroutine function. + * + */ + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_27iscoroutinefunction, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3691, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_iscoroutinefunction, __pyx_t_1) < 0) __PYX_ERR(1, 3691, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; + + /* "dependency_injector/providers.pyx":3702 + * + * + * def isasyncgenfunction(obj): # <<<<<<<<<<<<<< + * """Check if object is an asynchronous generator function. + * + */ + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_29isasyncgenfunction, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3702, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_isasyncgenfunction, __pyx_t_1) < 0) __PYX_ERR(1, 3702, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_Provider(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_26__pyx_unpickle_Provider, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Provider, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_32__pyx_unpickle_Provider, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Provider, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_Provider__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Provider__set_state(Provider __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1] - * if len(__pyx_state) > 2 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] + * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_28__pyx_unpickle_Object, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Object, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_34__pyx_unpickle_Object, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Object, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_Delegate(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_30__pyx_unpickle_Delegate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Delegate, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_36__pyx_unpickle_Delegate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Delegate, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_Delegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Delegate__set_state(Delegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_32__pyx_unpickle_Dependency, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Dependency, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_38__pyx_unpickle_Dependency, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Dependency, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_ExternalDependency(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_34__pyx_unpickle_ExternalDependency, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ExternalDependenc, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_40__pyx_unpickle_ExternalDependency, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ExternalDependenc, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_ExternalDependency__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ExternalDependency__set_state(ExternalDependency __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instance_of = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instance_of = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_36__pyx_unpickle_DependenciesContainer, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DependenciesConta, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_42__pyx_unpickle_DependenciesContainer, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DependenciesConta, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_OverridingContext(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_38__pyx_unpickle_OverridingContext, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_OverridingContext, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_44__pyx_unpickle_OverridingContext, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_OverridingContext, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_OverridingContext__set_state( __pyx_result, __pyx_state) @@ -93800,394 +105112,394 @@ if (!__Pyx_RefNanny) { * __pyx_result.__overridden = __pyx_state[0]; __pyx_result.__overriding = __pyx_state[1] * if len(__pyx_state) > 2 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_40__pyx_unpickle_Callable, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Callable, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_46__pyx_unpickle_Callable, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Callable, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_DelegatedCallable(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_42__pyx_unpickle_DelegatedCallable, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedCallable, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_48__pyx_unpickle_DelegatedCallable, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedCallable, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_DelegatedCallable__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedCallable__set_state(DelegatedCallable __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_44__pyx_unpickle_AbstractCallable, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_AbstractCallable, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_50__pyx_unpickle_AbstractCallable, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_AbstractCallable, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_CallableDelegate(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_46__pyx_unpickle_CallableDelegate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_CallableDelegate, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_52__pyx_unpickle_CallableDelegate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_CallableDelegate, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_CallableDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_CallableDelegate__set_state(CallableDelegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_48__pyx_unpickle_Coroutine, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Coroutine, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_54__pyx_unpickle_Coroutine, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Coroutine, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_DelegatedCoroutine(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_50__pyx_unpickle_DelegatedCoroutine, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedCoroutin, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_56__pyx_unpickle_DelegatedCoroutine, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedCoroutin, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_DelegatedCoroutine__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_DelegatedCoroutine__set_state(DelegatedCoroutine __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_52__pyx_unpickle_AbstractCoroutine, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_AbstractCoroutine, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_58__pyx_unpickle_AbstractCoroutine, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_AbstractCoroutine, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_CoroutineDelegate(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_54__pyx_unpickle_CoroutineDelegate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_CoroutineDelegate, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_60__pyx_unpickle_CoroutineDelegate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_CoroutineDelegate, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_CoroutineDelegate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_CoroutineDelegate__set_state(CoroutineDelegate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__provides = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provides = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_56__pyx_unpickle_ConfigurationOption, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ConfigurationOpti, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_62__pyx_unpickle_ConfigurationOption, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ConfigurationOpti, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_TypedConfigurationOption(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_58__pyx_unpickle_TypedConfigurationOption, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_TypedConfiguratio, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_64__pyx_unpickle_TypedConfigurationOption, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_TypedConfiguratio, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_TypedConfigurationOption__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_TypedConfigurationOption__set_state(TypedConfigurationOption __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provides = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provides = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_60__pyx_unpickle_Configuration, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Configuration, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_66__pyx_unpickle_Configuration, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Configuration, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_Factory(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_62__pyx_unpickle_Factory, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Factory, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_68__pyx_unpickle_Factory, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Factory, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_Factory__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Factory__set_state(Factory __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_64__pyx_unpickle_DelegatedFactory, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedFactory, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_70__pyx_unpickle_DelegatedFactory, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedFactory, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_AbstractFactory(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_66__pyx_unpickle_AbstractFactory, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_AbstractFactory, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_72__pyx_unpickle_AbstractFactory, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_AbstractFactory, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_AbstractFactory__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AbstractFactory__set_state(AbstractFactory __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attributes = __pyx_state[0]; __pyx_result.__attributes_len = __pyx_state[1]; __pyx_result.__instantiator = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attributes = __pyx_state[1]; __pyx_result.__attributes_len = __pyx_state[2]; __pyx_result.__instantiator = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_68__pyx_unpickle_FactoryDelegate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_FactoryDelegate, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_74__pyx_unpickle_FactoryDelegate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_FactoryDelegate, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_FactoryAggregate(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_70__pyx_unpickle_FactoryAggregate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_FactoryAggregate, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_76__pyx_unpickle_FactoryAggregate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_FactoryAggregate, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_FactoryAggregate__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_FactoryAggregate__set_state(FactoryAggregate __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__factories = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__factories = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] + * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_72__pyx_unpickle_BaseSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_BaseSingleton, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_78__pyx_unpickle_BaseSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_BaseSingleton, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_Singleton(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_74__pyx_unpickle_Singleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Singleton, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_80__pyx_unpickle_Singleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Singleton, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_Singleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Singleton__set_state(Singleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_76__pyx_unpickle_DelegatedSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedSingleto, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_82__pyx_unpickle_DelegatedSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedSingleto, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_ThreadSafeSingleton(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_78__pyx_unpickle_ThreadSafeSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ThreadSafeSinglet, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_84__pyx_unpickle_ThreadSafeSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ThreadSafeSinglet, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_ThreadSafeSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ThreadSafeSingleton__set_state(ThreadSafeSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3]; __pyx_result.__storage_lock = __pyx_state[4] - * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4]; __pyx_result.__storage_lock = __pyx_state[5] + * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_80__pyx_unpickle_DelegatedThreadSafeSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedThreadSa, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_86__pyx_unpickle_DelegatedThreadSafeSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedThreadSa, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_ThreadLocalSingleton(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_82__pyx_unpickle_ThreadLocalSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ThreadLocalSingle, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_88__pyx_unpickle_ThreadLocalSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ThreadLocalSingle, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_ThreadLocalSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_ThreadLocalSingleton__set_state(ThreadLocalSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__storage = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_84__pyx_unpickle_DelegatedThreadLocalSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedThreadLo, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_90__pyx_unpickle_DelegatedThreadLocalSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_DelegatedThreadLo, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_AbstractSingleton(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_86__pyx_unpickle_AbstractSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_AbstractSingleton, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_92__pyx_unpickle_AbstractSingleton, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_AbstractSingleton, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_AbstractSingleton__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AbstractSingleton__set_state(AbstractSingleton __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__instantiator = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2] - * if len(__pyx_state) > 3 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__instantiator = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__storage = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_88__pyx_unpickle_SingletonDelegate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_SingletonDelegate, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_94__pyx_unpickle_SingletonDelegate, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_SingletonDelegate, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_List(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_90__pyx_unpickle_List, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_List, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_96__pyx_unpickle_List, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_List, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_List__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_List__set_state(List __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__last_overriding = __pyx_state[3]; __pyx_result.__overridden = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_92__pyx_unpickle_Dict, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Dict, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_98__pyx_unpickle_Dict, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Dict, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_Resource(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_94__pyx_unpickle_Resource, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Resource, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_100__pyx_unpickle_Resource, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Resource, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_Resource__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Resource__set_state(Resource __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__initialized = __pyx_state[2]; __pyx_result.__initializer = __pyx_state[3]; __pyx_result.__kwargs = __pyx_state[4]; __pyx_result.__kwargs_len = __pyx_state[5]; __pyx_result.__last_overriding = __pyx_state[6]; __pyx_result.__overridden = __pyx_state[7]; __pyx_result.__resource = __pyx_state[8]; __pyx_result.__shutdowner = __pyx_state[9] - * if len(__pyx_state) > 10 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__initialized = __pyx_state[3]; __pyx_result.__initializer = __pyx_state[4]; __pyx_result.__kwargs = __pyx_state[5]; __pyx_result.__kwargs_len = __pyx_state[6]; __pyx_result.__last_overriding = __pyx_state[7]; __pyx_result.__overridden = __pyx_state[8]; __pyx_result.__resource = __pyx_state[9]; __pyx_result.__shutdowner = __pyx_state[10] + * if len(__pyx_state) > 11 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_96__pyx_unpickle_Container, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Container, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_102__pyx_unpickle_Container, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Container, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_Selector(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_98__pyx_unpickle_Selector, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Selector, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_104__pyx_unpickle_Selector, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Selector, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_Selector__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_Selector__set_state(Selector __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__last_overriding = __pyx_state[0]; __pyx_result.__overridden = __pyx_state[1]; __pyx_result.__providers = __pyx_state[2]; __pyx_result.__selector = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__providers = __pyx_state[3]; __pyx_result.__selector = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_100__pyx_unpickle_ProvidedInstance, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ProvidedInstance, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_106__pyx_unpickle_ProvidedInstance, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ProvidedInstance, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_AttributeGetter(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_102__pyx_unpickle_AttributeGetter, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_AttributeGetter, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_108__pyx_unpickle_AttributeGetter, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_AttributeGetter, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_AttributeGetter__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_AttributeGetter__set_state(AttributeGetter __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__attribute = __pyx_state[0]; __pyx_result.__last_overriding = __pyx_state[1]; __pyx_result.__overridden = __pyx_state[2]; __pyx_result.__provider = __pyx_state[3] - * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__async_mode = __pyx_state[0]; __pyx_result.__attribute = __pyx_state[1]; __pyx_result.__last_overriding = __pyx_state[2]; __pyx_result.__overridden = __pyx_state[3]; __pyx_result.__provider = __pyx_state[4] + * if len(__pyx_state) > 5 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_104__pyx_unpickle_ItemGetter, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ItemGetter, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_110__pyx_unpickle_ItemGetter, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_ItemGetter, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_MethodCaller(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_106__pyx_unpickle_MethodCaller, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_MethodCaller, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_112__pyx_unpickle_MethodCaller, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_MethodCaller, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_MethodCaller__set_state( __pyx_result, __pyx_state) * return __pyx_result * cdef __pyx_unpickle_MethodCaller__set_state(MethodCaller __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<< - * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__kwargs = __pyx_state[2]; __pyx_result.__kwargs_len = __pyx_state[3]; __pyx_result.__last_overriding = __pyx_state[4]; __pyx_result.__overridden = __pyx_state[5]; __pyx_result.__provider = __pyx_state[6] - * if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'): + * __pyx_result.__args = __pyx_state[0]; __pyx_result.__args_len = __pyx_state[1]; __pyx_result.__async_mode = __pyx_state[2]; __pyx_result.__kwargs = __pyx_state[3]; __pyx_result.__kwargs_len = __pyx_state[4]; __pyx_result.__last_overriding = __pyx_state[5]; __pyx_result.__overridden = __pyx_state[6]; __pyx_result.__provider = __pyx_state[7] + * if len(__pyx_state) > 8 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_108__pyx_unpickle_Injection, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Injection, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_114__pyx_unpickle_Injection, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Injection, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":1 * def __pyx_unpickle_PositionalInjection(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<< * cdef object __pyx_PickleError * cdef object __pyx_result */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_110__pyx_unpickle_PositionalInjection, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_PositionalInjecti, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_116__pyx_unpickle_PositionalInjection, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_PositionalInjecti, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "(tree fragment)":11 * __pyx_unpickle_PositionalInjection__set_state( __pyx_result, __pyx_state) @@ -94196,27 +105508,27 @@ if (!__Pyx_RefNanny) { * __pyx_result.__call = __pyx_state[0]; __pyx_result.__is_delegated = __pyx_state[1]; __pyx_result.__is_provider = __pyx_state[2]; __pyx_result.__value = __pyx_state[3] * if len(__pyx_state) > 4 and hasattr(__pyx_result, '__dict__'): */ - __pyx_t_8 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_112__pyx_unpickle_NamedInjection, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_NamedInjection, __pyx_t_8) < 0) __PYX_ERR(2, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_19dependency_injector_9providers_118__pyx_unpickle_NamedInjection, NULL, __pyx_n_s_dependency_injector_providers); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_NamedInjection, __pyx_t_1) < 0) __PYX_ERR(2, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "dependency_injector/providers.pyx":1 * """Providers module.""" # <<<<<<<<<<<<<< * * from __future__ import absolute_import */ - __pyx_t_8 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 1, __pyx_L1_error) - __Pyx_GOTREF(__pyx_t_8); - if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_8) < 0) __PYX_ERR(1, 1, __pyx_L1_error) - __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1, __pyx_L1_error) + __Pyx_GOTREF(__pyx_t_1); + if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_1) < 0) __PYX_ERR(1, 1, __pyx_L1_error) + __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "dependency_injector/providers.pxd":447 - * - * - * cdef inline object __factory_call(Factory self, tuple args, dict kwargs): # <<<<<<<<<<<<<< - * cdef object instance + /* "cfunc.to_py":64 * + * @cname("__Pyx_CFunc_void____object___to_py") + * cdef object __Pyx_CFunc_void____object___to_py(void (*f)(object) except *): # <<<<<<<<<<<<<< + * def wrap(object future): + * """wrap(future) -> 'void'""" */ /*--- Wrapped vars code ---*/ @@ -95402,6 +106714,106 @@ static CYTHON_INLINE PyObject *__Pyx_GetAttr3(PyObject *o, PyObject *n, PyObject return (likely(r)) ? r : __Pyx_GetAttr3Default(d); } +/* FastTypeChecks */ +#if CYTHON_COMPILING_IN_CPYTHON +static int __Pyx_InBases(PyTypeObject *a, PyTypeObject *b) { + while (a) { + a = a->tp_base; + if (a == b) + return 1; + } + return b == &PyBaseObject_Type; +} +static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b) { + PyObject *mro; + if (a == b) return 1; + mro = a->tp_mro; + if (likely(mro)) { + Py_ssize_t i, n; + n = PyTuple_GET_SIZE(mro); + for (i = 0; i < n; i++) { + if (PyTuple_GET_ITEM(mro, i) == (PyObject *)b) + return 1; + } + return 0; + } + return __Pyx_InBases(a, b); +} +#if PY_MAJOR_VERSION == 2 +static int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject* exc_type2) { + PyObject *exception, *value, *tb; + int res; + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + __Pyx_ErrFetch(&exception, &value, &tb); + res = exc_type1 ? PyObject_IsSubclass(err, exc_type1) : 0; + if (unlikely(res == -1)) { + PyErr_WriteUnraisable(err); + res = 0; + } + if (!res) { + res = PyObject_IsSubclass(err, exc_type2); + if (unlikely(res == -1)) { + PyErr_WriteUnraisable(err); + res = 0; + } + } + __Pyx_ErrRestore(exception, value, tb); + return res; +} +#else +static CYTHON_INLINE int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject *exc_type2) { + int res = exc_type1 ? __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type1) : 0; + if (!res) { + res = __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type2); + } + return res; +} +#endif +static int __Pyx_PyErr_GivenExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) { + Py_ssize_t i, n; + assert(PyExceptionClass_Check(exc_type)); + n = PyTuple_GET_SIZE(tuple); +#if PY_MAJOR_VERSION >= 3 + for (i=0; itp_base; - if (a == b) - return 1; - } - return b == &PyBaseObject_Type; -} -static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b) { - PyObject *mro; - if (a == b) return 1; - mro = a->tp_mro; - if (likely(mro)) { - Py_ssize_t i, n; - n = PyTuple_GET_SIZE(mro); - for (i = 0; i < n; i++) { - if (PyTuple_GET_ITEM(mro, i) == (PyObject *)b) - return 1; - } - return 0; - } - return __Pyx_InBases(a, b); -} -#if PY_MAJOR_VERSION == 2 -static int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject* exc_type2) { - PyObject *exception, *value, *tb; - int res; - __Pyx_PyThreadState_declare - __Pyx_PyThreadState_assign - __Pyx_ErrFetch(&exception, &value, &tb); - res = exc_type1 ? PyObject_IsSubclass(err, exc_type1) : 0; - if (unlikely(res == -1)) { - PyErr_WriteUnraisable(err); - res = 0; - } - if (!res) { - res = PyObject_IsSubclass(err, exc_type2); - if (unlikely(res == -1)) { - PyErr_WriteUnraisable(err); - res = 0; - } - } - __Pyx_ErrRestore(exception, value, tb); - return res; -} -#else -static CYTHON_INLINE int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject *exc_type2) { - int res = exc_type1 ? __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type1) : 0; - if (!res) { - res = __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type2); - } - return res; -} -#endif -static int __Pyx_PyErr_GivenExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) { - Py_ssize_t i, n; - assert(PyExceptionClass_Check(exc_type)); - n = PyTuple_GET_SIZE(tuple); -#if PY_MAJOR_VERSION >= 3 - for (i=0; i 0x030600B3 + if ((1)) { + return _PyDict_Pop(d, key, default_value); + } else +#endif + if (default_value) { + return __Pyx_CallUnboundCMethod2(&__pyx_umethod_PyDict_Type_pop, d, key, default_value); + } else { + return __Pyx_CallUnboundCMethod1(&__pyx_umethod_PyDict_Type_pop, d, key); + } +} + /* DictGetItem */ #if PY_MAJOR_VERSION >= 3 && !CYTHON_COMPILING_IN_PYPY static PyObject *__Pyx_PyDict_GetItem(PyObject *d, PyObject* key) { @@ -96098,6 +107424,87 @@ static CYTHON_INLINE PyObject *__Pyx_PyIter_Next2(PyObject* iterator, PyObject* return __Pyx_PyIter_Next2Default(defval); } +/* StopAsyncIteration */ +#if PY_VERSION_HEX < 0x030500B1 +static PyTypeObject __Pyx__PyExc_StopAsyncIteration_type = { + PyVarObject_HEAD_INIT(0, 0) + "StopAsyncIteration", + sizeof(PyBaseExceptionObject), + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE | Py_TPFLAGS_HAVE_GC, + PyDoc_STR("Signal the end from iterator.__anext__()."), + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, +#if PY_VERSION_HEX >= 0x030400a1 + 0, +#endif +}; +#endif +static int __pyx_StopAsyncIteration_init(void) { +#if PY_VERSION_HEX >= 0x030500B1 + __Pyx_PyExc_StopAsyncIteration = PyExc_StopAsyncIteration; +#else + PyObject *builtins = PyEval_GetBuiltins(); + if (likely(builtins)) { + PyObject *exc = PyMapping_GetItemString(builtins, (char*) "StopAsyncIteration"); + if (exc) { + __Pyx_PyExc_StopAsyncIteration = exc; + return 0; + } + } + PyErr_Clear(); + __Pyx__PyExc_StopAsyncIteration_type.tp_traverse = ((PyTypeObject*)PyExc_BaseException)->tp_traverse; + __Pyx__PyExc_StopAsyncIteration_type.tp_clear = ((PyTypeObject*)PyExc_BaseException)->tp_clear; + __Pyx__PyExc_StopAsyncIteration_type.tp_dictoffset = ((PyTypeObject*)PyExc_BaseException)->tp_dictoffset; + __Pyx__PyExc_StopAsyncIteration_type.tp_base = (PyTypeObject*)PyExc_Exception; + __Pyx_PyExc_StopAsyncIteration = (PyObject*) __Pyx_FetchCommonType(&__Pyx__PyExc_StopAsyncIteration_type); + if (unlikely(!__Pyx_PyExc_StopAsyncIteration)) + return -1; + if (builtins && unlikely(PyMapping_SetItemString(builtins, (char*) "StopAsyncIteration", __Pyx_PyExc_StopAsyncIteration) < 0)) + return -1; +#endif + return 0; +} + /* Import */ static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level) { PyObject *empty_list = 0; @@ -96458,395 +107865,6 @@ static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); } -/* PyObject_GenericGetAttrNoDict */ -#if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000 -static PyObject *__Pyx_RaiseGenericGetAttributeError(PyTypeObject *tp, PyObject *attr_name) { - PyErr_Format(PyExc_AttributeError, -#if PY_MAJOR_VERSION >= 3 - "'%.50s' object has no attribute '%U'", - tp->tp_name, attr_name); -#else - "'%.50s' object has no attribute '%.400s'", - tp->tp_name, PyString_AS_STRING(attr_name)); -#endif - return NULL; -} -static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name) { - PyObject *descr; - PyTypeObject *tp = Py_TYPE(obj); - if (unlikely(!PyString_Check(attr_name))) { - return PyObject_GenericGetAttr(obj, attr_name); - } - assert(!tp->tp_dictoffset); - descr = _PyType_Lookup(tp, attr_name); - if (unlikely(!descr)) { - return __Pyx_RaiseGenericGetAttributeError(tp, attr_name); - } - Py_INCREF(descr); - #if PY_MAJOR_VERSION < 3 - if (likely(PyType_HasFeature(Py_TYPE(descr), Py_TPFLAGS_HAVE_CLASS))) - #endif - { - descrgetfunc f = Py_TYPE(descr)->tp_descr_get; - if (unlikely(f)) { - PyObject *res = f(descr, obj, (PyObject *)tp); - Py_DECREF(descr); - return res; - } - } - return descr; -} -#endif - -/* PyObject_GenericGetAttr */ -#if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000 -static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name) { - if (unlikely(Py_TYPE(obj)->tp_dictoffset)) { - return PyObject_GenericGetAttr(obj, attr_name); - } - return __Pyx_PyObject_GenericGetAttrNoDict(obj, attr_name); -} -#endif - -/* SetVTable */ -static int __Pyx_SetVtable(PyObject *dict, void *vtable) { -#if PY_VERSION_HEX >= 0x02070000 - PyObject *ob = PyCapsule_New(vtable, 0, 0); -#else - PyObject *ob = PyCObject_FromVoidPtr(vtable, 0); -#endif - if (!ob) - goto bad; - if (PyDict_SetItem(dict, __pyx_n_s_pyx_vtable, ob) < 0) - goto bad; - Py_DECREF(ob); - return 0; -bad: - Py_XDECREF(ob); - return -1; -} - -/* PyObjectGetAttrStrNoError */ -static void __Pyx_PyObject_GetAttrStr_ClearAttributeError(void) { - __Pyx_PyThreadState_declare - __Pyx_PyThreadState_assign - if (likely(__Pyx_PyErr_ExceptionMatches(PyExc_AttributeError))) - __Pyx_PyErr_Clear(); -} -static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStrNoError(PyObject* obj, PyObject* attr_name) { - PyObject *result; -#if CYTHON_COMPILING_IN_CPYTHON && CYTHON_USE_TYPE_SLOTS && PY_VERSION_HEX >= 0x030700B1 - PyTypeObject* tp = Py_TYPE(obj); - if (likely(tp->tp_getattro == PyObject_GenericGetAttr)) { - return _PyObject_GenericGetAttrWithDict(obj, attr_name, NULL, 1); - } -#endif - result = __Pyx_PyObject_GetAttrStr(obj, attr_name); - if (unlikely(!result)) { - __Pyx_PyObject_GetAttrStr_ClearAttributeError(); - } - return result; -} - -/* SetupReduce */ -static int __Pyx_setup_reduce_is_named(PyObject* meth, PyObject* name) { - int ret; - PyObject *name_attr; - name_attr = __Pyx_PyObject_GetAttrStr(meth, __pyx_n_s_name); - if (likely(name_attr)) { - ret = PyObject_RichCompareBool(name_attr, name, Py_EQ); - } else { - ret = -1; - } - if (unlikely(ret < 0)) { - PyErr_Clear(); - ret = 0; - } - Py_XDECREF(name_attr); - return ret; -} -static int __Pyx_setup_reduce(PyObject* type_obj) { - int ret = 0; - PyObject *object_reduce = NULL; - PyObject *object_reduce_ex = NULL; - PyObject *reduce = NULL; - PyObject *reduce_ex = NULL; - PyObject *reduce_cython = NULL; - PyObject *setstate = NULL; - PyObject *setstate_cython = NULL; -#if CYTHON_USE_PYTYPE_LOOKUP - if (_PyType_Lookup((PyTypeObject*)type_obj, __pyx_n_s_getstate)) goto __PYX_GOOD; -#else - if (PyObject_HasAttr(type_obj, __pyx_n_s_getstate)) goto __PYX_GOOD; -#endif -#if CYTHON_USE_PYTYPE_LOOKUP - object_reduce_ex = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto __PYX_BAD; -#else - object_reduce_ex = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto __PYX_BAD; -#endif - reduce_ex = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce_ex); if (unlikely(!reduce_ex)) goto __PYX_BAD; - if (reduce_ex == object_reduce_ex) { -#if CYTHON_USE_PYTYPE_LOOKUP - object_reduce = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto __PYX_BAD; -#else - object_reduce = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto __PYX_BAD; -#endif - reduce = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce); if (unlikely(!reduce)) goto __PYX_BAD; - if (reduce == object_reduce || __Pyx_setup_reduce_is_named(reduce, __pyx_n_s_reduce_cython)) { - reduce_cython = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_reduce_cython); - if (likely(reduce_cython)) { - ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce, reduce_cython); if (unlikely(ret < 0)) goto __PYX_BAD; - ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce_cython); if (unlikely(ret < 0)) goto __PYX_BAD; - } else if (reduce == object_reduce || PyErr_Occurred()) { - goto __PYX_BAD; - } - setstate = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_setstate); - if (!setstate) PyErr_Clear(); - if (!setstate || __Pyx_setup_reduce_is_named(setstate, __pyx_n_s_setstate_cython)) { - setstate_cython = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_setstate_cython); - if (likely(setstate_cython)) { - ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate, setstate_cython); if (unlikely(ret < 0)) goto __PYX_BAD; - ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate_cython); if (unlikely(ret < 0)) goto __PYX_BAD; - } else if (!setstate || PyErr_Occurred()) { - goto __PYX_BAD; - } - } - PyType_Modified((PyTypeObject*)type_obj); - } - } - goto __PYX_GOOD; -__PYX_BAD: - if (!PyErr_Occurred()) - PyErr_Format(PyExc_RuntimeError, "Unable to initialize pickling for %s", ((PyTypeObject*)type_obj)->tp_name); - ret = -1; -__PYX_GOOD: -#if !CYTHON_USE_PYTYPE_LOOKUP - Py_XDECREF(object_reduce); - Py_XDECREF(object_reduce_ex); -#endif - Py_XDECREF(reduce); - Py_XDECREF(reduce_ex); - Py_XDECREF(reduce_cython); - Py_XDECREF(setstate); - Py_XDECREF(setstate_cython); - return ret; -} - -/* PatchModuleWithCoroutine */ -static PyObject* __Pyx_Coroutine_patch_module(PyObject* module, const char* py_code) { -#if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED) - int result; - PyObject *globals, *result_obj; - globals = PyDict_New(); if (unlikely(!globals)) goto ignore; - result = PyDict_SetItemString(globals, "_cython_coroutine_type", - #ifdef __Pyx_Coroutine_USED - (PyObject*)__pyx_CoroutineType); - #else - Py_None); - #endif - if (unlikely(result < 0)) goto ignore; - result = PyDict_SetItemString(globals, "_cython_generator_type", - #ifdef __Pyx_Generator_USED - (PyObject*)__pyx_GeneratorType); - #else - Py_None); - #endif - if (unlikely(result < 0)) goto ignore; - if (unlikely(PyDict_SetItemString(globals, "_module", module) < 0)) goto ignore; - if (unlikely(PyDict_SetItemString(globals, "__builtins__", __pyx_b) < 0)) goto ignore; - result_obj = PyRun_String(py_code, Py_file_input, globals, globals); - if (unlikely(!result_obj)) goto ignore; - Py_DECREF(result_obj); - Py_DECREF(globals); - return module; -ignore: - Py_XDECREF(globals); - PyErr_WriteUnraisable(module); - if (unlikely(PyErr_WarnEx(PyExc_RuntimeWarning, "Cython module failed to patch module with custom type", 1) < 0)) { - Py_DECREF(module); - module = NULL; - } -#else - py_code++; -#endif - return module; -} - -/* PatchInspect */ -static PyObject* __Pyx_patch_inspect(PyObject* module) { -#if defined(__Pyx_Generator_USED) && (!defined(CYTHON_PATCH_INSPECT) || CYTHON_PATCH_INSPECT) - static int inspect_patched = 0; - if (unlikely((!inspect_patched) && module)) { - module = __Pyx_Coroutine_patch_module( - module, "" -"old_types = getattr(_module.isgenerator, '_cython_generator_types', None)\n" -"if old_types is None or not isinstance(old_types, set):\n" -" old_types = set()\n" -" def cy_wrap(orig_func, type=type, cython_generator_types=old_types):\n" -" def cy_isgenerator(obj): return type(obj) in cython_generator_types or orig_func(obj)\n" -" cy_isgenerator._cython_generator_types = cython_generator_types\n" -" return cy_isgenerator\n" -" _module.isgenerator = cy_wrap(_module.isgenerator)\n" -"old_types.add(_cython_generator_type)\n" - ); - inspect_patched = 1; - } -#else - if ((0)) return __Pyx_Coroutine_patch_module(module, NULL); -#endif - return module; -} - -/* PatchAsyncIO */ -static PyObject* __Pyx_patch_asyncio(PyObject* module) { -#if PY_VERSION_HEX < 0x030500B2 &&\ - (defined(__Pyx_Coroutine_USED) || defined(__Pyx_Generator_USED)) &&\ - (!defined(CYTHON_PATCH_ASYNCIO) || CYTHON_PATCH_ASYNCIO) - PyObject *patch_module = NULL; - static int asyncio_patched = 0; - if (unlikely((!asyncio_patched) && module)) { - PyObject *package; - package = __Pyx_Import(__pyx_n_s_asyncio_coroutines, NULL, 0); - if (package) { - patch_module = __Pyx_Coroutine_patch_module( - PyObject_GetAttrString(package, "coroutines"), "" -"try:\n" -" coro_types = _module._COROUTINE_TYPES\n" -"except AttributeError: pass\n" -"else:\n" -" if _cython_coroutine_type is not None and _cython_coroutine_type not in coro_types:\n" -" coro_types = tuple(coro_types) + (_cython_coroutine_type,)\n" -" if _cython_generator_type is not None and _cython_generator_type not in coro_types:\n" -" coro_types = tuple(coro_types) + (_cython_generator_type,)\n" -"_module._COROUTINE_TYPES = coro_types\n" - ); - } else { - PyErr_Clear(); - package = __Pyx_Import(__pyx_n_s_asyncio_tasks, NULL, 0); - if (unlikely(!package)) goto asyncio_done; - patch_module = __Pyx_Coroutine_patch_module( - PyObject_GetAttrString(package, "tasks"), "" -"if hasattr(_module, 'iscoroutine'):\n" -" old_types = getattr(_module.iscoroutine, '_cython_coroutine_types', None)\n" -" if old_types is None or not isinstance(old_types, set):\n" -" old_types = set()\n" -" def cy_wrap(orig_func, type=type, cython_coroutine_types=old_types):\n" -" def cy_iscoroutine(obj): return type(obj) in cython_coroutine_types or orig_func(obj)\n" -" cy_iscoroutine._cython_coroutine_types = cython_coroutine_types\n" -" return cy_iscoroutine\n" -" _module.iscoroutine = cy_wrap(_module.iscoroutine)\n" -" if _cython_coroutine_type is not None:\n" -" old_types.add(_cython_coroutine_type)\n" -" if _cython_generator_type is not None:\n" -" old_types.add(_cython_generator_type)\n" - ); - } - Py_DECREF(package); - if (unlikely(!patch_module)) goto ignore; -asyncio_done: - PyErr_Clear(); - asyncio_patched = 1; -#ifdef __Pyx_Generator_USED - { - PyObject *inspect_module; - if (patch_module) { - inspect_module = PyObject_GetAttr(patch_module, __pyx_n_s_inspect); - Py_DECREF(patch_module); - } else { - inspect_module = __Pyx_Import(__pyx_n_s_inspect, NULL, 0); - } - if (unlikely(!inspect_module)) goto ignore; - inspect_module = __Pyx_patch_inspect(inspect_module); - if (unlikely(!inspect_module)) { - Py_DECREF(module); - module = NULL; - } - Py_XDECREF(inspect_module); - } -#else - if ((0)) return __Pyx_patch_inspect(module); -#endif - } - return module; -ignore: - PyErr_WriteUnraisable(module); - if (unlikely(PyErr_WarnEx(PyExc_RuntimeWarning, "Cython module failed to patch asyncio package with custom generator type", 1) < 0)) { - Py_DECREF(module); - module = NULL; - } -#else - if ((0)) return __Pyx_patch_inspect(__Pyx_Coroutine_patch_module(module, NULL)); -#endif - return module; -} - -/* PyIntCompare */ -static CYTHON_INLINE PyObject* __Pyx_PyInt_EqObjC(PyObject *op1, PyObject *op2, CYTHON_UNUSED long intval, CYTHON_UNUSED long inplace) { - if (op1 == op2) { - Py_RETURN_TRUE; - } - #if PY_MAJOR_VERSION < 3 - if (likely(PyInt_CheckExact(op1))) { - const long b = intval; - long a = PyInt_AS_LONG(op1); - if (a == b) Py_RETURN_TRUE; else Py_RETURN_FALSE; - } - #endif - #if CYTHON_USE_PYLONG_INTERNALS - if (likely(PyLong_CheckExact(op1))) { - int unequal; - unsigned long uintval; - Py_ssize_t size = Py_SIZE(op1); - const digit* digits = ((PyLongObject*)op1)->ob_digit; - if (intval == 0) { - if (size == 0) Py_RETURN_TRUE; else Py_RETURN_FALSE; - } else if (intval < 0) { - if (size >= 0) - Py_RETURN_FALSE; - intval = -intval; - size = -size; - } else { - if (size <= 0) - Py_RETURN_FALSE; - } - uintval = (unsigned long) intval; -#if PyLong_SHIFT * 4 < SIZEOF_LONG*8 - if (uintval >> (PyLong_SHIFT * 4)) { - unequal = (size != 5) || (digits[0] != (uintval & (unsigned long) PyLong_MASK)) - | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[3] != ((uintval >> (3 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[4] != ((uintval >> (4 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)); - } else -#endif -#if PyLong_SHIFT * 3 < SIZEOF_LONG*8 - if (uintval >> (PyLong_SHIFT * 3)) { - unequal = (size != 4) || (digits[0] != (uintval & (unsigned long) PyLong_MASK)) - | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[3] != ((uintval >> (3 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)); - } else -#endif -#if PyLong_SHIFT * 2 < SIZEOF_LONG*8 - if (uintval >> (PyLong_SHIFT * 2)) { - unequal = (size != 3) || (digits[0] != (uintval & (unsigned long) PyLong_MASK)) - | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)); - } else -#endif -#if PyLong_SHIFT * 1 < SIZEOF_LONG*8 - if (uintval >> (PyLong_SHIFT * 1)) { - unequal = (size != 2) || (digits[0] != (uintval & (unsigned long) PyLong_MASK)) - | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)); - } else -#endif - unequal = (size != 1) || (((unsigned long) digits[0]) != (uintval & (unsigned long) PyLong_MASK)); - if (unequal == 0) Py_RETURN_TRUE; else Py_RETURN_FALSE; - } - #endif - if (PyFloat_CheckExact(op1)) { - const long b = intval; - double a = PyFloat_AS_DOUBLE(op1); - if ((double)a == (double)b) Py_RETURN_TRUE; else Py_RETURN_FALSE; - } - return ( - PyObject_RichCompare(op1, op2, Py_EQ)); -} - /* FetchCommonType */ static PyTypeObject* __Pyx_FetchCommonType(PyTypeObject* type) { PyObject* fake_module; @@ -97503,6 +108521,395 @@ static PyObject *__Pyx_CyFunction_New(PyMethodDef *ml, int flags, PyObject* qual return op; } +/* PyObject_GenericGetAttrNoDict */ +#if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000 +static PyObject *__Pyx_RaiseGenericGetAttributeError(PyTypeObject *tp, PyObject *attr_name) { + PyErr_Format(PyExc_AttributeError, +#if PY_MAJOR_VERSION >= 3 + "'%.50s' object has no attribute '%U'", + tp->tp_name, attr_name); +#else + "'%.50s' object has no attribute '%.400s'", + tp->tp_name, PyString_AS_STRING(attr_name)); +#endif + return NULL; +} +static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name) { + PyObject *descr; + PyTypeObject *tp = Py_TYPE(obj); + if (unlikely(!PyString_Check(attr_name))) { + return PyObject_GenericGetAttr(obj, attr_name); + } + assert(!tp->tp_dictoffset); + descr = _PyType_Lookup(tp, attr_name); + if (unlikely(!descr)) { + return __Pyx_RaiseGenericGetAttributeError(tp, attr_name); + } + Py_INCREF(descr); + #if PY_MAJOR_VERSION < 3 + if (likely(PyType_HasFeature(Py_TYPE(descr), Py_TPFLAGS_HAVE_CLASS))) + #endif + { + descrgetfunc f = Py_TYPE(descr)->tp_descr_get; + if (unlikely(f)) { + PyObject *res = f(descr, obj, (PyObject *)tp); + Py_DECREF(descr); + return res; + } + } + return descr; +} +#endif + +/* PyObject_GenericGetAttr */ +#if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000 +static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name) { + if (unlikely(Py_TYPE(obj)->tp_dictoffset)) { + return PyObject_GenericGetAttr(obj, attr_name); + } + return __Pyx_PyObject_GenericGetAttrNoDict(obj, attr_name); +} +#endif + +/* SetVTable */ +static int __Pyx_SetVtable(PyObject *dict, void *vtable) { +#if PY_VERSION_HEX >= 0x02070000 + PyObject *ob = PyCapsule_New(vtable, 0, 0); +#else + PyObject *ob = PyCObject_FromVoidPtr(vtable, 0); +#endif + if (!ob) + goto bad; + if (PyDict_SetItem(dict, __pyx_n_s_pyx_vtable, ob) < 0) + goto bad; + Py_DECREF(ob); + return 0; +bad: + Py_XDECREF(ob); + return -1; +} + +/* PyObjectGetAttrStrNoError */ +static void __Pyx_PyObject_GetAttrStr_ClearAttributeError(void) { + __Pyx_PyThreadState_declare + __Pyx_PyThreadState_assign + if (likely(__Pyx_PyErr_ExceptionMatches(PyExc_AttributeError))) + __Pyx_PyErr_Clear(); +} +static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStrNoError(PyObject* obj, PyObject* attr_name) { + PyObject *result; +#if CYTHON_COMPILING_IN_CPYTHON && CYTHON_USE_TYPE_SLOTS && PY_VERSION_HEX >= 0x030700B1 + PyTypeObject* tp = Py_TYPE(obj); + if (likely(tp->tp_getattro == PyObject_GenericGetAttr)) { + return _PyObject_GenericGetAttrWithDict(obj, attr_name, NULL, 1); + } +#endif + result = __Pyx_PyObject_GetAttrStr(obj, attr_name); + if (unlikely(!result)) { + __Pyx_PyObject_GetAttrStr_ClearAttributeError(); + } + return result; +} + +/* SetupReduce */ +static int __Pyx_setup_reduce_is_named(PyObject* meth, PyObject* name) { + int ret; + PyObject *name_attr; + name_attr = __Pyx_PyObject_GetAttrStr(meth, __pyx_n_s_name); + if (likely(name_attr)) { + ret = PyObject_RichCompareBool(name_attr, name, Py_EQ); + } else { + ret = -1; + } + if (unlikely(ret < 0)) { + PyErr_Clear(); + ret = 0; + } + Py_XDECREF(name_attr); + return ret; +} +static int __Pyx_setup_reduce(PyObject* type_obj) { + int ret = 0; + PyObject *object_reduce = NULL; + PyObject *object_reduce_ex = NULL; + PyObject *reduce = NULL; + PyObject *reduce_ex = NULL; + PyObject *reduce_cython = NULL; + PyObject *setstate = NULL; + PyObject *setstate_cython = NULL; +#if CYTHON_USE_PYTYPE_LOOKUP + if (_PyType_Lookup((PyTypeObject*)type_obj, __pyx_n_s_getstate)) goto __PYX_GOOD; +#else + if (PyObject_HasAttr(type_obj, __pyx_n_s_getstate)) goto __PYX_GOOD; +#endif +#if CYTHON_USE_PYTYPE_LOOKUP + object_reduce_ex = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto __PYX_BAD; +#else + object_reduce_ex = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto __PYX_BAD; +#endif + reduce_ex = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce_ex); if (unlikely(!reduce_ex)) goto __PYX_BAD; + if (reduce_ex == object_reduce_ex) { +#if CYTHON_USE_PYTYPE_LOOKUP + object_reduce = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto __PYX_BAD; +#else + object_reduce = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto __PYX_BAD; +#endif + reduce = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce); if (unlikely(!reduce)) goto __PYX_BAD; + if (reduce == object_reduce || __Pyx_setup_reduce_is_named(reduce, __pyx_n_s_reduce_cython)) { + reduce_cython = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_reduce_cython); + if (likely(reduce_cython)) { + ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce, reduce_cython); if (unlikely(ret < 0)) goto __PYX_BAD; + ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce_cython); if (unlikely(ret < 0)) goto __PYX_BAD; + } else if (reduce == object_reduce || PyErr_Occurred()) { + goto __PYX_BAD; + } + setstate = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_setstate); + if (!setstate) PyErr_Clear(); + if (!setstate || __Pyx_setup_reduce_is_named(setstate, __pyx_n_s_setstate_cython)) { + setstate_cython = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_setstate_cython); + if (likely(setstate_cython)) { + ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate, setstate_cython); if (unlikely(ret < 0)) goto __PYX_BAD; + ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate_cython); if (unlikely(ret < 0)) goto __PYX_BAD; + } else if (!setstate || PyErr_Occurred()) { + goto __PYX_BAD; + } + } + PyType_Modified((PyTypeObject*)type_obj); + } + } + goto __PYX_GOOD; +__PYX_BAD: + if (!PyErr_Occurred()) + PyErr_Format(PyExc_RuntimeError, "Unable to initialize pickling for %s", ((PyTypeObject*)type_obj)->tp_name); + ret = -1; +__PYX_GOOD: +#if !CYTHON_USE_PYTYPE_LOOKUP + Py_XDECREF(object_reduce); + Py_XDECREF(object_reduce_ex); +#endif + Py_XDECREF(reduce); + Py_XDECREF(reduce_ex); + Py_XDECREF(reduce_cython); + Py_XDECREF(setstate); + Py_XDECREF(setstate_cython); + return ret; +} + +/* PatchModuleWithCoroutine */ +static PyObject* __Pyx_Coroutine_patch_module(PyObject* module, const char* py_code) { +#if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED) + int result; + PyObject *globals, *result_obj; + globals = PyDict_New(); if (unlikely(!globals)) goto ignore; + result = PyDict_SetItemString(globals, "_cython_coroutine_type", + #ifdef __Pyx_Coroutine_USED + (PyObject*)__pyx_CoroutineType); + #else + Py_None); + #endif + if (unlikely(result < 0)) goto ignore; + result = PyDict_SetItemString(globals, "_cython_generator_type", + #ifdef __Pyx_Generator_USED + (PyObject*)__pyx_GeneratorType); + #else + Py_None); + #endif + if (unlikely(result < 0)) goto ignore; + if (unlikely(PyDict_SetItemString(globals, "_module", module) < 0)) goto ignore; + if (unlikely(PyDict_SetItemString(globals, "__builtins__", __pyx_b) < 0)) goto ignore; + result_obj = PyRun_String(py_code, Py_file_input, globals, globals); + if (unlikely(!result_obj)) goto ignore; + Py_DECREF(result_obj); + Py_DECREF(globals); + return module; +ignore: + Py_XDECREF(globals); + PyErr_WriteUnraisable(module); + if (unlikely(PyErr_WarnEx(PyExc_RuntimeWarning, "Cython module failed to patch module with custom type", 1) < 0)) { + Py_DECREF(module); + module = NULL; + } +#else + py_code++; +#endif + return module; +} + +/* PatchInspect */ +static PyObject* __Pyx_patch_inspect(PyObject* module) { +#if defined(__Pyx_Generator_USED) && (!defined(CYTHON_PATCH_INSPECT) || CYTHON_PATCH_INSPECT) + static int inspect_patched = 0; + if (unlikely((!inspect_patched) && module)) { + module = __Pyx_Coroutine_patch_module( + module, "" +"old_types = getattr(_module.isgenerator, '_cython_generator_types', None)\n" +"if old_types is None or not isinstance(old_types, set):\n" +" old_types = set()\n" +" def cy_wrap(orig_func, type=type, cython_generator_types=old_types):\n" +" def cy_isgenerator(obj): return type(obj) in cython_generator_types or orig_func(obj)\n" +" cy_isgenerator._cython_generator_types = cython_generator_types\n" +" return cy_isgenerator\n" +" _module.isgenerator = cy_wrap(_module.isgenerator)\n" +"old_types.add(_cython_generator_type)\n" + ); + inspect_patched = 1; + } +#else + if ((0)) return __Pyx_Coroutine_patch_module(module, NULL); +#endif + return module; +} + +/* PatchAsyncIO */ +static PyObject* __Pyx_patch_asyncio(PyObject* module) { +#if PY_VERSION_HEX < 0x030500B2 &&\ + (defined(__Pyx_Coroutine_USED) || defined(__Pyx_Generator_USED)) &&\ + (!defined(CYTHON_PATCH_ASYNCIO) || CYTHON_PATCH_ASYNCIO) + PyObject *patch_module = NULL; + static int asyncio_patched = 0; + if (unlikely((!asyncio_patched) && module)) { + PyObject *package; + package = __Pyx_Import(__pyx_n_s_asyncio_coroutines, NULL, 0); + if (package) { + patch_module = __Pyx_Coroutine_patch_module( + PyObject_GetAttrString(package, "coroutines"), "" +"try:\n" +" coro_types = _module._COROUTINE_TYPES\n" +"except AttributeError: pass\n" +"else:\n" +" if _cython_coroutine_type is not None and _cython_coroutine_type not in coro_types:\n" +" coro_types = tuple(coro_types) + (_cython_coroutine_type,)\n" +" if _cython_generator_type is not None and _cython_generator_type not in coro_types:\n" +" coro_types = tuple(coro_types) + (_cython_generator_type,)\n" +"_module._COROUTINE_TYPES = coro_types\n" + ); + } else { + PyErr_Clear(); + package = __Pyx_Import(__pyx_n_s_asyncio_tasks, NULL, 0); + if (unlikely(!package)) goto asyncio_done; + patch_module = __Pyx_Coroutine_patch_module( + PyObject_GetAttrString(package, "tasks"), "" +"if hasattr(_module, 'iscoroutine'):\n" +" old_types = getattr(_module.iscoroutine, '_cython_coroutine_types', None)\n" +" if old_types is None or not isinstance(old_types, set):\n" +" old_types = set()\n" +" def cy_wrap(orig_func, type=type, cython_coroutine_types=old_types):\n" +" def cy_iscoroutine(obj): return type(obj) in cython_coroutine_types or orig_func(obj)\n" +" cy_iscoroutine._cython_coroutine_types = cython_coroutine_types\n" +" return cy_iscoroutine\n" +" _module.iscoroutine = cy_wrap(_module.iscoroutine)\n" +" if _cython_coroutine_type is not None:\n" +" old_types.add(_cython_coroutine_type)\n" +" if _cython_generator_type is not None:\n" +" old_types.add(_cython_generator_type)\n" + ); + } + Py_DECREF(package); + if (unlikely(!patch_module)) goto ignore; +asyncio_done: + PyErr_Clear(); + asyncio_patched = 1; +#ifdef __Pyx_Generator_USED + { + PyObject *inspect_module; + if (patch_module) { + inspect_module = PyObject_GetAttr(patch_module, __pyx_n_s_inspect); + Py_DECREF(patch_module); + } else { + inspect_module = __Pyx_Import(__pyx_n_s_inspect, NULL, 0); + } + if (unlikely(!inspect_module)) goto ignore; + inspect_module = __Pyx_patch_inspect(inspect_module); + if (unlikely(!inspect_module)) { + Py_DECREF(module); + module = NULL; + } + Py_XDECREF(inspect_module); + } +#else + if ((0)) return __Pyx_patch_inspect(module); +#endif + } + return module; +ignore: + PyErr_WriteUnraisable(module); + if (unlikely(PyErr_WarnEx(PyExc_RuntimeWarning, "Cython module failed to patch asyncio package with custom generator type", 1) < 0)) { + Py_DECREF(module); + module = NULL; + } +#else + if ((0)) return __Pyx_patch_inspect(__Pyx_Coroutine_patch_module(module, NULL)); +#endif + return module; +} + +/* PyIntCompare */ +static CYTHON_INLINE PyObject* __Pyx_PyInt_EqObjC(PyObject *op1, PyObject *op2, CYTHON_UNUSED long intval, CYTHON_UNUSED long inplace) { + if (op1 == op2) { + Py_RETURN_TRUE; + } + #if PY_MAJOR_VERSION < 3 + if (likely(PyInt_CheckExact(op1))) { + const long b = intval; + long a = PyInt_AS_LONG(op1); + if (a == b) Py_RETURN_TRUE; else Py_RETURN_FALSE; + } + #endif + #if CYTHON_USE_PYLONG_INTERNALS + if (likely(PyLong_CheckExact(op1))) { + int unequal; + unsigned long uintval; + Py_ssize_t size = Py_SIZE(op1); + const digit* digits = ((PyLongObject*)op1)->ob_digit; + if (intval == 0) { + if (size == 0) Py_RETURN_TRUE; else Py_RETURN_FALSE; + } else if (intval < 0) { + if (size >= 0) + Py_RETURN_FALSE; + intval = -intval; + size = -size; + } else { + if (size <= 0) + Py_RETURN_FALSE; + } + uintval = (unsigned long) intval; +#if PyLong_SHIFT * 4 < SIZEOF_LONG*8 + if (uintval >> (PyLong_SHIFT * 4)) { + unequal = (size != 5) || (digits[0] != (uintval & (unsigned long) PyLong_MASK)) + | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[3] != ((uintval >> (3 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[4] != ((uintval >> (4 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)); + } else +#endif +#if PyLong_SHIFT * 3 < SIZEOF_LONG*8 + if (uintval >> (PyLong_SHIFT * 3)) { + unequal = (size != 4) || (digits[0] != (uintval & (unsigned long) PyLong_MASK)) + | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[3] != ((uintval >> (3 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)); + } else +#endif +#if PyLong_SHIFT * 2 < SIZEOF_LONG*8 + if (uintval >> (PyLong_SHIFT * 2)) { + unequal = (size != 3) || (digits[0] != (uintval & (unsigned long) PyLong_MASK)) + | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)); + } else +#endif +#if PyLong_SHIFT * 1 < SIZEOF_LONG*8 + if (uintval >> (PyLong_SHIFT * 1)) { + unequal = (size != 2) || (digits[0] != (uintval & (unsigned long) PyLong_MASK)) + | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)); + } else +#endif + unequal = (size != 1) || (((unsigned long) digits[0]) != (uintval & (unsigned long) PyLong_MASK)); + if (unequal == 0) Py_RETURN_TRUE; else Py_RETURN_FALSE; + } + #endif + if (PyFloat_CheckExact(op1)) { + const long b = intval; + double a = PyFloat_AS_DOUBLE(op1); + if ((double)a == (double)b) Py_RETURN_TRUE; else Py_RETURN_FALSE; + } + return ( + PyObject_RichCompare(op1, op2, Py_EQ)); +} + /* CalculateMetaclass */ static PyObject *__Pyx_CalculateMetaclass(PyTypeObject *metaclass, PyObject *bases) { Py_ssize_t i, nbases = PyTuple_GET_SIZE(bases); diff --git a/src/dependency_injector/providers.pxd b/src/dependency_injector/providers.pxd index 90f3ca9d..55ec23ca 100644 --- a/src/dependency_injector/providers.pxd +++ b/src/dependency_injector/providers.pxd @@ -1,5 +1,12 @@ """Providers module.""" +try: + import asyncio +except ImportError: + asyncio = None + +import inspect + cimport cython @@ -7,6 +14,7 @@ cimport cython cdef class Provider(object): cdef tuple __overridden cdef Provider __last_overriding + cdef int __async_mode cpdef object _provide(self, tuple args, dict kwargs) cpdef void _copy_overridings(self, Provider copied, dict memo) @@ -134,10 +142,10 @@ cdef class FactoryAggregate(Provider): # Singleton providers cdef class BaseSingleton(Provider): cdef Factory __instantiator + cdef object __storage cdef class Singleton(BaseSingleton): - cdef object __storage cpdef object _provide(self, tuple args, dict kwargs) @@ -147,7 +155,6 @@ cdef class DelegatedSingleton(Singleton): cdef class ThreadSafeSingleton(BaseSingleton): - cdef object __storage cdef object __storage_lock cpdef object _provide(self, tuple args, dict kwargs) @@ -158,7 +165,6 @@ cdef class DelegatedThreadSafeSingleton(ThreadSafeSingleton): cdef class ThreadLocalSingleton(BaseSingleton): - cdef object __storage cpdef object _provide(self, tuple args, dict kwargs) @@ -331,30 +337,38 @@ cdef inline tuple __separate_prefixed_kwargs(dict kwargs): @cython.boundscheck(False) @cython.wraparound(False) -cdef inline tuple __provide_positional_args( +cdef inline object __provide_positional_args( tuple args, tuple inj_args, int inj_args_len, ): cdef int index - cdef list positional_args + cdef list positional_args = [] + cdef list awaitables = [] cdef PositionalInjection injection if inj_args_len == 0: return args - positional_args = list() for index in range(inj_args_len): injection = inj_args[index] - positional_args.append(__get_value(injection)) + value = __get_value(injection) + positional_args.append(value) + + if __isawaitable(value): + awaitables.append((index, value)) + positional_args.extend(args) - return tuple(positional_args) + if awaitables: + return __awaitable_args_kwargs_future(positional_args, awaitables) + + return positional_args @cython.boundscheck(False) @cython.wraparound(False) -cdef inline dict __provide_keyword_args( +cdef inline object __provide_keyword_args( dict kwargs, tuple inj_kwargs, int inj_kwargs_len, @@ -362,14 +376,18 @@ cdef inline dict __provide_keyword_args( cdef int index cdef object name cdef object value - cdef dict prefixed + cdef dict prefixed = {} + cdef list awaitables = [] cdef NamedInjection kw_injection if len(kwargs) == 0: for index in range(inj_kwargs_len): kw_injection = inj_kwargs[index] name = __get_name(kw_injection) - kwargs[name] = __get_value(kw_injection) + value = __get_value(kw_injection) + kwargs[name] = value + if __isawaitable(value): + awaitables.append((name, value)) else: kwargs, prefixed = __separate_prefixed_kwargs(kwargs) @@ -387,23 +405,77 @@ cdef inline dict __provide_keyword_args( value = __get_value(kw_injection) kwargs[name] = value + if __isawaitable(value): + awaitables.append((name, value)) + + if awaitables: + return __awaitable_args_kwargs_future(kwargs, awaitables) return kwargs +cdef inline object __awaitable_args_kwargs_future(object args, list awaitables): + future_result = asyncio.Future() + + args_future = asyncio.Future() + args_future.set_result((future_result, args, awaitables)) + + args_ready = asyncio.gather(args_future, *[value for _, value in awaitables]) + args_ready.add_done_callback(__async_prepare_args_kwargs_callback) + asyncio.ensure_future(args_ready) + + return future_result + + +cdef inline void __async_prepare_args_kwargs_callback(object future): + (future_result, args, awaitables), *awaited = future.result() + for value, (key, _) in zip(awaited, awaitables): + args[key] = value + future_result.set_result(args) + + @cython.boundscheck(False) @cython.wraparound(False) -cdef inline object __inject_attributes( - object instance, - tuple attributes, - int attributes_len, -): +cdef inline object __provide_attributes(tuple attributes, int attributes_len): cdef NamedInjection attr_injection + cdef dict attribute_injections = {} + cdef list awaitables = [] + for index in range(attributes_len): attr_injection = attributes[index] - setattr(instance, - __get_name(attr_injection), - __get_value(attr_injection)) + name = __get_name(attr_injection) + value = __get_value(attr_injection) + attribute_injections[name] = value + if __isawaitable(value): + awaitables.append((name, value)) + + if awaitables: + return __awaitable_args_kwargs_future(attribute_injections, awaitables) + + return attribute_injections + + +cdef inline object __async_inject_attributes(future_instance, future_attributes): + future_result = asyncio.Future() + + future = asyncio.Future() + future.set_result(future_result) + + attributes_ready = asyncio.gather(future, future_instance, future_attributes) + attributes_ready.add_done_callback(__async_inject_attributes_callback) + asyncio.ensure_future(attributes_ready) + + return future_result + +cdef inline void __async_inject_attributes_callback(future): + future_result, instance, attributes = future.result() + __inject_attributes(instance, attributes) + future_result.set_result(instance) + + +cdef inline void __inject_attributes(object instance, dict attributes): + for name, value in attributes.items(): + setattr(instance, name, value) cdef inline object __call( @@ -411,25 +483,53 @@ cdef inline object __call( tuple context_args, tuple injection_args, int injection_args_len, - dict kwargs, + dict context_kwargs, tuple injection_kwargs, int injection_kwargs_len, ): - cdef tuple positional_args - cdef dict keyword_args - - positional_args = __provide_positional_args( + args = __provide_positional_args( context_args, injection_args, injection_args_len, ) - keyword_args = __provide_keyword_args( - kwargs, + kwargs = __provide_keyword_args( + context_kwargs, injection_kwargs, injection_kwargs_len, ) - return call(*positional_args, **keyword_args) + args_awaitable = __isawaitable(args) + kwargs_awaitable = __isawaitable(kwargs) + + if args_awaitable or kwargs_awaitable: + if not args_awaitable: + future = asyncio.Future() + future.set_result(args) + args = future + + if not kwargs_awaitable: + future = asyncio.Future() + future.set_result(kwargs) + kwargs = future + + future_result = asyncio.Future() + + future = asyncio.Future() + future.set_result((future_result, call)) + + args_kwargs_ready = asyncio.gather(future, args, kwargs) + args_kwargs_ready.add_done_callback(__async_call_callback) + asyncio.ensure_future(args_kwargs_ready) + + return future_result + + return call(*args, **kwargs) + + +cdef inline void __async_call_callback(object future): + (future_result, call), args, kwargs = future.result() + result = call(*args, **kwargs) + future_result.set_result(result) cdef inline object __callable_call(Callable self, tuple args, dict kwargs): @@ -450,8 +550,40 @@ cdef inline object __factory_call(Factory self, tuple args, dict kwargs): instance = __callable_call(self.__instantiator, args, kwargs) if self.__attributes_len > 0: - __inject_attributes(instance, - self.__attributes, - self.__attributes_len) + attributes = __provide_attributes(self.__attributes, self.__attributes_len) + + instance_awaitable = __isawaitable(instance) + attributes_awaitable = __isawaitable(attributes) + + if instance_awaitable or attributes_awaitable: + if not instance_awaitable: + future = asyncio.Future() + future.set_result(instance) + instance = future + + if not attributes_awaitable: + future = asyncio.Future() + future.set_result(attributes) + attributes = future + + return __async_inject_attributes(instance, attributes) + + __inject_attributes(instance, attributes) return instance + + +cdef bint __has_isawaitable = False + + +cdef inline bint __isawaitable(object instance): + global __has_isawaitable + + if __has_isawaitable is True: + return inspect.isawaitable(instance) + + if hasattr(inspect, 'isawaitable'): + __has_isawaitable = True + return inspect.isawaitable(instance) + + return False diff --git a/src/dependency_injector/providers.pyi b/src/dependency_injector/providers.pyi index 983f80db..61a598f8 100644 --- a/src/dependency_injector/providers.pyi +++ b/src/dependency_injector/providers.pyi @@ -2,6 +2,7 @@ from __future__ import annotations from pathlib import Path from typing import ( + Awaitable, TypeVar, Generic, Type, @@ -14,6 +15,7 @@ from typing import ( Union, Coroutine as _Coroutine, Iterator as _Iterator, + AsyncIterator as _AsyncIterator, Generator as _Generator, overload, ) @@ -33,7 +35,13 @@ class OverridingContext: class Provider(Generic[T]): def __init__(self) -> None: ... + + @overload def __call__(self, *args: Injection, **kwargs: Injection) -> T: ... + @overload + def __call__(self, *args: Injection, **kwargs: Injection) -> Awaitable[T]: ... + def async_(self, *args: Injection, **kwargs: Injection) -> Awaitable[T]: ... + def __deepcopy__(self, memo: Optional[_Dict[Any, Any]]) -> Provider: ... def __str__(self) -> str: ... def __repr__(self) -> str: ... @@ -49,30 +57,33 @@ class Provider(Generic[T]): def provider(self) -> Provider: ... @property def provided(self) -> ProvidedInstance: ... + def enable_async_mode(self) -> None: ... + def disable_async_mode(self) -> None: ... + def reset_async_mode(self) -> None: ... + def is_async_mode_enabled(self) -> bool: ... + def is_async_mode_disabled(self) -> bool: ... + def is_async_mode_undefined(self) -> bool: ... def _copy_overridings(self, copied: Provider, memo: Optional[_Dict[Any, Any]]) -> None: ... -class Object(Provider, Generic[T]): +class Object(Provider[T]): def __init__(self, provides: T) -> None: ... - def __call__(self, *args: Injection, **kwargs: Injection) -> T: ... -class Delegate(Provider): +class Delegate(Provider[Provider]): def __init__(self, provides: Provider) -> None: ... - def __call__(self, *args: Injection, **kwargs: Injection) -> Provider: ... @property def provides(self) -> Provider: ... -class Dependency(Provider, Generic[T]): +class Dependency(Provider[T]): def __init__(self, instance_of: Type[T] = object) -> None: ... - def __call__(self, *args: Injection, **kwargs: Injection) -> T: ... @property def instance_of(self) -> Type[T]: ... def provided_by(self, provider: Provider) -> OverridingContext: ... -class ExternalDependency(Dependency): ... +class ExternalDependency(Dependency[T]): ... class DependenciesContainer(Object): @@ -82,9 +93,8 @@ class DependenciesContainer(Object): def providers(self) -> _Dict[str, Provider]: ... -class Callable(Provider, Generic[T]): +class Callable(Provider[T]): def __init__(self, provides: _Callable[..., T], *args: Injection, **kwargs: Injection) -> None: ... - def __call__(self, *args: Injection, **kwargs: Injection) -> T: ... @property def provides(self) -> T: ... @property @@ -93,16 +103,16 @@ class Callable(Provider, Generic[T]): def set_args(self, *args: Injection) -> Callable[T]: ... def clear_args(self) -> Callable[T]: ... @property - def kwargs(self) -> _Dict[str, Injection]: ... + def kwargs(self) -> _Dict[Any, Injection]: ... def add_kwargs(self, **kwargs: Injection) -> Callable[T]: ... def set_kwargs(self, **kwargs: Injection) -> Callable[T]: ... def clear_kwargs(self) -> Callable[T]: ... -class DelegatedCallable(Callable): ... +class DelegatedCallable(Callable[T]): ... -class AbstractCallable(Callable): +class AbstractCallable(Callable[T]): def override(self, provider: Callable) -> OverridingContext: ... @@ -110,13 +120,13 @@ class CallableDelegate(Delegate): def __init__(self, callable: Callable) -> None: ... -class Coroutine(Callable): ... +class Coroutine(Callable[T]): ... -class DelegatedCoroutine(Coroutine): ... +class DelegatedCoroutine(Coroutine[T]): ... -class AbstractCoroutine(Coroutine): +class AbstractCoroutine(Coroutine[T]): def override(self, provider: Coroutine) -> OverridingContext: ... @@ -124,10 +134,9 @@ class CoroutineDelegate(Delegate): def __init__(self, coroutine: Coroutine) -> None: ... -class ConfigurationOption(Provider): +class ConfigurationOption(Provider[Any]): UNDEFINED: object def __init__(self, name: Tuple[str], root: Configuration) -> None: ... - def __call__(self, *args: Injection, **kwargs: Injection) -> Any: ... def __getattr__(self, item: str) -> ConfigurationOption: ... def __getitem__(self, item: Union[str, Provider]) -> ConfigurationOption: ... @property @@ -149,7 +158,7 @@ class TypedConfigurationOption(Callable[T]): def option(self) -> ConfigurationOption: ... -class Configuration(Object): +class Configuration(Object[Any]): DEFAULT_NAME: str = 'config' def __init__(self, name: str = DEFAULT_NAME, default: Optional[Any] = None) -> None: ... def __getattr__(self, item: str) -> ConfigurationOption: ... @@ -165,10 +174,9 @@ class Configuration(Object): def from_env(self, name: str, default: Optional[Any] = None) -> None: ... -class Factory(Provider, Generic[T]): +class Factory(Provider[T]): provided_type: Optional[Type] def __init__(self, provides: _Callable[..., T], *args: Injection, **kwargs: Injection) -> None: ... - def __call__(self, *args: Injection, **kwargs: Injection) -> T: ... @property def cls(self) -> T: ... @property @@ -179,21 +187,21 @@ class Factory(Provider, Generic[T]): def set_args(self, *args: Injection) -> Factory[T]: ... def clear_args(self) -> Factory[T]: ... @property - def kwargs(self) -> _Dict[str, Injection]: ... + def kwargs(self) -> _Dict[Any, Injection]: ... def add_kwargs(self, **kwargs: Injection) -> Factory[T]: ... def set_kwargs(self, **kwargs: Injection) -> Factory[T]: ... def clear_kwargs(self) -> Factory[T]: ... @property - def attributes(self) -> _Dict[str, Injection]: ... + def attributes(self) -> _Dict[Any, Injection]: ... def add_attributes(self, **kwargs: Injection) -> Factory[T]: ... def set_attributes(self, **kwargs: Injection) -> Factory[T]: ... def clear_attributes(self) -> Factory[T]: ... -class DelegatedFactory(Factory): ... +class DelegatedFactory(Factory[T]): ... -class AbstractFactory(Factory): +class AbstractFactory(Factory[T]): def override(self, provider: Factory) -> OverridingContext: ... @@ -203,55 +211,60 @@ class FactoryDelegate(Delegate): class FactoryAggregate(Provider): def __init__(self, **factories: Factory): ... - def __call__(self, factory_name: str, *args: Injection, **kwargs: Injection) -> Any: ... def __getattr__(self, factory_name: str) -> Factory: ... + + @overload + def __call__(self, factory_name: str, *args: Injection, **kwargs: Injection) -> Any: ... + @overload + def __call__(self, factory_name: str, *args: Injection, **kwargs: Injection) -> Awaitable[Any]: ... + def async_(self, factory_name: str, *args: Injection, **kwargs: Injection) -> Awaitable[Any]: ... + @property def factories(self) -> _Dict[str, Factory]: ... -class BaseSingleton(Provider, Generic[T]): +class BaseSingleton(Provider[T]): provided_type = Optional[Type] def __init__(self, provides: _Callable[..., T], *args: Injection, **kwargs: Injection) -> None: ... - def __call__(self, *args: Injection, **kwargs: Injection) -> T: ... @property def cls(self) -> T: ... @property def args(self) -> Tuple[Injection]: ... - def add_args(self, *args: Injection) -> Factory[T]: ... - def set_args(self, *args: Injection) -> Factory[T]: ... - def clear_args(self) -> Factory[T]: ... + def add_args(self, *args: Injection) -> BaseSingleton[T]: ... + def set_args(self, *args: Injection) -> BaseSingleton[T]: ... + def clear_args(self) -> BaseSingleton[T]: ... @property - def kwargs(self) -> _Dict[str, Injection]: ... - def add_kwargs(self, **kwargs: Injection) -> Factory[T]: ... - def set_kwargs(self, **kwargs: Injection) -> Factory[T]: ... - def clear_kwargs(self) -> Factory[T]: ... + def kwargs(self) -> _Dict[Any, Injection]: ... + def add_kwargs(self, **kwargs: Injection) -> BaseSingleton[T]: ... + def set_kwargs(self, **kwargs: Injection) -> BaseSingleton[T]: ... + def clear_kwargs(self) -> BaseSingleton[T]: ... @property - def attributes(self) -> _Dict[str, Injection]: ... - def add_attributes(self, **kwargs: Injection) -> Factory[T]: ... - def set_attributes(self, **kwargs: Injection) -> Factory[T]: ... - def clear_attributes(self) -> Factory[T]: ... + def attributes(self) -> _Dict[Any, Injection]: ... + def add_attributes(self, **kwargs: Injection) -> BaseSingleton[T]: ... + def set_attributes(self, **kwargs: Injection) -> BaseSingleton[T]: ... + def clear_attributes(self) -> BaseSingleton[T]: ... def reset(self) -> None: ... -class Singleton(BaseSingleton): ... +class Singleton(BaseSingleton[T]): ... -class DelegatedSingleton(Singleton): ... +class DelegatedSingleton(Singleton[T]): ... -class ThreadSafeSingleton(Singleton): ... +class ThreadSafeSingleton(Singleton[T]): ... -class DelegatedThreadSafeSingleton(ThreadSafeSingleton): ... +class DelegatedThreadSafeSingleton(ThreadSafeSingleton[T]): ... -class ThreadLocalSingleton(BaseSingleton): ... +class ThreadLocalSingleton(BaseSingleton[T]): ... -class DelegatedThreadLocalSingleton(ThreadLocalSingleton): ... +class DelegatedThreadLocalSingleton(ThreadLocalSingleton[T]): ... -class AbstractSingleton(BaseSingleton): +class AbstractSingleton(BaseSingleton[T]): def override(self, provider: BaseSingleton) -> OverridingContext: ... @@ -259,19 +272,17 @@ class SingletonDelegate(Delegate): def __init__(self, factory: BaseSingleton): ... -class List(Provider): +class List(Provider[_List]): def __init__(self, *args: Injection): ... - def __call__(self, *args: Injection, **kwargs: Injection) -> _List[Any]: ... @property def args(self) -> Tuple[Injection]: ... - def add_args(self, *args: Injection) -> List: ... - def set_args(self, *args: Injection) -> List: ... - def clear_args(self) -> List: ... + def add_args(self, *args: Injection) -> List[T]: ... + def set_args(self, *args: Injection) -> List[T]: ... + def clear_args(self) -> List[T]: ... -class Dict(Provider): +class Dict(Provider[_Dict]): def __init__(self, dict_: Optional[_Dict[Any, Injection]] = None, **kwargs: Injection): ... - def __call__(self, *args: Injection, **kwargs: Injection) -> _Dict[Any, Any]: ... @property def kwargs(self) -> _Dict[Any, Injection]: ... def add_kwargs(self, dict_: Optional[_Dict[Any, Injection]] = None, **kwargs: Injection) -> Dict: ... @@ -279,42 +290,44 @@ class Dict(Provider): def clear_kwargs(self) -> Dict: ... -class Resource(Provider, Generic[T]): +class Resource(Provider[T]): @overload - def __init__(self, initializer: _Callable[..., resources.Resource[T]], *args: Injection, **kwargs: Injection) -> None: ... + def __init__(self, initializer: Type[resources.Resource[T]], *args: Injection, **kwargs: Injection) -> None: ... + @overload + def __init__(self, initializer: Type[resources.AsyncResource[T]], *args: Injection, **kwargs: Injection) -> None: ... @overload def __init__(self, initializer: _Callable[..., _Iterator[T]], *args: Injection, **kwargs: Injection) -> None: ... @overload + def __init__(self, initializer: _Callable[..., _AsyncIterator[T]], *args: Injection, **kwargs: Injection) -> None: ... + @overload + def __init__(self, initializer: _Callable[..., _Coroutine[Injection, Injection, T]], *args: Injection, **kwargs: Injection) -> None: ... + @overload def __init__(self, initializer: _Callable[..., T], *args: Injection, **kwargs: Injection) -> None: ... - def __call__(self, *args: Injection, **kwargs: Injection) -> T: ... @property def args(self) -> Tuple[Injection]: ... - def add_args(self, *args: Injection) -> Resource: ... - def set_args(self, *args: Injection) -> Resource: ... - def clear_args(self) -> Resource: ... + def add_args(self, *args: Injection) -> Resource[T]: ... + def set_args(self, *args: Injection) -> Resource[T]: ... + def clear_args(self) -> Resource[T]: ... @property def kwargs(self) -> _Dict[Any, Injection]: ... - def add_kwargs(self, **kwargs: Injection) -> Resource: ... - def set_kwargs(self, **kwargs: Injection) -> Resource: ... - def clear_kwargs(self) -> Resource: ... + def add_kwargs(self, **kwargs: Injection) -> Resource[T]: ... + def set_kwargs(self, **kwargs: Injection) -> Resource[T]: ... + def clear_kwargs(self) -> Resource[T]: ... @property def initialized(self) -> bool: ... - def init(self) -> T: ... - def shutdown(self) -> None: ... + def init(self) -> Optional[Awaitable[T]]: ... + def shutdown(self) -> Optional[Awaitable]: ... -class Container(Provider): - +class Container(Provider[T]): def __init__(self, container_cls: Type[T], container: Optional[T] = None, **overriding_providers: Provider) -> None: ... - def __call__(self, *args: Injection, **kwargs: Injection) -> T: ... def __getattr__(self, name: str) -> Provider: ... @property def container(self) -> T: ... -class Selector(Provider): +class Selector(Provider[Any]): def __init__(self, selector: _Callable[..., Any], **providers: Provider): ... - def __call__(self, *args: Injection, **kwargs: Injection) -> Any: ... def __getattr__(self, name: str) -> Provider: ... @property def providers(self) -> _Dict[str, Provider]: ... diff --git a/src/dependency_injector/providers.pyx b/src/dependency_injector/providers.pyx index 919c24e2..666d4526 100644 --- a/src/dependency_injector/providers.pyx +++ b/src/dependency_injector/providers.pyx @@ -3,6 +3,7 @@ from __future__ import absolute_import import copy +import functools import inspect import os import re @@ -88,6 +89,11 @@ else: return parser +cdef int ASYNC_MODE_UNDEFINED = 0 +cdef int ASYNC_MODE_ENABLED = 1 +cdef int ASYNC_MODE_DISABLED = 2 + + cdef class Provider(object): """Base provider class. @@ -148,6 +154,7 @@ cdef class Provider(object): """Initializer.""" self.__overridden = tuple() self.__last_overriding = None + self.__async_mode = ASYNC_MODE_UNDEFINED super(Provider, self).__init__() def __call__(self, *args, **kwargs): @@ -156,8 +163,24 @@ cdef class Provider(object): Callable interface implementation. """ if self.__last_overriding is not None: - return self.__last_overriding(*args, **kwargs) - return self._provide(args, kwargs) + result = self.__last_overriding(*args, **kwargs) + else: + result = self._provide(args, kwargs) + + if self.is_async_mode_disabled(): + return result + elif self.is_async_mode_enabled(): + if not __isawaitable(result): + future_result = asyncio.Future() + future_result.set_result(result) + return future_result + return result + elif self.is_async_mode_undefined(): + if __isawaitable(result): + self.enable_async_mode() + else: + self.disable_async_mode() + return result def __deepcopy__(self, memo): """Create and return full copy of provider.""" @@ -254,6 +277,23 @@ cdef class Provider(object): self.__overridden = tuple() self.__last_overriding = None + def async_(self, *args, **kwargs): + """Return provided object asynchronously. + + This method is a synonym of __call__(). + It provides typing stubs for correct type checking with + `await` expression: + + .. code-block:: python + + database_provider: Provider[DatabaseConnection] = Resource(init_db_async) + + async def main(): + db: DatabaseConnection = await database_provider.async_() + ... + """ + return self.__call__(*args, **kwargs) + def delegate(self): """Return provider's delegate. @@ -279,6 +319,33 @@ cdef class Provider(object): """Return :py:class:`ProvidedInstance` provider.""" return ProvidedInstance(self) + def enable_async_mode(self): + """Enable async mode.""" + self.__async_mode = ASYNC_MODE_ENABLED + + def disable_async_mode(self): + """Disable async mode.""" + self.__async_mode = ASYNC_MODE_DISABLED + + def reset_async_mode(self): + """Reset async mode. + + Provider will automatically set the mode on the next call. + """ + self.__async_mode = ASYNC_MODE_UNDEFINED + + def is_async_mode_enabled(self): + """Check if async mode is enabled.""" + return self.__async_mode == ASYNC_MODE_ENABLED + + def is_async_mode_disabled(self): + """Check if async mode is disabled.""" + return self.__async_mode == ASYNC_MODE_DISABLED + + def is_async_mode_undefined(self): + """Check if async mode is undefined.""" + return self.__async_mode == ASYNC_MODE_UNDEFINED + cpdef object _provide(self, tuple args, dict kwargs): """Providing strategy implementation. @@ -472,18 +539,38 @@ cdef class Dependency(Provider): :rtype: object """ - cdef object instance - if self.__last_overriding is None: raise Error('Dependency is not defined') - instance = self.__last_overriding(*args, **kwargs) + result = self.__last_overriding(*args, **kwargs) - if not isinstance(instance, self.instance_of): - raise Error('{0} is not an '.format(instance) + - 'instance of {0}'.format(self.instance_of)) - return instance + if self.is_async_mode_disabled(): + self._check_instance_type(result) + return result + elif self.is_async_mode_enabled(): + if __isawaitable(result): + future_result = asyncio.Future() + result = asyncio.ensure_future(result) + result.add_done_callback(functools.partial(self._async_provide, future_result)) + return future_result + else: + self._check_instance_type(result) + future_result = asyncio.Future() + future_result.set_result(result) + return future_result + elif self.is_async_mode_undefined(): + if __isawaitable(result): + self.enable_async_mode() + + future_result = asyncio.Future() + result = asyncio.ensure_future(result) + result.add_done_callback(functools.partial(self._async_provide, future_result)) + return future_result + else: + self.disable_async_mode() + self._check_instance_type(result) + return result def __str__(self): """Return string representation of provider. @@ -514,6 +601,19 @@ cdef class Dependency(Provider): """ return self.override(provider) + def _async_provide(self, future_result, future): + instance = future.result() + try: + self._check_instance_type(instance) + except Error as exception: + future_result.set_exception(exception) + else: + future_result.set_result(instance) + + def _check_instance_type(self, instance): + if not isinstance(instance, self.instance_of): + raise Error('{0} is not an instance of {1}'.format(instance, self.instance_of)) + cdef class ExternalDependency(Dependency): """:py:class:`ExternalDependency` provider describes dependency interface. @@ -904,7 +1004,7 @@ cdef class AbstractCallable(Callable): """ if self.__last_overriding is None: raise Error('{0} must be overridden before calling'.format(self)) - return self.__last_overriding(*args, **kwargs) + return super().__call__(*args, **kwargs) def override(self, provider): """Override provider with another provider. @@ -1020,7 +1120,7 @@ cdef class AbstractCoroutine(Coroutine): """ if self.__last_overriding is None: raise Error('{0} must be overridden before calling'.format(self)) - return self.__last_overriding(*args, **kwargs) + return super().__call__(*args, **kwargs) def override(self, provider): """Override provider with another provider. @@ -1790,7 +1890,7 @@ cdef class AbstractFactory(Factory): """ if self.__last_overriding is None: raise Error('{0} must be overridden before calling'.format(self)) - return self.__last_overriding(*args, **kwargs) + return super().__call__(*args, **kwargs) def override(self, provider): """Override provider with another provider. @@ -1881,13 +1981,6 @@ cdef class FactoryAggregate(Provider): return copied - def __call__(self, factory_name, *args, **kwargs): - """Create new object using factory with provided name. - - Callable interface implementation. - """ - return self.__get_factory(factory_name)(*args, **kwargs) - def __getattr__(self, factory_name): """Return aggregated factory.""" return self.__get_factory(factory_name) @@ -1915,6 +2008,19 @@ cdef class FactoryAggregate(Provider): raise Error( '{0} providers could not be overridden'.format(self.__class__)) + cpdef object _provide(self, tuple args, dict kwargs): + try: + factory_name = args[0] + except IndexError: + try: + factory_name = kwargs.pop('factory_name') + except KeyError: + raise TypeError('Factory missing 1 required positional argument: \'factory_name\'') + else: + args = args[1:] + + return self.__get_factory(factory_name)(*args, **kwargs) + cdef Factory __get_factory(self, str factory_name): if factory_name not in self.__factories: raise NoSuchProviderError( @@ -2075,6 +2181,16 @@ cdef class BaseSingleton(Provider): """ raise NotImplementedError() + def _async_init_instance(self, future_result, result): + try: + instance = result.result() + except Exception as exception: + self.__storage = None + future_result.set_exception(exception) + else: + self.__storage = instance + future_result.set_result(instance) + cdef class Singleton(BaseSingleton): """Singleton provider returns same instance on every call. @@ -2122,13 +2238,24 @@ cdef class Singleton(BaseSingleton): :rtype: None """ + if __isawaitable(self.__storage): + asyncio.ensure_future(self.__storage).cancel() self.__storage = None cpdef object _provide(self, tuple args, dict kwargs): """Return single instance.""" if self.__storage is None: - self.__storage = __factory_call(self.__instantiator, - args, kwargs) + instance = __factory_call(self.__instantiator, args, kwargs) + + if __isawaitable(instance): + future_result = asyncio.Future() + instance = asyncio.ensure_future(instance) + instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + self.__storage = future_result + return future_result + + self.__storage = instance + return self.__storage @@ -2179,18 +2306,30 @@ cdef class ThreadSafeSingleton(BaseSingleton): :rtype: None """ with self.__storage_lock: + if __isawaitable(self.__storage): + asyncio.ensure_future(self.__storage).cancel() self.__storage = None + cpdef object _provide(self, tuple args, dict kwargs): """Return single instance.""" - storage = self.__storage - if storage is None: + instance = self.__storage + + if instance is None: with self.__storage_lock: if self.__storage is None: - self.__storage = __factory_call(self.__instantiator, - args, kwargs) - storage = self.__storage - return storage + instance = __factory_call(self.__instantiator, args, kwargs) + + if __isawaitable(instance): + future_result = asyncio.Future() + instance = asyncio.ensure_future(instance) + instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + self.__storage = future_result + return future_result + + self.__storage = instance + + return instance cdef class DelegatedThreadSafeSingleton(ThreadSafeSingleton): @@ -2248,6 +2387,8 @@ cdef class ThreadLocalSingleton(BaseSingleton): :rtype: None """ + if __isawaitable(self.__storage.instance): + asyncio.ensure_future(self.__storage.instance).cancel() del self.__storage.instance cpdef object _provide(self, tuple args, dict kwargs): @@ -2258,10 +2399,28 @@ cdef class ThreadLocalSingleton(BaseSingleton): instance = self.__storage.instance except AttributeError: instance = __factory_call(self.__instantiator, args, kwargs) + + if __isawaitable(instance): + future_result = asyncio.Future() + instance = asyncio.ensure_future(instance) + instance.add_done_callback(functools.partial(self._async_init_instance, future_result)) + self.__storage.instance = future_result + return future_result + self.__storage.instance = instance finally: return instance + def _async_init_instance(self, future_result, result): + try: + instance = result.result() + except Exception as exception: + del self.__storage.instance + future_result.set_exception(exception) + else: + self.__storage.instance = instance + future_result.set_result(instance) + cdef class DelegatedThreadLocalSingleton(ThreadLocalSingleton): """Delegated thread-local singleton is injected "as is". @@ -2302,7 +2461,7 @@ cdef class AbstractSingleton(BaseSingleton): """ if self.__last_overriding is None: raise Error('{0} must be overridden before calling'.format(self)) - return self.__last_overriding(*args, **kwargs) + return super().__call__(*args, **kwargs) def override(self, provider): """Override provider with another provider. @@ -2705,18 +2864,30 @@ cdef class Resource(Provider): def shutdown(self): """Shutdown resource.""" if not self.__initialized: + if self.is_async_mode_enabled(): + result = asyncio.Future() + result.set_result(None) + return result return if self.__shutdowner: try: - self.__shutdowner(self.__resource) + shutdown = self.__shutdowner(self.__resource) except StopIteration: pass + else: + if inspect.isawaitable(shutdown): + return self._create_shutdown_future(shutdown) self.__resource = None self.__initialized = False self.__shutdowner = None + if self.is_async_mode_enabled(): + result = asyncio.Future() + result.set_result(None) + return result + cpdef object _provide(self, tuple args, dict kwargs): if self.__initialized: return self.__resource @@ -2733,6 +2904,19 @@ cdef class Resource(Provider): self.__kwargs_len, ) self.__shutdowner = initializer.shutdown + elif self._is_async_resource_subclass(self.__initializer): + initializer = self.__initializer() + async_init = __call( + initializer.init, + args, + self.__args, + self.__args_len, + kwargs, + self.__kwargs, + self.__kwargs_len, + ) + self.__initialized = True + return self._create_init_future(async_init, initializer.shutdown) elif inspect.isgeneratorfunction(self.__initializer): initializer = __call( self.__initializer, @@ -2745,6 +2929,30 @@ cdef class Resource(Provider): ) self.__resource = next(initializer) self.__shutdowner = initializer.send + elif iscoroutinefunction(self.__initializer): + initializer = __call( + self.__initializer, + args, + self.__args, + self.__args_len, + kwargs, + self.__kwargs, + self.__kwargs_len, + ) + self.__initialized = True + return self._create_init_future(initializer) + elif isasyncgenfunction(self.__initializer): + initializer = __call( + self.__initializer, + args, + self.__args, + self.__args_len, + kwargs, + self.__kwargs, + self.__kwargs_len, + ) + self.__initialized = True + return self._create_init_future(initializer.__anext__(), initializer.asend) elif callable(self.__initializer): self.__resource = __call( self.__initializer, @@ -2761,6 +2969,45 @@ cdef class Resource(Provider): self.__initialized = True return self.__resource + def _create_init_future(self, future, shutdowner=None): + callback = self._async_init_callback + if shutdowner: + callback = functools.partial(callback, shutdowner=shutdowner) + + future = asyncio.ensure_future(future) + future.add_done_callback(callback) + self.__resource = future + + return future + + def _async_init_callback(self, initializer, shutdowner=None): + try: + resource = initializer.result() + except Exception: + self.__initialized = False + raise + else: + self.__resource = resource + self.__shutdowner = shutdowner + + def _create_shutdown_future(self, shutdown_future): + future = asyncio.Future() + shutdown_future = asyncio.ensure_future(shutdown_future) + shutdown_future.add_done_callback(functools.partial(self._async_shutdown_callback, future)) + return future + + def _async_shutdown_callback(self, future_result, shutdowner): + try: + shutdowner.result() + except StopAsyncIteration: + pass + + self.__resource = None + self.__initialized = False + self.__shutdowner = None + + future_result.set_result(None) + @staticmethod def _is_resource_subclass(instance): if sys.version_info < (3, 5): @@ -2770,6 +3017,15 @@ cdef class Resource(Provider): from . import resources return issubclass(instance, resources.Resource) + @staticmethod + def _is_async_resource_subclass(instance): + if sys.version_info < (3, 5): + return False + if not isinstance(instance, CLASS_TYPES): + return + from . import resources + return issubclass(instance, resources.AsyncResource) + cdef class Container(Provider): """Container provider provides an instance of declarative container. @@ -3037,8 +3293,18 @@ cdef class AttributeGetter(Provider): cpdef object _provide(self, tuple args, dict kwargs): provided = self.__provider(*args, **kwargs) + if __isawaitable(provided): + future_result = asyncio.Future() + provided = asyncio.ensure_future(provided) + provided.add_done_callback(functools.partial(self._async_provide, future_result)) + return future_result return getattr(provided, self.__attribute) + def _async_provide(self, future_result, future): + provided = future.result() + result = getattr(provided, self.__attribute) + future_result.set_result(result) + cdef class ItemGetter(Provider): """Provider that returns the item of the injected instance. @@ -3087,8 +3353,18 @@ cdef class ItemGetter(Provider): cpdef object _provide(self, tuple args, dict kwargs): provided = self.__provider(*args, **kwargs) + if __isawaitable(provided): + future_result = asyncio.Future() + provided = asyncio.ensure_future(provided) + provided.add_done_callback(functools.partial(self._async_provide, future_result)) + return future_result return provided[self.__item] + def _async_provide(self, future_result, future): + provided = future.result() + result = provided[self.__item] + future_result.set_result(result) + cdef class MethodCaller(Provider): """Provider that calls the method of the injected instance. @@ -3169,6 +3445,11 @@ cdef class MethodCaller(Provider): cpdef object _provide(self, tuple args, dict kwargs): call = self.__provider() + if __isawaitable(call): + future_result = asyncio.Future() + call = asyncio.ensure_future(call) + call.add_done_callback(functools.partial(self._async_provide, future_result, args, kwargs)) + return future_result return __call( call, args, @@ -3179,6 +3460,19 @@ cdef class MethodCaller(Provider): self.__kwargs_len, ) + def _async_provide(self, future_result, args, kwargs, future): + call = future.result() + result = __call( + call, + args, + self.__args, + self.__args_len, + kwargs, + self.__kwargs, + self.__kwargs_len, + ) + future_result.set_result(result) + cdef class Injection(object): """Abstract injection class.""" @@ -3381,3 +3675,36 @@ def merge_dicts(dict1, dict2): result = dict1.copy() result.update(dict2) return result + + +def isawaitable(obj): + """Check if object is a coroutine function. + + Return False for any object in Python 3.4 or below. + """ + try: + return inspect.isawaitable(obj) + except AttributeError: + return False + + +def iscoroutinefunction(obj): + """Check if object is a coroutine function. + + Return False for any object in Python 3.4 or below. + """ + try: + return inspect.iscoroutinefunction(obj) + except AttributeError: + return False + + +def isasyncgenfunction(obj): + """Check if object is an asynchronous generator function. + + Return False for any object in Python 3.4 or below. + """ + try: + return inspect.isasyncgenfunction(obj) + except AttributeError: + return False diff --git a/src/dependency_injector/resources.py b/src/dependency_injector/resources.py index 34fe6c1c..50eeb3d2 100644 --- a/src/dependency_injector/resources.py +++ b/src/dependency_injector/resources.py @@ -29,3 +29,14 @@ class Resource(Generic[T], metaclass=ResourceMeta): @abc.abstractmethod def shutdown(self, resource: T) -> None: ... + + +class AsyncResource(Generic[T], metaclass=ResourceMeta): + + @abc.abstractmethod + async def init(self, *args, **kwargs) -> T: + ... + + @abc.abstractmethod + async def shutdown(self, resource: T) -> None: + ... diff --git a/src/dependency_injector/wiring.py b/src/dependency_injector/wiring.py index 056814d2..a3c36d4a 100644 --- a/src/dependency_injector/wiring.py +++ b/src/dependency_injector/wiring.py @@ -1,5 +1,6 @@ """Wiring module.""" +import asyncio import functools import inspect import importlib @@ -426,10 +427,20 @@ def _get_async_patched(fn): @functools.wraps(fn) async def _patched(*args, **kwargs): to_inject = kwargs.copy() + to_inject_await = [] + to_close_await = [] for injection, provider in _patched.__injections__.items(): if injection not in kwargs \ or _is_fastapi_default_arg_injection(injection, kwargs): - to_inject[injection] = provider() + provide = provider() + if inspect.isawaitable(provide): + to_inject_await.append((injection, provide)) + else: + to_inject[injection] = provide + + async_to_inject = await asyncio.gather(*[provide for _, provide in to_inject_await]) + for provide, (injection, _) in zip(async_to_inject, to_inject_await): + to_inject[injection] = provide result = await fn(*args, **to_inject) @@ -439,7 +450,11 @@ def _get_async_patched(fn): continue if not isinstance(provider, providers.Resource): continue - provider.shutdown() + shutdown = provider.shutdown() + if inspect.isawaitable(shutdown): + to_close_await.append(shutdown) + + await asyncio.gather(*to_close_await) return result return _patched diff --git a/tests/typing/callable.py b/tests/typing/callable.py index 474acb1a..1438f9ac 100644 --- a/tests/typing/callable.py +++ b/tests/typing/callable.py @@ -50,3 +50,9 @@ animal7: Animal = provider7(1, 2, 3, b='1', c=2, e=0.0) # Test 8: to check the CallableDelegate __init__ provider8 = providers.CallableDelegate(providers.Callable(lambda: None)) + +# Test 9: to check the return type with await +provider9 = providers.Callable(Cat) +async def _async9() -> None: + animal1: Animal = await provider9(1, 2, 3, b='1', c=2, e=0.0) # type: ignore + animal2: Animal = await provider9.async_(1, 2, 3, b='1', c=2, e=0.0) diff --git a/tests/typing/delegate.py b/tests/typing/delegate.py index 353c0830..e934cb5c 100644 --- a/tests/typing/delegate.py +++ b/tests/typing/delegate.py @@ -4,3 +4,9 @@ from dependency_injector import providers # Test 1: to check the return type provider1 = providers.Delegate(providers.Provider()) var1: providers.Provider = provider1() + +# Test 2: to check the return type with await +provider2 = providers.Delegate(providers.Provider()) +async def _async2() -> None: + var1: providers.Provider = await provider2() # type: ignore + var2: providers.Provider = await provider2.async_() diff --git a/tests/typing/dependency.py b/tests/typing/dependency.py index 77d6ff08..a699e4c2 100644 --- a/tests/typing/dependency.py +++ b/tests/typing/dependency.py @@ -20,3 +20,9 @@ var1: Animal = provider1() # Test 2: to check the return type provider2 = providers.Dependency(instance_of=Animal) var2: Type[Animal] = provider2.instance_of + +# Test 3: to check the return type with await +provider3 = providers.Dependency(instance_of=Animal) +async def _async3() -> None: + var1: Animal = await provider3() # type: ignore + var2: Animal = await provider3.async_() diff --git a/tests/typing/dict.py b/tests/typing/dict.py index a272ca66..31205067 100644 --- a/tests/typing/dict.py +++ b/tests/typing/dict.py @@ -35,3 +35,13 @@ provider5 = providers.Dict( a2=providers.Factory(object), ) provided5: providers.ProvidedInstance = provider5.provided + + +# Test 6: to check the return type with await +provider6 = providers.Dict( + a1=providers.Factory(object), + a2=providers.Factory(object), +) +async def _async3() -> None: + var1: Dict[Any, Any] = await provider6() # type: ignore + var2: Dict[Any, Any] = await provider6.async_() diff --git a/tests/typing/factory.py b/tests/typing/factory.py index 57a13524..d4224811 100644 --- a/tests/typing/factory.py +++ b/tests/typing/factory.py @@ -66,3 +66,9 @@ val9: Any = provider9('a') # Test 10: to check the explicit typing factory10: providers.Provider[Animal] = providers.Factory(Cat) animal10: Animal = factory10() + +# Test 11: to check the return type with await +provider11 = providers.Factory(Cat) +async def _async11() -> None: + animal1: Animal = await provider11(1, 2, 3, b='1', c=2, e=0.0) # type: ignore + animal2: Animal = await provider11.async_(1, 2, 3, b='1', c=2, e=0.0) diff --git a/tests/typing/list.py b/tests/typing/list.py index 60eb50b5..1831eff8 100644 --- a/tests/typing/list.py +++ b/tests/typing/list.py @@ -27,3 +27,12 @@ provided3: providers.ProvidedInstance = provider3.provided attr_getter3: providers.AttributeGetter = provider3.provided.attr item_getter3: providers.ItemGetter = provider3.provided['item'] method_caller3: providers.MethodCaller = provider3.provided.method.call(123, arg=324) + +# Test 4: to check the return type with await +provider4 = providers.List( + providers.Factory(object), + providers.Factory(object), +) +async def _async4() -> None: + var1: List[Any] = await provider4() # type: ignore + var2: List[Any] = await provider4.async_() diff --git a/tests/typing/object.py b/tests/typing/object.py index e53ea966..05829f05 100644 --- a/tests/typing/object.py +++ b/tests/typing/object.py @@ -11,3 +11,9 @@ provided2: providers.ProvidedInstance = provider2.provided attr_getter2: providers.AttributeGetter = provider2.provided.attr item_getter2: providers.ItemGetter = provider2.provided['item'] method_caller2: providers.MethodCaller = provider2.provided.method.call(123, arg=324) + +# Test 3: to check the return type with await +provider3 = providers.Object(int(3)) +async def _async3() -> None: + var1: int = await provider3() # type: ignore + var2: int = await provider3.async_() diff --git a/tests/typing/provider.py b/tests/typing/provider.py index 8ba13922..46dd23a0 100644 --- a/tests/typing/provider.py +++ b/tests/typing/provider.py @@ -4,3 +4,12 @@ from dependency_injector import providers # Test 1: to check .provided attribute provider1: providers.Provider[int] = providers.Object(1) provided: providers.ProvidedInstance = provider1.provided + +# Test 2: to check async mode API +provider2: providers.Provider = providers.Provider() +provider2.enable_async_mode() +provider2.disable_async_mode() +provider2.reset_async_mode() +r1: bool = provider2.is_async_mode_enabled() +r2: bool = provider2.is_async_mode_disabled() +r3: bool = provider2.is_async_mode_undefined() diff --git a/tests/typing/resource.py b/tests/typing/resource.py index 71808b13..b5687451 100644 --- a/tests/typing/resource.py +++ b/tests/typing/resource.py @@ -1,4 +1,4 @@ -from typing import List, Iterator, Generator +from typing import List, Iterator, Generator, AsyncIterator, AsyncGenerator from dependency_injector import providers, resources @@ -41,3 +41,59 @@ class MyResource4(resources.Resource[List[int]]): provider4 = providers.Resource(MyResource4) var4: List[int] = provider4() + + +# Test 5: to check the return type with async function +async def init5() -> List[int]: + ... + + +provider5 = providers.Resource(init5) + + +async def _provide5() -> None: + var1: List[int] = await provider5() # type: ignore + var2: List[int] = await provider5.async_() + + +# Test 6: to check the return type with async iterator +async def init6() -> AsyncIterator[List[int]]: + yield [] + + +provider6 = providers.Resource(init6) + + +async def _provide6() -> None: + var1: List[int] = await provider6() # type: ignore + var2: List[int] = await provider6.async_() + + +# Test 7: to check the return type with async generator +async def init7() -> AsyncGenerator[List[int], None]: + yield [] + + +provider7 = providers.Resource(init7) + + +async def _provide7() -> None: + var1: List[int] = await provider7() # type: ignore + var2: List[int] = await provider7.async_() + + +# Test 8: to check the return type with async resource subclass +class MyResource8(resources.AsyncResource[List[int]]): + async def init(self, *args, **kwargs) -> List[int]: + return [] + + async def shutdown(self, resource: List[int]) -> None: + ... + + +provider8 = providers.Resource(MyResource8) + + +async def _provide8() -> None: + var1: List[int] = await provider8() # type: ignore + var2: List[int] = await provider8.async_() diff --git a/tests/typing/selector.py b/tests/typing/selector.py index e26a45e1..6aa4ca8f 100644 --- a/tests/typing/selector.py +++ b/tests/typing/selector.py @@ -1,3 +1,5 @@ +from typing import Any + from dependency_injector import providers @@ -7,7 +9,7 @@ provider1 = providers.Selector( a=providers.Factory(object), b=providers.Factory(object), ) -var1: int = provider1() +var1: Any = provider1() # Test 2: to check the provided instance interface provider2 = providers.Selector( @@ -27,3 +29,13 @@ provider3 = providers.Selector( b=providers.Factory(object), ) attr3: providers.Provider = provider3.a + +# Test 4: to check the return type with await +provider4 = providers.Selector( + lambda: 'a', + a=providers.Factory(object), + b=providers.Factory(object), +) +async def _async4() -> None: + var1: Any = await provider4() # type: ignore + var2: Any = await provider4.async_() diff --git a/tests/typing/singleton.py b/tests/typing/singleton.py index a31e20fd..667edda6 100644 --- a/tests/typing/singleton.py +++ b/tests/typing/singleton.py @@ -69,3 +69,9 @@ animal11: Animal = provider11(1, 2, 3, b='1', c=2, e=0.0) # Test 12: to check the SingletonDelegate __init__ provider12 = providers.SingletonDelegate(providers.Singleton(object)) + +# Test 13: to check the return type with await +provider13 = providers.Singleton(Cat) +async def _async13() -> None: + animal1: Animal = await provider13(1, 2, 3, b='1', c=2, e=0.0) # type: ignore + animal2: Animal = await provider13.async_(1, 2, 3, b='1', c=2, e=0.0) diff --git a/tests/unit/asyncutils.py b/tests/unit/asyncutils.py new file mode 100644 index 00000000..ca1b96d2 --- /dev/null +++ b/tests/unit/asyncutils.py @@ -0,0 +1,57 @@ +"""Test utils.""" + +import asyncio +import contextlib +import sys +import gc +import unittest + + +def run(main): + loop = asyncio.get_event_loop() + return loop.run_until_complete(main) + + +def setup_test_loop( + loop_factory=asyncio.new_event_loop +) -> asyncio.AbstractEventLoop: + loop = loop_factory() + try: + module = loop.__class__.__module__ + skip_watcher = 'uvloop' in module + except AttributeError: # pragma: no cover + # Just in case + skip_watcher = True + asyncio.set_event_loop(loop) + if sys.platform != 'win32' and not skip_watcher: + policy = asyncio.get_event_loop_policy() + watcher = asyncio.SafeChildWatcher() # type: ignore + watcher.attach_loop(loop) + with contextlib.suppress(NotImplementedError): + policy.set_child_watcher(watcher) + return loop + + +def teardown_test_loop(loop: asyncio.AbstractEventLoop, fast: bool = False) -> None: + closed = loop.is_closed() + if not closed: + loop.call_soon(loop.stop) + loop.run_forever() + loop.close() + + if not fast: + gc.collect() + + asyncio.set_event_loop(None) + + +class AsyncTestCase(unittest.TestCase): + + def setUp(self): + self.loop = setup_test_loop() + + def tearDown(self): + teardown_test_loop(self.loop) + + def _run(self, f): + return self.loop.run_until_complete(f) diff --git a/tests/unit/containers/test_dynamic_async_resources_py36.py b/tests/unit/containers/test_dynamic_async_resources_py36.py new file mode 100644 index 00000000..f11d0cd8 --- /dev/null +++ b/tests/unit/containers/test_dynamic_async_resources_py36.py @@ -0,0 +1,71 @@ +"""Dependency injector dynamic container unit tests for async resources.""" + +import unittest2 as unittest + +# Runtime import to get asyncutils module +import os +_TOP_DIR = os.path.abspath( + os.path.sep.join(( + os.path.dirname(__file__), + '../', + )), +) +import sys +sys.path.append(_TOP_DIR) + +from asyncutils import AsyncTestCase + +from dependency_injector import ( + containers, + providers, +) + + +class AsyncResourcesTest(AsyncTestCase): + + @unittest.skipIf(sys.version_info[:2] <= (3, 5), 'Async test') + def test_async_init_resources(self): + async def _init1(): + _init1.init_counter += 1 + yield + _init1.shutdown_counter += 1 + + _init1.init_counter = 0 + _init1.shutdown_counter = 0 + + async def _init2(): + _init2.init_counter += 1 + yield + _init2.shutdown_counter += 1 + + _init2.init_counter = 0 + _init2.shutdown_counter = 0 + + class Container(containers.DeclarativeContainer): + resource1 = providers.Resource(_init1) + resource2 = providers.Resource(_init2) + + container = Container() + self.assertEqual(_init1.init_counter, 0) + self.assertEqual(_init1.shutdown_counter, 0) + self.assertEqual(_init2.init_counter, 0) + self.assertEqual(_init2.shutdown_counter, 0) + + self._run(container.init_resources()) + self.assertEqual(_init1.init_counter, 1) + self.assertEqual(_init1.shutdown_counter, 0) + self.assertEqual(_init2.init_counter, 1) + self.assertEqual(_init2.shutdown_counter, 0) + + self._run(container.shutdown_resources()) + self.assertEqual(_init1.init_counter, 1) + self.assertEqual(_init1.shutdown_counter, 1) + self.assertEqual(_init2.init_counter, 1) + self.assertEqual(_init2.shutdown_counter, 1) + + self._run(container.init_resources()) + self._run(container.shutdown_resources()) + self.assertEqual(_init1.init_counter, 2) + self.assertEqual(_init1.shutdown_counter, 2) + self.assertEqual(_init2.init_counter, 2) + self.assertEqual(_init2.shutdown_counter, 2) diff --git a/tests/unit/containers/test_dynamic_py2_py3.py b/tests/unit/containers/test_dynamic_py2_py3.py index 3c072bca..2b9afc8e 100644 --- a/tests/unit/containers/test_dynamic_py2_py3.py +++ b/tests/unit/containers/test_dynamic_py2_py3.py @@ -231,7 +231,3 @@ class DeclarativeContainerInstanceTests(unittest.TestCase): self.assertEqual(_init1.shutdown_counter, 2) self.assertEqual(_init2.init_counter, 2) self.assertEqual(_init2.shutdown_counter, 2) - - -if __name__ == '__main__': - unittest.main() diff --git a/tests/unit/providers/test_async_py36.py b/tests/unit/providers/test_async_py36.py new file mode 100644 index 00000000..10515e3f --- /dev/null +++ b/tests/unit/providers/test_async_py36.py @@ -0,0 +1,818 @@ +import asyncio +import random +import unittest + +from dependency_injector import containers, providers, errors + +# Runtime import to get asyncutils module +import os +_TOP_DIR = os.path.abspath( + os.path.sep.join(( + os.path.dirname(__file__), + '../', + )), +) +import sys +sys.path.append(_TOP_DIR) + +from asyncutils import AsyncTestCase + + +RESOURCE1 = object() +RESOURCE2 = object() + + +async def init_resource(resource): + await asyncio.sleep(random.randint(1, 10) / 1000) + yield resource + await asyncio.sleep(random.randint(1, 10) / 1000) + + +class Client: + def __init__(self, resource1: object, resource2: object) -> None: + self.resource1 = resource1 + self.resource2 = resource2 + + +class Service: + def __init__(self, client: Client) -> None: + self.client = client + + +class Container(containers.DeclarativeContainer): + resource1 = providers.Resource(init_resource, providers.Object(RESOURCE1)) + resource2 = providers.Resource(init_resource, providers.Object(RESOURCE2)) + + client = providers.Factory( + Client, + resource1=resource1, + resource2=resource2, + ) + + service = providers.Factory( + Service, + client=client, + ) + + +class FactoryTests(AsyncTestCase): + + def test_args_injection(self): + class ContainerWithArgs(containers.DeclarativeContainer): + resource1 = providers.Resource(init_resource, providers.Object(RESOURCE1)) + resource2 = providers.Resource(init_resource, providers.Object(RESOURCE2)) + + client = providers.Factory( + Client, + resource1, + resource2, + ) + + service = providers.Factory( + Service, + client, + ) + + container = ContainerWithArgs() + + client1 = self._run(container.client()) + client2 = self._run(container.client()) + + self.assertIsInstance(client1, Client) + self.assertIs(client1.resource1, RESOURCE1) + self.assertIs(client1.resource2, RESOURCE2) + + self.assertIsInstance(client2, Client) + self.assertIs(client2.resource1, RESOURCE1) + self.assertIs(client2.resource2, RESOURCE2) + + service1 = self._run(container.service()) + service2 = self._run(container.service()) + + self.assertIsInstance(service1, Service) + self.assertIsInstance(service1.client, Client) + self.assertIs(service1.client.resource1, RESOURCE1) + self.assertIs(service1.client.resource2, RESOURCE2) + + self.assertIsInstance(service2, Service) + self.assertIsInstance(service2.client, Client) + self.assertIs(service2.client.resource1, RESOURCE1) + self.assertIs(service2.client.resource2, RESOURCE2) + + self.assertIsNot(service1.client, service2.client) + + def test_kwargs_injection(self): + container = Container() + + client1 = self._run(container.client()) + client2 = self._run(container.client()) + + self.assertIsInstance(client1, Client) + self.assertIs(client1.resource1, RESOURCE1) + self.assertIs(client1.resource2, RESOURCE2) + + self.assertIsInstance(client2, Client) + self.assertIs(client2.resource1, RESOURCE1) + self.assertIs(client2.resource2, RESOURCE2) + + service1 = self._run(container.service()) + service2 = self._run(container.service()) + + self.assertIsInstance(service1, Service) + self.assertIsInstance(service1.client, Client) + self.assertIs(service1.client.resource1, RESOURCE1) + self.assertIs(service1.client.resource2, RESOURCE2) + + self.assertIsInstance(service2, Service) + self.assertIsInstance(service2.client, Client) + self.assertIs(service2.client.resource1, RESOURCE1) + self.assertIs(service2.client.resource2, RESOURCE2) + + self.assertIsNot(service1.client, service2.client) + + def test_context_kwargs_injection(self): + resource2_extra = object() + + container = Container() + + client1 = self._run(container.client(resource2=resource2_extra)) + client2 = self._run(container.client(resource2=resource2_extra)) + + self.assertIsInstance(client1, Client) + self.assertIs(client1.resource1, RESOURCE1) + self.assertIs(client1.resource2, resource2_extra) + + self.assertIsInstance(client2, Client) + self.assertIs(client2.resource1, RESOURCE1) + self.assertIs(client2.resource2, resource2_extra) + + def test_args_kwargs_injection(self): + class ContainerWithArgsAndKwArgs(containers.DeclarativeContainer): + resource1 = providers.Resource(init_resource, providers.Object(RESOURCE1)) + resource2 = providers.Resource(init_resource, providers.Object(RESOURCE2)) + + client = providers.Factory( + Client, + resource1, + resource2=resource2, + ) + + service = providers.Factory( + Service, + client=client, + ) + + container = ContainerWithArgsAndKwArgs() + + client1 = self._run(container.client()) + client2 = self._run(container.client()) + + self.assertIsInstance(client1, Client) + self.assertIs(client1.resource1, RESOURCE1) + self.assertIs(client1.resource2, RESOURCE2) + + self.assertIsInstance(client2, Client) + self.assertIs(client2.resource1, RESOURCE1) + self.assertIs(client2.resource2, RESOURCE2) + + service1 = self._run(container.service()) + service2 = self._run(container.service()) + + self.assertIsInstance(service1, Service) + self.assertIsInstance(service1.client, Client) + self.assertIs(service1.client.resource1, RESOURCE1) + self.assertIs(service1.client.resource2, RESOURCE2) + + self.assertIsInstance(service2, Service) + self.assertIsInstance(service2.client, Client) + self.assertIs(service2.client.resource1, RESOURCE1) + self.assertIs(service2.client.resource2, RESOURCE2) + + self.assertIsNot(service1.client, service2.client) + + def test_attributes_injection(self): + class ContainerWithAttributes(containers.DeclarativeContainer): + resource1 = providers.Resource(init_resource, providers.Object(RESOURCE1)) + resource2 = providers.Resource(init_resource, providers.Object(RESOURCE2)) + + client = providers.Factory( + Client, + resource1, + resource2=None, + ) + client.add_attributes(resource2=resource2) + + service = providers.Factory( + Service, + client=None, + ) + service.add_attributes(client=client) + + container = ContainerWithAttributes() + + client1 = self._run(container.client()) + client2 = self._run(container.client()) + + self.assertIsInstance(client1, Client) + self.assertIs(client1.resource1, RESOURCE1) + self.assertIs(client1.resource2, RESOURCE2) + + self.assertIsInstance(client2, Client) + self.assertIs(client2.resource1, RESOURCE1) + self.assertIs(client2.resource2, RESOURCE2) + + service1 = self._run(container.service()) + service2 = self._run(container.service()) + + self.assertIsInstance(service1, Service) + self.assertIsInstance(service1.client, Client) + self.assertIs(service1.client.resource1, RESOURCE1) + self.assertIs(service1.client.resource2, RESOURCE2) + + self.assertIsInstance(service2, Service) + self.assertIsInstance(service2.client, Client) + self.assertIs(service2.client.resource1, RESOURCE1) + self.assertIs(service2.client.resource2, RESOURCE2) + + self.assertIsNot(service1.client, service2.client) + + +class FactoryAggregateTests(AsyncTestCase): + + def test_async_mode(self): + object1 = object() + object2 = object() + + async def _get_object1(): + return object1 + + def _get_object2(): + return object2 + + provider = providers.FactoryAggregate( + object1=providers.Factory(_get_object1), + object2=providers.Factory(_get_object2), + ) + + self.assertTrue(provider.is_async_mode_undefined()) + + created_object1 = self._run(provider('object1')) + self.assertIs(created_object1, object1) + self.assertTrue(provider.is_async_mode_enabled()) + + created_object2 = self._run(provider('object2')) + self.assertIs(created_object2, object2) + + +class SingletonTests(AsyncTestCase): + + def test_injections(self): + class ContainerWithSingletons(containers.DeclarativeContainer): + resource1 = providers.Resource(init_resource, providers.Object(RESOURCE1)) + resource2 = providers.Resource(init_resource, providers.Object(RESOURCE2)) + + client = providers.Singleton( + Client, + resource1=resource1, + resource2=resource2, + ) + + service = providers.Singleton( + Service, + client=client, + ) + + container = ContainerWithSingletons() + + client1 = self._run(container.client()) + client2 = self._run(container.client()) + + self.assertIsInstance(client1, Client) + self.assertIs(client1.resource1, RESOURCE1) + self.assertIs(client1.resource2, RESOURCE2) + + self.assertIsInstance(client2, Client) + self.assertIs(client2.resource1, RESOURCE1) + self.assertIs(client2.resource2, RESOURCE2) + + service1 = self._run(container.service()) + service2 = self._run(container.service()) + + self.assertIsInstance(service1, Service) + self.assertIsInstance(service1.client, Client) + self.assertIs(service1.client.resource1, RESOURCE1) + self.assertIs(service1.client.resource2, RESOURCE2) + + self.assertIsInstance(service2, Service) + self.assertIsInstance(service2.client, Client) + self.assertIs(service2.client.resource1, RESOURCE1) + self.assertIs(service2.client.resource2, RESOURCE2) + + self.assertIs(service1, service2) + self.assertIs(service1.client, service2.client) + self.assertIs(service1.client, client1) + + self.assertIs(service2.client, client2) + self.assertIs(client1, client2) + + def test_async_mode(self): + instance = object() + + async def create_instance(): + return instance + + provider = providers.Singleton(create_instance) + + instance1 = self._run(provider()) + instance2 = self._run(provider()) + + self.assertIs(instance1, instance2) + self.assertIs(instance, instance) + + def test_async_init_with_error(self): + # Disable default exception handling to prevent output + asyncio.get_event_loop().set_exception_handler(lambda loop, context: ...) + + async def create_instance(): + create_instance.counter += 1 + raise RuntimeError() + + create_instance.counter = 0 + + provider = providers.Singleton(create_instance) + + + future = provider() + self.assertTrue(provider.is_async_mode_enabled()) + + with self.assertRaises(RuntimeError): + self._run(future) + + self.assertEqual(create_instance.counter, 1) + self.assertTrue(provider.is_async_mode_enabled()) + + with self.assertRaises(RuntimeError): + self._run(provider()) + + self.assertEqual(create_instance.counter, 2) + self.assertTrue(provider.is_async_mode_enabled()) + + # Restore default exception handling + asyncio.get_event_loop().set_exception_handler(None) + + +class DelegatedSingletonTests(AsyncTestCase): + + def test_async_mode(self): + instance = object() + + async def create_instance(): + return instance + + provider = providers.DelegatedSingleton(create_instance) + + instance1 = self._run(provider()) + instance2 = self._run(provider()) + + self.assertIs(instance1, instance2) + self.assertIs(instance, instance) + + +class ThreadSafeSingletonTests(AsyncTestCase): + + def test_async_mode(self): + instance = object() + + async def create_instance(): + return instance + + provider = providers.ThreadSafeSingleton(create_instance) + + instance1 = self._run(provider()) + instance2 = self._run(provider()) + + self.assertIs(instance1, instance2) + self.assertIs(instance, instance) + + +class DelegatedThreadSafeSingletonTests(AsyncTestCase): + + def test_async_mode(self): + instance = object() + + async def create_instance(): + return instance + + provider = providers.DelegatedThreadSafeSingleton(create_instance) + + instance1 = self._run(provider()) + instance2 = self._run(provider()) + + self.assertIs(instance1, instance2) + self.assertIs(instance, instance) + + +class ThreadLocalSingletonTests(AsyncTestCase): + + def test_async_mode(self): + instance = object() + + async def create_instance(): + return instance + + provider = providers.ThreadLocalSingleton(create_instance) + + instance1 = self._run(provider()) + instance2 = self._run(provider()) + + self.assertIs(instance1, instance2) + self.assertIs(instance, instance) + + + def test_async_init_with_error(self): + # Disable default exception handling to prevent output + asyncio.get_event_loop().set_exception_handler(lambda loop, context: ...) + + async def create_instance(): + create_instance.counter += 1 + raise RuntimeError() + create_instance.counter = 0 + + provider = providers.ThreadLocalSingleton(create_instance) + + future = provider() + self.assertTrue(provider.is_async_mode_enabled()) + + with self.assertRaises(RuntimeError): + self._run(future) + + self.assertEqual(create_instance.counter, 1) + self.assertTrue(provider.is_async_mode_enabled()) + + with self.assertRaises(RuntimeError): + self._run(provider()) + + self.assertEqual(create_instance.counter, 2) + self.assertTrue(provider.is_async_mode_enabled()) + + # Restore default exception handling + asyncio.get_event_loop().set_exception_handler(None) + + +class DelegatedThreadLocalSingletonTests(AsyncTestCase): + + def test_async_mode(self): + instance = object() + + async def create_instance(): + return instance + + provider = providers.DelegatedThreadLocalSingleton(create_instance) + + instance1 = self._run(provider()) + instance2 = self._run(provider()) + + self.assertIs(instance1, instance2) + self.assertIs(instance, instance) + + +class ProvidedInstanceTests(AsyncTestCase): + + def test_provided_attribute(self): + class TestClient: + def __init__(self, resource): + self.resource = resource + + class TestService: + def __init__(self, resource): + self.resource = resource + + class TestContainer(containers.DeclarativeContainer): + resource = providers.Resource(init_resource, providers.Object(RESOURCE1)) + client = providers.Factory(TestClient, resource=resource) + service = providers.Factory(TestService, resource=client.provided.resource) + + container = TestContainer() + + instance1, instance2 = self._run( + asyncio.gather( + container.service(), + container.service(), + ), + ) + + self.assertIs(instance1.resource, RESOURCE1) + self.assertIs(instance2.resource, RESOURCE1) + self.assertIs(instance1.resource, instance2.resource) + + def test_provided_item(self): + class TestClient: + def __init__(self, resource): + self.resource = resource + + def __getitem__(self, item): + return getattr(self, item) + + class TestService: + def __init__(self, resource): + self.resource = resource + + class TestContainer(containers.DeclarativeContainer): + resource = providers.Resource(init_resource, providers.Object(RESOURCE1)) + client = providers.Factory(TestClient, resource=resource) + service = providers.Factory(TestService, resource=client.provided['resource']) + + container = TestContainer() + + instance1, instance2 = self._run( + asyncio.gather( + container.service(), + container.service(), + ), + ) + + self.assertIs(instance1.resource, RESOURCE1) + self.assertIs(instance2.resource, RESOURCE1) + self.assertIs(instance1.resource, instance2.resource) + + def test_provided_method_call(self): + class TestClient: + def __init__(self, resource): + self.resource = resource + + def get_resource(self): + return self.resource + + class TestService: + def __init__(self, resource): + self.resource = resource + + class TestContainer(containers.DeclarativeContainer): + resource = providers.Resource(init_resource, providers.Object(RESOURCE1)) + client = providers.Factory(TestClient, resource=resource) + service = providers.Factory(TestService, resource=client.provided.get_resource.call()) + + container = TestContainer() + + instance1, instance2 = self._run( + asyncio.gather( + container.service(), + container.service(), + ), + ) + + self.assertIs(instance1.resource, RESOURCE1) + self.assertIs(instance2.resource, RESOURCE1) + self.assertIs(instance1.resource, instance2.resource) + + +class DependencyTests(AsyncTestCase): + + def test_isinstance(self): + dependency = 1.0 + + async def get_async(): + return dependency + + provider = providers.Dependency(instance_of=float) + provider.override(providers.Callable(get_async)) + + self.assertTrue(provider.is_async_mode_undefined()) + + dependency1 = self._run(provider()) + + self.assertTrue(provider.is_async_mode_enabled()) + + dependency2 = self._run(provider()) + + self.assertEqual(dependency1, dependency) + self.assertEqual(dependency2, dependency) + + def test_isinstance_invalid(self): + async def get_async(): + return {} + + provider = providers.Dependency(instance_of=float) + provider.override(providers.Callable(get_async)) + + self.assertTrue(provider.is_async_mode_undefined()) + + with self.assertRaises(errors.Error): + self._run(provider()) + + self.assertTrue(provider.is_async_mode_enabled()) + + def test_async_mode(self): + dependency = 123 + + async def get_async(): + return dependency + + def get_sync(): + return dependency + + provider = providers.Dependency(instance_of=int) + provider.override(providers.Factory(get_async)) + + self.assertTrue(provider.is_async_mode_undefined()) + + dependency1 = self._run(provider()) + + self.assertTrue(provider.is_async_mode_enabled()) + + dependency2 = self._run(provider()) + self.assertEqual(dependency1, dependency) + self.assertEqual(dependency2, dependency) + + provider.override(providers.Factory(get_sync)) + + dependency3 = self._run(provider()) + + self.assertTrue(provider.is_async_mode_enabled()) + + dependency4 = self._run(provider()) + self.assertEqual(dependency3, dependency) + self.assertEqual(dependency4, dependency) + + +class OverrideTests(AsyncTestCase): + + def test_provider(self): + dependency = object() + + async def _get_dependency_async(): + return dependency + + def _get_dependency_sync(): + return dependency + + provider = providers.Provider() + + provider.override(providers.Callable(_get_dependency_async)) + dependency1 = self._run(provider()) + + provider.override(providers.Callable(_get_dependency_sync)) + dependency2 = self._run(provider()) + + self.assertIs(dependency1, dependency) + self.assertIs(dependency2, dependency) + + def test_callable(self): + dependency = object() + + async def _get_dependency_async(): + return dependency + + def _get_dependency_sync(): + return dependency + + provider = providers.Callable(_get_dependency_async) + dependency1 = self._run(provider()) + + provider.override(providers.Callable(_get_dependency_sync)) + dependency2 = self._run(provider()) + + self.assertIs(dependency1, dependency) + self.assertIs(dependency2, dependency) + + def test_factory(self): + dependency = object() + + async def _get_dependency_async(): + return dependency + + def _get_dependency_sync(): + return dependency + + provider = providers.Factory(_get_dependency_async) + dependency1 = self._run(provider()) + + provider.override(providers.Callable(_get_dependency_sync)) + dependency2 = self._run(provider()) + + self.assertIs(dependency1, dependency) + self.assertIs(dependency2, dependency) + + def test_async_mode_enabling(self): + dependency = object() + + async def _get_dependency_async(): + return dependency + + provider = providers.Callable(_get_dependency_async) + self.assertTrue(provider.is_async_mode_undefined()) + + self._run(provider()) + + self.assertTrue(provider.is_async_mode_enabled()) + + def test_async_mode_disabling(self): + dependency = object() + + def _get_dependency(): + return dependency + + provider = providers.Callable(_get_dependency) + self.assertTrue(provider.is_async_mode_undefined()) + + provider() + + self.assertTrue(provider.is_async_mode_disabled()) + + def test_async_mode_enabling_on_overriding(self): + dependency = object() + + async def _get_dependency_async(): + return dependency + + provider = providers.Provider() + provider.override(providers.Callable(_get_dependency_async)) + self.assertTrue(provider.is_async_mode_undefined()) + + self._run(provider()) + + self.assertTrue(provider.is_async_mode_enabled()) + + def test_async_mode_disabling_on_overriding(self): + dependency = object() + + def _get_dependency(): + return dependency + + provider = providers.Provider() + provider.override(providers.Callable(_get_dependency)) + self.assertTrue(provider.is_async_mode_undefined()) + + provider() + + self.assertTrue(provider.is_async_mode_disabled()) + + +class TestAsyncModeApi(unittest.TestCase): + + def setUp(self): + self.provider = providers.Provider() + + def test_default_mode(self): + self.assertFalse(self.provider.is_async_mode_enabled()) + self.assertFalse(self.provider.is_async_mode_disabled()) + self.assertTrue(self.provider.is_async_mode_undefined()) + + def test_enable(self): + self.provider.enable_async_mode() + + self.assertTrue(self.provider.is_async_mode_enabled()) + self.assertFalse(self.provider.is_async_mode_disabled()) + self.assertFalse(self.provider.is_async_mode_undefined()) + + def test_disable(self): + self.provider.disable_async_mode() + + self.assertFalse(self.provider.is_async_mode_enabled()) + self.assertTrue(self.provider.is_async_mode_disabled()) + self.assertFalse(self.provider.is_async_mode_undefined()) + + def test_reset(self): + self.provider.enable_async_mode() + + self.assertTrue(self.provider.is_async_mode_enabled()) + self.assertFalse(self.provider.is_async_mode_disabled()) + self.assertFalse(self.provider.is_async_mode_undefined()) + + self.provider.reset_async_mode() + + self.assertFalse(self.provider.is_async_mode_enabled()) + self.assertFalse(self.provider.is_async_mode_disabled()) + self.assertTrue(self.provider.is_async_mode_undefined()) + + +class AsyncTypingStubTests(AsyncTestCase): + + def test_async_(self): + container = Container() + + client1 = self._run(container.client.async_()) + client2 = self._run(container.client.async_()) + + self.assertIsInstance(client1, Client) + self.assertIs(client1.resource1, RESOURCE1) + self.assertIs(client1.resource2, RESOURCE2) + + self.assertIsInstance(client2, Client) + self.assertIs(client2.resource1, RESOURCE1) + self.assertIs(client2.resource2, RESOURCE2) + + service1 = self._run(container.service.async_()) + service2 = self._run(container.service.async_()) + + self.assertIsInstance(service1, Service) + self.assertIsInstance(service1.client, Client) + self.assertIs(service1.client.resource1, RESOURCE1) + self.assertIs(service1.client.resource2, RESOURCE2) + + self.assertIsInstance(service2, Service) + self.assertIsInstance(service2.client, Client) + self.assertIs(service2.client.resource1, RESOURCE1) + self.assertIs(service2.client.resource2, RESOURCE2) + + self.assertIsNot(service1.client, service2.client) diff --git a/tests/unit/providers/test_coroutines_py35.py b/tests/unit/providers/test_coroutines_py35.py index c9109f26..a3697044 100644 --- a/tests/unit/providers/test_coroutines_py35.py +++ b/tests/unit/providers/test_coroutines_py35.py @@ -1,9 +1,6 @@ """Dependency injector coroutine providers unit tests.""" import asyncio -import contextlib -import sys -import gc import unittest2 as unittest @@ -12,6 +9,19 @@ from dependency_injector import ( errors, ) +# Runtime import to get asyncutils module +import os +_TOP_DIR = os.path.abspath( + os.path.sep.join(( + os.path.dirname(__file__), + '../', + )), +) +import sys +sys.path.append(_TOP_DIR) + +from asyncutils import AsyncTestCase + async def _example(arg1, arg2, arg3, arg4): future = asyncio.Future() @@ -25,52 +35,6 @@ def run(main): return loop.run_until_complete(main) -def setup_test_loop( - loop_factory=asyncio.new_event_loop -) -> asyncio.AbstractEventLoop: - loop = loop_factory() - try: - module = loop.__class__.__module__ - skip_watcher = 'uvloop' in module - except AttributeError: # pragma: no cover - # Just in case - skip_watcher = True - asyncio.set_event_loop(loop) - if sys.platform != "win32" and not skip_watcher: - policy = asyncio.get_event_loop_policy() - watcher = asyncio.SafeChildWatcher() # type: ignore - watcher.attach_loop(loop) - with contextlib.suppress(NotImplementedError): - policy.set_child_watcher(watcher) - return loop - - -def teardown_test_loop(loop: asyncio.AbstractEventLoop, - fast: bool=False) -> None: - closed = loop.is_closed() - if not closed: - loop.call_soon(loop.stop) - loop.run_forever() - loop.close() - - if not fast: - gc.collect() - - asyncio.set_event_loop(None) - - -class AsyncTestCase(unittest.TestCase): - - def setUp(self): - self.loop = setup_test_loop() - - def tearDown(self): - teardown_test_loop(self.loop) - - def _run(self, f): - return self.loop.run_until_complete(f) - - class CoroutineTests(AsyncTestCase): def test_init_with_coroutine(self): diff --git a/tests/unit/providers/test_factories_py2_py3.py b/tests/unit/providers/test_factories_py2_py3.py index 66bd5495..b6587859 100644 --- a/tests/unit/providers/test_factories_py2_py3.py +++ b/tests/unit/providers/test_factories_py2_py3.py @@ -520,6 +520,24 @@ class FactoryAggregateTests(unittest.TestCase): self.assertEqual(object_b.init_arg3, 33) self.assertEqual(object_b.init_arg4, 44) + def test_call_factory_name_as_kwarg(self): + object_a = self.factory_aggregate( + factory_name='example_a', + init_arg1=1, + init_arg2=2, + init_arg3=3, + init_arg4=4, + ) + self.assertIsInstance(object_a, self.ExampleA) + self.assertEqual(object_a.init_arg1, 1) + self.assertEqual(object_a.init_arg2, 2) + self.assertEqual(object_a.init_arg3, 3) + self.assertEqual(object_a.init_arg4, 4) + + def test_call_no_factory_name(self): + with self.assertRaises(TypeError): + self.factory_aggregate() + def test_call_no_such_provider(self): with self.assertRaises(errors.NoSuchProviderError): self.factory_aggregate('unknown') diff --git a/tests/unit/providers/test_resource_py35.py b/tests/unit/providers/test_resource_py35.py index 09286eeb..e080eb75 100644 --- a/tests/unit/providers/test_resource_py35.py +++ b/tests/unit/providers/test_resource_py35.py @@ -1,11 +1,24 @@ """Dependency injector resource provider unit tests.""" -import sys +import asyncio import unittest2 as unittest from dependency_injector import containers, providers, resources, errors +# Runtime import to get asyncutils module +import os +_TOP_DIR = os.path.abspath( + os.path.sep.join(( + os.path.dirname(__file__), + '../', + )), +) +import sys +sys.path.append(_TOP_DIR) + +from asyncutils import AsyncTestCase + def init_fn(*args, **kwargs): return args, kwargs @@ -156,6 +169,15 @@ class ResourceTests(unittest.TestCase): self.assertEqual(_init.init_counter, 2) self.assertEqual(_init.shutdown_counter, 2) + def test_shutdown_of_not_initialized(self): + def _init(): + yield + + provider = providers.Resource(_init) + + result = provider.shutdown() + self.assertIsNone(result) + def test_initialized(self): provider = providers.Resource(init_fn) self.assertFalse(provider.initialized) @@ -320,3 +342,186 @@ class ResourceTests(unittest.TestCase): provider.initialized, ) ) + + +class AsyncResourceTest(AsyncTestCase): + + def test_init_async_function(self): + resource = object() + + async def _init(): + await asyncio.sleep(0.001) + _init.counter += 1 + return resource + _init.counter = 0 + + provider = providers.Resource(_init) + + result1 = self._run(provider()) + self.assertIs(result1, resource) + self.assertEqual(_init.counter, 1) + + result2 = self._run(provider()) + self.assertIs(result2, resource) + self.assertEqual(_init.counter, 1) + + self._run(provider.shutdown()) + + def test_init_async_generator(self): + resource = object() + + async def _init(): + await asyncio.sleep(0.001) + _init.init_counter += 1 + + yield resource + + await asyncio.sleep(0.001) + _init.shutdown_counter += 1 + + _init.init_counter = 0 + _init.shutdown_counter = 0 + + provider = providers.Resource(_init) + + result1 = self._run(provider()) + self.assertIs(result1, resource) + self.assertEqual(_init.init_counter, 1) + self.assertEqual(_init.shutdown_counter, 0) + + self._run(provider.shutdown()) + self.assertEqual(_init.init_counter, 1) + self.assertEqual(_init.shutdown_counter, 1) + + result2 = self._run(provider()) + self.assertIs(result2, resource) + self.assertEqual(_init.init_counter, 2) + self.assertEqual(_init.shutdown_counter, 1) + + self._run(provider.shutdown()) + self.assertEqual(_init.init_counter, 2) + self.assertEqual(_init.shutdown_counter, 2) + + def test_init_async_class(self): + resource = object() + + class TestResource(resources.AsyncResource): + init_counter = 0 + shutdown_counter = 0 + + async def init(self): + await asyncio.sleep(0.001) + self.__class__.init_counter += 1 + return resource + + async def shutdown(self, resource_): + await asyncio.sleep(0.001) + self.__class__.shutdown_counter += 1 + assert resource_ is resource + + provider = providers.Resource(TestResource) + + result1 = self._run(provider()) + self.assertIs(result1, resource) + self.assertEqual(TestResource.init_counter, 1) + self.assertEqual(TestResource.shutdown_counter, 0) + + self._run(provider.shutdown()) + self.assertEqual(TestResource.init_counter, 1) + self.assertEqual(TestResource.shutdown_counter, 1) + + result2 = self._run(provider()) + self.assertIs(result2, resource) + self.assertEqual(TestResource.init_counter, 2) + self.assertEqual(TestResource.shutdown_counter, 1) + + self._run(provider.shutdown()) + self.assertEqual(TestResource.init_counter, 2) + self.assertEqual(TestResource.shutdown_counter, 2) + + def test_init_with_error(self): + async def _init(): + raise RuntimeError() + + provider = providers.Resource(_init) + + future = provider() + self.assertTrue(provider.initialized) + self.assertTrue(provider.is_async_mode_enabled()) + + # Disable default exception handling to prevent output + asyncio.get_event_loop().set_exception_handler(lambda loop, context: ...) + + with self.assertRaises(RuntimeError): + self._run(future) + + # Restore default exception handling + asyncio.get_event_loop().set_exception_handler(None) + + self.assertFalse(provider.initialized) + self.assertTrue(provider.is_async_mode_enabled()) + + def test_init_and_shutdown_methods(self): + async def _init(): + await asyncio.sleep(0.001) + _init.init_counter += 1 + + yield + + await asyncio.sleep(0.001) + _init.shutdown_counter += 1 + + _init.init_counter = 0 + _init.shutdown_counter = 0 + + provider = providers.Resource(_init) + + self._run(provider.init()) + self.assertEqual(_init.init_counter, 1) + self.assertEqual(_init.shutdown_counter, 0) + + self._run(provider.shutdown()) + self.assertEqual(_init.init_counter, 1) + self.assertEqual(_init.shutdown_counter, 1) + + self._run(provider.init()) + self.assertEqual(_init.init_counter, 2) + self.assertEqual(_init.shutdown_counter, 1) + + self._run(provider.shutdown()) + self.assertEqual(_init.init_counter, 2) + self.assertEqual(_init.shutdown_counter, 2) + + def test_shutdown_of_not_initialized(self): + async def _init(): + yield + + provider = providers.Resource(_init) + provider.enable_async_mode() + + result = self._run(provider.shutdown()) + self.assertIsNone(result) + + def test_concurrent_init(self): + resource = object() + + async def _init(): + await asyncio.sleep(0.001) + _init.counter += 1 + return resource + _init.counter = 0 + + provider = providers.Resource(_init) + + result1, result2 = self._run( + asyncio.gather( + provider(), + provider() + ), + ) + + self.assertIs(result1, resource) + self.assertEqual(_init.counter, 1) + + self.assertIs(result2, resource) + self.assertEqual(_init.counter, 1) diff --git a/tests/unit/samples/wiringsamples/asyncinjections.py b/tests/unit/samples/wiringsamples/asyncinjections.py new file mode 100644 index 00000000..204300e3 --- /dev/null +++ b/tests/unit/samples/wiringsamples/asyncinjections.py @@ -0,0 +1,50 @@ +import asyncio + +from dependency_injector import containers, providers +from dependency_injector.wiring import inject, Provide, Closing + + +class TestResource: + def __init__(self): + self.init_counter = 0 + self.shutdown_counter = 0 + + def reset_counters(self): + self.init_counter = 0 + self.shutdown_counter = 0 + + +resource1 = TestResource() +resource2 = TestResource() + + +async def async_resource(resource): + await asyncio.sleep(0.001) + resource.init_counter += 1 + + yield resource + + await asyncio.sleep(0.001) + resource.shutdown_counter += 1 + + +class Container(containers.DeclarativeContainer): + + resource1 = providers.Resource(async_resource, providers.Object(resource1)) + resource2 = providers.Resource(async_resource, providers.Object(resource2)) + + +@inject +async def async_injection( + resource1: object = Provide[Container.resource1], + resource2: object = Provide[Container.resource2], +): + return resource1, resource2 + + +@inject +async def async_injection_with_closing( + resource1: object = Closing[Provide[Container.resource1]], + resource2: object = Closing[Provide[Container.resource2]], +): + return resource1, resource2 diff --git a/tests/unit/wiring/test_wiring_py36.py b/tests/unit/wiring/test_wiring_py36.py index 7c061ad9..ada0e8d9 100644 --- a/tests/unit/wiring/test_wiring_py36.py +++ b/tests/unit/wiring/test_wiring_py36.py @@ -5,6 +5,12 @@ from dependency_injector.wiring import wire, Provide, Closing # Runtime import to avoid syntax errors in samples on Python < 3.5 import os +_TOP_DIR = os.path.abspath( + os.path.sep.join(( + os.path.dirname(__file__), + '../', + )), +) _SAMPLES_DIR = os.path.abspath( os.path.sep.join(( os.path.dirname(__file__), @@ -12,8 +18,11 @@ _SAMPLES_DIR = os.path.abspath( )), ) import sys +sys.path.append(_TOP_DIR) sys.path.append(_SAMPLES_DIR) +from asyncutils import AsyncTestCase + from wiringsamples import module, package from wiringsamples.service import Service from wiringsamples.container import Container, SubContainer @@ -267,3 +276,56 @@ class WiringAndFastAPITest(unittest.TestCase): self.assertEqual(result_2.shutdown_counter, 2) self.assertIsNot(result_1, result_2) + + +class WiringAsyncInjectionsTest(AsyncTestCase): + + def test_async_injections(self): + from wiringsamples import asyncinjections + + container = asyncinjections.Container() + container.wire(modules=[asyncinjections]) + self.addCleanup(container.unwire) + + asyncinjections.resource1.reset_counters() + asyncinjections.resource2.reset_counters() + + resource1, resource2 = self._run(asyncinjections.async_injection()) + + self.assertIs(resource1, asyncinjections.resource1) + self.assertEqual(asyncinjections.resource1.init_counter, 1) + self.assertEqual(asyncinjections.resource1.shutdown_counter, 0) + + self.assertIs(resource2, asyncinjections.resource2) + self.assertEqual(asyncinjections.resource2.init_counter, 1) + self.assertEqual(asyncinjections.resource2.shutdown_counter, 0) + + def test_async_injections_with_closing(self): + from wiringsamples import asyncinjections + + container = asyncinjections.Container() + container.wire(modules=[asyncinjections]) + self.addCleanup(container.unwire) + + asyncinjections.resource1.reset_counters() + asyncinjections.resource2.reset_counters() + + resource1, resource2 = self._run(asyncinjections.async_injection_with_closing()) + + self.assertIs(resource1, asyncinjections.resource1) + self.assertEqual(asyncinjections.resource1.init_counter, 1) + self.assertEqual(asyncinjections.resource1.shutdown_counter, 1) + + self.assertIs(resource2, asyncinjections.resource2) + self.assertEqual(asyncinjections.resource2.init_counter, 1) + self.assertEqual(asyncinjections.resource2.shutdown_counter, 1) + + resource1, resource2 = self._run(asyncinjections.async_injection_with_closing()) + + self.assertIs(resource1, asyncinjections.resource1) + self.assertEqual(asyncinjections.resource1.init_counter, 2) + self.assertEqual(asyncinjections.resource1.shutdown_counter, 2) + + self.assertIs(resource2, asyncinjections.resource2) + self.assertEqual(asyncinjections.resource2.init_counter, 2) + self.assertEqual(asyncinjections.resource2.shutdown_counter, 2) diff --git a/tests/unit/wiring/test_wiringfastapi_py36.py b/tests/unit/wiring/test_wiringfastapi_py36.py index 8b76d857..68b2ae0b 100644 --- a/tests/unit/wiring/test_wiringfastapi_py36.py +++ b/tests/unit/wiring/test_wiringfastapi_py36.py @@ -1,13 +1,13 @@ -import asyncio -import contextlib -import gc -import unittest -from unittest import mock - from httpx import AsyncClient -# Runtime import to avoid syntax errors in samples on Python < 3.5 +# Runtime import to avoid syntax errors in samples on Python < 3.5 and reach top-dir import os +_TOP_DIR = os.path.abspath( + os.path.sep.join(( + os.path.dirname(__file__), + '../', + )), +) _SAMPLES_DIR = os.path.abspath( os.path.sep.join(( os.path.dirname(__file__), @@ -15,58 +15,14 @@ _SAMPLES_DIR = os.path.abspath( )), ) import sys +sys.path.append(_TOP_DIR) sys.path.append(_SAMPLES_DIR) +from asyncutils import AsyncTestCase + from wiringfastapi import web -# TODO: Refactor to use common async test case -def setup_test_loop( - loop_factory=asyncio.new_event_loop -) -> asyncio.AbstractEventLoop: - loop = loop_factory() - try: - module = loop.__class__.__module__ - skip_watcher = 'uvloop' in module - except AttributeError: # pragma: no cover - # Just in case - skip_watcher = True - asyncio.set_event_loop(loop) - if sys.platform != "win32" and not skip_watcher: - policy = asyncio.get_event_loop_policy() - watcher = asyncio.SafeChildWatcher() # type: ignore - watcher.attach_loop(loop) - with contextlib.suppress(NotImplementedError): - policy.set_child_watcher(watcher) - return loop - - -def teardown_test_loop(loop: asyncio.AbstractEventLoop, - fast: bool=False) -> None: - closed = loop.is_closed() - if not closed: - loop.call_soon(loop.stop) - loop.run_forever() - loop.close() - - if not fast: - gc.collect() - - asyncio.set_event_loop(None) - - -class AsyncTestCase(unittest.TestCase): - - def setUp(self): - self.loop = setup_test_loop() - - def tearDown(self): - teardown_test_loop(self.loop) - - def _run(self, f): - return self.loop.run_until_complete(f) - - class WiringFastAPITest(AsyncTestCase): client: AsyncClient