more from_prefixed_env features

* support nested dict access with "__" separator
* don't specify separator in prefix
* catch exceptions for any loads function
This commit is contained in:
David Lord 2022-03-25 11:00:32 -07:00
parent 08a283af5e
commit 4eb5e9455b
No known key found for this signature in database
GPG key ID: 7A1C87E3F5BC42A8
4 changed files with 136 additions and 62 deletions

View file

@ -55,6 +55,10 @@ Unreleased
- From Werkzeug, for redirect responses the ``Location`` header URL
will remain relative, and exclude the scheme and domain, by default.
:pr:`4496`
- Add ``Config.from_prefixed_env()`` to load config values from
environment variables that start with ``FLASK_`` or another prefix.
This parses values as JSON by default, and allows setting keys in
nested dicts. :pr:`4479`
Version 2.0.3