Releases: illuin-tech/opyoid
Releases · illuin-tech/opyoid
3.0.4
07 Jan 16:02
Compare
Sorry, something went wrong.
No results found
Fixes
Fix dependency loops not always raising a CyclicDependencyError and crashing with a maximum recursion depth exceeded
3.0.3
16 May 08:32
Compare
Sorry, something went wrong.
No results found
Fixes
Fixed a crash when using Instance Bindings with objects without an equality operator, such as pandas DataFrames or
numpy arrays
3.0.2
28 Apr 10:50
Compare
Sorry, something went wrong.
No results found
Fixes
Fixed an issue with multi binding unexpectedly injecting multiple instances of the same class
Fixed an edge case when modules were configured multiple times when imported inside different modules
3.0.1
17 Jan 11:49
Compare
Sorry, something went wrong.
No results found
Fixes
Fix NoBindingFound error being raised when using multi bindings and injecting pep585 style list arguments
3.0.0
25 Nov 19:07
Compare
Sorry, something went wrong.
No results found
Breaking changes
Remove support for Python 3.8
2.0.2
09 Jan 17:06
Compare
Sorry, something went wrong.
No results found
Fixes
Fixed an InjectException raised when trying to bind a class with a stringified parameter type
2.0.1
30 Dec 11:03
Compare
Sorry, something went wrong.
No results found
Fixes
Fixed MultiBindings not using the correct provider when having multiple ItemBindings to Providers
2.0.0
03 Nov 10:52
Compare
Sorry, something went wrong.
No results found
Breaking changes
Remove support for Python < 3.8
MultiBindings now have the parameter override_bindings set to False by default (was True)
1.7.0
18 Nov 21:40
Compare
Sorry, something went wrong.
No results found
Features
Add official support for Python 3.11
Opyoid is now PEP561 compliant, and as such compatible with mypy
Added a Context Scope that can be used to control more precisely the scope of created objects:
from opyoid import ContextScope , Injector , SelfBinding
class MyClass :
pass
injector = Injector (bindings = [SelfBinding (MyClass , scope = ContextScope )])
scope = injector .inject (ContextScope )
with scope :
instance_1 = injector .inject (MyClass )
instance_2 = injector .inject (MyClass )
with scope :
instance_3 = injector .inject (MyClass )
assert instance_1 is instance_2
assert instance_1 is not instance_3
1.6.0
13 Sep 15:03
Compare
Sorry, something went wrong.
No results found
Features
Built-in types such as strings, ints, floats and booleans can be loaded from enviroment variables
The environment variable name should be <UPPER_CLASS_NAME_UPPER_PARAMTER_NAME>
Use InjectorOptions.use_env_vars to enable/disable the feature (activated by default)
Check the docs for more details