Fixed PEP 8 style using autopep8
Used autopep8 to correct styling.
Ran autopep8 on openbmc-test-automation, autopep8 is not
able to fix all styling issues. There is still around
1000 styling violations in openbmc-test-automation.
More information on autopep8 can be found here,
https://pypi.python.org/pypi/autopep8
Change-Id: Iddc131da1d74d978eb3dd0fdd6ce5d0a0e49b0f8
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
diff --git a/tools/github_issues_to_csv b/tools/github_issues_to_csv
index 3053e10..224bad2 100644
--- a/tools/github_issues_to_csv
+++ b/tools/github_issues_to_csv
@@ -45,13 +45,13 @@
# Change the following line to write out additional fields
csv_out.writerow([labels.encode('utf-8'),
- issue.get('title').encode('utf-8'),
- issue.get('state').encode('utf-8'),
- issue.get('created_at').split('T')[0],
- close_date,
- issue.get('html_url').encode('utf-8'),
- issue.get('user').get('login').encode('utf-8'),
- owners, milestone_resp])
+ issue.get('title').encode('utf-8'),
+ issue.get('state').encode('utf-8'),
+ issue.get('created_at').split('T')[0],
+ close_date,
+ issue.get('html_url').encode('utf-8'),
+ issue.get('user').get('login').encode('utf-8'),
+ owners, milestone_resp])
def get_issues_from_github_to_csv(name, response):
@@ -68,11 +68,11 @@
if 'link' in response.headers:
pages = {rel[6:-1]: url[url.index('<')+1:-1] for url, rel in
(link.split(';') for link in
- response.headers['link'].split(','))}
+ response.headers['link'].split(','))}
while 'last' in pages and 'next' in pages:
pages = {rel[6:-1]: url[url.index('<')+1:-1] for url, rel in
(link.split(';') for link in
- response.headers['link'].split(','))}
+ response.headers['link'].split(','))}
response = requests.get(pages['next'], auth=auth)
write_issues(response, csv_out)
if pages['next'] == pages['last']:
diff --git a/tools/oem/ibm/gen_csv_results.py b/tools/oem/ibm/gen_csv_results.py
index 2578da8..920e79e 100755
--- a/tools/oem/ibm/gen_csv_results.py
+++ b/tools/oem/ibm/gen_csv_results.py
@@ -6,7 +6,8 @@
http://robot-framework.readthedocs.io/en/3.0/autodoc/robot.result.html
"""
-import sys, os
+import sys
+import os
import getopt
import csv
import robot.errors
@@ -65,7 +66,6 @@
def exit_function(signal_number=0,
frame=None):
-
r"""
Execute whenever the program ends normally or with the signals that we
catch (i.e. TERM, INT).
@@ -80,7 +80,6 @@
def signal_handler(signal_number,
frame):
-
r"""
Handle signals. Without a function to catch a SIGTERM or SIGINT, the
program would terminate immediately with return code 143 and without
@@ -98,7 +97,6 @@
def validate_parms():
-
r"""
Validate program parameters, etc. Return True or False (i.e. pass/fail)
accordingly.
@@ -116,7 +114,6 @@
def parse_output_xml(xml_file_path, csv_dir_path, version_id, platform):
-
r"""
Parse the robot-generated output.xml file and extract various test
output data. Put the extracted information into a csv file in the "dest"
@@ -168,7 +165,7 @@
l_platform_type = ""
l_func_area = ""
- ## System data from XML meta data
+ # System data from XML meta data
#l_system_info = get_system_details(xml_file_path)
# First let us try to collect information from keyboard input
@@ -239,7 +236,6 @@
def xml_to_csv_time(xml_datetime):
-
r"""
Convert the time from %Y%m%d %H:%M:%S.%f format to %Y-%m-%d-%H-%M-%S format
and return it.
@@ -259,7 +255,6 @@
def get_system_details(xml_file_path):
-
r"""
Get the system data from output.xml generated by robot and return it.
The list returned will be in the following order: [driver,platform]