Skip to content

Commit

Permalink
Lint examples
Browse files Browse the repository at this point in the history
  • Loading branch information
albertyw committed Jul 17, 2018
1 parent e5e4897 commit 14eb9de
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
12 changes: 8 additions & 4 deletions examples/example.py
@@ -1,6 +1,7 @@
'''
This is an example script for using itol.py
To use itol.py, you essentially have to instantiate the object, set the tree, submit the file to itol, then use the returned data
To use itol.py, you essentially have to instantiate the object, set the tree,
submit the file to itol, then use the returned data
'''

import os
Expand All @@ -11,7 +12,7 @@
parent_path = fullpath + "/../"
sys.path.append(parent_path)

from itolapi import Itol, ItolExport
from itolapi import Itol, ItolExport # NOQA

print('Running example itol and itolexport script')
print('')
Expand All @@ -34,7 +35,10 @@
test.print_variables()
# Submit the tree
print('')
print('Uploading the tree. This may take some time depending on how large the tree is and how much load there is on the itol server')
print((
'Uploading the tree. This may take some time depending on how large the '
'tree is and how much load there is on the itol server'
))
good_upload = test.upload()
if not good_upload:
print('There was an error:' + test.comm.upload_output)
Expand All @@ -59,7 +63,7 @@
itol_exporter.set_export_param_value('format', 'pdf')
itol_exporter.set_export_param_value('datasetList', 'dataset1')
# itol_exporter.export('example_pdf.pdf')
#print('exported tree to ',export_location)
# print('exported tree to ',export_location)

# Export the tree above to pdf
print('Exporting to pdf')
Expand Down
2 changes: 1 addition & 1 deletion examples/failures/fatal.py
Expand Up @@ -11,7 +11,7 @@
parent_path = fullpath + "/../../"
sys.path.append(parent_path)

from itolapi import Itol
from itolapi import Itol # NOQA

parse_fn = 'huge.matrix.tree.parse'
color_fn = 'huge.matrix.tree.parse.color'
Expand Down
2 changes: 1 addition & 1 deletion examples/failures/warnings.py
Expand Up @@ -11,7 +11,7 @@
parent_path = fullpath + "/../../"
sys.path.append(parent_path)

from itolapi import Itol
from itolapi import Itol # NOQA

parse_fn = 'huge.matrix.tree.parse'
color_fn = 'huge.matrix.tree.parse.color'
Expand Down

0 comments on commit 14eb9de

Please sign in to comment.