Mariusz Felisiak
9e456f3166
Refs #30747 -- Removed django.utils.http.is_safe_url() per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak
157ab32f34
Refs #27753 -- Removed django.utils.text.unescape_entities() per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak
5e33ec80d1
Refs #30158 -- Made alias argument required in signature of Expression.get_group_by_cols() subclasses.
...
Per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak
d134b0b93e
Refs #15902 -- Stopped set_language() storing user's language in the session.
...
Per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak
52a238ddf2
Refs #30165 -- Removed ugettext(), ugettext_lazy(), ugettext_noop(), ungettext(), and ungettext_lazy() per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak
810f037b29
Refs #27753 -- Removed django.utils.encoding.force_text() and smart_text() per deprecation timeline.
2021-01-14 17:50:04 +01:00
Mariusz Felisiak
88ed1c8d08
Refs #27753 -- Removed django.utils.http urllib aliases per deprecation timeline.
2021-01-14 17:50:04 +01:00
Hasan Ramezani
f750377318
Fixed #32321 -- Added system checks for invalid model field names in functional indexes.
2021-01-14 12:27:00 +01:00
Jon Moroney
76ae6ccf85
Fixed #31358 -- Increased salt entropy of password hashers.
...
Co-authored-by: Florian Apolloner <florian@apolloner.eu>
2021-01-14 11:20:28 +01:00
Jon Moroney
6bd206e1ff
Refs #31358 -- Added bcrypt password hashers tests for must_update() with salt().
2021-01-14 11:20:28 +01:00
Nick Pope
9204485396
Fixed #16117 -- Added decorators for admin action and display functions.
...
Refs #25134 , #32099 .
2021-01-13 17:19:22 +01:00
Hannes Ljungberg
83fcfc9ec8
Fixed #26167 -- Added support for functional indexes.
...
Thanks Simon Charette, Mads Jensen, and Mariusz Felisiak for reviews.
Co-authored-by: Markus Holtermann <info@markusholtermann.eu>
2021-01-13 11:47:50 +01:00
Tim Graham
e3ece0144a
Removed redundant database vendor helpers in gis_tests/utils.py.
2021-01-13 09:22:44 +01:00
Tim Graham
9f91122ed8
Added SpatialFeatures.empty_intersection_returns_none.
2021-01-13 09:22:44 +01:00
Hannes Ljungberg
4c62cdaa10
Refs #26709 -- Made Index raise ValueError on non-string fields.
2021-01-12 20:22:44 +01:00
Paolo Melchiorre
c412d9af7e
Fixed #32291 -- Added fixtures compression support to dumpdata.
2021-01-12 15:47:58 +01:00
Jon Dufresne
ba31b01034
Fixed #31747 -- Fixed model enumeration via admin URLs.
...
Co-authored-by: Carlton Gibson <carlton.gibson@noumenal.es>
2021-01-12 14:37:56 +01:00
Johannes Maron
3071660acf
Fixed #29010 , Fixed #29138 -- Added limit_choices_to and to_field support to autocomplete fields.
...
* Fixed #29010 -- Added limit_choices_to support to autocomplete fields.
* Fixed #29138 -- Allowed autocomplete fields to target a custom
to_field rather than the PK.
2021-01-12 11:37:38 +01:00
Hasan Ramezani
ba3fb2e4d0
Refs #32311 -- Fixed CSRF_FAILURE_VIEW system check errors code.
2021-01-12 11:22:13 +01:00
Hasan Ramezani
64331419c8
Fixed #32311 -- Added system check for CSRF_FAILURE_VIEW setting.
2021-01-12 09:44:36 +01:00
Florian Apolloner
2d6179c819
Fixed #32191 -- Made CookieStorage use RFC 6265 compliant format.
...
Co-authored-by: Craig Smith <hello@craigiansmith.com.au>
2021-01-07 13:00:53 +01:00
Florian Apolloner
102d92fc09
Refs #32191 -- Added Signer.sign_object()/unsign_object().
...
Co-authored-by: Craig Smith <hello@craigiansmith.com.au>
2021-01-06 20:16:47 +01:00
William Schwartz
ec6d2531c5
Fixed #32314 -- Fixed detection when started non-django modules with "python -m" in autoreloader.
...
django.utils.autoreload.get_child_arguments() detected when Python was
started with the `-m` option only for `django` module. This commit
changes the logic to check __spec__, see
https://docs.python.org/3/reference/import.html#main-spec
Now packages can implement their own __main__ with the runserver
command.
2021-01-05 21:03:29 +01:00
Alexander Lyabah
415f50298f
Fixed #32231 -- Allowed passing None params to QuerySet.raw().
2021-01-05 10:37:11 +01:00
Alexander Lyabah
aa3d360631
Refs #32231 -- Added tests for QuerySet.raw() with an escaped % symbol.
2021-01-05 10:36:30 +01:00
Akshat1Nar
b41d38ae26
Fixed #32298 -- Fixed URLValidator hostname length validation.
...
URLValidator now validates the maximum length of a hostname without
the userinfo and port.
2021-01-04 09:25:40 +01:00
Tim Graham
060e6bdd1f
Replaced DatabaseFeatures.supports_left_right_lookups with skipUnlessGISLookup.
2021-01-02 21:39:48 +01:00
Mariusz Felisiak
e13b71403b
Fixed #32304 -- Fixed prefixing STATIC_URL and MEDIA_URL by SCRIPT_NAME for absolute URLs with no domain.
...
Thanks Adam Hooper for the report.
Regression in c574bec092
.
2020-12-31 13:18:57 +01:00
Hasan Ramezani
a2e3f95b09
Fixed #31413 -- Fixed isolation of migrations.test_loader on databases that don't support transactions.
2020-12-31 08:18:51 +01:00
manav014
a9a7421ab8
Fixed #32294 -- Prevented ManyToManyField's hidden related name collisions between apps.
2020-12-30 13:11:47 +01:00
Mariusz Felisiak
74fd233b14
Fixed #32303 -- Bumped minimum supported SQLite to 3.9.0.
2020-12-30 09:01:56 +01:00
William Schwartz
e64c1d8055
Fixed #32302 -- Allowed migrations to be loaded from regular packages with no __file__ attribute.
...
The migrations loader prevents the use of PEP-420 namespace packages
for holding apps' migrations modules. Previously the loader tested for
this only by checking that app.migrations.__file__ is present. This
prevented migrations' being found in frozen Python environments that
don't set __file__ on any modules. Now the loader *additionally* checks
whether app.migrations.__path__ is a list because namespace packages
use a different type for __path__. Namespace packages continue to be
forbidden, and, in fact, users of normal Python environments should
experience no change whatsoever.
2020-12-29 12:54:08 +01:00
Mariusz Felisiak
98ad327864
Fixed #32299 -- Prevented mutating handlers when processing middlewares marking as unused in an async context.
...
Thanks Hubert Bielenia for the report.
2020-12-29 09:04:35 +01:00
Mariusz Felisiak
45519937e5
Added app labels to related fields checks messages E302-E305.
2020-12-29 09:01:35 +01:00
Florian Apolloner
c76d51b3ad
Refs #31358 -- Fixed decoding salt in Argon2PasswordHasher.
...
Argon2 encodes the salt as base64 for representation in the final hash
output. To be able to accurately return the used salt from decode(),
add padding, b64decode, and decode from latin1 (for the remote
possibility that someone supplied a custom hash consisting solely of
bytes -- this would require a manual construction of the hash though,
Django's interface does not allow for that).
2020-12-28 11:02:08 +01:00
François Freitag
b11ec9a69e
Fixed #32301 -- Made clearsessions raise CommandError when clear_expired() is not implemented.
2020-12-28 09:30:16 +01:00
Chinmoy Chakraborty
270072c4c2
Fixed #32158 -- Fixed loaddata crash on SQLite when table/column names are SQL keywords.
2020-12-28 08:57:30 +01:00
Jacob Walls
89fc144ded
Fixed #27827 -- Used "raise from" when raising InvalidTemplateLibrary exceptions in get_package_libraries().
...
This change sets the __cause__ attribute to raised exceptions and makes
small cleanups in error messages.
2020-12-28 07:31:37 +01:00
Mariusz Felisiak
ada83fd8b8
Fixed isolation of test_migrate_fake_split_initial.
2020-12-23 07:48:45 +01:00
Hasan Ramezani
8b2a30f6f1
Fixed #32285 -- Raised ImproperlyConfigured when AppConfig.label is not a valid Python identifier.
2020-12-22 13:26:30 +01:00
starryrbs
2a76f43134
Fixed #32269 -- Fixed parse_duration() for negative days in ISO 8601 format.
2020-12-21 10:28:07 +01:00
starryrbs
57d05f94c3
Added more assertions for parse_duration() with negative timedeltas.
2020-12-21 10:15:22 +01:00
Hasan Ramezani
577f2338f1
Fixed #32208 -- Allowed adding lazy() objects.
...
Co-authored-by: Claude Paroz <claude@2xlibre.net>
2020-12-21 09:24:41 +01:00
Nick Pope
9ef0394b54
Fixed typo in tests/admin_views/test_history_view.py test name.
2020-12-18 09:23:22 +01:00
Hasan Ramezani
8d582bf510
Fixed #32262 -- Fixed migration optimization for model creation and Meta options removal.
2020-12-18 06:57:57 +01:00
Nick Pope
bb64b99b78
Fixed #29867 -- Added support for storing None value in caches.
...
Many of the cache operations make use of the default argument to the
.get() operation to determine whether the key was found in the cache.
The default value of the default argument is None, so this results in
these operations assuming that None is not stored in the cache when it
actually is. Adding a sentinel object solves this issue.
Unfortunately the unmaintained python-memcached library does not support
a default argument to .get(), so the previous behavior is preserved for
the deprecated MemcachedCache backend.
2020-12-17 09:57:21 +01:00
David Smith
8f384505ee
Refs #32273 -- Completed test coverage for AdminSite.unregister().
2020-12-17 08:27:56 +01:00
Alexey Nigin
b9ba85a7ce
Fixed #32089 -- Fixed prefetch_related_objects() when some objects are already fetched.
...
Thanks Dennis Kliban for the report and Adam Johnson for the initial
patch.
Co-authored-by: Adam Johnson <me@adamj.eu>
2020-12-16 10:52:59 +01:00
Tom Forbes
b5e12d490a
Fixed #31007 -- Allowed specifying type of auto-created primary keys.
...
This also changes the default type of auto-created primary keys
for new apps and projects to BigAutoField.
2020-12-15 11:25:46 +01:00
Ayush Bansal
b960e4ed72
Fixed #32261 -- Added error logging to Signal.send_robust().
2020-12-15 11:00:26 +01:00
Mariusz Felisiak
965d2d95c6
Fixed typo in tests/servers/tests.py.
2020-12-15 08:51:58 +01:00
Petter Strandmark
772eca0b02
Fixed #32240 -- Made runserver suppress ConnectionAbortedError/ConnectionResetError errors.
...
See https://bugs.python.org/issue27682 and
https://github.com/python/cpython/pull/9713
2020-12-14 20:46:18 +01:00
Petter Strandmark
28124e7bdf
Refs #4444 -- Added tests for handling broken pipe errors in WSGIServer.
2020-12-14 20:46:18 +01:00
Adam Johnson
cf2ca22a57
Ensured that registered checks accept keyword arguments.
2020-12-14 18:08:37 +01:00
Tim Graham
5a434677a7
Relaxed MemSize test for CockroachDB.
2020-12-14 12:28:38 +01:00
Tim Graham
1e7653117f
Refs #32178 -- Fixed test_mark_expected_failures_and_skips_call teardown.
...
Test isolation failure observed on CockroachDB and PostgreSQL.
2020-12-11 21:06:33 +01:00
sage
8d7085e0fd
Fixed #32252 -- Fixed __isnull=True on key transforms on SQLite and Oracle.
...
__isnull=True on key transforms should not match keys with NULL values.
2020-12-11 09:15:42 +01:00
Mariusz Felisiak
00a1d42bf0
Fixed isolation of test_runner.EmptyDefaultDatabaseTest.
...
This fixes test_runner.test_debug_sql.TestDebugSQL.
test_setupclass_exception when run in reverse.
2020-12-10 18:48:07 +01:00
Hasan Ramezani
275dd4ebba
Fixed #32178 -- Allowed database backends to skip tests and mark expected failures.
...
Co-authored-by: Tim Graham <timograham@gmail.com>
2020-12-10 18:00:57 +01:00
Mariusz Felisiak
5ce31d6a71
Fixed #32193 -- Deprecated MemcachedCache.
2020-12-09 21:27:32 +01:00
Florian Apolloner
98e05ccde4
Fixed #32233 -- Cleaned-up duplicate connection functionality.
2020-12-08 08:55:44 +01:00
Mariusz Felisiak
0f00560d45
Refs #32233 -- Added tests for nonexistent cache backend.
2020-12-08 08:54:54 +01:00
Mariusz Felisiak
30f2d1af03
Refs #32233 -- Added tests for nonexistent cache and databases aliases.
2020-12-08 08:54:50 +01:00
Tim Graham
406eb43112
Removed unused variable in runtests.py.
...
Unused since 1e72b1c5c1
.
2020-12-07 07:08:27 +01:00
Timo Ludwig
d8dfff2ab0
Fixed #32235 -- Made ReadOnlyPasswordHashField disabled by default.
2020-12-03 09:32:08 +01:00
Mariusz Felisiak
d746f28949
Refs #27095 -- Fixed test_contained_by_including_F_object when run in reverse.
...
Tests should not rely on auto PKs.
Test regression in 33403bf80f
.
2020-12-03 09:30:33 +01:00
Artur Beltsov
48b4bae983
Fixed #32179 -- Added JSONObject database function.
2020-12-02 09:30:50 +01:00
Tim Graham
371022a20d
Added SpatialFeatures.supports_tolerance_parameter.
2020-11-30 07:29:00 +01:00
Mariusz Felisiak
3828427f63
Refs #31978 -- Fixed hint in admin's password reset confirmation form for custom username fields.
...
Thanks Jaap Roes for the report.
2020-11-30 06:34:22 +01:00
Mariusz Felisiak
58740c0d7f
Refs #22909 -- Removed camelCasing in auth_tests.test_templates tests.
2020-11-30 06:34:22 +01:00
Adam Johnson
b9fd09d21b
Fixed #32227 -- Prevented crash when setUpTestData() errors with --debug-sql.
...
Thanks Mariusz Felisiak for the report.
2020-11-28 12:22:59 +01:00
Giannis Adamopoulos
7603036bd0
Fixed #21021 -- Changed BaseGeometryWidget's default geometry type to 'Geometry'.
2020-11-28 09:14:40 +01:00
Giannis Adamopoulos
9175a2cc32
Added assertion for geom_type in BaseGeometryWidget.get_context().
2020-11-28 09:14:40 +01:00
Mariusz Felisiak
931c6e982c
Refs #32230 -- Made LayerMapping support pathlib.Path.
2020-11-28 07:41:54 +01:00
Hasan Ramezani
b37be072a2
Fixed #32230 -- Made DataSource support pathlib.Path.
2020-11-28 07:36:19 +01:00
Ian Foote
3828879eee
Fixed #32220 -- Added durable argument to transaction.atomic().
2020-11-27 21:43:15 +01:00
Ian Foote
8b040e3cbb
Fixed #25534 , Fixed #31639 -- Added support for transform references in expressions.
...
Thanks Mariusz Felisiak and Simon Charette for reviews.
2020-11-27 20:42:04 +01:00
Hannes Ljungberg
33403bf80f
Refs #27095 -- Allowed (non-nested) arrays containing expressions for ArrayField lookups.
2020-11-26 10:57:58 +01:00
Hannes Ljungberg
755b327552
Added test for ArrayField's __contains lookup with subqueries.
2020-11-26 09:36:00 +01:00
sage
fe6e582421
Fixed #32203 -- Fixed QuerySet.values()/values_list() crash on key transforms with non-string values on SQLite.
...
Thanks Gordon Wrigley for the report.
2020-11-25 14:51:35 +01:00
sage
7408c4cd15
Refs #32203 -- Added tests for QuerySet.values()/values_list() on key transforms with non-trivial values.
2020-11-25 13:48:11 +01:00
Mariusz Felisiak
f5e5aac59e
Fixed #32224 -- Avoided suppressing connection errors in supports_json_field on SQLite.`
...
Regression in 6789ded0a6
.
Thanks Juan Garcia Alvite for the report.
2020-11-25 12:19:45 +01:00
Mariusz Felisiak
bec415b290
Added test for filtering JSONField key transforms with quoted strings.
2020-11-24 18:11:19 +01:00
Daniel Hahler
c70cd2a926
Refs #15053 -- Clarified debug message when skipping templates to avoid recursion.
2020-11-21 10:49:31 +01:00
Thibaud Colas
a1215a3237
Fixed #32053 -- Fixed accessibility issues on the 'Congrats' page.
...
- Add lang attribute.
- Use the same text for the page’s main heading, and title.
- Add underlines for all links in copy.
- Stop using h2 for link to the Django page.
- Use h1 for the main heading.
- Remove useless type attribute on style element.
- Remove grey text that fails contrast checks.
- Use a shade of grey that passes AAA contrast requirements.
- Stop using h4 for footer links.
- Add full stop in block-level links so VoiceOver correctly pauses
between runs of text.
- Hide main artwork for screen reader users.
- Update SVG icons markup to be screen-reader friendly.
- Switch options to be block-level links.
- Remove unused markup.
2020-11-20 19:18:07 +01:00
Florian Apolloner
d10425f9c7
Simplified MessageEncoder instantiation with default separators.
2020-11-20 10:27:09 +01:00
Hasan Ramezani
fe9c7ded29
Fixed #32200 -- Fixed grouping by ExpressionWrapper() with Q objects.
...
Thanks Gordon Wrigley for the report.
Regression in df32fd42b8
.
2020-11-19 21:00:04 +01:00
Carlton Gibson
ead37dfb58
Fixed #32202 -- Fixed autoreloader argument generation for Windows with Python 3.7-.
2020-11-19 12:07:15 +01:00
David-Wobrock
ba42569d5c
Fixed #31507 -- Added QuerySet.exists() optimizations to compound queries.
2020-11-16 20:29:13 +01:00
David-Wobrock
7b42d34646
Refs #27718 -- Doc'd and tested QuerySet.exists() for combined querysets.
...
Supported since 84c1826ded
.
2020-11-16 15:15:41 +01:00
Hasan Ramezani
4cce1d13cf
Fixed #32197 -- Improved error message when loading a database backend fails.
2020-11-16 06:05:03 +01:00
David-Wobrock
464a4c0c59
Fixed #31496 -- Fixed QuerySet.values()/values_list() crash on combined querysets ordered by annotations.
2020-11-14 10:22:09 +01:00
Nick Pope
477c800443
Changed docs and a code comment to use gender-neutral pronouns.
...
Follow up to e1b7723817
.
2020-11-13 22:26:30 +01:00
Nick Pope
fed8129276
Unified admin action description generation.
...
Actions added to AdminSite.actions would not have the first character
of their description capitalized.
Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2020-11-13 21:41:18 +01:00
manav014
f63f3cdf09
Fixed #29712 -- Made makemessages warn if locales have hyphens and skip them.
2020-11-13 09:25:42 +01:00
Tim Graham
8ed024b9b9
Refs #32120 -- Fixed test_add_inline_fk_index_update_data for DatabaseFeatures.indexes_foreign_keys.
...
This test creates an index with editor.add_index() so it's present
regardless of the database's behavior. Reverted the change from
ede9fac758
.
2020-11-13 06:17:13 +01:00
Nick Pope
0cbccaebeb
Simplified TimeFormat.g().
2020-11-12 15:19:17 +01:00
Sam
895f6e4992
Fixed #32149 -- Added support for years < 1000 to DateFormat.y().
2020-11-12 12:43:06 +01:00
MinchinWeb
f1585c54d0
Fixed #31216 -- Added support for colorama terminal colors on Windows.
...
Modern setups on Windows support terminal colors.
The colorama library may also be used, as an
alternative to the ANSICON library.
2020-11-11 14:27:10 +01:00
Artem Kosenko
b7f500396e
Fixed #31757 -- Adjusted system check for SECRET_KEY to warn about autogenerated default keys.
...
Thanks Nick Pope, René Fleschenberg, and Carlton Gibson for reviews.
2020-11-11 12:45:34 +01:00