python-injection 0.14.4__tar.gz → 0.14.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python_injection-0.14.4 → python_injection-0.14.5}/PKG-INFO +1 -1
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/__init__.pyi +1 -1
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/module.py +1 -1
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/utils.py +2 -1
- {python_injection-0.14.4 → python_injection-0.14.5}/pyproject.toml +1 -1
- {python_injection-0.14.4 → python_injection-0.14.5}/.gitignore +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/README.md +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/__init__.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/__init__.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/common/__init__.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/common/asynchronous.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/common/event.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/common/invertible.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/common/key.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/common/lazy.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/common/type.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/descriptors.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/injectables.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/scope.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/_core/slots.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/exceptions.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/integrations/__init__.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/integrations/fastapi.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/py.typed +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/testing/__init__.py +0 -0
- {python_injection-0.14.4 → python_injection-0.14.5}/injection/testing/__init__.pyi +0 -0
@@ -550,7 +550,7 @@ class Module(Broker, EventListener):
|
|
550
550
|
) -> Slot[T]:
|
551
551
|
def when_empty() -> T:
|
552
552
|
raise EmptySlotError(
|
553
|
-
f"The slot for `{on}`
|
553
|
+
f"The slot for `{on}` isn't set in the current `{scope_name}` scope."
|
554
554
|
)
|
555
555
|
|
556
556
|
injectable = SimpleScopedInjectable(SyncCaller(when_empty), scope_name)
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import sys
|
1
2
|
from collections.abc import Callable, Collection, Iterator
|
2
3
|
from importlib import import_module
|
3
4
|
from importlib.util import find_spec
|
@@ -89,7 +90,7 @@ def __iter_modules_from(
|
|
89
90
|
for info in walk_packages(path=package_path, prefix=f"{package_name}."):
|
90
91
|
name = info.name
|
91
92
|
|
92
|
-
if info.ispkg or not predicate(name):
|
93
|
+
if info.ispkg or name in sys.modules or not predicate(name):
|
93
94
|
continue
|
94
95
|
|
95
96
|
yield name, import_module(name)
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|