mirror of
https://github.com/ets-labs/python-dependency-injector.git
synced 2024-11-25 11:04:01 +03:00
Merge branch 'release/4.32.2' into master
This commit is contained in:
commit
64574dff4d
|
@ -7,6 +7,12 @@ that were made in every particular version.
|
||||||
From version 0.7.6 *Dependency Injector* framework strictly
|
From version 0.7.6 *Dependency Injector* framework strictly
|
||||||
follows `Semantic versioning`_
|
follows `Semantic versioning`_
|
||||||
|
|
||||||
|
4.32.2
|
||||||
|
------
|
||||||
|
- Improve wiring fault tolerance.
|
||||||
|
See issue `#441 <https://github.com/ets-labs/python-dependency-injector/issues/441>`_.
|
||||||
|
Thanks to `@ssheng <https://github.com/ssheng>`_ for reporting the issue.
|
||||||
|
|
||||||
4.32.1
|
4.32.1
|
||||||
------
|
------
|
||||||
- Fix a bug with ``List`` provider not working in async mode.
|
- Fix a bug with ``List`` provider not working in async mode.
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
"""Top-level package."""
|
"""Top-level package."""
|
||||||
|
|
||||||
__version__ = '4.32.1'
|
__version__ = '4.32.2'
|
||||||
"""Version number.
|
"""Version number.
|
||||||
|
|
||||||
:type: str
|
:type: str
|
||||||
|
|
|
@ -342,11 +342,17 @@ def wire( # noqa: C901
|
||||||
_patch_fn(module, member_name, member, providers_map)
|
_patch_fn(module, member_name, member, providers_map)
|
||||||
elif inspect.isclass(member):
|
elif inspect.isclass(member):
|
||||||
cls = member
|
cls = member
|
||||||
for cls_member_name, cls_member in inspect.getmembers(cls):
|
try:
|
||||||
if _is_marker(cls_member):
|
cls_members = inspect.getmembers(cls)
|
||||||
_patch_attribute(cls, cls_member_name, cls_member, providers_map)
|
except Exception: # noqa
|
||||||
elif _is_method(cls_member):
|
# Hotfix, see: https://github.com/ets-labs/python-dependency-injector/issues/441
|
||||||
_patch_method(cls, cls_member_name, cls_member, providers_map)
|
continue
|
||||||
|
else:
|
||||||
|
for cls_member_name, cls_member in cls_members:
|
||||||
|
if _is_marker(cls_member):
|
||||||
|
_patch_attribute(cls, cls_member_name, cls_member, providers_map)
|
||||||
|
elif _is_method(cls_member):
|
||||||
|
_patch_method(cls, cls_member_name, cls_member, providers_map)
|
||||||
|
|
||||||
for patched in _patched_registry.get_callables_from_module(module):
|
for patched in _patched_registry.get_callables_from_module(module):
|
||||||
_bind_injections(patched, providers_map)
|
_bind_injections(patched, providers_map)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user