Tomodachi

Latest version: v0.28.3

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

Scan your dependencies

Page 12 of 26

0.15.0

- `message_middleware` will now receive four arguments instead of the earlier three. `func: Callable, service: Any, message: Any, topic: str` for SNS and `func: Callable, service: Any, message: Any, route_key: str` for AMQP. If you are using middlewares for messaging you will most likely need to update these.
- Additional kwargs may be passed into the `aws_sns_sqs_publish` and `amqp_publish` functions and will be forwarded to the `message_protocol` `build_message` function.

0.14.8

- Fixes an issue when websockets were initiated together with an HTTP middleware applying additional arguments and keywords.
- Sets the `request._cache['is_websocket']` value before handing the processing off to the middleware.
- Fixes a bug causing `aiohttp.web.FileResponse` return values to not show any content.

0.14.7

- Added helper functions to be able to get the status code of a HTTP response or on a raised exception during a HTTP request. `await tomodachi.get_http_response_status(value, request=request)` or `await tomodachi.get_http_response_status(exception, request=request)`

0.14.6

- Extended middleware functionality to also be available for event based messaging (AMQP and SNS+SQS) as `message_middleware`.

0.14.5

- Added the support of middlewares to inject additional arguments and keywords arguments or overriding existing keyword arguments of the invoked function.

0.14.4

- Service classes may now use `http_middleware` which is a list of functions to be run on all HTTP calls and may change the behaviour before or after the invoked function is called, either preventing the function from being called or modifying the response values. An example has been added to the examples directory.
- The auto-reloader on code changes will now only reload if a the files content has actually changed and not when the file was written to disk without changes.

Page 12 of 26

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.