-
Notifications
You must be signed in to change notification settings - Fork 201
/
ChangeLog
595 lines (383 loc) · 21.8 KB
/
ChangeLog
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
Sun, 14 Jan 2024 08:49:00 -0700 Sean Reifschneider <[email protected]>
* Fix some docstring typos (Christian Clauss PR #192)
* delete() return value now is 1 for "DELETED" and 0 for "NOT_FOUND" or server error.
(Nick Pope PR #190)
* Removed obsolete configuration for Travis CI. (Nick Pope PR #189)
Thu, 28 Dec 2023 19:24:00 -0700 Sean Reifschneider <[email protected]>
* 1.61 release.
* Fixing the ChangeLog entry which had a bad date.
Sun, 24 Dec 2023 22:33:47 -0700 Sean Reifschneider <[email protected]>
* 1.60 release.
* Allow to use a datetime.timedelta parameter for Client.set
(PR from Theo Massard)
* Fix cmemcahe_hash 0 values being translated to 1 (PR from Chow Loong Jin)
* Fix tuple key support in multi methods (PR from Sergii Mikhtoniuk) #154
* Add support for default value in get (PR from Jakub Szafrański)
* test_memcache.py: try import unittest.mock (PR from Tim Orling)
* Use == as suggested by Python 3.8 (PR from @za)
* Decoding in slab funcs, replacing "1" with "True" in while. #175
* Tell PyPI to parse README as markdown (PR from @MartinThoma) #168
* test_memcache.py: try import unittest.mock (PR from @moto-timo) #172
* Removed Python 2.7 from setup.cfg, adding 3.8-3.12
* Add support for default value in get() (PR from @samupl) #158
* Fix tuple key support in multi methods (regression in 1.55).
(PR from @sergiimk) #155
* Fix cmemcahe_hash 0 values being translated to 1. For example "ob"
would hash to 0 and then get converted to 1. Looks like this dated
back to 2009, the original code we imported for that hash function.
(PR from @hyperair) #152
* Removing six.PY2/3 conditionals
* Removing "time" from delete and making expiry mandatory in touch.
(port of @erankor's PR in #30 )
* Added quit() method. This method sends the 'quit' command to the
servers and then closes the connections, reducing the number of
TIME_WAIT sockets hanging around the OS. (PR from @userrl) #15
* Allow to use a datetime.timedelta parameter for Client.set (PR from @tbobm) #146
* Allow keys to be encoded before use. (Port of PR in #52 from @harlowja)
* Removing historic python 2to3 code and deprecated socket.error (for
OSError). (PR from @pgajdos) #186
* Updating to the latest PSF license
Fri, 15 Dec 2018 09:02:05 -0700 Sean Reifschneider <[email protected]>
* 1.59 release.
* Added testing for Python 3.5 and 3.6 (PR from Tim Graham) #110, #131
* Fixed typos in docstrings (PR from Romuald Brunet, reviewed by Tim
Graham) #105
* Removing Python 2.6, 3.2, and 3.3 testing (PR from Tim Graham) #115, #116
* Removing unnecessary parens in return statements (PR from Tim Graham)
#113
* Remove unused _has_unicode/_str_cls vars (PR from Tim Graham) #111
* Add flake8 testing and cleanups (PR from Tim Graham, cleanups from Sean
Reifschneider) #112
* Fixed storing non-ASCII values on Python 2 and binary values on Python 3
(PR from Nicolas Noé) #135
* Fixed touch(..., time=0) command (PR from Nicolas Noé) #137
Fri, 27 May 2016 13:44:55 -0600 Sean Reifschneider <[email protected]>
* 1.58 release.
* Fixing a performance regression in v1.54 in Python 2, using cPickle again.
Patch by edmorley #86
* Support for "stats slabs".
Patch by grg350 #93
* get_stats encoding fix.
Patch by bartTC #91
* Pin Six version to >= 1.4
Patch by pipermirriam #81
* setup.py build process pulls version from memcached.py
Patch by dieselmachine #72
* delete() and delete_multi() now default the "time" argument to None,
since the protocol doesn't allow a time in some implementations.
Patch by oremj #27
Fri, 31 Jul 2015 11:38:25 -0600 Sean Reifschneider <[email protected]>
* 1.57 release.
* Fix for #75 and #76, mc.set(key, False) results in "ValueError:
invalid literal for int()". Reported by Carlos Sanchez on github.
Sun, 26 Jul 2015 14:44:20 -0600 Sean Reifschneider <[email protected]>
* 1.56 release.
* More patches for python3 from Victor Stinner #67. Thanks!
* Tests moved out into their own unittest testcases.
Patch by Jeremy Thurgood.
* Adding support for pluggable compressors. Patch by cactus on github.
* Adding support for "noreply". Patch by cactus on github.
* Allowing empty key in _multi() calls. Suggested by sergio97 on github.
Sun, 21 Sep 2014 13:41:30 -0600 Sean Reifschneider <[email protected]>
* 1.54 release.
* Numerous patches to attempt to get Python 3 working, but
tests are still failing under Python 3, so this code is not ready
yet.
* MemcachedKeyCharacterError better describes key problem.
Suggested by Roy Smith
* Added touch(), patch by erankor on github.
* Allow empty server list, patch by zewt on github.
* If unknown flags in get request, raises a value error rather than the
code bombing out.
* Setting the SERVER_MAX_* values after import did not work, despite
being documented to. Reported by alexf101 on github.
Sun, 07 Jun 2013 11:12:18 -0600 Sean Reifschneider <[email protected]>
* 1.53 release.
* Fixing set_multi() so that if the server closes the connection
it will no longer raise AttributeError. Issue found and resolution
reviewed by Ben Hoyt.
* readline() now will mark the connection dead if the read fails.
It was just closing it before. This is related to the set_multi()
change but worth noting separately. Thanks to Ben Hoyt.
* Discussion of the above:
https://github.com/linsomniac/python-memcached/commit/b7054a964aed0e6d86e853e60aab09cd0183b9f6#commitcomment-3337557
Sun, 02 Jun 2013 01:08:26 -0600 Sean Reifschneider <[email protected]>
* 1.52 release.
* Changing check_keys to use re.match() instead of str.translate(),
because re.match() works with Python < 2.6.
Found by Giovanni Di Milia.
Mon, 06 May 2013 15:29:07 -0600 Sean Reifschneider <[email protected]>
* 1.51 release.
* Add a MANIFEST.in file, patch by Daniel Widerin.
Mon, 06 May 2013 07:20:21 -0600 Sean Reifschneider <[email protected]>
* 1.50 release.
* Client() now takes a "check_keys" option, which defaults to True.
If False, it disables the checking of keys to ensure they have
acceptable size and are composed of non-control characters.
Suggested by Ben Hoyt.
* Converting control character checking of keys based on performance
testing of alternatives by Ben Hoyt.
* Converted unicode tests from using u'', patch from Eren Güve.
* Included license file (pull request by "Philippe" pombredanne).
* Doing a "set" after server goes away, raised AttributeError:
'NoneType' object has no attribute 'sendall'. Patch by Ken Lalonde
* incr/decr return None instead of 0 on server connection failure.
Suggested by Ivan Virabyan
* Supports IPv6 connections using: "inet6:[fd00::32:19f7]:11000".
Patch by Romain Courteaud
* Switching over to github for this project:
https://github.com/linsomniac
* Bug #974632: _ConnectionDeadError sometimes was escaping the get/set
code. This should return to readline() not raising an exception, except
in the case that it's called from the get/set(). Report from Gary
Poster, proposed patch by Brad Crittenden.
Misc fixes by Brad Crittenden: fixing a docstring, if "port" is set to
any false-like value it will default to 11211.
Mon, 29 Nov 2011 12:37:32 -0700 Sean Reifschneider <[email protected]>
* Bug #887765: Interrupted connection to memcache server can cause
inconsistencies.
Added "flush_on_reconnect" (defaults to off) to Client() which will
cause a client that has lost connection to a server and then reconnects
to flush the cache on the reconnect so that it doesn't get old values
from that server. Patch by Daniel Benamy.
Sun, 27 Nov 2011 18:15:32 -0700 Sean Reifschneider <[email protected]>
* Bug #745633: Values of maximum size are not stored
API inconsistency, max value length was tested for <= while max KEY
length was <. So I picked that keys and values *LONGER* than the
specified max value are what is used, and added documentation and tests
to that effect. The test for max value tested that length plus 4, so
I've changed that to be that value plus 1. Issue found by matt-quru.
* Bug #713488: Issues Invalid "delete" command.
Protocol has changed so that the "delete" operation no longer takes a
"time" argument. It seems that some servers will refuse a "delete key
0" while others will accept it, but the official server will NOT accept
"delete key 1". So I've changed it so that if no "time" argument is
specified, no time argument is sent to the server.
* Bug #713451: server.expect("END") needs to be in a finally block
Expect an "END" when the _recv_value() raises an exception.
Patch by Jay Farrimond.
* Bug: #741090: cas cache can grow unbounded. Default now is that the
cache is not used, unless the "Client()" object is created with
"cache_cas=True". In that case, you need to have your own cas clearing
code, a simple one would be to use Client().reset_cas() to completely
clear the cas_ids cache. Problem pointed out by Shaun Cutts.
* Bug #728359: Make python-memcache work on memcache restarts.
Patch by Tarek Ziade', reviewed and further patches submitted by Hugo
Beauze'e-Luysse and Neganov Alexandr.
* Bug #798342: If memcached server sends unknown flag in response for
"get", results in:
"UnboundLocalError: local variable 'val' referenced before assignment"
Now returns "None" instead. Patch by Sharoon Thomas
Mon, 20 Dec 2010 19:14:17 -0700 Sean Reifschneider <[email protected]>
* Bug #680359: useOldServerHashFunction() is broken. It now correctly
switches back to the old memcache hash function.
Thu, 16 Dec 2010 02:07:40 -0700 Sean Reifschneider <[email protected]>
* Bug #471727: Changed the delete() code to explicitly check for both
NOT_FOUND and DELETED as the responses and return successful for both.
It also logs an error if one of these two responses is not found.
Also added a test to ensure that delete() works.
* When using set_multi and one value is too big, traceback
TypeError: 'int' object is unsubscriptable
Patch by Orjan Persson
* Fixing Bug #529855: Server host can now be bare host without ":<port>".
Fix proposed by Roger Binns.
* Fixing Bug #491164: Typo fix, "compession" -> "compRession".
* Fixing Bug #509712: "TypeError: 'NoneType' object is unsubscriptable"
Also fixed some other similar code to not have issues with that.
* Also related to 509712 and 628339: readline() now returns '' instead
of None when a server dies. This should be safer. Patch suggested by
Denis Otkidach.
* Fixing Bug #628339: Read from server sometimes fails. Patch by Jeremy
Cowles.
* Fixing Bug #633553: Add stat arguments support to get_stats(). Patch
by Ryan Lane.
* Changing the license to the PSF License.
* Removing Evan's e-mail address at his request, changing authorship to
Sean.
Sat, 28 Nov 2009 01:07:42 -0700 Sean Reifschneider <[email protected]>
* Version 1.45
* Per-connection max server key length. Patch by Nicolas Delaby
* Patches to make memcached more garbage-collectable. Removes
"debugfunc" argument from _Host objects and changed to "debug"
boolean. Patches by John McFarlane and Aryeh Katz.
* Switching to a cmemcache compatible hash function. Implemented by
André Cru and Ludvig Ericson. To switch back to the old style, use:
memcached.useOldServerHashFunction()
* Rejecting keys that have spaces in them. Patch by Etienne Posthumus.
* Fixing exception raising syntax. Patch by Samuel Stauffer.
* Optimizations in read code. Patch by Samuel Stauffer.
* Changing classes to be newstyle. Patch by Samuel Stauffer.
* Changed "has_key" to "in". Patch by Samuel Stauffer.
* incr/decr were raising ValueError if the key did not exist, the
docstring said it returned none. Patch by Chihiro Sakatoku.
* Adding cas method, submitted by Ben Gutierrez.
* Fix in the docstring for how to use the "set" method. Found and fixed
by William McVey
Thu, 02 Apr 2009 13:37:49 -0600 Sean Reifschneider <[email protected]>
* Version 1.44
* Allowing spaces in the key. (Patch provided by xmm on Launchpad)
* Detecting when the pickler needs a positional argument. (Patch
provided by Brad Clements on Launchpad)
* Moving length check after the compression. (Patch provided by user
Tom on Launchpad)
* Fixing arguments passed to the _Error if invalid read length.
* Fixing the representation of domain sockets. (Patch provided by user
MTB on Launchpad)
* Changing a typo of dead_until. (Patch provided by Shane R. Spencer)
* Providing better error messages (patch provided by Johan Euphrosine).
* Adding get_slabs() function to get stats. (Patch provided
by Nick Verbeck)
Sun, 01 Jun 2008 15:05:11 -0600 Sean Reifschneider <[email protected]>
* Version 1.43
* eliott reported a bug in the 1.42 related to the socket timeout code
causing a traceback due to the timeout value not being set.
Sat, 31 May 2008 02:09:17 -0600 Sean Reifschneider <[email protected]>
* Version 1.42
* Paul Hummer set up a Launchpad project which I'm going to start using
to track patches and allow users to set up their own bzr branches and
manage merging in the upstream patches with their own.
https://launchpad.net/python-memcached
* Patch from Jehiah Czebotar which does: Changing the calls to
mark_dead() to make them dereference tuples, reducing timeout on
sockets to 3 seconds, settable via setting Host._SOCKET_TIMEOUT.
* Patches from Steve Schwarz for set_multi() to return the full set of
keys if all servers are down. Previously would not report any keys.
* Fix from Steve Schwarz delete_multi() argument "seconds" not being
correctly handled. Changed it to "time" to match all other calls.
* Patch from Peter Wilkinson to support using unix domain sockets.
He reports that tests succeed with with memcached daemons running,
the normal and a domain socket started via
"memcached -s memcached.socket". I massaged it quite a bit.
To use domain sockets, use a connect string of "unix:/path/to/socket"
Note however that if you are using a host name of "unix", it will now
detect "unix:11211" as being a domain socket with the name "11211".
In this case, please use "inet:unix:11211".
Because of this, it is now preferred to use a connect string prefix
of "inet:" or "unix:".
Tue, 29 Apr 2008 21:03:53 -0600 Sean Reifschneider <[email protected]>
* Version 1.41
* Patch from Jehiah Czebotar to catch an additional server disconnect
situation.
* Patch from Andrey Petrov to add the "append" and "replace" commands.
Tue, 18 Sep 2007 20:52:09 -0600 Sean Reifschneider <[email protected]>
* Version 1.40
* Updated setup.py file that uses distutils provided by Kai Lautaportti.
* Prevent keys from containing ASCII character 127 as well, patch provided
by Philip Neustrom.
* Added ability to overload the persistent_load/id, patch provided by
Steve Schwarz.
* Fixed ability to pass (server_hash,key) in place of key in Client.set()
Reported by Alexander Klyuev.
Tue, 14 Aug 2007 14:43:27 -0600 Sean Reifschneider <[email protected]>
* Version 1.39
* Michael Krause reports the previous version doesn't work for
_val_to_store_info() calls because it's defined as a staticmethod.
Removing staticmethod decorator. Also confirmed by Kai Lautaportti,
with suggested fix of removing staticmethod.
Fri, 10 Aug 2007 17:50:13 -0600 Sean Reifschneider <[email protected]>
* Version 1.38
* Matt McClanahan submitted a patch that allow add() to have a
min_compress_len argument.
* Steve Schwarz submitted a patch allowing user-defined picklers.
* Michael Krause suggested checking the return value to prevent an
exception from being raised in _set() when a value is too large to be
stored.
Fri, 27 Jul 2007 01:55:48 -0600 Sean Reifschneider <[email protected]>
* Version 1.37
* Fixing call from add() to _set() with parameter for min_compress_len.
Reported by Jeff Fisher.
Thu, 07 Jun 2007 04:10:31 -0600 Sean Reifschneider <[email protected]>
* Version 1.36
* Patch by Dave St.Germain to make the Client() class sub-class
threadlocal to help with multi-threading issues. Only available in
Python 2.4 and above.
* Patch by James Robinson with:
1) new set_multi method.
2) factored out determining the flags, length, and value to store
from set() into method _val_to_store_info() for use by both set()
and set_multi().
3) send_cmds() method on host which doesn't apply the trailing '\r\n'
for use by set_multi.
4) check_key() extended a bit to allow for testing the prefix passed
to set_multi just once, not once per each key.
5) Patch also enables support for auto compression in set, set_multi,
and replace.
* Suggestion by Helge Tesdal, fixes in check_key for non-string keys.
* NOTE: On a farm of clients with multiple servers, all clients will
need to be upgraded to this version. The next patch changes the
server hash.
* Philip Neustrom supplied a patch to change the server hash function to
binascii.crc32. The original "hash()" call is not cross-platform, so
big and little endian systems accessing the same memcache may end up
hitting different servers. Restore the old functionality by calling:
"memcached.serverHashFunction = hash" after importing memcache.
* Philip Neustrom points out that passing Unicode keys or values causes
problems because len(key) or len(value) is not equal to the number of
bytes that are required to store the key/value. Philip provides a
patch which raises an exception in this case. Raises
memcache.Client.MemcachedStringEncodingError exception in this case.
* NOTE: If you recompiled memcached to increase the default 1MB max
value size, you will need to call "memcached.MAX_SERVER_VALUE_LENGTH = N"
or memcached will not store values larger than the default 1MB.
* Philip Neustrom includes another patch which checks that the key
doesn't exceed the memcache server's max size. If it does, the item
is silently not stored.
* Philip Neustrom added a bunch of sanity checks.
* Jehiah Czebotar provided a patch to make the add() and replace()
functions return 0 when the add or replace fails, similar to how set()
works.
Sat, 16 Sep 2006 18:31:46 -0600 Sean Reifschneider <[email protected]>
* Version 1.34
* In get_multi, if the recv loop reads 0 bytes, raising an EOFError.
Identified by Jim Baker.
Tue, 05 Sep 2006 14:06:50 -0600 Sean Reifschneider <[email protected]>
* Version 1.33
* Including patch from Yoshinori K. Okuji to read in larger chunks for
readline() calls. This should dramatically improve performance under
some circumstances.
Sun, 03 Sep 2006 14:02:03 -0600 Sean Reifschneider <[email protected]>
* Version 1.32
* Including patch from Philip Neustrom which checks keys sent to the
server for length and bad characters.
Sat, 20 May 2006 14:51:28 -0600 Sean Reifschneider <[email protected]>
* Version 1.31
* Rolled version 1.30 since the Danga folks are now listing this
version as the official version. Removing the "tummy" from the version
number, and incrementing so that it's clear it's more recent than "1.2".
* Patch applied from Simon Forman for handling of weighted hosts.
* Added a little more meat to the README.
Sat, 28 Jan 2006 15:59:50 -0700 Sean Reifschneider <[email protected]>
* cludwin at socallocal suggested that the write-combining with
sendall() may not be beneficial. After testing on both SMP and non-SMP
machines, I can't see a significant benefit to not doing the
write-combining, even on large strings. The benefits of write-combining
on smaller strings seems to be significant on UP machines in tight loops.
Even on strings that are larger than 2MB, there seems to be no benefit to
splitting out the writes.
Sun, 18 Sep 2005 18:56:31 -0600 Sean Reifschneider <[email protected]>
* Changing a printf to debuglog and catching a pickle exception, patch
submitted by Justin Azoff.
Thu, 14 Jul 2005 11:17:30 -0700 Sean Reifschneider <[email protected]>
* Alex Stapleton found that the sendall call was slow for writing data
larger than several kilobytes. I had him test a change to his patch,
which worked as well, but was simpler. The code now does two sendall
calls, one for the data and one for the line termination, if the data is
larger than 100 bytes.
Thu, 7 Apr 2005 14:45:44 -0700 Sean Reifschneider <[email protected]>
* Incorporating some fixes to get_multi() from Bo Yang
Mon, 13 Dec 2004 02:35:17 -0700 Sean Reifschneider <[email protected]>
* Simplifying the readline() function and speeding it up ~25%.
* Fixing a bug in readline() if the server drops, mark_dead() was not
being properly called.
Sun, 12 Dec 2004 18:56:33 -0700 Sean Reifschneider <[email protected]>
* Adding "stats()" and "flush_all()" methods.
Thu, 10 Aug 2003 12:17:50 -0700 Evan Martin <[email protected]>
* Slightly more verbose self-test output.
* Fix mark_dead() to use proper classname.
* Make pooltest.py run from the test directory.
Thu, 07 Aug 2003 16:32:32 -0700 Evan Martin <[email protected]>
* Add incr, decr, and delete.
* Better Python (based on comments from Uriah Welcome).
* Docs, using epydoc.
Thu, 07 Aug 2003 14:20:27 -0700 Evan Martin <[email protected]>
* Initial prerelease.