summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTodd Gamblin <tgamblin@llnl.gov>2019-05-16 09:47:02 +0200
committerGitHub <noreply@github.com>2019-05-16 09:47:02 +0200
commita75023753294293995729bec25674a17a71e21fc (patch)
tree8763cc620e91219af5f69fdb53dda3649d1a9317
parentf68f5e3014b3196a89b2e077fadb7b611057ac24 (diff)
downloadspack-a75023753294293995729bec25674a17a71e21fc.tar.gz
spack-a75023753294293995729bec25674a17a71e21fc.tar.bz2
spack-a75023753294293995729bec25674a17a71e21fc.tar.xz
spack-a75023753294293995729bec25674a17a71e21fc.zip
flake8: add exceptions for overly pedantic camelcase rules from pep8-naming (#11477)
Rules N813 and N814 prevented import statements like this: xml.etree.ElementTree as et xml.etree.ElementTree as ET But both of those seem pretty reasonable. We see no reason to require any camelcase import to be imported "as" a camelcase word.
-rw-r--r--.flake84
-rw-r--r--.flake8_packages2
2 files changed, 4 insertions, 2 deletions
diff --git a/.flake8 b/.flake8
index ef62b6efbb..195c783726 100644
--- a/.flake8
+++ b/.flake8
@@ -24,7 +24,9 @@
#
# N8: PEP8-naming
# - N801: class names should use CapWords convention
+# - N813: camelcase imported as lowercase
+# - N814: camelcase imported as constant
#
[flake8]
-ignore = E129,E221,E241,E272,E731,W503,W504,F999,N801
+ignore = E129,E221,E241,E272,E731,W503,W504,F999,N801,N813,N814
max-line-length = 79
diff --git a/.flake8_packages b/.flake8_packages
index e7677e66d2..d17a34951d 100644
--- a/.flake8_packages
+++ b/.flake8_packages
@@ -20,5 +20,5 @@
# - F821: undefined name `name`
#
[flake8]
-ignore = E129,E221,E241,E272,E731,W503,W504,F405,F821,F999
+ignore = E129,E221,E241,E272,E731,W503,W504,F405,F821,F999,N801,N813,N814
max-line-length = 79