Opened 19 years ago

Last modified 8 years ago

#1371 closed defect

[patch] provide a standard way for new config variables in apps — at Initial Version

Reported by: django@… Owned by: Adrian Holovaty
Component: Core (Other) Version: dev
Severity: normal Keywords:
Cc: Gonzalo Saavedra Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

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 (1)

by django@…, 19 years ago

Attachment: default_config.patch added

implements app.default_settings as suggested

Note: See TracTickets for help on using tickets.
Back to Top