Run flake8

`devscripts/buildserver.py` is too broken for me to bother with
This commit is contained in:
pukkandan 2022-11-12 00:57:56 +05:30
commit dc02afbb11
No known key found for this signature in database
GPG key ID: 7EEE9E1E817D0A39
3 changed files with 8 additions and 8 deletions

View file

@ -2,7 +2,7 @@
universal = True
[flake8]
exclude = build,venv,.tox,.git,.pytest_cache
exclude = build,venv,.tox,.git,.pytest_cache,devscripts/buildserver.py
ignore = E402,E501,E731,E741,W503
max_line_length = 80
per_file_ignores =

View file

@ -18,7 +18,7 @@ from distutils.spawn import spawn
try:
# This will create an exe that needs Microsoft Visual C++ 2008
# Redistributable Package
import py2exe
import py2exe # noqa: F401
except ImportError:
if len(sys.argv) >= 2 and sys.argv[1] == 'py2exe':
print('Cannot import py2exe', file=sys.stderr)
@ -42,11 +42,11 @@ LONG_DESCRIPTION = 'Command-line program to download videos from YouTube.com and
py2exe_console = [{
'script': './youtube_dl/__main__.py',
'dest_base': 'youtube-dl',
'version': __version__,
'version': __version__, # noqa: F821
'description': DESCRIPTION,
'comments': LONG_DESCRIPTION,
'product_name': 'youtube-dl',
'product_version': __version__,
'product_version': __version__, # noqa: F821
}]
py2exe_params = {
@ -103,7 +103,7 @@ class build_lazy_extractors(Command):
setup(
name='youtube_dl',
version=__version__,
version=__version__, # noqa: F821
description=DESCRIPTION,
long_description=LONG_DESCRIPTION,
url='https://github.com/ytdl-org/youtube-dl',

View file

@ -1,19 +1,19 @@
from __future__ import unicode_literals
try:
from .lazy_extractors import *
from .lazy_extractors import * # noqa: F403
from .lazy_extractors import _ALL_CLASSES
_LAZY_LOADER = True
except ImportError:
_LAZY_LOADER = False
from .extractors import *
from .extractors import * # noqa: F403
_ALL_CLASSES = [
klass
for name, klass in globals().items()
if name.endswith('IE') and name != 'GenericIE'
]
_ALL_CLASSES.append(GenericIE)
_ALL_CLASSES.append(GenericIE) # noqa: F405
def gen_extractor_classes():