All notable changes to persist-cache
will be documented here. This project adheres to Keep a Changelog and Semantic Versioning.
0.4.3 - 2024-06-19
- Fixed a typo that caused the fix for #6 to not work and instead break
flush()
.
0.4.2 - 2024-06-18
- Fixed a bug wherein
flush()
would try locking lock files (#6). - Fixed typo in the docstring for the
test_persist_cache()
unit test intest_persist_cache.py
.
0.4.1 - 2024-06-10
- Fixed the formatting of the docstring of
cache()
because a portion of it was being rendered by Vscode as a single line instead of a bullet point list.
0.4.0 - 2024-05-06
- Added support for the caching of both synchronous and asynchronous generator functions.
- Added
delete()
,clear()
andflush()
helper functions for deleting, clearing and flushing caches.
0.3.2 - 2024-03-21
- Began hashing the names of caches with
XXH3
to ensure caches may be assigned any arbitrary name, regardless of whether it is compatible with the local file system.
0.3.1 - 2024-03-20
- Fixed a bug causing
cache()
to raise aTypeError
when attempting to cache a function call that contains an argument that is a list containing a dictionary (#4) (ec07874).
0.3.0 - 2024-03-19
- Ceased delimiting hashes and the length of the input with hyphens as the hashes already have a fixed size so there is no possibility of collision.
0.2.0 - 2024-03-18
- Stale calls are now flushed when initialising a cache.
- Switched hashing algorithm from
XXH3
toXXH128
and began suffixing hashes with the length of their input to significantly reduce the already very low likelihood of hash collisions. - Pickle data is now compressed with LZ4 to speed up IO and reduce disk usage.
- Removed unused import of
asyncio
inpersist_cache.py
.
0.1.1 - 2024-03-14
- Added a unit test for passing a custom name to
cache()
. - Added unit tests for the caching of asynchronous functions and methods.
- Added unit tests for the caching of synchronous methods.
- Fixed
cache()
's inability to identify certain wrapped asynchronous functions and methods as being asynchronous (#1) (fe7aa6c). - Fixed
cache()
's inability to cache function calls returningbytes
,bytearray
andmemoryview
objects (#2) (f763ce7).
0.1.0 - 2024-03-12
- Added the
cache()
decorator, which locally and persistently caches functions.