Skip to main content

Middleware for Django, Flask, and FastAPI to intercept requests, logs, and exceptions.

Project description

SF3 Middleware - Currently transmissions are diabled

Middleware for Python (Django, Flask, and FastAPI) to intercept requests, print statements, logs, and exceptions while persisting tracing.

Installation

Use Poetry to install:

poetry add sf-veritas

Usage

Django, etc

Switch the following:

python manage.py runserver 0.0.0.0:8000

To:

sf-veritas API-KEY python manage.py runserver 0.0.0.0:8000

TODO - Rename all Sailfish artifacts to Sailfish.ai

Network Hop Calculation Time

To evaluate the performance impact of this package, we benchmarked 1000 HTTP requests with and without the package enabled.

Configuration Mean (ms) Median (ms) Std Dev (ms)
✅ With Package 79.12 54.00 111.18
❌ Without Package 69.70 52.00 73.78

⚠️ Note: The package introduces a slight increase in mean response time and variance. This trade-off may be acceptable depending on the value the package provides (e.g., additional logging, monitoring, or security features).


Optimized Entrypoint Capture (Post-Refactor)

After optimizing how the user-code entrypoint is captured (via faster stack inspection), we observed improved stability and performance across 1015 analyzed requests:

Configuration Mean (ms) Median (ms) Std Dev (ms)
✅ With Package 142.45 138.50 80.78
❌ Without Package 131.07 127.00 35.75

⚠️ The optimized implementation added a slight increase in mean latency (~8.7%), but this tradeoff is offset by improved accuracy of entrypoint capture.


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

sf_veritas-0.10.6-cp314-cp314-manylinux_2_28_x86_64.whl (4.8 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.28+ x86-64

sf_veritas-0.10.6-cp313-cp313-manylinux_2_28_x86_64.whl (4.8 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64

sf_veritas-0.10.6-cp312-cp312-manylinux_2_28_x86_64.whl (4.8 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

sf_veritas-0.10.6-cp311-cp311-manylinux_2_28_x86_64.whl (4.8 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

sf_veritas-0.10.6-cp310-cp310-manylinux_2_28_x86_64.whl (4.8 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

sf_veritas-0.10.6-cp39-cp39-manylinux_2_28_x86_64.whl (4.8 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.28+ x86-64

File details

Details for the file sf_veritas-0.10.6-cp314-cp314-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for sf_veritas-0.10.6-cp314-cp314-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 d09873acefbba5a0fcce15ef6e29d7db9c75f92819b17323d4f31a15b53a0060
MD5 b8be6c787e820cddf838cd8489c1b018
BLAKE2b-256 764e66332a7f9da9b47f6bdc20b2eec00d445ca0637bc781d7ce0c19bc9f4e8f

See more details on using hashes here.

File details

Details for the file sf_veritas-0.10.6-cp313-cp313-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for sf_veritas-0.10.6-cp313-cp313-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 46bfcd4884b90cce6e3d7806ed7966397d0d029768714b54ac0aaaa4a9cb1b7e
MD5 e6f1c774baaf7888599a4e9874453ef4
BLAKE2b-256 9694ce278aef985df9eae6cf349da8db9cfc1b8fa90f630f60df031208a6819d

See more details on using hashes here.

File details

Details for the file sf_veritas-0.10.6-cp312-cp312-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for sf_veritas-0.10.6-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 ef7829ef1efc69c4c31bf39ce37565dbe7a64894cf0331a1645e71fcc11aaaa6
MD5 ae2bfaa284ed6dac4cd77de7f35df86d
BLAKE2b-256 844c257f8f782091dfff7f8246e4600832662d3ed89d3fc0a6bdef58d9fa94e8

See more details on using hashes here.

File details

Details for the file sf_veritas-0.10.6-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for sf_veritas-0.10.6-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 5d68f41fb15f0edb4d431610bb3c9a6fb73ed942b0825d63940dbbb681665474
MD5 21b19cb1b5ddbdd8da9839d09ce0d88f
BLAKE2b-256 f3a3717bfa917984aafd46875e0105106b83bd0abbead4fa1b974afa98dbd62f

See more details on using hashes here.

File details

Details for the file sf_veritas-0.10.6-cp310-cp310-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for sf_veritas-0.10.6-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 800743efb5b817988adc8fd084458c740bbcf5096eeb4a1aeea3dfb0e8ae24c7
MD5 89100f73b4d1fb61656df67012165c69
BLAKE2b-256 4a3490fc682bc223b183ca404c90ffb137ba22034c4bddaa21eb1f5632a7ff5e

See more details on using hashes here.

File details

Details for the file sf_veritas-0.10.6-cp39-cp39-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for sf_veritas-0.10.6-cp39-cp39-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 223c90bd0e5727d6aef7a23472e8b24a0b00e1324b3a1e6087d979d214aa49c9
MD5 ac730da27d808db73cf7d08f7b59e5fb
BLAKE2b-256 86c6df35c4a0188b92da03c1f99d255b0a405fc694e8e153be4b77fa494ca1a4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page