Дилян Палаузов
d7b2aa24f7
Fixed #28982 -- Simplified code with and/or.
2018-01-03 20:12:23 -05:00
Nick Pope
d13a9e44de
Fixed #28909 -- Simplified code using tuple/list/set/dict unpacking.
2017-12-11 07:08:45 -05:00
Nick Pope
c68f66e014
Refs #23919 -- Replaced super() calls for old-style classes.
2017-12-07 09:10:32 -05:00
Adam Johnson
acc989f037
Fixed #28760 -- Removed DummyCache's unnecessary get/set/delete_many().
2017-10-31 12:16:09 -04:00
Adam Johnson
abacd09f07
Refs #27318 -- Made DummyCache.set_many() return a list for consistency with other backends.
2017-10-30 12:13:17 -04:00
Daniel Tao
4d60261b2a
Fixed #28601 -- Prevented cache.get_or_set() from caching None if default is a callable that returns None.
2017-10-10 09:20:34 -04:00
Tim Graham
e47b56d791
Refs #20892 -- Removed support for passing pylibmc behavior settings as top-level attributes of CACHES['OPTIONS'].
...
Per deprecation timeline.
2017-09-22 12:51:17 -04:00
Tim Graham
6e4c6281db
Reverted "Fixed #27818 -- Replaced try/except/pass with contextlib.suppress()."
...
This reverts commit 550cb3a365
because try/except performs better.
2017-09-07 08:16:21 -04:00
Olivier Tabone
a027447f56
Fixed #27318 -- Made cache.set_many() return the list of failed keys.
2017-09-06 14:38:44 -04:00
Sergey Fedoseev
3633c2a045
Used dict comprehensions in BaseMemcachedCache.get_many() and set_many() for better readability.
2017-09-05 09:14:41 -04:00
caleb logan
68f0e8d8b1
Fixed #28500 -- Fixed crash in FileBasedCache._is_expired() if the cache file is empty.
2017-09-03 20:11:49 -04:00
Tim Graham
487362fa8f
Fixed #28370 -- Deprecated the context arg of Field.from_db_value() and Expression.convert_value().
...
Unused since a0d166306f
.
2017-07-20 16:30:08 -04:00
Tim Graham
2e9ada1551
Fixed #28397 -- Removed django.core.exceptions.DjangoRuntimeWarning.
2017-07-14 12:06:06 -04:00
Mads Jensen
550cb3a365
Fixed #27818 -- Replaced try/except/pass with contextlib.suppress().
2017-06-28 14:07:55 -04:00
Jon Dufresne
2c69824e5a
Refs #23968 -- Removed unnecessary lists, generators, and tuple calls.
2017-06-01 19:08:59 -04:00
Anton Samarchyan
5a6f70b428
Refs #27656 -- Updated django.core docstring verbs according to PEP 257.
2017-02-21 11:58:42 -05:00
Tim Graham
29f607927f
Fixed spelling of "nonexistent".
2017-02-03 08:01:45 -05:00
Claude Paroz
fee42fd99e
Refs #23919 -- Replaced usage of django.utils.http utilities with Python equivalents
...
Thanks Tim Graham for the review.
2017-01-26 19:49:03 +01:00
chillaranand
d6eaf7c018
Refs #23919 -- Replaced super(ClassName, self) with super().
2017-01-25 12:23:46 -05:00
Tim Graham
632c4ffd9c
Refs #23919 -- Replaced errno checking with PEP 3151 exceptions.
2017-01-25 10:13:08 -05:00
Claude Paroz
dc8834cad4
Refs #23919 -- Removed unneeded force_str calls
2017-01-20 08:44:31 +01:00
Simon Charette
cecc079168
Refs #23919 -- Stopped inheriting from object to define new style classes.
2017-01-19 08:39:46 +01:00
Aymeric Augustin
a556396339
Refs #23919 -- Replaced io.open() with open().
...
io.open() is an alias for open() on Python 3.
2017-01-18 21:45:12 -05:00
Aymeric Augustin
eb422e476f
Refs #23919 -- Removed obsolete __ne__() methods.
...
__ne__() defaults to the opposite of __eq__() on Python 3
when it doesn't return NotImplemented.
2017-01-18 21:44:00 -05:00
Claude Paroz
2b281cc35e
Refs #23919 -- Removed most of remaining six usage
...
Thanks Tim Graham for the review.
2017-01-18 21:33:28 +01:00
Claude Paroz
7b2f2e74ad
Refs #23919 -- Removed six.<various>_types usage
...
Thanks Tim Graham and Simon Charette for the reviews.
2017-01-18 20:18:46 +01:00
Claude Paroz
c716fe8782
Refs #23919 -- Removed six.PY2/PY3 usage
...
Thanks Tim Graham for the review.
2017-01-18 16:21:28 +01:00
Claude Paroz
d7b9aaa366
Refs #23919 -- Removed encoding preambles and future imports
2017-01-18 09:55:19 +01:00
Ramin Farajpour Cami
967be82443
Fixed E305 flake8 warnings.
2016-11-14 12:30:46 -05:00
Ed Morley
f02dbbe1ae
Fixed #11331 -- Stopped closing pylibmc connections after each request.
...
libmemcached manages its own connections, so isn't affected by refs #5133 .
2016-09-02 14:44:27 -04:00
Ed Morley
d8ef5b0e65
Fixed #27152 -- Supported comma delimiter in memcached LOCATION string.
2016-08-31 17:23:41 -04:00
Ed Morley
65ec8fa8ca
Fixed #20892 -- Allowed configuring memcached client using OPTIONS.
...
Previously, the MemcachedCache backend ignored `OPTIONS` and
PyLibMCCache used them to set pylibmc behaviors. Both backends now
pass `OPTIONS` as keyword arguments to the client constructors.
2016-08-31 12:50:14 -04:00
Dmitry S..ky / skype: dvska-at-skype
82be474efa
Fixed #26792 -- Allowed None for the value of cache.get_or_set().
2016-07-11 20:49:27 -04:00
Ville Skyttä
96f97691ad
Fixed broken links in docs and comments.
2016-06-15 21:20:23 -04:00
Jon Dufresne
779829662d
Fixed #26694 -- Made FileBasedCache.get() reraise non-ENOENT IOErrors.
2016-06-01 15:29:24 -04:00
Jon Dufresne
359be1c870
Fixed #26691 -- Removed checking for a file's existence before deleting.
...
File operations always raise a ENOENT error when a file doesn't exist.
Checking the file exists before the operation adds a race condition
condition where the file could be removed between operations. As the
operation already raises an error on a missing file, avoid this race and
avoid checking the file exists twice. Instead only check a file exists
by catching the ENOENT error.
2016-05-31 12:03:27 -04:00
Tim Graham
df8d8d4292
Fixed E128 flake8 warnings in django/.
2016-04-08 09:51:06 -04:00
Przemysław Suliga
90ce5d46bf
Fixed #26462 -- Fixed Python 2 UnicodeEncodeError when warning about long cache keys.
2016-04-05 11:16:04 -04:00
Przemysław Suliga
d356bb653f
Fixed #26460 -- Issued a single warning for invalid cache key
2016-04-04 15:20:55 -04:00
Przemysław Suliga
96ec67a7cf
Fixed #26332 -- Fixed a race condition in BaseCache.get_or_set().
2016-03-08 11:44:37 -05:00
userimack
60586dd737
Fixed #26125 -- Fixed E731 flake warnings.
2016-01-25 14:23:43 -05:00
Matthew Madurski
7df9aa3a33
Fixed typo in BaseCache.delete_many() docstring.
2015-12-29 20:50:04 -05:00
Emre Yilmaz
8e838d9c86
Fixed #25840 -- Fixed BaseCache.get_or_set() on the DummyCache backend.
...
This also fixes a possible data eviction race condition between
setting and getting a key. Another thread could remove the key
before get_and_set() accesses it again. In this case, now the
default value will be returned instead of None.
2015-12-04 12:22:17 -05:00
Jaap Roes
1aba0e4c68
Refs #25501 -- Fixed a typo in django/core/cache/backends/filebased.py
...
The original intent in refs #20536 was to use the highest protocol.
Calling zlib.compress() with a compression level of -1 seems to
fall back to the default level of 6.
2015-11-14 15:10:14 -05:00
Ville Skyttä
3ee18400ae
Fixed #25668 -- Misc spelling errors
2015-11-03 11:58:13 +02:00
Andrew Artajos
48888a1a67
Fixed #25501 -- Made the file-based cache backend use the highest pickling protocol.
2015-10-20 13:05:33 -04:00
Tom Christie
b02f08e02c
Fixed #25034 -- Converted caches ImproperlyConfigured error to a system check.
2015-09-18 07:44:39 -04:00
Matthew Crowson
8615e41586
Fixed typo in django/core/cache/backends/base.py docstring.
2015-09-16 09:29:56 -04:00
Maxime Lorant
5153a3bfdc
Fixed #25331 -- Removed trailing blank lines in docstrings.
2015-08-31 17:37:21 -04:00
Karol Duleba
b74b94445d
Updated Memcached get_backend_timeout() comment.
2015-07-06 10:13:20 -04:00