Joblib Typed Cache
Joblib's cache functionality in joblib.Memory does not preserve type annotations of the underlying function.
That poses obstacles for pydantic validation and for modern type checkers and autocompletion in IDEs.
This package simply defines an incomplete adapter for the cache functionality.
Installation
uv add joblib-typed-cache
Usage
The package offers a drop-in replacement for joblib.Memory.cache.
from typed_joblib_cache import Memory
cache = Memory(location="~/.cache", verbose=0)
@cache(ignore=["db_connection"])
def get_user(user_id: str, db_connection: str) -> dict[str, str]:
# Simulate data retrieval
return {"user_id": user_id, "email": "john@example.com", "transaction_id": 42}
In this example, the function get_user will retain helpful tooltips in IDE and can also be used in conjunction with pydantic type validation.
import pydantic
get_user_validated = validate_call(get_user)
Metadata
Release files for joblib-typed-cache 0.1.0
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 |
|---|---|---|---|---|
| joblib_typed_cache-0.1.0.tar.gz | 4.4 kB | With provenance | Details for joblib_typed_cache-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| joblib_typed_cache-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for joblib_typed_cache-0.1.0-py3-none-any.whl |
Total release size: 9.3 kB
Release files / joblib_typed_cache-0.1.0.tar.gz
| Download URL | joblib_typed_cache-0.1.0.tar.gz |
|---|---|
| Size | 4.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c2dfb52dfa825cad25756217941f5df4d4996e34775dfa25ecb7c3c5b6234a84
|
|
BLAKE2b-256 checksum How to use checksums |
ba4b0b2ce04d3bd2b412168d95d5180cf0e5c90482f18b6fbbb3c39defe6412c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Mar 15, 2026.
Transparency logRelease files / joblib_typed_cache-0.1.0-py3-none-any.whl
| Download URL | joblib_typed_cache-0.1.0-py3-none-any.whl |
|---|---|
| Size | 4.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d87656bc33e993e86b657346209d2296cfb83a5b12277bcb722cfb2fc2aaaafc
|
|
BLAKE2b-256 checksum How to use checksums |
0353a1944714c15bbd0edb9eb85086eab51581148d1f8521d7418c022aafb1b1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Mar 15, 2026.
Transparency logSecurity for joblib-typed-cache 0.1.0
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.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for joblib_typed_cache-0.1.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Mar 15, 2026.
Transparency logA 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.