Bevy

Latest version: v2.0.2

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

Scan your dependencies

Page 2 of 4

2.0.0b4

2.0.0b2

Corrects some minor issues in the readme.

2.0.0b1

This is a complete rewrite and reenvisioning of Bevy. Bevy now uses contextvars, so the context state no longer has to be attached to class instances and functions. This allows for cleaner syntax and simple support for both classes and functions!

Version 2.0 also introduces the new Annotated Provider. The Annotated Provider looks for `typing.Annotated` hints, which allows for cached instances of the same type to coexist in the same repository.

Version 2.0 also does away with needing to deal with a context repository. You can just write a class, annotate the attributes, and assign them the dependency instance to have them injected at runtime when needed. Same goes for functions, use the inject decorator, annotate your parameters, and assign them the dependency instance as their default value, Bevy will handle everything when you call the function.

1.3.12

Fix a bug where the bevy context descriptor would return `None` if an object had a `__bool__` method that returned `False`. Also the descriptor now correctly handles objects that do not have a `__bevy_context__` attribute.

1.3.11

- Rename the old get method to find (return default if not found)
- Create a new get method (attempt to create if not found)
- Change the add_to_context parameter to cache

1.3.10

Fixes the function provider not understanding string annotations.

Page 2 of 4

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.