blob: 0c24a03c6564b87adcd30ca13963255be7cba988 [file] [log] [blame]
Thomas Kemmer8b9bbc42021-09-30 12:12:24 +02001v4.2.4 (2021-09-30)
2===================
3
4- Add submodule shims for backward compatibility.
5
6
Thomas Kemmerbc998ba2021-09-29 22:21:52 +02007v4.2.3 (2021-09-29)
8===================
9
10- Add documentation and tests for using ``TTLCache`` with
11 ``datetime``.
12
13- Link to typeshed typing stubs.
14
15- Flatten package file hierarchy.
16
17
Thomas Kemmere919f2f2021-04-27 23:11:46 +020018v4.2.2 (2021-04-27)
19===================
20
21- Update build environment.
22
23- Remove Python 2 remnants.
24
25- Format code with Black.
26
27
Thomas Kemmer16c77042021-01-24 21:35:22 +010028v4.2.1 (2021-01-24)
Thomas Kemmer1d99e162021-01-24 20:49:22 +010029===================
30
31- Handle ``__missing__()`` not storing cache items.
32
33- Clean up ``__missing__()`` example.
34
35
Thomas Kemmere6acc1e2020-12-10 21:25:58 +010036v4.2.0 (2020-12-10)
Thomas Kemmer6d2692f2020-12-09 22:32:23 +010037===================
38
39- Add FIFO cache implementation.
40
41- Add MRU cache implementation.
42
43- Improve behavior of decorators in case of race conditions.
44
45- Improve documentation regarding mutability of caches values and use
46 of key functions with decorators.
47
48- Officially support Python 3.9.
49
50
Thomas Kemmer31a78b52020-06-28 21:27:40 +020051v4.1.1 (2020-06-28)
Thomas Kemmer4c1907e2020-06-28 21:16:38 +020052===================
53
54- Improve ``popitem()`` exception context handling.
55
56- Replace ``float('inf')`` with ``math.inf``.
57
58- Improve "envkey" documentation example.
59
60
Thomas Kemmera6258fb2020-04-08 13:33:09 +020061v4.1.0 (2020-04-08)
Thomas Kemmerbb8df8f2020-04-08 13:23:29 +020062===================
63
64- Support ``user_function`` with ``cachetools.func`` decorators
65 (Python 3.8 compatibility).
66
67- Support ``cache_parameters()`` with ``cachetools.func`` decorators
68 (Python 3.9 compatibility).
69
70
Thomas Kemmerfa9d4762019-12-15 20:53:23 +010071v4.0.0 (2019-12-15)
Thomas Kemmeraa936f02019-12-15 20:46:13 +010072===================
73
74- Require Python 3.5 or later.
75
76
Thomas Kemmerc5309242019-05-23 21:49:13 +020077v3.1.1 (2019-05-23)
Thomas Kemmeraa936f02019-12-15 20:46:13 +010078===================
Thomas Kemmer695a47e2019-05-23 21:43:36 +020079
80- Document how to use shared caches with ``@cachedmethod``.
81
82- Fix pickling/unpickling of cache keys
83
84
Thomas Kemmer1b67cdd2019-01-29 21:33:49 +010085v3.1.0 (2019-01-29)
Thomas Kemmeraa936f02019-12-15 20:46:13 +010086===================
Thomas Kemmer664b45b2019-01-29 21:25:27 +010087
88- Fix Python 3.8 compatibility issue.
89
Thomas Kemmer1b67cdd2019-01-29 21:33:49 +010090- Use ``time.monotonic`` as default timer if available.
Thomas Kemmer664b45b2019-01-29 21:25:27 +010091
92- Improve documentation regarding thread safety.
93
94
Thomas Kemmer90d35072018-11-03 20:26:37 +010095v3.0.0 (2018-11-04)
Thomas Kemmeraa936f02019-12-15 20:46:13 +010096===================
Thomas Kemmer90d35072018-11-03 20:26:37 +010097
98- Officially support Python 3.7.
99
100- Drop Python 3.3 support (breaking change).
101
102- Remove ``missing`` cache constructor parameter (breaking change).
103
104- Remove ``self`` from ``@cachedmethod`` key arguments (breaking
105 change).
106
107- Add support for ``maxsize=None`` in ``cachetools.func`` decorators.
108
109
Thomas Kemmer36d864e2018-05-12 18:21:47 +0200110v2.1.0 (2018-05-12)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100111===================
Thomas Kemmer45d9b0d2018-05-12 14:41:46 +0200112
113- Deprecate ``missing`` cache constructor parameter.
114
115- Handle overridden ``getsizeof()`` method in subclasses.
116
117- Fix Python 2.7 ``RRCache`` pickling issues.
118
119- Various documentation improvements.
120
121
Thomas Kemmerfba5f8a2017-08-11 18:51:13 +0200122v2.0.1 (2017-08-11)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100123===================
Thomas Kemmerfba5f8a2017-08-11 18:51:13 +0200124
125- Officially support Python 3.6.
126
127- Move documentation to RTD.
128
129- Documentation: Update import paths for key functions (courtesy of
130 slavkoja).
131
132
Thomas Kemmere27332b2016-10-03 14:00:45 +0200133v2.0.0 (2016-10-03)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100134===================
Thomas Kemmere27332b2016-10-03 14:00:45 +0200135
136- Drop Python 3.2 support (breaking change).
137
138- Drop support for deprecated features (breaking change).
139
140- Move key functions to separate package (breaking change).
141
142- Accept non-integer ``maxsize`` in ``Cache.__repr__()``.
143
144
Thomas Kemmer8bb68a22016-04-01 11:56:54 +0200145v1.1.6 (2016-04-01)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100146===================
Thomas Kemmer8bb68a22016-04-01 11:56:54 +0200147
148- Reimplement ``LRUCache`` and ``TTLCache`` using
149 ``collections.OrderedDict``. Note that this will break pickle
150 compatibility with previous versions.
151
152- Fix ``TTLCache`` not calling ``__missing__()`` of derived classes.
153
154- Handle ``ValueError`` in ``Cache.__missing__()`` for consistency
155 with caching decorators.
156
157- Improve how ``TTLCache`` handles expired items.
158
159- Use ``Counter.most_common()`` for ``LFUCache.popitem()``.
160
161
Thomas Kemmer42853732015-10-25 14:58:38 +0100162v1.1.5 (2015-10-25)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100163===================
Thomas Kemmer42853732015-10-25 14:58:38 +0100164
165- Refactor ``Cache`` base class. Note that this will break pickle
166 compatibility with previous versions.
167
168- Clean up ``LRUCache`` and ``TTLCache`` implementations.
169
170
Thomas Kemmer41d521b2015-10-24 22:38:47 +0200171v1.1.4 (2015-10-24)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100172===================
Thomas Kemmer41d521b2015-10-24 22:38:47 +0200173
174- Refactor ``LRUCache`` and ``TTLCache`` implementations. Note that
175 this will break pickle compatibility with previous versions.
176
177- Document pending removal of deprecated features.
178
179- Minor documentation improvements.
180
181
Thomas Kemmer4f4b4522015-09-15 20:43:42 +0200182v1.1.3 (2015-09-15)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100183===================
Thomas Kemmer4f4b4522015-09-15 20:43:42 +0200184
185- Fix pickle tests.
186
187
Thomas Kemmerc8c8db12015-09-15 20:06:57 +0200188v1.1.2 (2015-09-15)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100189===================
Thomas Kemmerc8c8db12015-09-15 20:06:57 +0200190
191- Fix pickling of large ``LRUCache`` and ``TTLCache`` instances.
192
193
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200194v1.1.1 (2015-09-07)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100195===================
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200196
197- Improve key functions.
198
199- Improve documentation.
200
201- Improve unit test coverage.
202
203
204v1.1.0 (2015-08-28)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100205===================
Thomas Kemmer6a4c6f02015-08-28 20:31:47 +0200206
207- Add ``@cached`` function decorator.
208
209- Add ``hashkey`` and ``typedkey`` fuctions.
210
211- Add `key` and `lock` arguments to ``@cachedmethod``.
212
213- Set ``__wrapped__`` attributes for Python versions < 3.2.
214
215- Move ``functools`` compatible decorators to ``cachetools.func``.
216
217- Deprecate ``@cachedmethod`` `typed` argument.
218
219- Deprecate `cache` attribute for ``@cachedmethod`` wrappers.
220
221- Deprecate `getsizeof` and `lock` arguments for `cachetools.func`
222 decorator.
223
224
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200225v1.0.3 (2015-06-26)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100226===================
Thomas Kemmer37024a72015-06-26 08:06:17 +0200227
228- Clear cache statistics when calling ``clear_cache()``.
229
230
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200231v1.0.2 (2015-06-18)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100232===================
Thomas Kemmer0ca640f2015-06-18 19:24:52 +0200233
234- Allow simple cache instances to be pickled.
235
236- Refactor ``Cache.getsizeof`` and ``Cache.missing`` default
237 implementation.
238
239
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200240v1.0.1 (2015-06-06)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100241===================
Thomas Kemmerb26d1e52015-06-06 15:20:02 +0200242
243- Code cleanup for improved PEP 8 conformance.
244
245- Add documentation and unit tests for using ``@cachedmethod`` with
246 generic mutable mappings.
247
248- Improve documentation.
249
250
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200251v1.0.0 (2014-12-19)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100252===================
Thomas Kemmerf3437a12014-12-19 15:56:11 +0100253
Thomas Kemmer5c2a69b2014-12-19 15:59:10 +0100254- Provide ``RRCache.choice`` property.
255
Thomas Kemmerc6137f22014-12-19 16:22:07 +0100256- Improve documentation.
257
Thomas Kemmerf3437a12014-12-19 15:56:11 +0100258
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200259v0.8.2 (2014-12-15)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100260===================
Thomas Kemmerb624bf82014-12-10 06:50:01 +0100261
262- Use a ``NestedTimer`` for ``TTLCache``.
263
264
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200265v0.8.1 (2014-12-07)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100266===================
Thomas Kemmerd7cb9942014-12-07 17:53:43 +0100267
268- Deprecate ``Cache.getsize()``.
269
270
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200271v0.8.0 (2014-12-03)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100272===================
Thomas Kemmer08a83b32014-12-03 12:07:44 +0100273
Thomas Kemmerbf2de582014-12-03 18:37:35 +0100274- Ignore ``ValueError`` raised on cache insertion in decorators.
Thomas Kemmer08a83b32014-12-03 12:07:44 +0100275
Thomas Kemmer98e32c42014-12-03 12:14:36 +0100276- Add ``Cache.getsize()``.
277
Thomas Kemmerbf2de582014-12-03 18:37:35 +0100278- Add ``Cache.__missing__()``.
Thomas Kemmer5f805192014-12-03 13:07:43 +0100279
Thomas Kemmer35855b52014-12-03 18:54:11 +0100280- Feature freeze for `v1.0`.
281
Thomas Kemmer08a83b32014-12-03 12:07:44 +0100282
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200283v0.7.1 (2014-11-22)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100284===================
Thomas Kemmer827e2f52014-11-22 21:20:49 +0100285
286- Fix `MANIFEST.in`.
287
288
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200289v0.7.0 (2014-11-12)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100290===================
Thomas Kemmer101513c2014-11-05 19:56:17 +0100291
Thomas Kemmer8dd27642014-11-11 06:43:58 +0100292- Deprecate ``TTLCache.ExpiredError``.
Thomas Kemmera49f49f2014-11-10 16:47:47 +0100293
Thomas Kemmercef66532014-11-11 12:27:05 +0100294- Add `choice` argument to ``RRCache`` constructor.
Thomas Kemmer07646b72014-11-05 20:27:14 +0100295
Thomas Kemmercef66532014-11-11 12:27:05 +0100296- Refactor ``LFUCache``, ``LRUCache`` and ``TTLCache``.
297
Thomas Kemmer53854452014-11-12 07:58:59 +0100298- Use custom ``NullContext`` implementation for unsynchronized
Thomas Kemmercef66532014-11-11 12:27:05 +0100299 function decorators.
Thomas Kemmer101513c2014-11-05 19:56:17 +0100300
301
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200302v0.6.0 (2014-10-13)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100303===================
Thomas Kemmer101513c2014-11-05 19:56:17 +0100304
305- Raise ``TTLCache.ExpiredError`` for expired ``TTLCache`` items.
306
307- Support unsynchronized function decorators.
308
309- Allow ``@cachedmethod.cache()`` to return None
310
311
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200312v0.5.1 (2014-09-25)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100313===================
Thomas Kemmer101513c2014-11-05 19:56:17 +0100314
315- No formatting of ``KeyError`` arguments.
316
317- Update ``README.rst``.
318
319
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200320v0.5.0 (2014-09-23)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100321===================
Thomas Kemmer101513c2014-11-05 19:56:17 +0100322
323- Do not delete expired items in TTLCache.__getitem__().
324
325- Add ``@ttl_cache`` function decorator.
326
327- Fix public ``getsizeof()`` usage.
328
329
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200330v0.4.0 (2014-06-16)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100331===================
Thomas Kemmer101513c2014-11-05 19:56:17 +0100332
333- Add ``TTLCache``.
334
335- Add ``Cache`` base class.
336
337- Remove ``@cachedmethod`` `lock` parameter.
338
339
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200340v0.3.1 (2014-05-07)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100341===================
Thomas Kemmer101513c2014-11-05 19:56:17 +0100342
343- Add proper locking for ``cache_clear()`` and ``cache_info()``.
344
345- Report `size` in ``cache_info()``.
346
347
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200348v0.3.0 (2014-05-06)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100349===================
Thomas Kemmer101513c2014-11-05 19:56:17 +0100350
351- Remove ``@cache`` decorator.
352
353- Add ``size``, ``getsizeof`` members.
354
355- Add ``@cachedmethod`` decorator.
356
357
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200358v0.2.0 (2014-04-02)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100359===================
Thomas Kemmer101513c2014-11-05 19:56:17 +0100360
361- Add ``@cache`` decorator.
362
363- Update documentation.
364
365
Thomas Kemmer5cdedd52015-09-07 20:53:37 +0200366v0.1.0 (2014-03-27)
Thomas Kemmeraa936f02019-12-15 20:46:13 +0100367===================
Thomas Kemmer101513c2014-11-05 19:56:17 +0100368
369- Initial release.