jmcvetta/django-cacheops
47.6
Weak · 10 November 2026
1.1k
lines of production code
Python
primary language
9
measurements over time
What this system is
This system is a Django caching library that provides automatic cache invalidation for database queries and template fragments. It integrates with Redis and supports file-based caching, offering decorators and template tags to manage cache states. The system also includes management commands for cache invalidation and cleanup, ensuring consistency across various Django model relationships.
Features
Add Jinja2 template tags and improve Redis connection handling
Adds Jinja2 template tags (\\{% cached %}\\ and \\{% cached\_as %}\\) for caching template fragments, integrating with the existing \\@cached\_as\\ decorator. The Redis client is now wrapped in a \\SafeRedis\\ class that degrades gracefully on connection failures, controlled by the new \\CACHEOPS\_DEGRADE\_ON\_FAILURE\\ setting. Additionally, the \\dnf\\ function now supports \\isnull\\ lookups and uses \\attname\\ for better field resolution, while the \\@cacheoped\_method\\ and \\@cacheoped\_as\\ decorators are renamed to \\@cached\_method\\ and \\@cached\_as\\ respectively.
cacheops · high confidence
Initial release of django-cacheops v0.9.8
The project is being initialized with version 0.9.8, establishing the core package structure, dependencies (Django, Redis, simplejson), and standard repository metadata files. This includes the addition of a BSD license, an AUTHORS file, a CHANGELOG, a MANIFEST for packaging, and a .gitignore configuration. The release also introduces a Python benchmarking script (bench.py) for performance testing and a test runner (run\_tests.py) that supports the -x (failfast) argument.
(repo-wide) · high confidence
Behavioural changes
Enhanced cache invalidation and new file cache cleanup command
The 'invalidate' management command now supports invalidating auto-created models by passing 'all' or specific app/model identifiers, and uses a new 'invalidate\_all' function instead of directly flushing the Redis database. Additionally, a new 'cleanfilecache' command has been added to remove old files from the file-based cache directory.
cacheops/management · high confidence
Test coverage
Added test suite for cache invalidation scenarios
Added a comprehensive test suite in the \tests\ directory to verify cache invalidation behavior. The new tests cover invalidation triggers for foreign keys, one-to-one fields, boolean fields, and many-to-many relationships. It also includes tests for proxy models and multi-table inheritance, ensuring that cache invalidation works correctly across these different model configurations.
tests · high confidence
Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 48 → 48 (-0.5)
- Rubric changed (rubric-2026.10.5 → rubric-2026.11.2) — scores are not directly comparable.
Lenses
- Code Health 98 → 98 (+0.0)
- Architecture 69 → 69 (+0.0)
- Maturity 38 → 38 (+0.0)
- Readiness 33 → 33 (+0.0)
- Security 87 → 81 (-6.3)
- Domain Modelling 100 → 100 (+0.0)
Resolved (3)
- Documentation: no installation or build instructions (README.rst)
- Documentation: no usage examples (README.rst)
- Inconsistent parameter naming for identical operations across cache backends. RedisCache and FileCache use 'cache_key' and 'key' respectively for the same concept, while SafeRedis.get is exposed as a field reference without signature clarity.
Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
jmcvetta/django-cacheops was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 10 November 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit 217b97f1fbc3bb25c219d2640e2dc964e4f7ef2e — the exact code this score is about.
- Scored under rubric-2026.11.2 — the same rubric and the same method as every other entry in this index.
- Measured by Canine Code Analyzer (cca.canine.dev) using cca measure-2026.11.4+preprod-464a0040a931.