Zackary Troop
30f8642f2e
Fixed #29350 -- Fix get_primary_key_column() method in sqlite3 backend
...
Thanks Tim Graham and Mariusz Felisiak for the reviews.
2018-04-28 12:01:45 +02:00
priyanshsaxena
6b3d292043
Fixed #29015 -- Added an exception if the PostgreSQL database name is too long.
2018-04-27 21:37:42 -04:00
Oscar Esgalha
6d1f576945
Fixed #29367 -- Fixed model state on objects with a primary key created with QuerySet.bulk_create().
2018-04-27 17:57:38 -04:00
Nicolas Noé
3246ad1065
Fixed #27480 -- Added cache.touch().
2018-04-27 17:48:35 -04:00
Claude Paroz
8e960c5aba
Removed urllib2 reference in file storage tests
2018-04-27 14:02:39 +02:00
Claude Paroz
a9189d27ef
Fixed #29353 -- Made StaticFilesHandler return a 404 response when settings.DEBUG is False
2018-04-25 10:38:13 +02:00
Tim Graham
c591bc3cce
Fixed "invalid escape sequence" warning in runtests.py.
2018-04-24 12:06:04 -04:00
Claude Paroz
3aae43d800
Fixed #28973 -- Silenced copying/linking messages in collectstatic's default verbosity.
2018-04-23 23:04:02 -04:00
François Freitag
d1413c5d70
Refs #28312 -- Added an optimized __bool__() to ModelChoiceIterator.
...
COUNT is more expensive than EXISTS; use the latter when possible.
2018-04-23 13:03:07 -04:00
François Freitag
3fca95e1ad
Fixed #28312 -- Made ModelChoiceIterator.__len__() more memory-efficient.
...
Instead of loading all QuerySet results in memory, count the number of
entries. This adds an extra query when list() or tuple() is called on the
choices (because both call __len__() then __iter__()) but uses less
memory since the QuerySet results won't be cached. In most cases, the
choices will only be iterated on, meaning that __len__() won't be called
and only one query will be executed.
2018-04-23 12:39:43 -04:00
Hasan Ramezani
b33f10d8cc
Refs #29131 -- Made ArrayField error messages index from 1 instead of 0.
2018-04-22 22:18:46 -04:00
Hasan Ramezani
dd68b51e1d
Fixed #29295 -- Fixed management command crash when using subparsers.
...
Thanks Tim Graham for the fix.
2018-04-21 17:33:17 -04:00
orlnub123
21420096c4
Fixed #29247 -- Allowed blank model field choice to be defined in nested choices.
2018-04-20 11:06:14 -04:00
Tim Graham
e35004966b
Moved tests for model Field.get_choices().
2018-04-20 11:05:25 -04:00
Adnan Umer
534d8d875e
Fixed #28600 -- Added prefetch_related() support to RawQuerySet.
2018-04-19 13:48:27 -04:00
Adnan Umer
f2026ca5e2
Fixed #29337 -- Added __len__() & __bool__() to RawQuerySet.
2018-04-19 12:46:31 -04:00
Adnan Umer
ec0319ff82
Fixed #29339 -- Added result caching to RawQuerySet.
2018-04-19 11:35:49 -04:00
Tom
c1c163b427
Fixed #28574 -- Added QuerySet.explain().
2018-04-19 10:52:19 -04:00
Nick Pope
df90e462d9
Fixed #29212 -- Doc'd redirect loop if @permission_required used with redirect_authenticated_user.
2018-04-19 10:21:24 -04:00
Tim Graham
a917a5601f
Refs #23890 -- Removed numpy deprecation warning silencing.
...
Obsolete since numpy 1.12.0.
2018-04-18 22:09:26 -04:00
Tim Graham
7a22d9f751
Fixed a test failure with the latest GeoIP2 database.
2018-04-17 21:30:05 -04:00
Brett Cannon
64b74804c5
Fixed #29334 -- Updated pypi.python.org URLs to pypi.org.
2018-04-17 20:24:27 -04:00
Jon Dufresne
b3cffde555
Fixed #29324 -- Made Settings raise ImproperlyConfigured if SECRET_KEY is accessed and not set.
2018-04-17 13:02:05 -04:00
Tim Graham
fff689ed98
Added a test for a settings error message.
2018-04-17 12:55:26 -04:00
Chris Jerdonek
fdc936c913
Fixed #29253 -- Made method_decorator(list) copy attributes.
2018-04-16 13:38:37 -04:00
Tim Graham
a480ef89ad
Fixed inconsistent formatting in tests/modeladmin/test_checks.py.
2018-04-16 13:35:40 -04:00
Chris Jerdonek
09f1f0387b
Updated decorators test to use subTest().
2018-04-16 12:48:01 -04:00
Daniel Miller
60156750f6
Fixed #29330 -- Fixed crash when pickling BaseExpression.
...
Regression in cfff2af02b
.
2018-04-16 10:15:13 -04:00
Alex Gaynor
9a56b4b13e
Fixed #27863 -- Added support for the SameSite cookie flag.
...
Thanks Alex Gaynor for contributing to the patch.
2018-04-13 20:58:31 -04:00
Matthias Kestenholz
13efbb233a
Fixed #29322 -- Made admin check all ModelAdmin fieldsets for duplicates.
2018-04-13 11:08:30 -04:00
Mariusz Felisiak
0b66c3b442
Fixed #29286 -- Fixed column mismatch crash with QuerySet.values() or values_list() after combining an annotated and unannotated queryset with union(), difference(), or intersection().
...
Regression in a0c03c62a8
.
Thanks Tim Graham and Carlton Gibson for reviews.
2018-04-13 12:15:52 +02:00
Flávio Juvenal
e1f13f1551
Fixed #29320 -- Added an exception when an annotation alias matches a ForeignKey attname.
2018-04-12 21:15:40 -04:00
Tim Graham
78f8b80f9b
Fixed schema test failure when running tests in reverse.
...
Follow up to 003334f8af
.
2018-04-12 13:59:02 -04:00
Paul Donohue
33a0b7ac81
Fixed #29296 -- Fixed crashes in admindocs when a view is a callable object.
2018-04-12 13:11:08 -04:00
Jeremy Bowman
ee17bb8a67
Fixed #29193 -- Prevented unnecessary foreign key drops when altering a unique field.
...
Stopped dropping and recreating foreign key constraints on other fields
in the same table as the one which is actually being altered in an
AlterField operation.
Regression in c3e0adcad8
.
2018-04-11 23:17:11 -04:00
Jeremy Bowman
003334f8af
Tested altering a unique field when a reverse M2M relation exists.
2018-04-11 23:17:11 -04:00
David Foster
c3055242c8
Fixed #29301 -- Made management command --help display command-specific arguments before common arguments.
2018-04-11 13:52:20 -04:00
Alasdair Nicol
65c44a5c1d
Fixed #29307 -- Fixed inspectdb import paths for django.contrib.postgres fields.
...
Thanks erindy for the report.
2018-04-10 09:33:05 -04:00
Vinay Karanam
6a1957bb98
Fixed #28950 -- Fixed ArrayField.has_changed() for empty values.
2018-04-07 17:53:33 -04:00
Vinay Karanam
e67dc0fbb2
Added tests for ArrayField.has_changed().
2018-04-07 17:48:29 -04:00
Faheel Ahmad
5d4d62bf4f
Fixed #29248 -- Renamed admin CSS class field-box to fieldBox.
2018-04-05 10:55:36 -04:00
Jon Dufresne
be6ca89396
Fixed #27991 -- Added obj arg to InlineModelAdmin.has_add_permission().
...
Thanks Vladimir Ivanov for the initial patch.
2018-04-04 19:21:50 -04:00
Jirka Vejrazka
6148dda72f
Fixed #29288 -- Made {% widthratio %} assign to as var if an exception occurs.
2018-04-04 14:03:16 -04:00
safu9
9fd9f8bbb2
Fixed #29284 -- Made ImageField render with accept="image/*"' HTML attribute.
2018-04-04 13:16:03 -04:00
Mads Jensen
9c651641f1
Added additional AdminPasswordChangeForm tests.
2018-04-04 11:25:28 -04:00
Dmitry Dygalo
c979c0a2b8
Fixed #25718 -- Made a JSONField lookup value of None match keys that have a null value.
2018-04-04 10:53:46 -04:00
Mariusz Felisiak
816b386d41
Refs #24791 -- Made PostgreSQL's nodb connection use first PostgresSQL db when 'postgres' db isn't available.
...
Thanks Tim Graham and Claude Paroz for reviews.
2018-04-03 22:21:47 +02:00
Mariusz Felisiak
55cc26941a
Refs #28643 -- Added Repeat database function.
...
Thanks Tim Graham and Nick Pope for reviews.
2018-04-03 19:36:12 +02:00
Mariusz Felisiak
6141c752fe
Fixed #29251 -- Added bytes to str conversion in LPad/RPad database functions on MySQL.
...
Thanks Tim Graham for the review.
2018-04-03 18:24:04 +02:00
Tim Graham
4f7467b690
Refs #28577 -- Added check for HStoreField to prevent mutable default.
2018-04-03 11:12:56 -04:00
Jon Dufresne
167d98528a
Refs #27728 -- Fixed BytesWarning in admin_views tests.
2018-04-03 10:11:35 -04:00
Jon Dufresne
f3b1c3bd06
Refs #23406 -- Fixed "invalid escape sequence" warning in migrations test.
2018-04-02 22:54:05 -04:00
Claude Paroz
2a2ed0e70a
Fixed #29116 -- Fixed OpenLayersWidget deserialization ignoring the widget map's SRID.
...
Regression in 6ecccad711
.
2018-04-02 10:20:00 -04:00
Claude Paroz
f3b69f9757
Fixed #29273 -- Prevented initial selection of empty choice in multiple choice widgets.
...
Regression in b52c73008a
.
2018-04-02 08:52:53 -04:00
Dan Watson
e163effecc
Fixed #29279 -- Added renderer argument to ModelForm.
2018-03-31 20:45:59 -04:00
Chris Lamb
84ad721bd9
Fixed #29275 -- Made assertFormError() output "(actual errors: none)" instead of "(actual errors: )".
2018-03-31 18:35:45 -04:00
Malte Gerth
874977d388
Fixed #29270 -- Fixed UserChangeForm crash if password field is excluded.
2018-03-29 15:25:54 -04:00
Mads Jensen
c59aa9e6aa
Added test for combining Q objects with non-Q objects.
2018-03-29 13:58:55 -04:00
Simon Charette
2156565b5b
Fixed #29245 -- Made autodetector treat field renames + db_column addition as RenameField.
2018-03-28 12:43:43 -04:00
Abeer Upadhyay
1bf4646f91
Fixed #29258 -- Added type checking for login()'s backend argument.
2018-03-28 10:10:18 -04:00
Hasan Ramezani
76ae1e9a94
Increased test coverage for {% get_admin_log %} and {% static %}.
2018-03-26 13:34:23 -04:00
Mads Jensen
4554f9a783
Increased test coverage for various template tags.
2018-03-24 19:56:46 -04:00
Dan Watson
29150d5da8
Fixed #23406 -- Allowed migrations to be loaded from .pyc files.
2018-03-23 13:20:38 -04:00
Tim Graham
a4f0e9aec7
Fixed #28718 -- Allowed user to request a password reset if their password doesn't use an enabled hasher.
...
Regression in aeb1389442
.
Reverted changes to is_password_usable() from
703c266682
and documentation changes from
92f48680db
.
2018-03-22 10:03:43 -04:00
Tim Graham
623139b5d1
Refs #29147 --- Added JSONField serialization tests.
2018-03-21 20:11:06 -04:00
Michael Sinov
9aca67bea8
Fixed #27533 -- Fixed inspectdb crash if a unique constraint uses an unsupported type.
2018-03-21 12:28:16 -04:00
Tim Graham
a170dac887
Fixed too many parentheses in inspectdb Meta.unique_together output.
...
Regression in c76d87427d
.
2018-03-21 10:39:36 -04:00
Mads Jensen
bb79e480e1
Increased test coverage for i18n template tags.
2018-03-21 08:38:07 -04:00
Tim Graham
c76d87427d
Refs #23919 -- Removed obsolete comments about u'' prefixes.
2018-03-21 08:15:07 -04:00
Tim Graham
6421bd702f
Refs #29227 -- Made inspectdb generate BooleanField(null=True) rather than NullBooleanField.
2018-03-20 12:10:10 -04:00
Tim Graham
5fa4f40f45
Fixed #29227 -- Allowed BooleanField to be null=True.
...
Thanks Lynn Cyrin for contributing to the patch, and Nick Pope for review.
2018-03-20 12:10:10 -04:00
Astral
a0c03c62a8
Fixed #29229 -- Fixed column mismatch crash when combining two annotated values_list() querysets with union(), difference(), or intersection().
...
Regression in 7316720603821ebb64dfe8fa592ba6edcef5f3e.
2018-03-19 21:05:43 -04:00
Mariusz Felisiak
cede5111bb
Refs #28643 -- Added LPad and RPad database functions.
...
Thanks Tim Graham for the review.
2018-03-19 17:35:16 +01:00
Hasan Ramezani
274e3e27f3
Fixed #29184 -- Made TabularInline respect model form's Meta.labels and help_texts.
2018-03-17 20:51:24 -04:00
Claude Paroz
3c4ff21763
Fixed #29103 -- Removed bad 'b'-prefix added by MySQL's SchemaEditor.quote_value().
2018-03-17 16:36:54 -04:00
Claude Paroz
aa0ee372cd
Added tests for MySQL's SchemaEditor.quote_value().
2018-03-17 16:36:50 -04:00
Tim Graham
f8b98f0edc
Removed DatabaseFeatures.can_introspect_null.
...
The only known usage is in the unmaintained django-pymssql project.
2018-03-16 11:43:41 -04:00
Mariusz Felisiak
362813d628
Fixed hanging indentation in various code.
2018-03-16 10:54:34 +01:00
Mattia Procopio
aeb8c38178
Fixed #29206 -- Fixed PasswordResetConfirmView crash when the URL contains a non-UUID where one is expected.
2018-03-15 21:33:15 -04:00
Josh Schneier
b60e5fdbb7
Fixed #28959 -- Fixed 'No, take me back' button on admin's inline popup.
2018-03-15 20:47:18 -04:00
Mariusz Felisiak
9421aee35e
Refs #28643 -- Added LTrim, RTrim, and Trim database functions.
...
Thanks Tim Graham and Mads Jensen for reviews.
2018-03-15 20:57:23 +01:00
Artem Tabolin
a2f7433adc
Fixed #29221 -- Corrected admin's autocomplete widget to add a space after custom classes.
2018-03-15 10:55:34 -04:00
Mariusz Felisiak
ba3078c92d
Refs #29155 -- Fixed LookupTests.test_pattern_lookups_with_substr() crash on Oracle.
...
Test introduced in feb683c4c2
revealed
unexpected behavior on Oracle that allows concatenating NULL with string.
2018-03-15 09:54:24 -04:00
Tim Graham
87dc0844a6
Fixed #29200 -- Fixed label rendering when using RadioSelect and CheckboxSelectMultiple with MultiWidget.
2018-03-15 09:10:23 -04:00
Tim Graham
fb8fd535c0
Moved SchemaLoggingTest to tests/schema.
2018-03-14 10:24:34 -04:00
Mariusz Felisiak
feb683c4c2
Fixed #29155 -- Fixed crash when database functions are used with pattern lookups.
...
Thanks Tim Graham and Sergey Fedoseev for reviews.
2018-03-14 10:00:07 +01:00
Mariusz Felisiak
acfc650f2a
Fixed #29199 -- Fixed crash when database user password contains @ sign on Oracle.
...
Thanks Shane Allgeier for the report and Tim Graham for the review.
2018-03-13 19:06:40 +01:00
dzhuang
e17088a108
Fixed #29213 -- Fixed autocomplete widget's translations for zh-hans/zh-hant.
2018-03-13 10:58:34 -04:00
robwa
4ab027b944
Fixed #28988 -- Fixed queries when a GenericRelation is used with multi-table inheritance.
2018-03-12 22:42:48 -04:00
Sergey Fedoseev
d696fccae6
Fixed #29209 -- Fixed Cast() with TextField on MySQL and Oracle.
2018-03-12 21:57:14 -04:00
Mariusz Felisiak
c3a1337dfa
Refs #29004 -- Optimized InspectDBTransactionalTests.test_include_views() by limiting introspected tables.
2018-03-12 11:22:57 -04:00
Tim Graham
25b97ee170
Added functions for inspectdb table filtering in tests.
2018-03-12 11:15:13 -04:00
Carlton Gibson
5b083a824e
Fixed #29180 -- Fixed a regression where migrations already in the plan were readded.
...
Regression in a38ae914d8
.
2018-03-09 08:59:57 +01:00
Alex Stovbur
2d9ec4d735
Fixed #29188 -- Fixed ContentFile.size after a write().
2018-03-08 14:07:29 -05:00
Simon Charette
277ed07209
Fixed #29195 -- Fixed Exists.output_field resolution on single-valued queries.
...
The Subquery class which Exists inherits from defaulted to using single-valued
querie's field if no output_field was explicitly specified on initialization
which was bypassing the Exists.output_field defined at the class level.
Moving Subquery's dynamic output_field resolution to _resolve_output_field
should make sure the fallback logic is only performed if required.
Regression in 08654a99bb
.
Thanks Oli Warner for the detailed report.
2018-03-08 13:30:41 -05:00
Fabrizio Ettore Messina
10c0fe528a
Fixed #29178 -- Allowed Index.fields to accept a tuple.
2018-03-08 10:56:55 -05:00
Tim Graham
911af0d24b
Added more tests for django.utils.html.urlize().
2018-03-06 08:30:41 -05:00
Tim Graham
97b7dd59bb
Fixed CVE-2018-7537 -- Fixed catastrophic backtracking in django.utils.text.Truncator.
...
Thanks James Davis for suggesting the fix.
2018-03-06 08:30:40 -05:00
Tim Graham
8618271caa
Fixed CVE-2018-7536 -- Fixed catastrophic backtracking in urlize and urlizetrunc template filters.
...
Thanks Florian Apolloner for assisting with the patch.
2018-03-06 08:30:40 -05:00
Alex Stovbur
d171843f57
Fixed #28981 -- Added an exception if GeoIP database can't be loaded from the path.
2018-03-05 12:20:30 -05:00