From 4531e155190f93252275ba7ebe6967674e37630e Mon Sep 17 00:00:00 2001 From: Kyle McCormick Date: Tue, 22 Dec 2020 14:40:17 -0500 Subject: [PATCH] refactor!: stop using import_shims Attempting to import packages from lms/djangoapps, cms/djangoapps, or common/djangoapps as if they are import roots will now simply raise ImportErrors (like any other invalid import) instead of DeprecatedEdxPlatformImportError. See docs/decisions/0007-sys-path-modification-removal.rst for more details. --- cms/envs/common.py | 5 ----- lms/envs/common.py | 5 ----- scripts/xsslint_config.py | 1 - 3 files changed, 11 deletions(-) diff --git a/cms/envs/common.py b/cms/envs/common.py index 579507ddbb..8bc5df44ba 100644 --- a/cms/envs/common.py +++ b/cms/envs/common.py @@ -492,11 +492,6 @@ COURSES_ROOT = ENV_ROOT / "data" GITHUB_REPO_ROOT = ENV_ROOT / "data" -# TODO: This path modification exists as temporary support for deprecated import patterns. -# It will be removed in an upcoming Open edX release. -# See docs/decisions/0007-sys-path-modification-removal.rst -sys.path.append(REPO_ROOT / 'import_shims' / 'studio') - # For geolocation ip database GEOIP_PATH = REPO_ROOT / "common/static/data/geoip/GeoLite2-Country.mmdb" diff --git a/lms/envs/common.py b/lms/envs/common.py index dd8983daed..e7af6f1187 100644 --- a/lms/envs/common.py +++ b/lms/envs/common.py @@ -970,11 +970,6 @@ NODE_MODULES_ROOT = REPO_ROOT / "node_modules" DATA_DIR = COURSES_ROOT -# TODO: This path modification exists as temporary support for deprecated import patterns. -# It will be removed in an upcoming Open edX release. -# See docs/decisions/0007-sys-path-modification-removal.rst -sys.path.append(REPO_ROOT / 'import_shims' / 'lms') - # For Node.js system_node_path = os.environ.get("NODE_PATH", NODE_MODULES_ROOT) diff --git a/scripts/xsslint_config.py b/scripts/xsslint_config.py index 8de7d43c5b..2f463a49df 100644 --- a/scripts/xsslint_config.py +++ b/scripts/xsslint_config.py @@ -30,7 +30,6 @@ SKIP_DIRS = ( 'spec', 'test_root', 'vendor', - 'import_shims', )