Fix declarative container mypy stub

This commit is contained in:
Roman Mogylatov 2020-09-07 11:53:03 -04:00
parent 5306b27c48
commit 098ecb4eec
2 changed files with 2 additions and 1 deletions

View File

@ -10,6 +10,7 @@ follows `Semantic versioning`_
Develop
-------
- Refactor "password hashing" example.
- Fix declarative container mypy stub to ``__init__`` to accept not only providers.
3.40.0
------

View File

@ -24,7 +24,7 @@ class DynamicContainer(Container): ...
class DeclarativeContainer(Container):
cls_providers: ClassVar[Dict[str, Provider]]
inherited_providers: ClassVar[Dict[str, Provider]]
def __init__(self, **overriding_providers: Provider) -> None: ...
def __init__(self, **overriding_providers: Union[Provider, Any]) -> None: ...
def override(container: Container) -> _Callable[[Container], Container]: ...