mirror of
https://github.com/django/django.git
synced 2025-08-03 10:34:04 +00:00
Fixed #29324 -- Made SECRET_KEY validation lazy (on first access).
This commit is contained in:
parent
9c9a3fe118
commit
948a874425
5 changed files with 26 additions and 17 deletions
|
@ -272,7 +272,13 @@ Requests and Responses
|
|||
Security
|
||||
~~~~~~~~
|
||||
|
||||
* ...
|
||||
* The :setting:`SECRET_KEY` setting is now checked for a valid value upon first
|
||||
access, rather than when settings are first loaded. This enables running
|
||||
management commands that do not rely on the ``SECRET_KEY`` without needing to
|
||||
provide a value. As a consequence of this, calling
|
||||
:func:`~django.conf.settings.configure` without providing a valid
|
||||
``SECRET_KEY``, and then going on to access ``settings.SECRET_KEY`` will now
|
||||
raise an :exc:`~django.core.exceptions.ImproperlyConfigured` exception.
|
||||
|
||||
Serialization
|
||||
~~~~~~~~~~~~~
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue