Skip to content

Merge LMS/CMS settings with partially overlapping values by using Derived values #37280

@wgu-taylor-payne

Description

@wgu-taylor-payne

Find settings defined in lms/envs/common.py and cms/envs/common.py with overlapping, but not equal, values. Where possible, bring these settings up into openedx/envs/common.py where the value is defined with both the overlapping part, and then the non-overlapping part becomes based on values from settings in {lms/cms}/envs/common.py. This is accomplished by using a Derived value.

For example, we currently have HELP_TOKENS_INI_FILE defined like so in the common.py files:

# lms/envs/common.py
HELP_TOKENS_INI_FILE = REPO_ROOT / "lms" / "envs" / "help_tokens.ini"

# cms/envs/common.py
HELP_TOKENS_INI_FILE = REPO_ROOT / "cms" / "envs" / "help_tokens.ini"

If possible, we bring up HELP_TOKENS_INI_FILE into openedx/envs/common.py as a Derived setting that depends on the final value of REPO_ROOT and some other variable that holds the application name (i.e. "lms" or "cms"), such as SERVICE_VARIANT.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions