Fix flake8 E265 block comment should start with '# '

Ignore for NZBGET scripts
This commit is contained in:
Labrys of Knossos 2019-04-07 12:56:50 -04:00
commit 077f04bc53
2 changed files with 13 additions and 12 deletions

View file

@ -60,13 +60,13 @@ def process_torrent(input_directory, input_name, input_category, input_hash, inp
input_category = 'UNCAT'
usercat = input_category
#try:
# try:
# input_name = input_name.encode(core.SYS_ENCODING)
#except UnicodeError:
# except UnicodeError:
# pass
#try:
# try:
# input_directory = input_directory.encode(core.SYS_ENCODING)
#except UnicodeError:
# except UnicodeError:
# pass
logger.debug('Determined Directory: {0} | Name: {1} | Category: {2}'.format
@ -125,9 +125,9 @@ def process_torrent(input_directory, input_name, input_category, input_hash, inp
else:
output_destination = os.path.normpath(
core.os.path.join(core.OUTPUT_DIRECTORY, input_category))
#try:
# try:
# output_destination = output_destination.encode(core.SYS_ENCODING)
#except UnicodeError:
# except UnicodeError:
# pass
if output_destination in input_directory:
@ -170,9 +170,9 @@ def process_torrent(input_directory, input_name, input_category, input_hash, inp
core.os.path.join(output_destination, os.path.basename(file_path)), full_file_name)
logger.debug('Setting outputDestination to {0} to preserve folder structure'.format
(os.path.dirname(target_file)))
#try:
# try:
# target_file = target_file.encode(core.SYS_ENCODING)
#except UnicodeError:
# except UnicodeError:
# pass
if root == 1:
if not found_file:
@ -353,14 +353,14 @@ def main(args):
if client_agent.lower() not in core.TORRENT_CLIENTS:
continue
#try:
# try:
# dir_name = dir_name.encode(core.SYS_ENCODING)
#except UnicodeError:
# except UnicodeError:
# pass
input_name = os.path.basename(dir_name)
#try:
# try:
# input_name = input_name.encode(core.SYS_ENCODING)
#except UnicodeError:
# except UnicodeError:
# pass
results = process_torrent(dir_name, input_name, subsection, input_hash or None, input_id or None,

View file

@ -66,6 +66,7 @@ ignore =
per-file-ignores =
; F401 imported but unused
; E402 module level import not at top of file
nzbTo*.py: E265
core/__init__.py: E402, F401
core/utils/__init__.py: F401
core/plugins/downloaders/configuration.py: F401