pyramid_debugtoolbar_api_performance
.. image:: https://github.com/jvanasco/pyramid_debugtoolbar_api_performance/workflows/Python%20package/badge.svg :alt: Build Status
pyramid_debugtoolbar_api_performance extends the existing pyramid_debugtoolbar
Performance Panel to support downloadable CSV files of profiling data.
This package does not replace the default panel, and requires it to be active.
This package is designed for application profile and to be a useful part of test suites, allowing developers to run a series of tests and log the Performance performance.
The package exposes two routes for CSV data:
- timing
- function_calls
Both correlate to the official Performance panel data.
The urls are generated in a machine-friendly format, so you can regex the
request_id off a page and pull it from the API. This is explained below...
NOTES:
This packages requires pyramid_debugtoolbar 4.0 or newer
How to use this package
Update your ENVIRONMENT.ini file
.. code-block:: python
debugtoolbar.includes = pyramid_debugtoolbar_api_performance
You MUST be using pyramid_debugtoolbar with the Performance panel enabled.
This package simply piggybacks on the existing module's work to log queries.
You MUST use debugtoolbar.includes. This will not work properly via pyramid.includes
You can access a csv of the Profiling report via the following url hack:
.. code-block:: python
url_html = '/_debug_toolbar/{request_id}'
url_api = '/_debug_toolbar/api-performance/timing-{request_id}.csv'
url_api = '/_debug_toolbar/api-performance/function_calls-{request_id}.csv'
The file will be downloaded and offer a content-disposition as:
.. code-block:: shell
performance-{request_id}.csv
Configuration
By default, this package writes CSV files using "UTF-8" encoding.
To change this, use the environment variable pyramid_debugtoolbar_api_performance_encoding
.. code-block:: shell
export pyramid_debugtoolbar_api_performance_encoding=ascii
Metadata
Release files for pyramid-debugtoolbar-api-performance 0.3.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| pyramid_debugtoolbar_api_performance-0.3.1.tar.gz | 8.5 kB | Without provenance | Details |
Release files / pyramid_debugtoolbar_api_performance-0.3.1.tar.gz
| Download URL | pyramid_debugtoolbar_api_performance-0.3.1.tar.gz |
|---|---|
| Size | 8.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9aebb13bcb94237e417d10bc98ca1e4018a7af3c4d6bbd317c5c6e9eabfd4fb2
|
|
BLAKE2b-256 checksum How to use checksums |
b195ae6d559cc77f3f501d2097c6ff60ae698dd6435ff15975cdc8bd0d4cde89
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.5
|
Security for pyramid-debugtoolbar-api-performance 0.3.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.