Merge pull request #336 from jelmer/flakes
Fix pyflakes errors & run pyflakes on travis.
This commit is contained in:
commit
539e6e4486
@ -18,9 +18,11 @@ matrix:
|
|||||||
install:
|
install:
|
||||||
- pip install -U pip
|
- pip install -U pip
|
||||||
- pip install tox
|
- pip install tox
|
||||||
|
- pip install pyflakes
|
||||||
- sudo rm -rf /dev/shm && sudo ln -s /run/shm /dev/shm
|
- sudo rm -rf /dev/shm && sudo ln -s /run/shm /dev/shm
|
||||||
script:
|
script:
|
||||||
- tox -e $TOX_ENV
|
- tox -e $TOX_ENV
|
||||||
|
- python -m pyflakes.__main__ $(git ls-files | grep -E "^isso/.+.py$" | grep -v "^isso/compat.py")
|
||||||
notifications:
|
notifications:
|
||||||
irc:
|
irc:
|
||||||
channels:
|
channels:
|
||||||
|
4
Makefile
4
Makefile
@ -34,9 +34,9 @@ init:
|
|||||||
|
|
||||||
check:
|
check:
|
||||||
@echo "Python 2.x"
|
@echo "Python 2.x"
|
||||||
-@python2 -m pyflakes $(ISSO_PY_SRC)
|
@python2 -m pyflakes $(filter-out isso/compat.py,$(ISSO_PY_SRC))
|
||||||
@echo "Python 3.x"
|
@echo "Python 3.x"
|
||||||
-@python3 -m pyflakes $(ISSO_PY_SRC)
|
@python3 -m pyflakes $(filter-out isso/compat.py,$(ISSO_PY_SRC))
|
||||||
|
|
||||||
isso/js/%.min.js: $(ISSO_JS_SRC) $(ISSO_CSS)
|
isso/js/%.min.js: $(ISSO_JS_SRC) $(ISSO_CSS)
|
||||||
$(RJS) -o isso/js/build.$*.js out=$@
|
$(RJS) -o isso/js/build.$*.js out=$@
|
||||||
|
@ -220,8 +220,6 @@ def main():
|
|||||||
imprt.add_argument("--empty-id", dest="empty_id", action="store_true",
|
imprt.add_argument("--empty-id", dest="empty_id", action="store_true",
|
||||||
help="workaround for weird Disqus XML exports, #135")
|
help="workaround for weird Disqus XML exports, #135")
|
||||||
|
|
||||||
serve = subparser.add_parser("run", help="run server")
|
|
||||||
|
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
conf = config.load(join(dist.location, dist.project_name, "defaults.ini"), args.conf)
|
conf = config.load(join(dist.location, dist.project_name, "defaults.ini"), args.conf)
|
||||||
|
|
||||||
|
@ -44,7 +44,7 @@ class curl(object):
|
|||||||
self.con = http(host, port, timeout=self.timeout)
|
self.con = http(host, port, timeout=self.timeout)
|
||||||
try:
|
try:
|
||||||
self.con.request(self.method, self.path, headers=self.headers)
|
self.con.request(self.method, self.path, headers=self.headers)
|
||||||
except (httplib.HTTPException, socket.error) as e:
|
except (httplib.HTTPException, socket.error):
|
||||||
return None
|
return None
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
Loading…
Reference in New Issue
Block a user