Commit Graph

28177 Commits

Author SHA1 Message Date
David Smith 2014319159
Updated iTunes podcast format link in syndication docs. 2020-04-20 08:10:13 +02:00
Jon Dufresne fb21625270
Refs #30165 -- Removed obsolete doc references to deprecated ugettext() & co.
The u-prefixed variants were removed from the documentation in
6eb4996672.
2020-04-20 07:57:24 +02:00
Jon Dufresne 5673d4b102
Fixed #31477 -- Removed "using" argument from DatabaseOperations.execute_sql_flush(). 2020-04-20 07:49:35 +02:00
Jon Dufresne 661e39c8d5 Fixed #24559 -- Made MigrationLoader.load_disk() catch more specific ModuleNotFoundError.
Avoids inspecting the exception message, which is not considered a
stable API and can change across Python versions.

ModuleNotFoundError was introduced in Python 3.6. It is a subclass of
ImportError that is raised when the imported module does not exist. It
is not raised for other errors that can occur during an import. This
exception instance has the property "name" which holds the name of
module that failed to import.
2020-04-20 07:22:20 +02:00
Tom Forbes 141ab6bc6d Refs #29069 -- Added test for calling request_finished signal by static file responses.
Fixed in 41a3b3d186.
2020-04-20 06:17:57 +02:00
Jon Dufresne 537d422942
Simplified LongNameTest.test_sequence_name_length_limits_flush() with execute_sql_flush(). 2020-04-18 20:48:30 +02:00
hashlash dfbd9ca065 Fixed #30311 -- Restored ability to override global admin actions. 2020-04-17 20:23:00 +02:00
Jon Dufresne 75410228df Fixed #31473 -- Made sql_flush() use RESTART IDENTITY to reset sequences on PostgreSQL.
The sql_flush() positional argument sequences is replaced by the boolean
keyword-only argument reset_sequences. This ensures that the old
function signature can't be used by mistake when upgrading Django. When
the new argument is True, the sequences of the truncated tables will
reset. Using a single boolean value, rather than a list, allows making a
binary yes/no choice as to whether to reset all sequences rather than a
working on a completely different set.
2020-04-17 11:57:24 +02:00
Jon Dufresne 8005829bb9 Simplified DatabaseOperations.sql_flush() on Oracle and PostgreSQL.
Added early return to decrease an indentation level.
2020-04-17 10:46:19 +02:00
Jon Dufresne 8bcca47e83 Added test coverage for DatabaseOperations.sql_flush(). 2020-04-17 09:52:43 +02:00
Mariusz Felisiak eeab63e57e
Refs #26552 -- Made reloading the database for tests check only loaded tables constraints. 2020-04-17 08:14:27 +02:00
Mariusz Felisiak 4c9886085b
Refs #31351 -- Made partial constraints tests use required_db_features.
This will notably silence the warnings issued when running the test
suite on MySQL and MariaDB.
2020-04-17 07:45:52 +02:00
Hasan Ramezani 7b31ba541f Fixed #29329 -- Made datetime logging from runserver more consistent.
Setting default_msec_format=None will make it the same, unfortunately
it's not supported by Python, see https://bugs.python.org/issue40300.
2020-04-16 12:55:53 +02:00
Hasan Ramezani 96c6f9c61c Fixed #31441 -- Ensured TabluarInline expands when child inputs have errors. 2020-04-16 12:17:49 +02:00
Hasan Ramezani b4e7bf5284 Refs #31441 -- Added red border to inputs with errors for TabluarInline. 2020-04-16 12:17:49 +02:00
Nick Pope 058b38b43e
Improved message example in admin actions documentation.
Avoid partial string construction and make use of ``ngettext`` to show
example of how to handle plural variants with translations. Also make
use of ``messages.SUCCESS`` to highlight customizing the style of the
message - in this case it better fits what the message is conveying.
2020-04-16 11:26:33 +02:00
Nick Pope daabb102c0 Fixed #31470 -- Fixed fieldset admin CSS to prevent overflowing <pre> elements.
Co-Authored-By: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2020-04-16 10:47:42 +02:00
Author: Mads Jensen 6461583b6c Removed unused __str__() methods in tests models.
Co-Authored-By: Mariusz Felisiak <felisiak.mariusz@gmail.com>
Co-Authored-By: Hasan Ramezani <hasan.r67@gmail.com>
2020-04-15 20:20:32 +02:00
Mariusz Felisiak f1a808a502 Used :rfc: role in various docs. 2020-04-15 18:31:30 +02:00
Claude Paroz 71c4fb7beb Refs #27468 -- Changed default Signer algorithm to SHA-256. 2020-04-15 12:49:14 +02:00
Adam Johnson 4bb33bb074 Fixed #31459 -- Fixed handling invalid indentifiers in URL path conversion.
This patch adjusted existing tests that used invalid identifiers.
2020-04-15 11:29:35 +02:00
sobolevn 578c03b276 Fixed #31223 -- Added __class_getitem__() to Manager and QuerySet. 2020-04-15 11:26:11 +02:00
Mariusz Felisiak fc0b48d2e7
Fixed typo in docs/ref/templates/builtins.txt. 2020-04-15 10:41:19 +02:00
infosrabah 25afe59d34 Fixed #31268 -- Updated Algerian Arabic (ar_DZ) locale formats. 2020-04-15 09:51:56 +02:00
Ichlasul Affan 3e7c39f710 Fixed #31451 -- Made settings cleansing work with list and tuple settings. 2020-04-15 09:18:40 +02:00
007 d51c50d836 Fixed #31462 -- Allowed overriding autocomplete/raw_id_fields/filter widgets for ManyToManyFields with formfield_overrides. 2020-04-15 08:33:40 +02:00
Adam Johnson 5b884d45ac Fixed #29501 -- Allowed dbshell to pass options to underlying tool. 2020-04-14 14:02:51 +01:00
Adam Johnson 8e8c3f964e Refs #29501 -- Allowed customizing exit status for management commands. 2020-04-14 13:22:47 +02:00
Adam Johnson 6cad911674 Refs #29501 -- Simplified BaseCommand.run_from_argv() a bit. 2020-04-14 13:22:47 +02:00
Adam Johnson 8bd9000a7d Refs #29501 -- Made dbshell catch more specific FileNotFoundError. 2020-04-14 13:22:47 +02:00
Mariusz Felisiak 8189976663 Refs #29501 -- Added test for missing dbshell executable. 2020-04-14 13:22:46 +02:00
Sergey Fedoseev b9e2355eb0 Fixed #31196 -- Added support for PostGIS 3. 2020-04-14 13:19:59 +02:00
Claude Paroz a6b4c07b6e Refs #31196 -- Installed postgis_raster extension on PostGIS 3+. 2020-04-14 09:34:01 +02:00
Mariusz Felisiak cc70a0343e
Fixed term warning on Sphinx 3.0.1+.
"term" role became case sensitive in Sphinx 3.0.1.
2020-04-14 09:32:09 +02:00
Tim Graham ee37d2070a
Sorted imports in docs/_ext/djangodocs.py. 2020-04-14 07:31:36 +02:00
Andrew Godwin b5ad450fa6
Refs #31224 -- Removed incorrect @sync_to_async(thread_sensitive=True) example.
It does not support thread_sensitive when used as a decorator, yet.
2020-04-14 07:26:16 +02:00
Ichlasul Affan 53d229ff63 Fixed #31351 -- Added system checks for partial indexes and unique constraints support. 2020-04-10 12:00:27 +02:00
Mariusz Felisiak e8d3088925 Refs #31055 -- Allowed database queries in invalid_models_tests.test_models.FieldNamesTests. 2020-04-10 11:54:14 +02:00
Simon Charette f5ede1cb6d Refs #28305 -- Consolidated field referencing detection in migrations.
This moves all the field referencing resolution methods to shared
functions instead of duplicating efforts amongst state_forwards and
references methods.
2020-04-10 09:19:16 +02:00
David Smith 734fde7714 Refs #10427 -- Corrected BoundField.css_classes() signature in docs. 2020-04-10 07:37:54 +02:00
David Smith c8c9dbfc63 Completed test coverage for BoundField.css_classes(). 2020-04-10 07:37:54 +02:00
David Smith a350bfa6f4 Fixed #13009 -- Added BoundField.widget_type property. 2020-04-10 07:11:14 +02:00
Shrikrishna Singh ab903fe304 Mentioned non_field_errors in form validation docs. 2020-04-09 12:37:36 +02:00
Carlton Gibson ed274a4ae4 Fixed #31407 -- Fixed unawaited coroutine warning for Python 3.8+.
Co-authored-by: Mark Korput <dr.theman@gmail.com>
2020-04-09 12:35:19 +02:00
Daniel Hahler 377018b6ff Fixed #30779 -- Improved selection of filenames in technical 500 debug page. 2020-04-09 11:28:26 +02:00
Mariusz Felisiak 9cab261427
Refs #31411 -- Used RENAME COLUMN on MySQL 8.0.4+.
MySQL 8.0.3 added support for this syntax but also imposed a
restriction against ALTER TABLE RENAME on tables in a foreign key
relationship if a LOCK TABLES was active which has been lifted in MySQL
8.0.4+.
2020-04-09 11:16:28 +02:00
Simon Charette 8b7b19f6c9 Replaced ModelTuple by a model resolving function and bare tuples.
ModelTuple made handling of app_label=None easier but it isn't necessary
anymore.
2020-04-09 10:08:06 +02:00
Simon Charette 5ca5178a78 Replaced Operation._get_model_tuple() by ModelTuple.from_model().
This method predated the introduction of ModelTuple and had a single use.
2020-04-09 10:08:06 +02:00
Simon Charette 8069526ce3 Made Operation.references_model/references_field require app_label.
This will allow them to drop a ton of logic to deal with null
app_label.
2020-04-09 10:08:06 +02:00
Simon Charette 25bf15c0da Refs #22608 -- Made app_label required when optimizing migrations.
This paved the way for the removal of lot of logic when app_label was
not specified.
2020-04-09 10:08:02 +02:00