Yuri Konotopov
330bc402a8
Fixed #32546 -- Avoided Meta.ordering columns in GROUP BY clauses.
...
Follow up to 0ddb4ebf7b
.
2021-03-16 07:58:38 +01:00
Hasan Ramezani
775b796d8d
Refs #32508 -- Raised ValueError instead of using "assert" in lazy().
2021-03-15 13:10:30 +01:00
Hasan Ramezani
2cd0ccef04
Added tests for AssertionErrors in get_complete_version() and _lazy_re_compile().
2021-03-15 13:03:30 +01:00
manav014
99640e24b4
Fixed #31516 -- Improved naming of migrations with multiple operations.
...
52 gives 60 in total (52 + 5 + 3).
Co-authored-by: Adam Johnson <me@adamj.eu>
2021-03-12 11:56:12 +01:00
Adam Johnson
927fead2f5
Refs #31516 -- Added Migration.suggest_name() tests for migrations with no operations.
2021-03-12 11:56:12 +01:00
Adam Johnson
b1cb923883
Refs #31516 , Refs #31703 -- Made makemigrations always name initial migrations "initial".
2021-03-12 09:19:23 +01:00
Chris Jerdonek
d828beb68f
Fixed #32529 -- Delayed creating a test suite in build_suite().
2021-03-11 10:02:06 +01:00
Chris Jerdonek
d8a4bcffdb
Refs #32489 -- Doc'd and tested iter_test_cases() support for an iterable of tests.
2021-03-11 09:23:33 +01:00
Hasan Ramezani
a2d5ea626e
Refs #32508 -- Raised ImproperlyConfigured instead of using "assert" in middlewares.
2021-03-11 08:34:28 +01:00
Jonny Park
dc86a25a67
Refs #24121 -- Added __repr__() to MiddlewareMixin and subclasses.
2021-03-10 21:16:58 +01:00
Mariusz Felisiak
a6a94fb966
Removed unnecessary lines in test_has_view_or_change_permission_required().
...
AutocompleteJsonViewTests.user is already a staff member.
2021-03-10 15:37:28 +01:00
Nick Pope
afb0eb8bb3
Refs #24121 -- Added __repr__() to OrderedSet.
2021-03-10 09:29:05 +01:00
Mariusz Felisiak
ba9a2b7544
Refs #32508 -- Raised TypeError instead of using "assert" on unsupported operations for sliced querysets.
2021-03-10 09:16:28 +01:00
Chris Jerdonek
77e0a35a10
Fixed #32516 -- Fixed reorder_suite() with duplicates and reverse=True.
2021-03-09 13:30:51 +01:00
Markus Holtermann
d9a266d657
Updated Git branch "master" to "main".
...
This change follows a long discussion on django-develops:
https://groups.google.com/g/django-developers/c/tctDuKUGosc/
2021-03-09 08:48:32 +01:00
Tim Graham
76c0b32f82
Refs #26167 -- Added @skipUnlessDBFeature('supports_expression_indexes') to a test.
...
Failure observed on CockroachDB.
2021-03-08 20:12:26 +01:00
Diego Lima
2e5aa444d1
Fixed #32517 -- Made OrderedSet reversible.
...
Refs #32516 .
2021-03-08 08:22:07 +01:00
Johan Schiff
d01709aae2
Fixed #24141 -- Added QuerySet.contains().
2021-03-06 20:40:29 +01:00
Chris Jerdonek
22c9af0eae
Fixed #32489 -- Added iter_test_cases() to iterate over a TestSuite.
...
This also makes partition_suite_by_type(), partition_suite_by_case(),
filter_tests_by_tags(), and DiscoverRunner._get_databases() to use
iter_test_cases().
2021-03-05 13:04:07 +01:00
Hasan Ramezani
20ddc3b81d
Fixed #32494 -- Adjusted system check for raw_id_fields to warn about Field.attname.
2021-03-04 08:41:28 +01:00
Hasan Ramezani
1da54bfe7d
Corrected messages of admin checks for invalid model field names.
2021-03-04 08:41:28 +01:00
Jacob Walls
b23232b6ab
Fixed #27854 -- Added system check for nonexistent directories in STATICFILES_DIRS setting.
2021-03-03 11:27:08 +01:00
Mariusz Felisiak
7186c536c4
Used CollectionTestCase in FindersCheckTests tests.
2021-03-03 11:20:13 +01:00
François Freitag
7ca7f4495b
Refs #21429 -- Added SimpleTestCase.assertNoLogs() on Python < 3.10.
2021-03-02 20:35:33 +01:00
Rohith PR
d3ecef26b9
Refs #24121 -- Added __repr__() to URLNode.
2021-03-02 12:24:49 +01:00
Jacob Walls
73b1b225ce
Fixed #22640 -- Raised TypeError when instantiating model with keyword and positional args for the same field.
2021-03-01 20:26:39 +01:00
Hasan Ramezani
8380fe08a0
Fixed #32456 -- Added dbshell support for specifying a password file on PostgreSQL.
2021-03-01 09:33:49 +01:00
Jacob Walls
64a0d1ef6e
Fixed typo in assertQuerysetEqual() exception message.
2021-02-26 21:12:11 +01:00
Mariusz Felisiak
8908846444
Refs #32292 -- Made dbshell do not use 'postgres' database when service name is set.
...
Regression in dcb3ad3319
.
2021-02-26 20:53:01 +01:00
Jacob Walls
9d7e31cc74
Removed unused code in admin_views tests.
...
Unused since its introduction in 7b21bfc074
and 1e4ad6f118
.
2021-02-26 20:49:21 +01:00
Jacob Walls
337cd652a5
Fixed #28607 -- Prevented duplicates in HashedFilesMixin post-processing results.
...
Thanks Ed Morley for the implementation idea.
2021-02-26 11:38:32 +01:00
David Smith
179ee13eb3
Refs #24121 -- Added __repr__() to FilterExpression, Lexer, Parser, and Token.
2021-02-26 10:25:08 +01:00
Simon Charette
3089018e95
Fixed #32446 -- Deprecated SERIALIZE test database setting.
...
Whether or not the state of a test database should be serialized can be
inferred from the set of databases allowed to be access from discovered
TestCase/TransactionTestCase enabling the serialized_rollback feature
which makes this setting unnecessary.
This should make a significant test suite bootstraping time difference
on large projects that didn't explicitly disable test database
serialization.
2021-02-24 20:31:11 +01:00
Haki Benita
3fd82a6241
Refs #32468 -- Added error message on invalid usage of cache decorators.
2021-02-24 10:13:51 +01:00
Simon Charette
277eea8fcc
Fixed #32478 -- Included nested columns referenced by subqueries in GROUP BY on aggregations.
...
Regression in fb3f034f1c
.
Refs #31094 , #31150 .
Thanks Igor Pejic for the report.
2021-02-24 09:01:36 +01:00
Hannes Ljungberg
3aa545281e
Fixed #30916 -- Added support for functional unique constraints.
...
Thanks Ian Foote and Mariusz Felisiak for reviews.
2021-02-23 20:19:53 +01:00
Marc Gibbons
d6572ee4b0
Fixed #32470 -- Fixed ResolverMatch instance on test clients when request.urlconf is set.
2021-02-23 09:54:49 +01:00
Mariusz Felisiak
fb93363c49
Fixed DataUploadMaxNumberOfFieldsFormPost.test_number_exceeded().
...
Follow up to 0ad9fa02e0
.
2021-02-23 09:47:30 +01:00
Chris Jerdonek
5c4c3e2d1f
Fixed #32445 -- Fixed LiveServerThreadTest.test_closes_connections() for non-in-memory database on SQLite.
2021-02-23 06:08:43 +01:00
Nick Pope
0e4e35722a
Fixed #32469 -- Made assertQuerysetEqual() respect maxDiff when ordered=False.
2021-02-22 09:27:46 +01:00
Hannes Ljungberg
87acbf0631
Fixed #32458 -- Made __repr__() for Index and BaseConstraint subclasses more consistent.
2021-02-19 20:25:11 +01:00
Hasan Ramezani
7c18b22e2f
Fixed #32256 -- Fixed migration optimization crash when swapping field names.
...
This disables optimization of RenameField operation when an old field
name is referenced in subsequent operations.
Co-authored-by: InvalidInterrupt <InvalidInterrupt@users.noreply.github.com>
2021-02-19 11:19:01 +01:00
Nick Pope
0ad9fa02e0
Refs CVE-2021-23336 -- Updated tests and release notes for affected versions.
2021-02-19 09:03:06 +01:00
David Smith
96a5093400
Refs #30231 -- Fixed SeleniumTests.test_inlines_verbose_name with headless mode.
...
Horizontal scrollbar doesn't appear with the headless mode on small
windows, that's why window.scrollTo() is not an option for these tests
even after fixing #32459 .
2021-02-19 07:15:54 +01:00
Hasan Ramezani
f2bef2b7bc
Fixed #32455 -- Allowed right combining Q() with boolean expressions.
2021-02-18 22:20:36 +01:00
Mariusz Felisiak
efce21497c
Refs #32455 -- Added tests for left combining an empty Q() with boolean expressions.
2021-02-18 22:19:56 +01:00
starryrbs
466920f6d7
Fixed #32450 -- Fixed crash when ANDing/ORing an empty Q() with not pickleable Q().
...
Regression in bb0b6e5263
.
2021-02-18 21:13:24 +01:00
Amir Ajorloo
1710cdbe79
Fixed #32443 -- Removed "shifted" CSS class when admin's sidebar is disabled.
2021-02-18 09:18:19 +01:00
Hannes Ljungberg
4d99375b46
Fixed #32453 -- Added introspection of unique constraint field ordering on SQLite.
...
Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2021-02-17 10:59:17 +01:00
Teresa Partida
45bef6706a
Fixed #30231 -- Fixed admin filter horizontal/vertical verbose_name generation.
...
Co-authored-by: David Smith <smithdc@gmail.com>
2021-02-16 14:26:53 +01:00
Harm Geerts
06e5f7ae16
Fixed #29052 -- Made test database creation preserve alias order and prefer the "default" database.
...
This fixes flushing test databases when two aliases point to the same
database.
Use a list() to store the test database aliases so the order remains
stable by following the order of the connections. Also, always use the
"default" database alias as the first alias to accommodate `migrate`.
Previously `migrate` could be executed on a secondary alias which
caused truncating the "default" database.
2021-02-16 10:25:34 +01:00
manav014
3119a6deca
Fixed #26607 -- Allowed customizing formset kwargs with ModelAdmin.get_formset_kwargs().
...
Thanks Nick Pope for reviews.
2021-02-15 11:37:35 +01:00
Chris Jerdonek
fc0069bfa5
Refs #32417 -- Improved cleaning up and fixed isolation of staticfiles_tests tests.
2021-02-15 10:23:54 +01:00
Chris Jerdonek
694deff82f
Fixed #32437 -- Fixed cleaning up ALLOWED_HOSTS in LiveServerTestCase on setUpClass() failure.
2021-02-12 09:39:48 +01:00
Chris Jerdonek
91c243f80f
Refs #32416 -- Added LiveServerThread.server_class to ease subclassing.
2021-02-12 08:17:46 +01:00
Egidijus Macijauskas
6307c3f1a1
Fixed #32433 -- Added error message on QuerySet.delete() following distinct().
2021-02-11 08:33:30 +01:00
Egidijus Macijauskas
4e8ecf0cb6
Refs #19102 -- Removed flaky test Ticket19102Tests.test_ticket_19102_distinct_on.
...
The subquery pushdown only happens because another table is involved in
filter. It's not the distinct usage that causes the pushdown.
The distinct('description').order_by('pk') expression is not valid
because SELECT DISTINCT ON must match initial ORDER BY expressions
which is not the case here.
2021-02-11 08:33:30 +01:00
Ramon Saraiva
dcb094abe8
Fixed #32421 -- Made admindocs ModelDetailView show model cached properties.
2021-02-11 06:50:50 +01:00
Mariusz Felisiak
ec0ff40631
Fixed #32355 -- Dropped support for Python 3.6 and 3.7
2021-02-10 10:20:54 +01:00
Josh Santos
9c6ba87692
Fixed #32145 -- Improved makemessages error message when app's locale directory doesn't exist.
2021-02-09 20:00:20 +01:00
Jordan Bae
d4ac23bee1
Fixed #32425 -- Fixed adding nullable field with default on MySQL.
...
Thanks Simon Charette for the review.
2021-02-09 06:59:31 +01:00
ThinkChaos
b99d6c9cbc
Fixed #28216 -- Added next_page/get_default_redirect_url() to LoginView.
2021-02-08 21:08:05 +01:00
Markus Holtermann
50a5f8840f
Refs #32394 -- Changed STATIC_URL/MEDIA_URL to relative paths in tests and docs where appropriate.
2021-02-06 13:41:35 +01:00
Hasan Ramezani
63d239db03
Fixed #32411 -- Fixed __icontains lookup for JSONField on MySQL.
2021-02-05 16:14:12 +01:00
Mikolaj Rybinski
8e90560aa8
Fixed #32420 -- Fixed detecting primary key values in deserialization when PK is also a FK.
2021-02-05 12:33:43 +01:00
Daniel Ebrahimian
3f8979e37b
Fixed #32350 -- Fixed showmigrations crash for applied squashed migrations.
...
Thanks Simon Charette for reviews.
2021-02-04 21:17:26 +01:00
Mariusz Felisiak
ae48601e6d
Skipped test_archive tests when bz2/lzma module is not installed.
2021-02-04 14:08:43 +01:00
Simon Charette
f23b05696e
Fixed #32395 -- Allowed capturing stdout of migration signals.
2021-02-04 11:19:49 +01:00
Simon Charette
31bebc558b
Used subTest() in migrate_signals.tests.MigrateSignalTests.test_args().
2021-02-04 11:19:49 +01:00
Jim Xie
ce60d28929
Fixed #31527 -- Allowed admindocs index to handle non-string URLconfs.
2021-02-04 10:11:58 +01:00
Hasan Ramezani
7cba92ec55
Fixed #32332 -- Fixed loss of parent with non-numeric pk when saving child after parent.
...
Follow up to 519016e5f2
.
2021-02-04 06:06:00 +01:00
Mariusz Felisiak
f39634ff22
Refs #32390 -- Bumped required cx_Oracle to 7.0.
2021-02-03 10:03:33 +01:00
Mariusz Felisiak
f131841c60
Fixed #32403 -- Fixed re-raising DatabaseErrors when using only 'postgres' database.
...
Thanks Kazantcev Andrey for the report.
Regression in f48f671223
.
2021-02-02 21:34:36 +01:00
Mariusz Felisiak
05413afa8c
Fixed CVE-2021-3281 -- Fixed potential directory-traversal via archive.extract().
...
Thanks Florian Apolloner, Shai Berger, and Simon Charette for reviews.
Thanks Wang Baohua for the report.
2021-02-01 09:07:36 +01:00
Sandro Covo
6822aa5c6c
Fixed #32345 -- Fixed preserving encoded query strings in set_language() view.
...
Thanks Johannes Maron for the review.
2021-01-29 11:58:43 +01:00
Tilman Koschnick
fdfbc66331
Fixed #32392 -- Fixed ExclusionConstraint crash with Cast() in expressions.
2021-01-29 11:05:00 +01:00
Mariusz Felisiak
135c800fe6
Fixed GeoIPTest.test04_city() failure with the latest GeoIP2 database.
2021-01-29 11:00:12 +01:00
Illia Volochii
3c004075b1
Fixed #32389 -- Fixed ResponseHeaders crash when data is not mapping.
2021-01-28 10:10:08 +01:00
Hasan Ramezani
c978dd93fd
Fixed #32290 -- Fixed TemplateNotFound in {% include %} tag for relative path in variable.
2021-01-27 10:07:31 +01:00
Hasan Ramezani
640a6e1dce
Refs #32290 -- Added {% extends %} test for relative path in variable.
2021-01-27 09:37:03 +01:00
Mariusz Felisiak
b989d21336
Refs #26602 -- Added tests for aggregating over a RawSQL() annotation.
...
Fixed in 3f32154f40
.
Thanks Manav Agarwal for initial test.
2021-01-26 10:59:05 +01:00
Jerin Peter George
1adc09064f
Fixed #32347 -- Made ModelChoiceField include the value in ValidationError for invalid_choice.
2021-01-26 09:31:53 +01:00
Simon Charette
42e8cf47c7
Fixed #32369 -- Fixed adding check constraints with pattern lookups and expressions as rhs.
...
This disables interpolation of constraint creation statements. Since
Constraint.create_sql interpolates its parameters instead of deferring
this responsibility to the backend connection it must disable
connection level parameters interpolation.
2021-01-26 06:41:57 +01:00
Mariusz Felisiak
84ad7f3404
Refs #32380 -- Added test for distance lookups with F() expression.
...
Fixed in 5935a9aead
.
2021-01-25 08:40:46 +01:00
Timothy McCurrach
b1821fbad5
Fixed #32360 -- Added system check for FILE_UPLOAD_TEMP_DIR setting.
2021-01-22 07:51:00 +01:00
Mariusz Felisiak
a03a36121d
Fixed #32367 -- Fixed system check for specifying type of auto-created primary keys for inherited PKs.
...
Regression in b5e12d490a
.
Thanks אורי for the report.
2021-01-21 09:03:07 +01:00
Simon Charette
0c42cdf0d2
Fixed #32374 -- Stopped recording migration application before deferred SQL.
...
Migrations cannot be recorded in the same transaction as its associated
DDL operations when some of it is deferred until the schema editor
context exits.
Regression in c86a3d80a2
.
2021-01-21 07:03:35 +01:00
Simon Charette
533a583578
Refs #29721 -- Simplified migration used to test atomic recording.
...
This makes sure atomic recording of migration application is used when
the schema editor doesn't defer any statement.
2021-01-21 06:50:23 +01:00
Hasan Ramezani
dcb3ad3319
Fixed #32292 -- Added support for connection by service name to PostgreSQL.
2021-01-20 17:30:37 +01:00
Mariusz Felisiak
cfddca543a
Fixed isolation of utils_tests.test_autoreload tests.
2021-01-20 09:53:34 +01:00
Mariusz Felisiak
5371342ed6
Fixed #32357 -- Dropped support for PostgreSQL 9.6 and PostGIS 2.3.
2021-01-19 12:25:20 +01:00
Paul Ganssle
10d1261984
Refs #32365 -- Allowed use of non-pytz timezone implementations.
2021-01-19 11:59:37 +01:00
Hasan Ramezani
34aa4f1997
Fixed #32296 -- Added --skip-checks option to runserver command.
2021-01-18 12:51:35 +01:00
Mariusz Felisiak
e8b4f23115
Fixed isolation of test_check_errors_catches_all_exceptions.
2021-01-18 12:51:35 +01:00
Illia Volochii
bef6f75842
Fixed #32358 -- Fixed queryset crash when grouping by annotation with Distance()/Area().
...
Made MeasureBase hashable.
2021-01-18 09:58:50 +01:00
Timothy McCurrach
0aff3fd711
Fixed #18549 -- Fixed heading for inlines with a OneToOneField.
...
Used verbose_name instead of verbose_name_plural.
2021-01-18 08:12:19 +01:00
Timothy McCurrach
13409a0c0d
Refs #18549 -- Added test for heading of foreign key inlines.
2021-01-18 07:38:12 +01:00
Mariusz Felisiak
a948d9df39
Increased the default PBKDF2 iterations for Django 4.0.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak
b4c5f878bd
Advanced deprecation warnings for Django 4.0.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak
0aa6a602b2
Refs #31842 -- Removed DEFAULT_HASHING_ALGORITHM transitional setting.
...
Per deprecation timeline.
2021-01-14 17:50:04 +01:00