Various Flake8 fixes to base scripts

This commit is contained in:
Andrew Murray 2015-04-24 10:15:14 +10:00
parent 86be744d1f
commit 87c4c6a72d
2 changed files with 5 additions and 4 deletions

View File

@ -3,7 +3,8 @@
from multiprocessing import Pool, cpu_count from multiprocessing import Pool, cpu_count
from distutils.ccompiler import CCompiler from distutils.ccompiler import CCompiler
import os, sys import os
import sys
try: try:
MAX_PROCS = int(os.environ.get('MAX_CONCURRENCY', min(4, cpu_count()))) MAX_PROCS = int(os.environ.get('MAX_CONCURRENCY', min(4, cpu_count())))
@ -38,7 +39,7 @@ def _mp_compile(self, sources, output_dir=None, macros=None,
pool = Pool(MAX_PROCS) pool = Pool(MAX_PROCS)
try: try:
print ("Building using %d processes" % pool._processes) print("Building using %d processes" % pool._processes)
except: except:
pass pass
arr = [(self, obj, build, cc_args, extra_postargs, pp_opts) arr = [(self, obj, build, cc_args, extra_postargs, pp_opts)

View File

@ -570,7 +570,7 @@ class pil_build_ext(build_ext):
if feature.webpmux: if feature.webpmux:
defs.append(("HAVE_WEBPMUX", None)) defs.append(("HAVE_WEBPMUX", None))
libs.append(feature.webpmux) libs.append(feature.webpmux)
libs.append(feature.webpmux.replace('pmux','pdemux')) libs.append(feature.webpmux.replace('pmux', 'pdemux'))
exts.append(Extension( exts.append(Extension(
"PIL._webp", ["_webp.c"], libraries=libs, define_macros=defs)) "PIL._webp", ["_webp.c"], libraries=libs, define_macros=defs))
@ -757,6 +757,6 @@ setup(
test_suite='nose.collector', test_suite='nose.collector',
keywords=["Imaging", ], keywords=["Imaging", ],
license='Standard PIL License', license='Standard PIL License',
zip_safe= not debug_build(), zip_safe=not debug_build(),
) )
# End of file # End of file