Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python3 syntax errors #219

Open
t0rrant opened this issue Aug 16, 2019 · 3 comments
Open

Python3 syntax errors #219

t0rrant opened this issue Aug 16, 2019 · 3 comments
Labels
bug Something isn't working mid/low priority
Milestone

Comments

@t0rrant
Copy link

t0rrant commented Aug 16, 2019

Usage of print as a macro, i.e https://github.com/assemblerflow/flowcraft/blob/master/flowcraft/bin/renamePE_samtoolsFASTQ.py#L98:

print 'Runtime :' + str(hours) + 'h:' + str(minutes) + 'm:' + str(round(seconds, 2)) + 's'

is not allowed, all print '<string>' references should be updated to print('<string>') formatted or python3 installation fails:

# python3 setup.py install
...
byte-compiling build/bdist.linux-x86_64/egg/flowcraft/bin/renamePE_samtoolsFASTQ.py to renamePE_samtoolsFASTQ.cpython-35.pyc
  File "build/bdist.linux-x86_64/egg/flowcraft/bin/renamePE_samtoolsFASTQ.py", line 98
     print 'Runtime :' + str(hours) + 'h:' + str(minutes) + 'm:' + str(round(seconds, 2)) + 's'
                     ^
SyntaxError: invalid syntax

This and other fixes can be automatically applied by using 2to3

@cimendes
Copy link
Member

This is a case of a misplaced template script that should not be in the bin folder. Thank you for reporting this! :)

@cimendes cimendes added bug Something isn't working mid/low priority recipe and removed recipe labels Aug 16, 2019
@cimendes cimendes added this to the 1.5.0 milestone Aug 23, 2019
@t0rrant
Copy link
Author

t0rrant commented Sep 9, 2019

@cimendes is this just a case of removing that template script, as it is not actually needed, or is it supposed to be moved to another location?

@cimendes
Copy link
Member

cimendes commented Sep 9, 2019

Hi! This file right here should be rewritten and added as a propper template (moving to flowcraft/templates/) instead of sneakily living in the bin folder. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working mid/low priority
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants