Re-enable pyflakes in linter and remove python 3 pyflakes errors.

This commit is contained in:
Eklavya Sharma
2016-05-25 19:25:13 +05:30
parent 1a6257394c
commit 1c04560def
4 changed files with 4 additions and 3 deletions

View File

@@ -122,7 +122,7 @@ def setup_virtualenv(target_venv_path, requirements_file, virtualenv_args=[]):
print("Using cached Python venv from %s" % (cached_venv_path,))
run(["sudo", "ln", "-nsf", cached_venv_path, target_venv_path])
activate_this = os.path.join(target_venv_path, "bin", "activate_this.py")
execfile(activate_this, dict(__file__=activate_this))
exec(open(activate_this).read(), {}, dict(__file__=activate_this)) # type: ignore # https://github.com/python/mypy/issues/1577
def do_setup_virtualenv(venv_path, requirements_file, virtualenv_args):
# Setup Python virtualenv
@@ -133,7 +133,7 @@ def do_setup_virtualenv(venv_path, requirements_file, virtualenv_args):
# Switch current Python context to the virtualenv.
activate_this = os.path.join(venv_path, "bin", "activate_this.py")
execfile(activate_this, dict(__file__=activate_this))
exec(open(activate_this).read(), {}, dict(__file__=activate_this)) # type: ignore # https://github.com/python/mypy/issues/1577
run(["pip", "install", "--upgrade", "pip"])
run(["pip", "install", "--no-deps", "--requirement", requirements_file])

View File

@@ -5,6 +5,7 @@ import shutil
import subprocess
import json
import sys
from six import unichr
from PIL import Image, ImageDraw, ImageFont

View File

@@ -60,7 +60,6 @@ else:
logger.setLevel(logging.WARNING)
def check_pyflakes():
return False
if not by_lang['py']:
return False
failed = False

View File

@@ -34,6 +34,7 @@ import six
from six.moves import filter
from six.moves import map
from six.moves import range
from six import unichr
session_engine = import_module(settings.SESSION_ENGINE)