diff --git a/cms/envs/aws.py b/cms/envs/aws.py index e07c7706f8..e933f0207d 100644 --- a/cms/envs/aws.py +++ b/cms/envs/aws.py @@ -6,6 +6,11 @@ This is the default template for our main set of AWS servers. # want to import all variables from base settings files # pylint: disable=wildcard-import, unused-wildcard-import +# Pylint gets confused by path.py instances, which report themselves as class +# objects. As a result, pylint applies the wrong regex in validating names, +# and throws spurious errors. Therefore, we disable invalid-name checking. +# pylint: disable=invalid-name + import json from .common import * diff --git a/cms/envs/bok_choy.py b/cms/envs/bok_choy.py index 37bb2e2185..6c645e5454 100644 --- a/cms/envs/bok_choy.py +++ b/cms/envs/bok_choy.py @@ -5,6 +5,11 @@ Settings for bok choy tests import os from path import path +# Pylint gets confused by path.py instances, which report themselves as class +# objects. As a result, pylint applies the wrong regex in validating names, +# and throws spurious errors. Therefore, we disable invalid-name checking. +# pylint: disable=invalid-name + ########################## Prod-like settings ################################### # These should be as close as possible to the settings we use in production. diff --git a/cms/envs/common.py b/cms/envs/common.py index f0818b2db3..9ad9d8c433 100644 --- a/cms/envs/common.py +++ b/cms/envs/common.py @@ -24,6 +24,11 @@ Longer TODO: # want to import all variables from base settings files # pylint: disable=wildcard-import, unused-import, unused-wildcard-import +# Pylint gets confused by path.py instances, which report themselves as class +# objects. As a result, pylint applies the wrong regex in validating names, +# and throws spurious errors. Therefore, we disable invalid-name checking. +# pylint: disable=invalid-name + import imp import os import sys diff --git a/cms/envs/test.py b/cms/envs/test.py index 63cc896d9d..037201ec10 100644 --- a/cms/envs/test.py +++ b/cms/envs/test.py @@ -12,6 +12,11 @@ sessions. Assumes structure: # want to import all variables from base settings files # pylint: disable=wildcard-import, unused-wildcard-import +# Pylint gets confused by path.py instances, which report themselves as class +# objects. As a result, pylint applies the wrong regex in validating names, +# and throws spurious errors. Therefore, we disable invalid-name checking. +# pylint: disable=invalid-name + from .common import * import os from path import path diff --git a/lms/envs/aws.py b/lms/envs/aws.py index 70257e889c..a33359ad29 100644 --- a/lms/envs/aws.py +++ b/lms/envs/aws.py @@ -11,6 +11,11 @@ Common traits: # want to import all variables from base settings files # pylint: disable=wildcard-import, unused-wildcard-import +# Pylint gets confused by path.py instances, which report themselves as class +# objects. As a result, pylint applies the wrong regex in validating names, +# and throws spurious errors. Therefore, we disable invalid-name checking. +# pylint: disable=invalid-name + import json from .common import * diff --git a/lms/envs/bok_choy.py b/lms/envs/bok_choy.py index 14a290b306..325812a546 100644 --- a/lms/envs/bok_choy.py +++ b/lms/envs/bok_choy.py @@ -6,6 +6,11 @@ import os from path import path from tempfile import mkdtemp +# Pylint gets confused by path.py instances, which report themselves as class +# objects. As a result, pylint applies the wrong regex in validating names, +# and throws spurious errors. Therefore, we disable invalid-name checking. +# pylint: disable=invalid-name + CONFIG_ROOT = path(__file__).abspath().dirname() # pylint: disable=no-value-for-parameter TEST_ROOT = CONFIG_ROOT.dirname().dirname() / "test_root" diff --git a/lms/envs/cms/microsite_test.py b/lms/envs/cms/microsite_test.py index 586e357e85..541eab764f 100644 --- a/lms/envs/cms/microsite_test.py +++ b/lms/envs/cms/microsite_test.py @@ -5,6 +5,11 @@ This is a localdev test for the Microsite processing pipeline # want to import all variables from base settings files # pylint: disable=wildcard-import, unused-wildcard-import +# Pylint gets confused by path.py instances, which report themselves as class +# objects. As a result, pylint applies the wrong regex in validating names, +# and throws spurious errors. Therefore, we disable invalid-name checking. +# pylint: disable=invalid-name + from .dev import * from ..dev import ENV_ROOT, FEATURES diff --git a/lms/envs/common.py b/lms/envs/common.py index 06cf1ee4c2..519f5da8a6 100644 --- a/lms/envs/common.py +++ b/lms/envs/common.py @@ -24,6 +24,11 @@ Longer TODO: # want to import all variables from base settings files # pylint: disable=wildcard-import, unused-import, unused-wildcard-import, invalid-name +# Pylint gets confused by path.py instances, which report themselves as class +# objects. As a result, pylint applies the wrong regex in validating names, +# and throws spurious errors. Therefore, we disable invalid-name checking. +# pylint: disable=invalid-name + import sys import os import imp diff --git a/lms/envs/dev.py b/lms/envs/dev.py index 85ce3e3906..718be63183 100644 --- a/lms/envs/dev.py +++ b/lms/envs/dev.py @@ -12,6 +12,11 @@ sessions. Assumes structure: # want to import all variables from base settings files # pylint: disable=wildcard-import, unused-wildcard-import +# Pylint gets confused by path.py instances, which report themselves as class +# objects. As a result, pylint applies the wrong regex in validating names, +# and throws spurious errors. Therefore, we disable invalid-name checking. +# pylint: disable=invalid-name + from .common import * from logsettings import get_logger_config diff --git a/lms/envs/test.py b/lms/envs/test.py index 07964cf30b..37241ce389 100644 --- a/lms/envs/test.py +++ b/lms/envs/test.py @@ -12,6 +12,11 @@ sessions. Assumes structure: # want to import all variables from base settings files # pylint: disable=wildcard-import, unused-wildcard-import +# Pylint gets confused by path.py instances, which report themselves as class +# objects. As a result, pylint applies the wrong regex in validating names, +# and throws spurious errors. Therefore, we disable invalid-name checking. +# pylint: disable=invalid-name + from .common import * import os from path import path