defining default settings for apps
|Reported by:||Owned by:||Adrian Holovaty|
|Cc:||Gonzalo Saavedra||Triage Stage:||Unreviewed|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
I think django should have a simple and easy way for setting new variables in apps.
I suggest that a app/someapp/default_settings.py file would be imported when it exists and be handled like the global_settings.py
The patch hooks in after the installed_apps got deglobed and sets the default value from default_settings.py if it doesn't exist already in the user conf.
This way, adding new variables is very easy and uniform and apps can use the standard way without much checking for existence of keys.
Change History (16)
comment:7 Changed 9 years ago by
|Summary:||[patch] provide a standard way for new config variables in apps → defining default settings for apps|
|Version:||magic-removal → SVN|