You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by ra...@apache.org on 2018/07/13 12:01:06 UTC
[incubator-openwhisk] branch master updated: Fix warnings in python
scripts. (#3874)
This is an automated email from the ASF dual-hosted git repository.
rabbah pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk.git
The following commit(s) were added to refs/heads/master by this push:
new 731dbe5 Fix warnings in python scripts. (#3874)
731dbe5 is described below
commit 731dbe52f47d08ab7f5e026584ef5d5e5a06780a
Author: Markus Thömmes <ma...@me.com>
AuthorDate: Fri Jul 13 14:01:02 2018 +0200
Fix warnings in python scripts. (#3874)
* Fix Flake8 warnings.
* Enable Flake8 to abort the build even on warnings.
---
tools/build/citool | 4 ++--
tools/build/redo | 10 +++++-----
tools/travis/flake8.sh | 6 +++---
3 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/tools/build/citool b/tools/build/citool
index 2af9342..d9f218e 100755
--- a/tools/build/citool
+++ b/tools/build/citool
@@ -38,10 +38,10 @@ import time
import traceback
import argparse
if sys.version_info.major >= 3:
- from http.client import HTTPConnection, HTTPSConnection, IncompleteRead, TEMPORARY_REDIRECT, OK
+ from http.client import HTTPConnection, HTTPSConnection, TEMPORARY_REDIRECT, OK
from urllib.parse import urlparse
else:
- from httplib import HTTPConnection, HTTPSConnection, IncompleteRead, TEMPORARY_REDIRECT, OK
+ from httplib import HTTPConnection, HTTPSConnection, TEMPORARY_REDIRECT, OK
from urlparse import urlparse
import re
import threading
diff --git a/tools/build/redo b/tools/build/redo
index 941104d..b421a18 100755
--- a/tools/build/redo
+++ b/tools/build/redo
@@ -278,12 +278,12 @@ Components = [
'build a runtime action container, matching name using the regex; NOTE: must use --dir for path to runtime directory',
yaml = False,
gradle = 'core:$1:distDocker'),
-
- makeComponent('actionproxy',
- 'build action proxy container',
- yaml = False,
+
+ makeComponent('actionproxy',
+ 'build action proxy container',
+ yaml = False,
gradle = 'tools:actionProxy'),
-
+
# required for tests
makeComponent('props',
'build whisk.properties file (required for tests)',
diff --git a/tools/travis/flake8.sh b/tools/travis/flake8.sh
index 23aab82..7edddaa 100755
--- a/tools/travis/flake8.sh
+++ b/tools/travis/flake8.sh
@@ -30,13 +30,13 @@ do
flake8 "$i" --select=E999,F821 --statistics
RETURN_CODE=$?
if [ $RETURN_CODE != 0 ]; then
- echo 'Flake8 found Python 3 syntax errors above. See: https://docs.python.org/3/howto/pyporting.html'
+ echo 'Flake8 found Python 3 syntax errors above. See: https://docs.python.org/3/howto/pyporting.html'
exit $RETURN_CODE
fi
done
-echo 'Flake8: second round uses the --exit-zero flag to treat _every_ message as a warning...'
+echo 'Flake8: second round to find any other stylistic issues...'
for i in "${PYTHON_FILES[@]}"
do
- flake8 "$i" --ignore=E --max-line-length=127 --statistics --exit-zero
+ flake8 "$i" --ignore=E --max-line-length=127 --statistics
done