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

SyntaxError in plumbum/cli/image.py #365

Closed
grozin opened this issue Dec 15, 2017 · 4 comments · Fixed by #366
Closed

SyntaxError in plumbum/cli/image.py #365

grozin opened this issue Dec 15, 2017 · 4 comments · Fixed by #366

Comments

@grozin
Copy link

grozin commented Dec 15, 2017

image.py contains the line

import . as cli

All versions of python I tried (3.6, 3.5, 2.7) raise SyntaxError reading this line. According to the Python Language Reference, such syntax of the import statement is not allowed. What exactly is the purpose of this line? And how to achieve this purpose in legal python?

@grozin
Copy link
Author

grozin commented Dec 15, 2017

Is the following patch OK?
patch.txt
Argh, this site does not like .patch files, had to rename it.

@tkluck
Copy link
Contributor

tkluck commented Dec 22, 2017

With certain versions of pip, this will actually break the installation of Plumbum entirely, because those versions have a hard dependency on the py->pyc step succeeding. (This happened at one of my work deployments; don't have the logs on me atm.)

@tkluck
Copy link
Contributor

tkluck commented Dec 22, 2017

@grozin if that patch works (I haven't verified it), maybe you can submit it as a pull request, instead? That maximizes the chances of it being picked up.

@tkluck
Copy link
Contributor

tkluck commented Dec 22, 2017

@grozin never mind, I found a smaller patch and submitted that as a pull request. Thanks for opening this issue!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants