| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
| |
Also, streamline the use of 0 and None between cache backends.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Thanks Anssi for haggling until I implemented this.
This change alleviates the need for atomic_if_autocommit. When
autocommit is disabled for a database, atomic will simply create and
release savepoints, and not commit anything. This honors the contract of
not doing any transaction management.
This change also makes the hack to allow using atomic within the legacy
transaction management redundant.
None of the above will work with SQLite, because of a flaw in the design
of the sqlite3 library. This is a known limitation that cannot be lifted
without unacceptable side effects eg. triggering arbitrary commits.
|
|
|
|
|
|
|
|
| |
atomic block.
The atomic block provides a clean rollback to a savepoint on failed writes.
The ticket reported a race condition which I don't know how to test.
|
|
|
|
|
|
|
|
| |
Since "unless managed" now means "if database-level autocommit",
committing or rolling back doesn't have any effect.
Restored transactional integrity in a few places that relied on
automatically-started transactions with a transitory API.
|
|
|
|
|
|
| |
Introduced a public function
django.core.cache.utils.make_template_fragment_key
Thanks @chrismedrela for fruitful cooperation.
|
|
|
|
| |
pickle.HIGHEST_PROTOCOL
|
|
|
|
| |
database.
|
|
|
|
| |
`model_name`.
|
|
|
|
|
|
| |
dotted path
Thanks Carl Meyer for the report.
|
| |
|
|
|
|
| |
This is a provisional change. See #19221 for details.
|
|\
| |
| | |
Fixed #18582 -- Added a no-op close to BaseCache
|
| |
| |
| |
| |
| |
| | |
Also removed the hasattr check when firing request_finished signal for
caches with a 'close' method. Should be safe to call `cache.close`
everywhere now
|
| |
| |
| |
| |
| |
| |
| | |
There was a problem caused by Postgres 9.0+ having bytea_output default
value of 'hex' and cache backend inserting the content as 'bytes' into
a column of type TEXT. Fixed by converting the bytes value to a string
before insert.
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
incr/decr values
Thanks Michael Manfre for the report and initial patch and
Tobias McNulty for the review.
|
| |
| |
| |
| | |
going to a) silence real issues, or b) were impossible to hit.
|
| |
| |
| |
| |
| | |
smart_str/smart_text should only be used when a potential lazy
string should be preserved in the result of the function call.
|
| |
| |
| |
| |
| |
| | |
In all those occurrences, we didn't care about preserving the
lazy status of the strings, but we really wanted to obtain a
real bytestring.
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| | |
strings as keys
Thanks thecore for the report.
|
| |
| |
| |
| | |
This fixes a deprecation warning under Python 3.
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* Renamed smart_unicode to smart_text (but kept the old name under
Python 2 for backwards compatibility).
* Renamed smart_str to smart_bytes.
* Re-introduced smart_str as an alias for smart_text under Python 3
and smart_bytes under Python 2 (which is backwards compatible).
Thus smart_str always returns a str objects.
* Used the new smart_str in a few places where both Python 2 and 3
want a str.
|
| |
| |
| |
| |
| | |
xrange/range will be dealt with in a separate commit due to the huge
number of changes.
|
| |
| |
| |
| |
| | |
Lots of functions were moved. Use explicit imports in all cases
to keey it easy to identify where the functions come from.
|
|/ |
|
|
|
|
|
|
| |
friendly
This is Ian Kelly's patch from #15580 with minor modifications.
|
| |
|
|
|
|
| |
Thanks Ramiro for the patch.
|
|
|
|
|
| |
Thanks Clueless for the initial patch.
Note that unittest has been purposely left out (external package only used by Python 2.6).
|
|
|
|
|
|
| |
per official deprecation timeline.
Thanks Ramiro Morales for the review.
|
|
|
|
|
|
| |
process. Thanks Aymeric Augustin for the review.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17835 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
2.5. Thanks jonash for the initial patch and Aymeric Augustin for the review.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17834 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
2.6. Refs #17965. Thanks jonash for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17828 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
to connect to the signal handler that closes the cache connection when the request has been processed. Thanks, gnosek.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17479 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
using context managers. Puch prettier.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17152 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
changing key expiry time. Thanks Ivan Virabyan for report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17151 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
for better compatibility with other hash backends. Thanks aaugustin for the initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17136 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
compatible with time zone support.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17119 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
`DummyCache.set_many`, for compatiblity with other caches. Thanks to aaugustin for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16778 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
that we are on Python 2.5 to ease the Python 3 port. Thanks, Martin von Löwis.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16731 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
immplementation of the database-based cache backend so it works with Oracle. Thanks Aymeric Augustin for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16635 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
raising an exception if the timeout value isn't an integer. Thanks, Jeff Balogh.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16556 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
Aymeric Augustin for the work on the patch and Alex for reviewing.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16539 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
when given a string that can't be split. Thanks, jedie.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16511 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
|
|
| |
constructs from code and mentions from docs. Thanks Aymeric Augustin for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16349 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|
|
|
|
| |
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16001 bcc190cf-cafb-0310-a4f2-bffc1f526a37
|