Repository navigation
Conversation
seperman
commented
Nov 25, 2026
Member
- Dropping Cachebox dependency
…ce cache cachebox was only used by DistanceCache in deepdiff/lfucache.py, which is created only when cache_size > 0 (default 0). Every install still pulled in a compiled Rust package for it, and 3.15 support had to wait for cachebox to ship cp315 wheels. DistanceCache is now a bounded LRU on collections.OrderedDict with a lock, keeping the same eviction policy, interface and thread safety. The LFUCache/DummyLFU aliases are unchanged. Measured with the --runslow cache tests (CPython): - test_cache_deeply_nested_a1: 0.55-0.56s before, 0.56s after - test_cache_deeply_nested_a2: 1.46-1.48s before, 1.50-1.52s after - nested_a with cache_size=100: ~3.40s before, ~3.42s after PASSES COUNT, DIFF COUNT and DISTANCE CACHE HIT COUNT are identical to the cachebox version at cache sizes 5000, 500 and 100. uv.lock: cachebox entries removed by hand to keep the lock at revision 5.
Drop cachebox dependency; use a stdlib LRU for the distance cache
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #682 +/- ##
==========================================
+ Coverage 95.21% 95.22% +0.01%
==========================================
Files 19 19
Lines 5055 5070 +15
==========================================
+ Hits 4813 4828 +15
Misses 242 242 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.