Graphene-django-plus

Latest version: v5.1

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

Scan your dependencies

Page 4 of 11

3.0

New release which tries to fix some non-stardalized method signatures and other historical issues.

Note that this release has some breaking changes that need to be fixed if you relied on them:

- New `GuardedRelatedModel` that allows to define models that actually relies on a related (i.e. through a foreign key) model's permissions: https://github.com/0soft/graphene-django-plus/commit/d10dccb3e502155f7e51518d638ed824ff8034cc
- *BREAKING CHANGE* defaults `any_perm` checking to `True` to make it closer to how guardian works: https://github.com/0soft/graphene-django-plus/commit/5425234e22942fb3b796e03c13999804bc143d35 . Change your type meta options if you don't want that
- *BREAKING CHANGE* `created_at`, `updated_at` and `archived_at` are not excluded from mutations by default: https://github.com/0soft/graphene-django-plus/commit/c8cf295d9c9fbcc0aabbb6b2d05e1289cd1972eb . Use `exclude_fields` to exclude those if those are present in your model and you want to exclude them
- *BREAKING CHANGE* `allow_unauthenticated` is now called `public` to avoid confusion that the name could cause: https://github.com/0soft/graphene-django-plus/commit/e29240bb49936558c0ac5f23b90ff2d3d72f0ea1 . Just change all occurrencies from `allow_unauthenticated` to `public` and you should be fine
- Adjust all mutation's apis to receive `info` as their first argument: https://github.com/0soft/graphene-django-plus/commit/7a9036ca1f994c3978fce95c623f682e3113c93d . This is a historical problem in which not all apis had a startalized access method and the lack of info prevented some overrides to access it.

2.7

* Add type annotations to the project where we can

2.6.2

2.6.1

- Swallow all subclasses of django's `PermissionDenied` on mutations

2.6

*BREAKING CHANGES*

- Consider global permissions when checking `obj.has_perm`. This means that giving a user a global permission for a model will make it reply `True` when checking for permissions to any object of that model
- Queries and mutations don't raise `PermissionDenied` anymore. Instead, queries will return `null` when the user doesn't have permission to see that object and mutations will swallow the exception and return them in the `errors` list. To keep the old behaviour you can set the `MUTATIONS_SWALLOW_PERMISSIONS = False` in settings.

2.5

*BREAKING CHANGE*

- `GuardedModelManager.for_user` now defaults its `with_superuser` to `True` to keep compatibility with the default guardian behaviour.
If you were using this integration before and needs the old behaviour, you can subclass `GuardedModelManager` and override its `for_user` method to keep the old behaviour.

Page 4 of 11

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.