Merge pull request #407 from cjmayo/flake8

Update setup.cfg flake8 section
This commit is contained in:
Chris Mayo 2020-05-26 19:55:31 +01:00 committed by GitHub
commit fbad110e7c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 23 additions and 5 deletions

View file

@ -59,4 +59,4 @@ def find_bookmark_file(profile="Default"):
return ""
from .chromium import parse_bookmark_data, parse_bookmark_file
from .chromium import parse_bookmark_data, parse_bookmark_file # noqa: F401

View file

@ -176,4 +176,4 @@ def get_index_html(urls):
# all the URL classes
from . import (fileurl, unknownurl, ftpurl, httpurl, dnsurl,
mailtourl, telneturl, nntpurl, ignoreurl, itmsservicesurl)
mailtourl, telneturl, nntpurl, ignoreurl, itmsservicesurl) # noqa: E402

View file

@ -131,4 +131,4 @@ def parse_itms_services(url_data):
break
from .sitemap import parse_sitemap, parse_sitemapindex
from .sitemap import parse_sitemap, parse_sitemapindex # noqa: F401

View file

@ -19,8 +19,26 @@ ignore-bad-ideas = *.mo
ignore = *.rej
[flake8]
builtins = _
filename =
*.py
./linkchecker
builtins =
_
_n
max-line-length = 80
per-file-ignores =
# In several files imports intentionally cause:
# E402: module level import not at top of file
# F401: module imported but unused
linkchecker: E402
setup.py: E402
linkcheck/__init__.py: E402,F401
linkcheck/bookmarks/chrome.py: E402
linkcheck/checker/httpurl.py: E402
linkcheck/htmlutil/htmlsoup.py: E402
linkcheck/parser/__init__.py: E402
tests/__init__.py: F401
extend-ignore =
# https://pep8.readthedocs.org/en/latest/intro.html#error-codes
# these are ignored by default:

View file

@ -35,7 +35,7 @@ deps =
[testenv:flake8]
deps = flake8
skip_install = true
commands = flake8 setup.py linkcheck {posargs}
commands = flake8 linkchecker setup.py linkcheck {posargs}
[testenv:check-manifest]
deps = check-manifest