Skip to content

Commit d20ed5c

Browse files
feanilclaude
andcommitted
docs: drop stale FEATURES-dict references from comments and docstrings
These flags are now flat Django settings, but several comments/docstrings still described them as FEATURES-dict keys, and each kept a 'settings.FEATURES' reference alive in a repo-wide grep. Update them to the flat setting they now describe: - embargo/middleware.py: settings.FEATURES['EMBARGO'] -> settings.EMBARGO - git_export.py: FEATURE['ENABLE_EXPORT_GIT'] -> ENABLE_EXPORT_GIT setting - auto_auth.py: settings.FEATURES['AUTOMATIC_AUTH_FOR_TESTING'] -> settings.AUTOMATIC_AUTH_FOR_TESTING - split_mongo/split.py: reword the historical entrance-exams comment off the dict syntax - test_auto_auth.py: update the setUp comments to name the flat setting No code/behavior change; comment/docstring text only. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 1f82a10 commit d20ed5c

5 files changed

Lines changed: 7 additions & 7 deletions

File tree

‎cms/djangoapps/contentstore/management/commands/git_export.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
any have taken place.
1111
1212
This functionality is also available as an export view in studio if the giturl
13-
attribute is set and the FEATURE['ENABLE_EXPORT_GIT'] is set.
13+
attribute is set and the ENABLE_EXPORT_GIT setting is enabled.
1414
"""
1515

1616

‎openedx/core/djangoapps/embargo/middleware.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
1717
Usage:
1818
19-
1) Enable embargo by setting `settings.FEATURES['EMBARGO']` to True.
19+
1) Enable embargo by setting `settings.EMBARGO` to True.
2020
2121
2) In Django admin, create a new `IPFilter` model to block or whitelist
2222
an IP address from accessing the site.

‎openedx/core/djangoapps/user_authn/views/auto_auth.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def auto_auth(request): # pylint: disable=too-many-statements
4343
Create or configure a user account, then log in as that user.
4444
4545
Enabled only when
46-
settings.FEATURES['AUTOMATIC_AUTH_FOR_TESTING'] is true.
46+
settings.AUTOMATIC_AUTH_FOR_TESTING is true.
4747
4848
Accepts the following querystring parameters:
4949
* `username`, `email`, and `password` for the user account

‎openedx/core/djangoapps/user_authn/views/tests/test_auto_auth.py‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ class AutoAuthEnabledTestCase(AutoAuthTestCase, ModuleStoreTestCase):
4747

4848
@override_settings(AUTOMATIC_AUTH_FOR_TESTING=True)
4949
def setUp(self):
50-
# Patching the settings.FEATURES['AUTOMATIC_AUTH_FOR_TESTING']
50+
# Patching the AUTOMATIC_AUTH_FOR_TESTING setting
5151
# value affects the contents of urls.py,
5252
# so we need to call super.setUp() which reloads urls.py (because
5353
# of the UrlResetMixin)
@@ -305,7 +305,7 @@ class AutoAuthDisabledTestCase(AutoAuthTestCase):
305305

306306
@override_settings(AUTOMATIC_AUTH_FOR_TESTING=False)
307307
def setUp(self):
308-
# Patching the settings.FEATURES['AUTOMATIC_AUTH_FOR_TESTING']
308+
# Patching the AUTOMATIC_AUTH_FOR_TESTING setting
309309
# value affects the contents of urls.py,
310310
# so we need to call super.setUp() which reloads urls.py (because
311311
# of the UrlResetMixin)
@@ -329,7 +329,7 @@ class AutoAuthRestrictedTestCase(AutoAuthTestCase):
329329

330330
@override_settings(AUTOMATIC_AUTH_FOR_TESTING=True)
331331
def setUp(self):
332-
# Patching the settings.FEATURES['AUTOMATIC_AUTH_FOR_TESTING']
332+
# Patching the AUTOMATIC_AUTH_FOR_TESTING setting
333333
# value affects the contents of urls.py,
334334
# so we need to call super.setUp() which reloads urls.py (because
335335
# of the UrlResetMixin)

‎xmodule/modulestore/split_mongo/split.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1720,7 +1720,7 @@ def create_child(self, user_id, parent_usage_key, block_type, block_id=None, fie
17201720

17211721
parent = new_structure['blocks'][block_id]
17221722

1723-
# Originally added to support entrance exams (settings.FEATURES.get('ENTRANCE_EXAMS'))
1723+
# Originally added to support entrance exams (the ENTRANCE_EXAMS feature)
17241724
if kwargs.get('position') is None:
17251725
parent.fields.setdefault('children', []).append(BlockKey.from_usage_key(xblock.location))
17261726
else:

0 commit comments

Comments
 (0)