Opyoid

Latest version: v3.0.1

Safety actively analyzes 723177 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 4 of 6

0.10.0

Breaking changes
- Replaced `annotated_arg` with `named_arg`
- Renamed the `annotation` parameter to `named` in:
- all Binding subclasses
- the `AbstractModule.bind` method
- the `Injector.inject` method
- Changed the way annotated/named arguments work:
- When injecting a parameter in a constructor, opyoid will first try to find a binding with the same type and the
same name as the argument. If none is found, it will then try to find a binding with the same type and no name (this
part did not change).
- If the `named_arg` decorator is used, opyoid will only try to find a binding with this name, if none is found, no
unnamed binding will be used (this did not change).

Features
- Cyclic dependencies now raise a `CyclicDependencyError` instead of a `RecursionError`
- Cleaner and more verbose logs

Fixes
- Removed duplicate logs about registering bindings

0.9.0

Breaking changes
- ClassBindings cannot be used to bind a class to itself anymore, use a SelfBinding instead

Features
- When binding to a target an instance of a subclass of the target type, another InstanceBinding is created with the
same instance and its type as a target
- When binding to a target an instance of a provider, another InstanceBinding is created with the same provider and its
type as a target

Fixes
- Fixed Bindings with a target being overriden by `ClassBindings` with the same target as a `bound_type`

0.8.0

Features
- Support for PEP585 style type hints (list[str], set[str], ...)

0.7.0

Features
- MultiBindings can now be exposed by PrivateModules

Fixes
- Binding Provider classes in ItemBindings now works as expected

0.6.2

Fixes
- Non hashable instance bindings can be exposed in private modules

0.6.1

Fixes
- Fixed a bug preventing injection when using strings as type hints

Page 4 of 6

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.