1
0
mirror of https://github.com/django/django.git synced 2025-03-20 14:20:44 +00:00

19570 Commits

Author SHA1 Message Date
Giannis Terzopoulos
73df8b54a2 Fixed #35044 -- Avoided clearing reverse relations and private fields when accessing deferred fields.
Regression in a7b5ad8b19a08d7d57302ece74f6e26d2887fd9f for reverse
relations and possibly in 123b1d3fcf79f091573c40be6da7113a6ef35b62 for
private fields.
2024-03-08 11:09:54 +01:00
Giannis Terzopoulos
74f7fe3f3d Optimized Model.refresh_from_db(fields=...) by using a set. 2024-03-08 10:33:18 +01:00
Ben Cail
1570ef02f3 Fixed #35223 -- Made Model.full_clean() ignore fields with db_default when validating empty values.
Thanks Brian Ibbotson for the report.

Regression in 7414704e88d73dafbcfbb85f9bc54cb6111439d3.
2024-03-08 05:55:25 +01:00
Nick Pope
1669e54965
Refs #30397 -- Optimized interpolation of index and constraint names a bit more. 2024-03-08 05:49:32 +01:00
Dingning
549320946d Fixed #35030 -- Made django.contrib.auth decorators to work with async functions. 2024-03-07 09:59:33 +01:00
Mariusz Felisiak
1fffa4af12
Fixed typo in django/db/models/expressions.py. 2024-03-07 08:40:24 +01:00
Adam Johnson
9e35c8b2e3
Refs #30397 -- Optimized interpolation of index and constraint names a bit. 2024-03-07 05:59:13 +01:00
Michail Chatzis
4426b1a72d Fixed #35021 -- Fixed capturing queries when using client-side parameters binding with psycopg 3+. 2024-03-06 11:24:58 +01:00
Adam Johnson
eff21d8e7a Fixed #35252 -- Optimized _route_to_regex().
co-authored-by: Nick Pope <nick@nickpope.me.uk>
2024-03-05 13:09:10 +01:00
Adam Johnson
ab22b7c65f
Fixed #35266 -- Deferred formatting in RelatedField._check_clashes(). 2024-03-04 20:26:23 +01:00
Adam Johnson
71d5eafb05 Fixed #35250 -- Made URL system checks use uncompiled regexes. 2024-03-02 19:54:21 +01:00
Adam Johnson
5dfcf343cd Refs #35250 -- Avoided double conversion in RoutePattern. 2024-03-02 19:54:21 +01:00
Sarah Boyce
fad334e1a9 Refs #33497 -- Added connection pool support for PostgreSQL.
Co-authored-by: Florian Apolloner <florian@apolloner.eu>
Co-authored-by: Ran Benita <ran@unusedvar.com>
2024-03-01 09:01:18 +01:00
Florian Apolloner
bcccea3ef3 Made runserver close database connections from migration checks. 2024-03-01 08:13:59 +01:00
Simon Charette
daf7d482db Refs #35234 -- Deprecated CheckConstraint.check in favor of .condition.
Once the deprecation period ends CheckConstraint.check() can become the
documented method that performs system checks for BaseConstraint
subclasses.
2024-03-01 07:15:32 +01:00
Simon Charette
f82c67aa21 Fixed #35234 -- Added system checks for invalid model field names in ExclusionConstraint.expressions. 2024-02-29 12:22:17 +01:00
Simon Charette
0fb104dda2 Refs #35234 -- Moved constraint system checks to Check/UniqueConstraint methods. 2024-02-29 10:38:19 +01:00
Shafiya Adzhani
a738281265 Fixed #35198 -- Fixed facet filters crash on querysets with no primary key.
Thanks Simon Alef for the report.

Regression in 868e2fcddae6720d5713924a785339d1665f1bb9.
2024-02-29 10:01:18 +01:00
Adam Zapletal
107aa76bcf Fixed #29022 -- Fixed handling protocol-relative URLs in ManifestStaticFilesStorage when STATIC_URL is set to /. 2024-02-28 06:24:24 +01:00
David Wobrock
ef2434f850
Refs #32114 -- Fixed test crash on non-picklable objects in subtests when PickleError is raised.
Related to the https://github.com/python/cpython/issues/73373.

Follow up to c09e8f5fd8f977bf16e9ec5d11b370151fc81ea8.
2024-02-26 17:18:48 +01:00
Florian Apolloner
18d79033b9 Refs #34200 -- Removed unnecessary check in DatabaseWrapper.ensure_role() on PostgreSQL.
ensure_role() is only called in init_connection_state() where a new
connection is established.
2024-02-26 10:53:47 +01:00
Adam Johnson
e65deb7d14
Fixed #35246 -- Made Field.unique a cached property.
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
2024-02-26 06:20:16 +01:00
Adam Johnson
73d5eb8084 Fixed #35241 -- Cached model's full parent list.
co-authored-by: Keryn Knight <keryn@kerynknight.com>
co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
co-authored-by: David Smith <smithdc@gmail.com>
co-authored-by: Paolo Melchiorre <paolo@melchiorre.org>
2024-02-26 05:38:31 +01:00
Salvo Polizzi
6e1ece7ed5 Fixed #35090 -- Deprecated registering URL converters with the same name. 2024-02-23 15:54:49 +01:00
Florian Apolloner
50e95ad536 Simplified using DATABASES["OPTIONS"].
DATABASES["OPTIONS"] are always configured.
2024-02-23 07:49:43 +01:00
erosselli
cfecac27de Fixed #35140 -- Increased font size in debug views. 2024-02-23 06:44:16 +01:00
Sulabh Katila
eceb5e2eea
Fixed #34806 -- Made cached_db session backend resilient to cache write errors.
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
2024-02-21 21:51:58 -03:00
David Wobrock
c09e8f5fd8 Fixed #32114 -- Fixed parallel test crash on non-picklable objects in subtests. 2024-02-21 12:04:03 +01:00
Adam Johnson
98e6f2396c Fixed #35237 -- Merged system checks for admin actions. 2024-02-21 05:25:25 +01:00
AlexCLeduc
a084c5d35a Fixed #35238 -- Fixed database serialization crash when base managers use prefetch_related().
Regression in 139135627650ed6aaaf4c755b82c3bd43f2b8f51
following deprecation in eedbf930287cb72e9afab1f7208c24b1146b0c4ec.
2024-02-20 22:14:17 +01:00
Adam Zapletal
eb2d49b734 Fixed #23759 -- Preserved all file extensions in Storage.get_available_name(). 2024-02-20 21:06:39 +01:00
Mariusz Felisiak
3426a5c33c
Refs #34900 -- Fixed CommandTypes.test_help_default_options_with_custom_arguments test on Python 3.13+.
c4a2e8a2c5
2024-02-20 20:59:26 +01:00
Fabian Braun
e626716c28 Fixed #34429 -- Allowed setting unusable passwords for users in the auth forms.
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
2024-02-20 12:13:32 -03:00
Fabian Braun
f64c528c17 Refs #34429 -- Created SetPasswordMixin to reuse password validation logic in auth forms.
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
2024-02-20 10:50:49 -03:00
Adam Johnson
31314980be Fixed #35236 -- Used Field.attname/column attributes instead of get_attname()/get_attname_column(). 2024-02-20 11:34:00 +01:00
d9pouces
e0496b2e9a
Used <span> instead of <div> in admin theme button.
<div> is not allowed as child of <button>.
2024-02-20 10:01:45 +01:00
Mariusz Felisiak
5f637a8a8d
Fixed #35226 -- Reallowed executing queries for dynamically created connections.
Regression in 8fb0be3500cc7519a56985b1b6f415d75ac6fedb.

Thanks Florian Apolloner for the report.
2024-02-19 18:34:18 +01:00
Adam Johnson
f65f8ab84e Refs #28011 -- Removed ForeignObjectRel.is_hidden(). 2024-02-19 12:22:46 +01:00
Adam Johnson
6002df0671 Fixed #35224 -- Made GenericForeignKey inherit from Field. 2024-02-19 09:56:27 +01:00
Albert Defler
26aae56144 Refs #34060 -- Fixed JSONField __exact lookup for primitivies on Oracle 21c+.
Regression in c991602ce5798385261381025c06698d7fd30dc5.

Co-Authored-By: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2024-02-19 08:28:42 +01:00
Adam Johnson
f25d84f61a Fixed #35232 -- Cached model's Options.verbose_name_raw. 2024-02-19 06:05:52 +01:00
Adam Johnson
28a3fbe004
Fixed #35229 -- Made URL custom error handler check run once. 2024-02-19 05:58:37 +01:00
Adam Johnson
5e80390add
Fixed #35230 -- Added cached ForeignObjectRel.accessor_name. 2024-02-19 05:47:12 +01:00
Mariusz Felisiak
d1be05b3e9
Fixed #35187 -- Fixed @sensitive_variables/sensitive_post_parameters decorators crash with .pyc-only builds.
Thanks Jon Janzen for the implementation idea.

Thanks Marcus Hoffmann for the report.

Regression in 38e391e95fe5258bc6d2467332dc9cd44ce6ba52.
2024-02-17 08:15:59 +01:00
Aaron Linville
7a05b8a2fa Fixed #24018 -- Allowed setting pragma options on SQLite. 2024-02-16 12:59:19 +01:00
ontowhee
66e47ac69a Fixed #29725 -- Removed unnecessary join in QuerySet.count() and exists() on a many to many relation.
Co-Authored-By: Shiwei Chen <april.chen.0615@gmail.com>
2024-02-16 08:57:16 +01:00
Simon Charette
0d8fbe2ade Refs #34060 -- Fixed crash when filtering against literal JSON with psycopg2. 2024-02-16 07:40:33 +01:00
Albert Defler
c991602ce5 Fixed #34060 -- Fixed migrations crash when adding check constraints with JSONField __exact lookup on Oracle. 2024-02-15 13:57:58 +01:00
Shafiya Adzhani
22285d366c Fixed #33037 -- Fixed Trunc() with offset timezones on MySQL, SQLite, Oracle. 2024-02-15 10:02:57 +01:00
Mariusz Felisiak
3cadeea077
Refs #30686 -- Removed unused regexes in django.utils.text.
Unused since 6ee37ada3241ed263d8d1c2901b030d964cbd161.
2024-02-15 08:39:14 +01:00