Commit Graph

27820 Commits

Author SHA1 Message Date
Simon Charette 5a4d7285bd Fixed #31094 -- Included columns referenced by subqueries in GROUP BY on aggregations.
Thanks Johannes Hoppe for the report.

Regression in fb3f034f1c.

Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2019-12-19 10:04:56 +01:00
Simon Charette a0f34d8fef Refs #31094 -- Added test for not using aliases in GROUP BY clauses. 2019-12-19 09:12:29 +01:00
Mike Hansen 35d36d9462 Refs #30585 -- Updated project templates and tests to use (block)translate tags. 2019-12-18 13:15:38 +01:00
Mike Hansen d291c72bf2 Fixed #30585 -- Added {% translate %} and {% blocktranslate %} template tags. 2019-12-18 13:15:38 +01:00
Hasan Ramezani 70d95682b1 Corrected some typos in documentation. 2019-12-18 11:36:27 +01:00
Mariusz Felisiak 50a69efb2e Added stub release notes for 3.0.2. 2019-12-18 10:51:57 +01:00
Adam Johnson ef3baf966d Updated Pytest example in upgrade documentation.
Pytest changed their recommended entrypoint to 'pytest' in version 3.0.0 in 2016 : https://docs.pytest.org/en/latest/changelog.html#id1009. Also link the name since this is the only reference in the Django documentation at current.
2019-12-18 10:42:41 +01:00
Mariusz Felisiak 5a2b9f0b54 Added CVE-2019-19844 to the security archive. 2019-12-18 10:36:22 +01:00
Simon Charette 5b1fbcef7a Fixed CVE-2019-19844 -- Used verified user email for password reset requests.
Co-Authored-By: Florian Apolloner <florian@apolloner.eu>
2019-12-18 09:11:39 +01:00
Shubham singh f4647179cc Fixed #31086 -- Improved error message for admin model inlines with more than one foreign key to the same parent. 2019-12-17 09:15:01 +01:00
James Turk ff00a05347 Fixed #31088 -- Added support for websearch searching in SearchQuery. 2019-12-16 14:59:59 +01:00
Ram Rachum 972d93a95e Optimized containment check in ChoicesMeta. 2019-12-16 11:22:45 +01:00
Zeynel Özdemir 9d40b6bbf4 Fixed #31076 -- Fixed dbshell crash on Windows with Python < 3.8.
subprocess.run()'s args parameter accepts path-like objects on Windows
since Python 3.8.
2019-12-16 11:20:41 +01:00
Baptiste Mispelon 4161e35048 Refs #12679 -- Added test for using property as ModelAdmin.inlines.
Fixed in 1d8eb0cae5.
2019-12-14 21:15:44 +01:00
Rabah Saadi 5b7450080f Added Algerian Arabic language. 2019-12-14 16:26:31 +01:00
Baptiste Mispelon 738e9e615d Fixed #26743 -- Fixed UnboundLocalError crash when deserializing m2m fields and value isn't iterable. 2019-12-13 11:38:09 +01:00
Jon Dufresne 3fe5d0128b Rewrote CSRF JavaScript example without jQuery. 2019-12-12 16:34:03 +01:00
Hasan Ramezani 9736137cdc Fixed #31069, Refs #26431 -- Doc'd RegexPattern behavior change in passing optional named groups in Django 3.0. 2019-12-12 14:24:10 +01:00
Osaetin Daniel b33bfc3839 Fixed #30862 -- Allowed setting SameSite cookies flags to 'none'.
Thanks Florian Apolloner and Carlton Gibson for reviews.
2019-12-12 10:52:31 +01:00
Osaetin Daniel 14e690ae5a Doc'd HttpResponse.set_cookie()'s secure argument. 2019-12-12 10:52:31 +01:00
Osaetin Daniel 15c5875e69 Refs #6657 -- Corrected HttpResponse.set_cookie()/set_signed_cookie() signatures in docs. 2019-12-12 10:52:31 +01:00
Jon Dufresne b7d05b2e5a Refs #23919 -- Used yield from in inspectdb. 2019-12-12 10:51:46 +01:00
Hasan Ramezani 52018e1615 Fixed typos in 3.0 release notes and docs/ref/request-response.txt. 2019-12-12 10:19:09 +01:00
Baptiste Mispelon 200cd8803d Refs #25361 -- Added test for pickling queryset of abstract-inherited models with Meta.ordering.
Fixed in 67cf5efa31.
2019-12-12 09:01:47 +01:00
Jon Dufresne 9285926295 Removed unnecessary app_template directory from flake8 exclude.
Unnecessary since abc0777b63 where the
extension was changed to not be ".py".
2019-12-12 08:50:42 +01:00
Jon Dufresne 8ea3ff155e Fixed typo in tests/cache/tests.py docstring. 2019-12-11 17:39:21 +01:00
Jon Dufresne 8d087f9a17 Fixed typo in ModelChoiceFieldTests.
The subindex and attrs arguments should be passed through to the parent,
not overridden as None.
2019-12-11 15:15:12 +01:00
Sergey Fedoseev 88637064b3 Refs #28373 -- Stopped setting tzinfo in typecast_timestamp().
Unnecessary since cef3f2d3c6. When
USE_TZ=True, conn_tznames is always passed to methods that use
typecast_timestamp(). Therefore, it can return naive datetimes.
2019-12-11 13:59:49 +01:00
Mariusz Felisiak ec12c37384
Refs #31073 -- Added release notes for 02eff7ef60. 2019-12-11 10:07:41 +01:00
Jon Dufresne e703b93a65 Fixed #31080 -- Removed redundant type="text/javascript" attribute from <script> tags. 2019-12-11 09:49:54 +01:00
Baptiste Mispelon d8e2333528 Fixed #31077 -- Made debug decorators raise TypeError if they're not called.
Django will raise an error if you forget to call the decorator.
2019-12-10 13:34:28 +01:00
Peter Andersen 02eff7ef60 Fixed #31073 -- Prevented CheckboxInput.get_context() from mutating attrs. 2019-12-10 12:27:50 +01:00
Mariusz Felisiak 3fb7c12158
Refs #23433 -- Fixed test_django_admin_py.DeprecationTest tests failures on Windows and Python < 3.8.
subprocess.run()'s args parameter accepts a path-like object on Windows
since Python 3.8.
2019-12-10 11:17:50 +01:00
Baptiste Mispelon 09341856ed Used Signature API instead of deprecated inspect.getcallargs().
inspect.getcallargs() was deprecated in Python 3.5 and the Signature
API (PEP 362) has better support for decorated functions (by default,
it follows the __wrapped__ attribute set by functools.wraps for
example).
2019-12-10 09:36:34 +01:00
Baptiste Mispelon 3df3c5e670 Fixed #26480 -- Fixed crash of contrib.auth.authenticate() on decorated authenticate() methods of authentication backends.
The Signature API (PEP 362) has better support for decorated functions
(by default, it follows the __wrapped__ attribute set by
functools.wraps for example).
2019-12-10 09:36:30 +01:00
Baptiste Mispelon 23af086665 Used full module import for inspect in template/base.py. 2019-12-10 08:29:30 +01:00
Mariusz Felisiak d6505273cd Refs #31044 -- Fixed error message when using Prefetch with a values_list() queryset. 2019-12-09 15:45:53 +01:00
Hasan Ramezani 4540842bc3 Fixed #31044 -- Errored nicely when using Prefetch with a raw() queryset. 2019-12-09 15:45:18 +01:00
Baptiste Mispelon 9e565386d3 Fixed #27430 -- Added -b/--buffer option to DiscoverRunner. 2019-12-09 13:47:12 +01:00
Mariusz Felisiak f464526388
Refs #30676 -- Added test for invalid --pdb and --parallel usage in DiscoverRunner. 2019-12-09 11:12:06 +01:00
Ali Mirlou 663bb435de Fixed typo in docs/releases/3.0.1.txt. 2019-12-09 07:57:36 +01:00
exploit19 d8ab2c9bba Fixed #31066 -- Added a docstring to main() function in manage.py template. 2019-12-09 07:54:51 +01:00
Alex Aktsipetrov 723fc7fcf6 Made Query.check_filterable() use bool by default instead of str. 2019-12-06 13:52:36 +01:00
Alex Aktsipetrov bf12273db4 Fixed #31060 -- Reallowed window expressions to be used in conditions outside of queryset filters.
Regression in 4edad1ddf6.

Thanks utapyngo for the report.
2019-12-06 13:52:16 +01:00
Jon Dufresne 5708327c37 Fixed #23433 -- Deprecated django-admin.py entry point in favor of django-admin.
Unify on the entry point created by setuptools entry_points feature.
2019-12-06 12:11:44 +01:00
Jon Dufresne 8eb0f73eed Refs #23433 -- Removed script argument from AdminScriptTestCase.run_test(). 2019-12-06 10:33:54 +01:00
Jon Dufresne 8aefe11137 Removed unnecessary __init__.py creation in admin_scripts.tests. 2019-12-06 09:57:09 +01:00
Mariusz Felisiak 82a88d2f48
Fixed #31061 -- Ignored positional args in django.urls.resolve() when all optional named parameters are missing.
Regression in 76b993a117.

Thanks Claude Paroz for the report and Carlton Gibson for reviews.
2019-12-06 09:32:51 +01:00
Baptiste Mispelon f138e75910 Fixed outdated import in django/utils/safestring.py.
The backported version of functools.wraps was removed in
13864703bc.
2019-12-06 09:31:33 +01:00
Hasan Ramezani 5d674eac87 Fixed #31039 -- Added support for contained_by lookup with AutoFields, SmallIntegerField, and DecimalField. 2019-12-05 15:50:39 +01:00