Stop adding lms/lib and cms/lib to the PYTHONPATH for pylint

These two directories are not added to sys.path when running the
application, so there is no need to add them for pylint.  When they are
added, they make it impossible to run pylint properly because
lms.lib.xblock is imported when trying to import xblock.
This commit is contained in:
Ned Batchelder
2015-12-08 15:28:58 -05:00
parent 586dab51f5
commit 02fa9c101d

View File

@@ -50,8 +50,7 @@ def find_fixme(options):
apps_list = ' '.join(top_python_dirs(system))
pythonpath_prefix = (
"PYTHONPATH={system}:{system}/lib"
"common/djangoapps:common/lib".format(
"PYTHONPATH={system}/djangoapps:common/djangoapps:common/lib".format(
system=system
)
)
@@ -105,8 +104,7 @@ def run_pylint(options):
apps_list = ' '.join(top_python_dirs(system))
pythonpath_prefix = (
"PYTHONPATH={system}:{system}/djangoapps:{system}/"
"lib:common/djangoapps:common/lib".format(
"PYTHONPATH={system}/djangoapps:common/djangoapps:common/lib".format(
system=system
)
)
@@ -446,7 +444,7 @@ def run_quality(options):
jshint_reports = u' '.join(jshint_files)
pythonpath_prefix = (
"PYTHONPATH=$PYTHONPATH:lms:lms/djangoapps:lms/lib:cms:cms/djangoapps:cms/lib:"
"PYTHONPATH=$PYTHONPATH:lms:lms/djangoapps:cms:cms/djangoapps:"
"common:common/djangoapps:common/lib"
)