Sanic-plugin-toolkit

Latest version: v1.2.1

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

Scan your dependencies

Page 4 of 8

0.8.0

-----
- Added support for a spf config file

- This is in the python configparser format, it is like an INI file.
- See the config file example in /examples/ for how to use it.

- Added ability to get a plugin assoc object from SPF, simply by asking for the plugin name.

- This is to facilitate pulling the assoc object from when a plugin was registered via the config file

- A new way of advertising sanic plugins using setup.py entrypoints is defined.

- We use it in this project to advertise the 'Contextualize' plugin.

- Fixed some example files.

0.7.0

-----
- Added a new type of middleware called "cleanup" middleware

- It Runs after response middleware, whether response is generated or not, and even if there was errors.
- Moved the request-context removal process to run in the "cleanup" middleware step, because sometimes Response middleware is not run, eg. if Response is None (like in the case of a Websocket route), then Response Middleware will never fire.
- Cleanup middleware can be used to do per-request cleanup to prevent memory leaks.

0.6.7

-----
- A critical fix for plugin-private-request contexts. They were always overwriting the shared request context when they were created.
- Added new 'id' field inside the private request context container and the shared request context container, to tell them apart when they are used.
- Added a new test for this exact issue.

0.6.6

-----
- No 1.0 yet, there are more features planed before we call SPF ready for 1.0.
- Add more tests, and start filling in some missing test coverage
- Fix a couple of bugs already uncovered by filling in coverage.

- Notably, fix an issue that was preventing the plugin static file helper from working.

0.6.5

-----
- Changed the versioning scheme to not include ".devN" suffixes. This was preventing SPF from being installed using ``pipenv``

- This is in preparation for a 1.0.0 release, to coincide with the Sanic 2018.12 release.

0.6.4.dev20181101

-----------------
- Made changes in order for SPF, and Sanic Plugins to be pickled
- This fixes the ability for SPF-enabled Sanic Apps to use ``workers=`` on Windows, to allow multiprocessing.

- Added ``__setstate__``, ``__getstate__``, and ``__reduce__`` methods to all SPF classes
- Change usages of PriorityQueue to collections.deque (PriorityQueue cannot be pickled because it is a synchronous class)
- Changed the "name" part of all namedtuples to be the same name as the attribute key on the module they are declared in. This is necessary in order to be able to de-pickle a namedtuple object.

- This *may* be a breaking change?

- No longer store our own logger, because they cannot be picked. Just use the global logger provided by ``sanic.log.logger``

Page 4 of 8

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.