You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The setting EXTENSIONS_ARGUMENTS was introduced like a year ago with the idea to have a place to inject custom settings that are used by extension code.
I think that the approach of passing almost-arbitrary stuff through a single settings variable is a poor architectural choice: it gets very cumbersome once more than one or two values are needed.
Instead of forcing everything into this one variable, why not add some documentation and showing how to define custom settings without going through the Django settings infra?
Just have a custom extension settings module (eg. document-merge-service/extensions/settings.py) that defines whatever needs to be defined by reading env vars just as the regular settings.py does. Just you'll have to import that one instead of the django.conf.settings.
This would also free you from encoding stuff into one env variable that could/should be multiple ones.
The setting
EXTENSIONS_ARGUMENTS
was introduced like a year ago with the idea to have a place to inject custom settings that are used by extension code.I think that the approach of passing almost-arbitrary stuff through a single settings variable is a poor architectural choice: it gets very cumbersome once more than one or two values are needed.
Instead of forcing everything into this one variable, why not add some documentation and showing how to define custom settings without going through the Django settings infra?
Just have a custom extension settings module (eg.
document-merge-service/extensions/settings.py
) that defines whatever needs to be defined by reading env vars just as the regular settings.py does. Just you'll have to import that one instead of thedjango.conf.settings
.This would also free you from encoding stuff into one env variable that could/should be multiple ones.
Example:
The text was updated successfully, but these errors were encountered: