Baptiste Mispelon
f47ba7e780
Fixed #30255 -- Fixed admindocs errors when rendering docstrings without leading newlines.
...
Used inspect.cleandoc() which implements PEP-257 instead of an internal
hook.
2019-11-29 12:47:42 +01:00
Mariusz Felisiak
e8fcdaad5c
Fixed #31021 -- Fixed proxy model permissions data migration crash with a multiple databases setup.
...
Regression in 98296f86b3
.
2019-11-29 08:23:01 +01:00
Jon Dufresne
86a0231e0a
Refs #23919 -- Replaced super(...) with super() in metaclasses.
2019-11-28 15:34:29 +01:00
Jon Dufresne
c8bd37a860
Fixed #31042 -- Removed AdminSeleniumTestCase.get_css_value() in favor of Selenium .is_displayed().
...
All instances of AdminSeleniumTestCase.get_css_value() were used to
inspect the display property.
2019-11-28 15:10:13 +01:00
Jon Dufresne
875e3ff4fd
Fixed #29892 -- Added .wait_page_loaded() in SeleniumTests.test_first_field_focus().
2019-11-28 11:22:19 +01:00
Jon Dufresne
f0ed38edf3
Refs #29892 -- Replaced Selenium .submit() shim with .click() on the submit button.
...
There is no WebDriver submit primitive. The Selenium project implements
it as a convenience only. The geckodriver developers recommend against
using it. Replace it with a real primitive, click on the submit button.
Fixes failing Seleninum test test_date_time_picker_shortcuts when using
the Firefox Selenium driver.
2019-11-28 09:24:19 +01:00
Johannes Hoppe
249a6190ae
Fixed #30975 -- Replaced custom get_select_option with Selenium's select_by_value.
2019-11-27 16:34:07 +01:00
Johannes Hoppe
69dbb6b708
Fixed #30973 -- Converted selenium tests wait_page_loaded to context manager.
2019-11-27 14:36:26 +01:00
Hasan Ramezani
8d32290279
Fixed #30425 -- Handled jinja2.TemplateSyntaxError when rendering a template.
...
Jinja raises jinja2.TemplateSyntaxError in render() not in
get_template() when it's in an included template.
2019-11-27 12:48:07 +01:00
Farhaan Bukhsh
1f817daa20
Fixed #30803 -- Allowed comma separators for milliseconds in django.utils.dateparse functions.
...
Co-Authored-By: Ben Wilber <benwilber@gmail.com>
2019-11-27 09:43:12 +01:00
Farhaan Bukhsh
42b23d1e79
Refs #30803 -- Allowed comma separators for decimal fractions in parse_duration().
2019-11-27 09:43:12 +01:00
Baptiste Mispelon
52936eface
Fixed #31031 -- Fixed data loss in admin changelist view when formset's prefix contains regex special chars.
...
Regression in b18650a263
.
2019-11-26 08:48:10 +01:00
Simon Charette
0290e01d5a
Fixed #31002 -- Fixed GIS lookups crash against a subquery annotation.
...
Thanks Vasileios Bouzas for the report.
2019-11-25 12:30:33 +01:00
John Bowen
29d8198841
Fixed #27914 -- Fixed serialization of nested classes in migrations.
2019-11-25 11:12:44 +01:00
John Bowen
8008795a38
Refs #23950 --- Moved test DeconstructibleInstances class to a module level.
...
DeconstructibleInstances was not importable from the asserted path.
2019-11-25 11:05:09 +01:00
Sergey Fedoseev
a5855c8f0f
Fixed #30996 -- Added AsWKB and AsWKT GIS functions.
2019-11-22 13:40:48 +01:00
Baptiste Mispelon
8929afb8ec
Fixed #9762 -- Made DateFormat.r() locale-independent.
...
Thanks to Antonio Melé for the original report all those years ago
and to all the contributors who helped along the way.
2019-11-22 12:41:53 +01:00
Baptiste Mispelon
76ec032712
Refs #26281 -- Added a helpful error message for an invalid "r" specifier to dateformat.format().
2019-11-22 12:32:30 +01:00
Simon Charette
379bf1a2d4
Fixed #8467 -- Prevented crash when adding existent m2m relation with an invalid type.
...
This was an issue anymore on backends that allows conflicts to be
ignored (Refs #19544 ) as long the provided values were coercible to the
expected type. However on the remaining backends that don't support
this feature, namely Oracle, this could still result in an
IntegrityError.
By attempting to coerce the provided values to the expected types in
Python beforehand we allow the existing value set intersection in
ManyRelatedManager._get_missing_target_ids to prevent the problematic
insertion attempts.
Thanks Baptiste Mispelon for triaging this old ticket against the
current state of the master branch.
2019-11-22 09:08:10 +01:00
Simon Charette
8cc711999a
Refs #8467 -- Added test for RelatedManager.add()/remove() with an invalid type.
2019-11-22 09:04:03 +01:00
Carlton Gibson
ee4a19053a
Fixed #31012 -- Reverted "Fixed #29056 -- Fixed HTML5 validation of required SelectDateWidget."
...
This reverts commit f038214d91
.
The initial issue was incorrect. Django 2.2, and before, did not
generate invalid HTML as reported. With f03821 in place invalid HTML
was generated.
Thanks to Kevin Brown for follow-up report and investigation.
2019-11-21 20:53:31 +01:00
Farhaan Bukhsh
664c98f1f8
Fixed #30413 -- Fixed test database signature on SQLite when test database name is provided.
...
Previously, the same signature was created for multiple in-memory
databases on SQLite when they had tests databases names
DATABASES['TEST']['NAME'].
2019-11-21 19:50:24 +01:00
Simon Charette
f97a6123c0
Refs #25367 -- Made Query.build_filter() raise TypeError on non-conditional expressions.
2019-11-21 11:56:35 +01:00
Simon Charette
e9a0e1d4f6
Fixed #30484 -- Added conditional expressions support to CheckConstraint.
2019-11-21 11:56:35 +01:00
Simon Charette
306b687520
Refs #11964 -- Removed SimpleCol in favor of Query(alias_cols).
...
This prevent having to pass simple_col through multiple function calls
by defining whether or not references should be resolved with aliases
at the Query level.
2019-11-21 11:56:35 +01:00
Jon Dufresne
f5ebdfce5c
Fixed #25388 -- Added an option to allow disabling of migrations during test database creation.
2019-11-20 20:42:38 +01:00
Carlton Gibson
36453526d3
Pinned asgiref version.
2019-11-20 14:57:08 +01:00
Hasan Ramezani
0284a26af9
Fixed #30981 -- Fixed admin changelist crash when using F() or OrderBy() expressions in admin_order_field.
2019-11-19 15:40:04 +01:00
Daniel Izquierdo
89abecc75d
Fixed #27272 -- Added an on_delete RESTRICT handler to allow cascading deletions while protecting direct ones.
2019-11-19 10:55:05 +01:00
Caio Ariede
555bebe774
Fixed #30987 -- Added models.PositiveBigIntegerField.
2019-11-19 09:34:11 +01:00
Jon Dufresne
aa12cf07c9
Removed unnecessary numeric indexes in format strings.
2019-11-19 08:29:47 +01:00
Sergey Fedoseev
f95b59a1b3
Fixed #30994 -- Added Oracle support for AsGeoJSON GIS function.
2019-11-18 15:32:44 +01:00
Jon Dufresne
7f0946298e
Replaced encode() usage with bytes literals.
2019-11-18 15:31:42 +01:00
Jon Dufresne
57a3d96ff5
Replaced unnecessary str()/bytes() calls with literals.
2019-11-18 15:30:10 +01:00
Jon Dufresne
e649d691f8
Removed unnecessary parentheses in various code.
2019-11-18 15:25:59 +01:00
Simon Charette
11e327a3ff
Fixed #30988 -- Deprecated the InvalidQuery exception.
...
It was barely documented without pointers at its defining location and
was abused to prevent misuse of the QuerySet field deferring feature.
2019-11-18 14:06:51 +01:00
Tim Graham
9100c664db
Relaxed some query ordering assertions in tests.
...
It accounts for differences seen on cockroachdb.
2019-11-18 12:32:37 +01:00
Baptiste Mispelon
18e10740a4
Refs #30990 -- Added test for 'z' date format with a leap year.
2019-11-18 11:30:18 +01:00
Mariusz Felisiak
8685e764ef
Fixed #30986 -- Fixed queryset crash when filtering against boolean RawSQL expressions on Oracle.
2019-11-18 08:50:09 +01:00
Tim Graham
22a7a406c9
Removed hardcoded pk in view_tests.tests.test_defaults.
2019-11-18 08:46:39 +01:00
Tim Graham
7f61b6b039
Removed hardcoded pk in test_pk_set_on_repeated_add_remove.
...
Follow up to bed4a1527b
.
2019-11-18 08:46:39 +01:00
Mariusz Felisiak
4527d5db0f
Refs #29808 -- Fixed MigrateTests.test_migrate_fake_initial_case_insensitive() crash on Oracle.
2019-11-15 21:05:42 +01:00
Hasan Ramezani
530dd193f2
Fixed #29808 -- Fixed initial migration detection when identifiers are case-insensitive.
...
Thanks Simon Charette for the review.
2019-11-15 09:01:30 +01:00
Dulmandakh
24b9f50823
Fixed #29916 -- Added lower_inc, lower_inf, upper_inc, and upper_inf lookups for RangeFields.
...
Co-Authored-By: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2019-11-14 22:27:29 +01:00
daniel a rios
efc3e32d6d
Fixed #30759 -- Made cache.delete() return whether it succeeded.
...
Thanks Simon Charette for the review.
2019-11-14 11:14:11 +01:00
Mariusz Felisiak
ca0d50f34a
Fixed random auth_tests.test_tokens.TokenGeneratorTest.test_10265 failures.
...
Random failures depended on the current timestamp.
2019-11-13 14:22:23 +01:00
Mariusz Felisiak
3b4b36fb1d
Moved MockedPasswordResetTokenGenerator outside of TokenGeneratorTest.test_timeout().
2019-11-13 14:22:23 +01:00
George Marshall
8be79984dc
Fixed #30971 -- Prevented Query.resolve_lookup_value() from coercing list values to tuples.
...
Regression in 8a281aa7fe
.
2019-11-13 08:27:26 +01:00
Hasan Ramezani
4b78546ef1
Fixed #30405 -- Fixed source code mismatch crash in ExceptionReporter.
2019-11-12 11:31:12 +01:00
Hannes Ljungberg
6e2f05b2e3
Fixed #30967 -- Fixed TrigramTest failures on PostgreSQL 12+.
2019-11-11 12:58:49 +01:00