mirror of
https://github.com/ets-labs/python-dependency-injector.git
synced 2024-11-30 05:23:59 +03:00
19 lines
510 B
ReStructuredText
19 lines
510 B
ReStructuredText
|
.. _check-container-dependencies:
|
||
|
|
||
|
Check container dependencies
|
||
|
----------------------------
|
||
|
|
||
|
To check container dependencies use method ``.check_dependencies()``.
|
||
|
|
||
|
.. literalinclude:: ../../examples/containers/check_dependencies.py
|
||
|
:language: python
|
||
|
:lines: 3-
|
||
|
:emphasize-lines: 12
|
||
|
|
||
|
Method ``.check_dependencies()`` raises an error if container has any undefined dependencies.
|
||
|
If all dependencies are provided or have defaults, no error is raised.
|
||
|
|
||
|
See also: :ref:`dependency-provider`.
|
||
|
|
||
|
.. disqus::
|