Claude Paroz
208eead787
[1.10.x] Refs #26897 -- Missing directory containment in i18n test
2016-07-14 21:44:47 +02:00
Marten Kenbeek
06323dafc7
[1.10.x] Fixed #26888 -- Fixed concurrency issue in URL resolver.
...
Fixed a regression in 625b8e9295d79650208bfb3fca8bf9e6aaf578e4:
improper short-circuiting could lead to a KeyError when threads
concurrently call RegexURLResolver._populate().
Backport of 389a5318a0
from master
2016-07-14 14:42:23 -04:00
Claude Paroz
96a37a0266
[1.10.x] Fixed #26897 -- Fixed makemessages crash on Python 2 with non-ASCII file names
...
Thanks Tim Graham for the review.
Backport of 3e71f6544f
from master.
2016-07-14 20:39:00 +02:00
Jon Dufresne
acb804e552
[1.10.x] Fixed #26890 -- Fixed IntegerField crash on Unicode numbers.
...
Backport of 76e19da5b0
from master
2016-07-14 09:39:18 -04:00
Tim Graham
5c56ce7a3f
[1.10.x] Reverted "Fixed #25388 -- Added an option to allow disabling of migrations during test database creation"
...
This reverts commit 157d7f1f1d
since it
disables migrations all the time, not just during tests.
Backport of 944e66cb1d
from master
2016-07-14 09:22:06 -04:00
Jon Dufresne
1a2ee697e0
[1.10.x] Fixed #26889 -- Fixed missing PostgreSQL index in SchemaEditor.add_field().
...
Backport of 2e4cfcd2b9
from master
2016-07-13 21:55:25 -04:00
Andrey Fedoseev
ded5020241
[1.10.x] Fixed #17657 -- Made ModelForm respect ModelMultipleChoiceField's to_field_name.
...
Follow up to 67d984413c
.
Backport of 81963b37a9
from master
2016-07-12 16:20:28 -04:00
Julien Hartmann
39c25b772b
[1.10.x] Fixed #26749 -- Preserved behavior of use_for_related_field during deprecation.
...
Backport of f4afb85d7e
from master
2016-07-11 13:34:18 -04:00
Baptiste Mispelon
4b6560f5a9
[1.10.x] Fixed numpy deprecation warning silencing in template_tests.
...
Backport of 418658f453
from master
2016-07-09 10:24:27 -04:00
Loïc Bistuer
a2af2420ce
[1.10.x] Fixed #26881 -- Fixed duplicate managers in migrations.
...
When both parent and child models had managers with the same name and
a migrations opt-in both were added to the migration state.
Backport of dab83e5ba1
from master
2016-07-09 18:12:18 +07:00
Tim Graham
567cfc1601
[1.10.x] Replaced use of TestCase.fail() with assertRaises().
...
Also removed try/except/fail antipattern that hides exceptions.
Backport of c9ae09addf
from master
2016-07-01 09:58:56 -04:00
Andrew Nester
f683bba6f6
[1.10.x] Fixed #25292 -- Fixed crash in ManyToManyField.through_fields check.
...
Backport of baff4dd37d
from master
2016-06-30 08:55:21 -04:00
Christopher Grebs
712838a53d
[1.10.x] Fixed #26119 -- Fixed URLValidator crash on URLs with brackets.
...
Backport of a9e188ccd6
from master
2016-06-28 15:44:07 -04:00
Eduard Stepanov
28de25c249
[1.10.x] Fixed #26786 -- Avoided redundant max value validators on integer fields.
...
Backport of 49b4596cb4
from master
2016-06-28 11:40:59 -04:00
Aaron Elliot Ross
198128684b
[1.10.x] Fixed #26171 -- Made MySQL create an index on ForeignKeys with db_contraint=False.
...
Refactored "Prevented unneeded index creation on MySQL-InnoDB" (2ceb10f
)
to avoid setting db_index=False.
Backport of 6bf7964023
from master
2016-06-28 08:22:36 -04:00
Jon Dufresne
5c04852455
[1.10.x] Refs #26034 -- Corrected a schema test to work with the correct field state.
...
Backport of d47f6d75ef
from master
2016-06-27 12:16:52 -04:00
akki
7f249e73dd
[1.10.x] Fixed #26795 -- Factored out get_changes() in test_autodetector.py.
...
Backport of ca77b50905
from master
2016-06-24 22:01:56 -04:00
Sergey Fedoseev
be1022d0e7
[1.10.x] Fixed #26785 -- Made Oracle return None rather than empty string for empty geometries.
...
Backport of ea4665066b
from master
2016-06-21 18:51:08 -04:00
Simon Charette
23ac35af19
[1.10.x] Fixed #26781 -- Made table name case change a noop on SQLite.
...
SQLite disgresses from the SQL standard by ignoring case of quoted identifiers.
Thanks to laozzzi for the report and Tim for the review.
Backport of c2e62fd1ae
from master
2016-06-21 16:38:00 -04:00
Tim Graham
1b0b6f0342
[1.10.x] Refs #21379 , #26719 -- Moved username normalization to AbstractBaseUser.
...
Thanks Huynh Thanh Tam for the initial patch and Claude Paroz for review.
Backport of 39805686b3
from master
2016-06-21 16:20:00 -04:00
Tim Graham
45a650777e
[1.10.x] Fixed #26787 -- Documented deleting and reloading of model instance fields.
...
Thanks Julien Hartmann for the report.
Backport of 20d1cb33c2
from master
2016-06-21 15:25:16 -04:00
Paulo
c464cf88ff
[1.10.x] Fixed #26729 -- Allowed overriding a form field's label/help_text in Form.__init__() for TabularInline.
...
Backport of 9c2d5a8d33
from master
2016-06-21 14:32:19 -04:00
Jon Dufresne
e725a68bcc
[1.10.x] Fixed #26783 -- Fixed SessionMiddleware's empty cookie deletion when using SESSION_COOKIE_PATH.
...
Backport of d13881bd34
from master
2016-06-21 11:03:40 -04:00
Claude Paroz
b1592dd73b
[1.10.x] Fixed #26750 -- Fixed introspection for geography point field with dim=3
...
Thanks Yegor Kazantsev for the report and the initial patch.
Backport of 140c23502
from master.
2016-06-21 15:23:58 +02:00
Tim Graham
8c25d8fc10
[1.10.x] Refs #22384 -- Readded RegexURLResolver.reverse().
...
It was removed in 785cc71d5b
only because
it was untested and unused in Django itself, however, some third-party
apps use it.
Backport of 4e400dcb79
from master
2016-06-20 14:51:28 -04:00
Loïc Bistuer
0f23bcebdf
[1.10.x] Fixed #26643 -- Prevented unnecessary AlterModelManagers operations caused by the manager inheritance refactor.
...
This also makes migrations respect the base_manager_name and
default_manager_name model options.
Thanks Anthony King and Matthew Schinckel for the initial patches.
Backport of 2eb7cb2fff
from master
2016-06-20 12:56:37 -04:00
Tim Graham
91d754eb2a
[1.10.x] Fixed #26778 -- Fixed ModelSignal.connect() weak argument.
...
Backport of 9bf8d50a67
from master
2016-06-18 20:45:58 -04:00
Claude Paroz
1b6de8fd23
[1.10.x] Fixed #26775 -- Supported dim=3 geography fields
...
Thanks François-Xavier Thomas for the report.
Backport of 8ba44ecda0
from master.
2016-06-18 21:50:45 +02:00
Paul J Stevens
d3b9c49919
[1.10.x] Refs #26772 -- Added a test for FileField reopening closed files.
...
Thanks Simon Charette for review.
Backport of b45852c263
from master
2016-06-18 12:46:42 -04:00
Tim Graham
e2b266fdf7
[1.10.x] Reverted "Fixed #26644 -- Allowed wrapping NamedTemporaryFile with File."
...
This reverts commit 1b407050dd
as it
introduces a regression in the test for refs #26772 .
Backport of cd217de610
from master
2016-06-18 12:46:34 -04:00
Markus Holtermann
31a789f646
[1.10.x] Fixed #24931 -- Made namespaced RegexURLResolvers populate callback strings.
...
Fixed a regression in 2f16ff5a6c
.
Thanks Tim Graham for the review.
Backport of 625b8e9295
from master
2016-06-18 10:39:49 -04:00
Tim Graham
1213ef2b18
[1.10.x] Refs #15667 -- Fixed crash when indexing RadioFieldRenderer with ModelChoiceIterator.
...
Regression in 86573861a9
2016-06-18 10:37:37 -04:00
Tim Graham
bdc29b7188
[1.10.x] Reverted "Fixed #26398 -- Made FieldFile.open() respect its mode argument."
...
This reverts commit a52a531a8b
due to
regressions described in refs #26772 .
Backport of 7def55c3f6
from master
2016-06-17 21:08:56 -04:00
Carl Meyer
69de988f92
[1.10.x] Refs #26601 -- Improved backwards-compatibility of DEP 5 middleware exception handling.
...
Backport of 7d1b69dbe7
from master
2016-06-17 15:55:55 -04:00
Carl Meyer
34fbec3cb4
[1.10.x] Moved old-middleware tests in preparation for adding new tests.
...
Backport of 104ee2fdae
from master
2016-06-17 15:55:44 -04:00
Carl Meyer
6be0e93b8f
[1.10.x] Improved debugging of failed middleware_exceptions tests.
...
Backport of 702dfa3589
from master
2016-06-17 09:16:12 -04:00
Jon Dufresne
13d60298ea
[1.10.x] Fixed #26747 -- Used more specific assertions in the Django test suite.
...
Backport of 4f336f6652
from master
2016-06-16 14:21:14 -04:00
Tim Graham
70b7d6b4ea
[1.10.x] Fixed flake8 2.6 warnings.
...
Backport of ea34426ae7
from master
2016-06-16 09:33:02 -04:00
Hugo Osvaldo Barrera
c37f9253a6
[1.10.x] Fixed #26644 -- Allowed wrapping NamedTemporaryFile with File.
...
914c72be2a
introduced a regression that
causes saving a NamedTemporaryFile in a FileField to raise a
SuspiciousFileOperation. To remedy this, if a File has an absolute
path as a filename, use only the basename as the filename.
Backport of 1b407050dd
from master
2016-06-14 09:58:27 -04:00
Ville Skyttä
84737135f6
[1.10.x] Removed usage of a deprecated unittest assertion.
...
Backport of fa654da613
from master
2016-06-14 09:04:53 -04:00
Brett Haydon
bd7de3cb87
[1.10.x] Fixed #26716 -- Made CurrentSiteMiddleware compatible with new-style middleware.
...
Backport of 5e3f4c2e53
from master
2016-06-07 09:46:58 -04:00
Tim Graham
8996054cb4
[1.10.x] Fixed #26667 -- Fixed a regression in queries on a OneToOneField that has to_field and primary_key=True.
...
Thanks Simon Charette for review.
Backport of e2296e7f0a
from master
2016-06-04 09:15:10 -04:00
mieciu
9a204fc8a5
[1.10.x] Fixed #26698 -- Fixed PostgreSQL dbshell crash on an empty database name.
...
Backport of 19ff506878
from master
2016-06-03 12:42:41 -04:00
Brad Melin
3eb31867bb
[1.10.x] Fixed #26672 -- Fixed HStoreField to raise ValidationError instead of crashing on non-dict JSON input.
...
Backport of f6517a5335
from master
2016-06-02 16:29:22 -04:00
Alex Hill
85d2b80d5e
[1.10.x] Fixed #26686 -- Fixed crash when registering model signals with abstract senders.
...
Backport of 08014fe75b
from master
2016-06-02 14:46:44 -04:00
Alex Hill
f91247f598
[1.10.x] Fixed #26642 -- Made ModelSignal.disconnect() work with lazy references.
...
Backport of ff6c6feae1
from master
2016-06-02 14:46:31 -04:00
Ramiro Morales
777bc8f7d6
[1.10.x] Fixed #26692 -- Relaxed an i18n compilemessages test.
...
The actual non-ASCII character differs on Windows.
Backport of 71421e8f87
from master
2016-06-01 09:21:17 -04:00
Simon Charette
58f0d40b6d
[1.10.x] Fixed #26676 -- Prevented prefetching to_attr from caching its result in through attr.
...
Thanks Ursidours for the report.
Backport of 53a5fb3cc0
from master
2016-05-31 14:35:20 -04:00
Ramiro Morales
4095317afb
[1.10.x] Fixed #26687 -- Made an i18n test not use a hardcoded path separator.
...
Fixed a failure on Windows.
Backport of e3877c53ed
from master
2016-05-31 12:00:57 -04:00
Vytis Banaitis
b737c0f5db
[1.10.x] Fixed #25044 -- Fixed migrations for renaming ManyToManyField's through model.
...
Backport of f1e408ff40
from master
2016-05-30 10:27:28 -04:00
Ramiro Morales
af8ac46015
[1.10.x] Fixed #26674 -- Corrected a i18n makemessages test.
...
Made it consistently read the PO file, decode its contents and then
check for the non-breaking space Unicode code point.
Previously we were erroneously skipping the interpretation of what we
read as UTF-8 text.
This was causing the test to fail on Windows with Python 3.5.
Backport of 1b00ed0880
from master
2016-05-29 12:49:47 -04:00
Ramiro Morales
e0a4d4477c
[1.10.x] Fixed #26673 -- Fixed a I18N test case error on Windows+Python 2.7.
...
`subprocess.Popen` doesn't accept enviroment vars with Unicode var name
or value.
Backport of 15a5755e7c
from master
2016-05-28 17:16:03 -04:00
Tim Graham
f529d0cb58
[1.10.x] Refs #24227 -- Fixed crash of ManyToManyField.value_from_object() on unsaved model instances.
...
This behavior was removed in 67d984413c
but is needed to prevent a crash in formtools.
Backport of a4c20ae85b
from master
2016-05-28 16:06:06 -04:00
Daniel Wiesmann
85ab56944d
[1.10.x] Refs #25588 -- Fixed GDAL dependency in spatial lookups.
...
Backport of 9bb1b4b7f6
from master
2016-05-27 17:07:26 -04:00
Simon Charette
dfae72f45a
[1.10.x] Fixed #26647 -- Included the state of all applied migrations when migrating forward.
...
Thanks Jasper Maes for the detailed report.
Backport of 36d36818a3
from master
2016-05-26 13:32:02 -04:00
Tim Graham
8166f5e84a
[1.10.x] Updated GeoIP test for latest database.
...
Backport of a0a1c4fbde
from master
2016-05-23 20:17:37 -04:00
Simon Charette
826ec5ee57
[1.10.x] Refs #24067 -- Fixed contenttypes rename tests failures on Oracle.
...
Broke the initial migration in two to work around #25530 and added
'django.contrib.auth' to the available_apps to make sure its tables are also
flushed as Oracle doesn't implement cascade deletion in sql_flush().
Thanks Tim for the report.
Backport of 722344ee59
from master
2016-05-22 21:29:59 -04:00
Alex Hill
779bb82f51
Fixed #26421 -- Refactored ModelSignal to use Apps.lazy_model_operation()
2016-05-19 21:33:36 -04:00
Alex Hill
2ff7ef15b0
Refs #26421 -- Refactored Apps.lazy_model_operation() for better checks and tests
2016-05-19 21:33:36 -04:00
Simon Charette
05a9f3a09a
Refs #24100 -- Fixed a test failure on MySQL related to non-transactional DDL.
...
Thanks Tim for the report.
2016-05-19 11:01:19 -04:00
darius BERNARD
a7ad473ad2
Fixed #26515 -- Fixed Query.trim_joins() for nested ForeignObjects.
2016-05-19 09:56:24 -04:00
Shai Berger
5112e65ef2
Fixed #20869 -- made CSRF tokens change every request by salt-encrypting them
...
Note that the cookie is not changed every request, just the token retrieved
by the `get_token()` method (used also by the `{% csrf_token %}` tag).
While at it, made token validation strict: Where, before, any length was
accepted and non-ASCII chars were ignored, we now treat anything other than
`[A-Za-z0-9]{64}` as invalid (except for 32-char tokens, which, for
backwards-compatibility, are accepted and replaced by 64-char ones).
Thanks Trac user patrys for reporting, github user adambrenecki
for initial patch, Tim Graham for help, and Curtis Maloney,
Collin Anderson, Florian Apolloner, Markus Holtermann & Jon Dufresne
for reviews.
2016-05-19 05:02:19 +03:00
Simon Charette
7694e196ce
Moved the AUTH_USER_MODEL setting changed receiver.
...
Test suites besides Django's may need the same behavior.
2016-05-18 09:56:29 -04:00
Marti Raudsepp
b9ae662c97
Fixed #26620 -- Made Model.refresh_from_db() fail when passed unknown kwargs.
2016-05-18 09:27:23 -04:00
Barthelemy Dagenais
a5c8072ab1
Fixed #26627 -- Fixed on_commit callbacks execution order when callbacks make transactions.
2016-05-18 09:09:48 -04:00
Loïc Bistuer
4ff1e6ef58
Fixed running auth_tests in isolation after 3a47d42fa3
.
2016-05-18 06:38:42 -04:00
Josh Smeaton
2a4af0ea43
Fixed #25774 -- Refactor datetime expressions into public API
2016-05-18 20:14:58 +10:00
boaz85@gmail.com
5f23f904af
Fixed #14415 -- Used the test database name in BaseDatabaseCreation.test_db_signature().
2016-05-17 21:35:36 -04:00
Simon Charette
f179113e6c
Fixed #24067 -- Renamed content types upon model renaming.
...
Thanks to Tim for the extensive review.
2016-05-17 12:14:58 -04:00
Tim Graham
354acd04af
Refs #26601 -- Added a warning if both MIDDLEWARE AND MIDDLEWARE_CLASSES are set.
2016-05-17 07:24:45 -04:00
Tim Graham
ece4d24f8e
Refs #26601 -- Deprecated old-style middleware.
2016-05-17 07:22:26 -04:00
Florian Apolloner
9baf692a58
Fixed #26601 -- Improved middleware per DEP 0005.
...
Thanks Tim Graham for polishing the patch, updating the tests, and
writing documentation. Thanks Carl Meyer for shepherding the DEP.
2016-05-17 07:22:22 -04:00
Loïc Bistuer
ed0ff913c6
Fixed #10506 , #13793 , #14891 , #25201 -- Introduced new APIs to specify models' default and base managers.
...
This deprecates use_for_related_fields.
Old API:
class CustomManager(models.Model):
use_for_related_fields = True
class Model(models.Model):
custom_manager = CustomManager()
New API:
class Model(models.Model):
custom_manager = CustomManager()
class Meta:
base_manager_name = 'custom_manager'
Refs #20932 , #25897 .
Thanks Carl Meyer for the guidance throughout this work.
Thanks Tim Graham for writing the docs.
2016-05-17 12:07:22 +07:00
Loïc Bistuer
3a47d42fa3
Fixed #20932 , #25897 -- Streamlined manager inheritance.
2016-05-17 02:29:22 +07:00
Claude Paroz
9935f97cd2
Refs #21379 -- Normalized unicode username inputs
2016-05-16 19:38:02 +02:00
Claude Paroz
526575c641
Fixed #21379 -- Created auth-specific username validators
...
Thanks Tim Graham for the review.
2016-05-16 19:37:57 +02:00
Aron Podrigal
85ef98dc6e
Fixed #24305 -- Allowed overriding fields on abstract models.
...
Fields inherited from abstract base classes may be overridden like
any other Python attribute. Inheriting from multiple models/classes
with the same attribute name will follow the MRO.
2016-05-16 07:32:21 -04:00
Simon Charette
61a16e0270
Fixed #24075 -- Used post-migration models in contrib apps receivers.
...
Thanks Markus and Tim for the review.
2016-05-15 19:51:16 -04:00
Simon Charette
f937c9ec97
Fixed #24100 -- Made the migration signals dispatch its plan and apps.
...
Thanks Markus for your contribution and Tim for your review.
2016-05-15 19:51:15 -04:00
Tim Graham
55c3133df8
Simplified a ClearableFileInput test.
2016-05-14 10:31:32 -04:00
Bouke Haarsma
31501fb53e
Refs #18599 -- Added a test for assigning a GenericForeignKey in Model.__init__().
...
The issue was fixed by 8a47ba679d
(refs #16508 ).
2016-05-13 21:26:48 -04:00
Simon Charette
104727030c
Adjusted a variable name in migration signal tests.
2016-05-13 16:47:02 -04:00
Simon Charette
c0118ff80b
Refs #24201 -- Ignored order_with_respect_to private fields in migrations.
...
Thanks Tim for the review.
2016-05-13 15:43:23 -04:00
Simon Charette
18900e55c5
Added tests for the post_migrate signal.
2016-05-13 15:32:54 -04:00
Tim Graham
99d9d4e695
Cosmetic edits to tests/managers_regress/tests.py
2016-05-13 15:23:24 -04:00
Matthew Somerville
1962a96a30
Fixed #24938 -- Added PostgreSQL trigram support.
2016-05-13 12:38:21 -04:00
Tim Graham
d7334b405f
Refs #26333 -- Reverted inadvertent edits to fix tests.
2016-05-13 12:21:44 -04:00
Nicolas Noé
e158ec0ba0
Fixed #26333 -- Made GIS Geometry classes deconstructible.
2016-05-13 11:30:19 -04:00
David Sanders
14c952d581
Fixed #26612 -- Fixed SelectFilter2 buttons changing URL.
2016-05-13 09:06:20 -04:00
Vincenzo Pandolfo
069319396f
Fixed #26277 -- Added support for null values in ChoicesFieldListFilter.
2016-05-12 12:40:14 -04:00
Andre Cruz
929684d6ee
Fixed #21231 -- Enforced a max size for GET/POST values read into memory.
...
Thanks Tom Christie for review.
2016-05-12 10:17:52 -04:00
Tim Graham
60b095cc4c
Refs #24046 -- Fixed a template test when run in reverse.
2016-05-11 11:41:10 -04:00
Raphael Gaschignard
8f6a1a1551
Fixed #26429 -- Added a timestamp to merge migration names.
...
This reduces the possibility of a naming conflict, especially after
squashing migrations.
2016-05-11 08:19:19 -04:00
Simon Charette
535660b852
Refs #18100 -- Added tests for deferred model deletion signals.
...
Thanks Tim for the review and pointing out this was fixed by #26207 .
2016-05-10 13:21:52 -04:00
Tim Graham
2f0e0eee45
Fixed #24046 -- Deprecated the "escape" half of utils.safestring.
2016-05-10 12:46:47 -04:00
Claude Paroz
c3e1086949
Stopped truncating AdminEmailHandler message subjects
...
Refs #26572 , #17281 . The RFC doesn't limit total length, just the line length
which is already taken care of by Python itself.
Thanks Tim Graham for the review.
2016-05-10 18:17:43 +02:00
Simon Charette
207c5b4acd
Fixed #26603 -- Forced lazy template names to text when computing cache key.
...
Refs #26536 .
Thanks Sylvain Fankhauser for the very detailed report.
2016-05-10 10:03:01 -04:00
Iacopo Spalletti
49c57f8565
Fixed #25005 -- Made date and time fields with auto_now/auto_now_add use effective default.
...
Thanks to Andriy Sokolovskiy for initial patch.
2016-05-09 07:48:40 -04:00
Jarek Glowacki
80bf3135d0
Sorted migration list order in test; added trailing comma.
2016-05-08 13:53:36 +02:00
Jarek Glowacki
c8df17b612
Included reverse deps in showmigrations
2016-05-08 13:53:36 +02:00