Debug cache
Note. This is Alpha software, use with caution.
A cache meant to speed up debugging and testing process. Stores intermediate results in files.
Installation
pip install debug-cache
Usage
from debug_cache import DebugCache
cache = DebugCache(path='/path/to/debug_cache')
# or just use default
from debug_cache import cache
First debug_cache usage is to fasten repeated and heavy calls to tighten edit/rerun loop:
@cache.cached
def some_function(x, y):
# do something
return res
Second debug_cache usage is to check that function results didn’t change. Useful when refactoring or optimizing:
# Check that function results didn't change, they need to be cached first
@cache.checked
def some_function(x, y):
# ...
# Same, but cache first time, check all subsequent ones
@cache.checked(strict=False)
def some_function(x, y):
# ...
This will stop and start debugger if function results don’t match ones saved earlier. Strict version also stops if no cached results are found.
Metadata
Release files for debug-cache 0.0.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 | Actions |
|---|---|---|---|---|
| debug-cache-0.0.1.tar.gz | 6.0 kB | Without provenance | Details for debug-cache-0.0.1.tar.gz |
Release files / debug-cache-0.0.1.tar.gz
| Download URL | debug-cache-0.0.1.tar.gz |
|---|---|
| Size | 6.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f75729ce62913fc47c378eb1beb14360644f229550ea3b0f8507d4a0a4106acf
|
|
BLAKE2b-256 checksum How to use checksums |
af0d6633b108a167a6087919a071ef28ea7f1d48fc76a17fc8e93197d90b56b4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for debug-cache 0.0.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.
To learn more about protecting yourself from malicious actors, visit our package security documentation.