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

Support Python 2.6 #40

Merged
merged 1 commit into from
Jan 30, 2015
Merged

Conversation

sholsapp
Copy link
Contributor

This string formatting nicety was introduced in Python 2.7 and breaks
Python 2.6 users like myself. This change is forwards and backwards
compatible between all Pythons.

This string formatting nicety was introduced in Python 2.7 and breaks
Python 2.6 users like myself. This change is forwards and backwards
compatible between all Pythons.
@wickman
Copy link
Contributor

wickman commented Jan 30, 2015

Thanks for the catch! Was unaware that this formatting quirk failed in 2.6.

This points out the need for better integration/coverage testing of the pex tool itself since 2.6 is supported and definitely covered by the rest of the tests.

wickman added a commit that referenced this pull request Jan 30, 2015
@wickman wickman merged commit d4fba94 into pex-tool:master Jan 30, 2015
@sholsapp
Copy link
Contributor Author

You're welcome!

Awesome tool, btw, we're playing with pex now to see if we can use it to manage a somewhat large codebase. So far it is looking great.

@sholsapp sholsapp deleted the support-python2.6.6 branch January 30, 2015 23:49
@wickman
Copy link
Contributor

wickman commented Jan 30, 2015

Cool. If you have any questions or need any help, don't hesitate to reach out. We don't have a pex-specific mailing list but the pants mailing list can be pretty helpful, and there's usually at least one of us in #pypa or #pypa-dev.

@sholsapp
Copy link
Contributor Author

sholsapp commented Feb 5, 2015

Hi @wickman, I know the change was trivial, but do you have any idea when a new version of pex might be available on pypi? We're largely a Python 2.6 shop and I'm trying to work pex into our artifact generating machinery... I can't do that until we get this fix released.

@wickman
Copy link
Contributor

wickman commented Feb 5, 2015

unless i'm missing something, '{}'.format(foo) is not a syntax error in Python 2.6 so the toolchain should work just fine (just that the 'pex --version' command is broken.) we should still roll a patch release but i just wanted to be clear that you shouldn't be blocked.

@sholsapp
Copy link
Contributor Author

sholsapp commented Feb 5, 2015

You're right, it's not a syntax error, but every command I try to run on Python 2.6 yields an error like this.

Traceback (most recent call last):
  File "/home/sholsapp/.virtualenvs/py509/bin/pex", line 11, in <module>
    sys.exit(main())
  File "/home/sholsapp/.virtualenvs/py509/lib/python2.6/site-packages/pex/bin/pex.py", line 320, in main
    parser = configure_clp()
  File "/home/sholsapp/.virtualenvs/py509/lib/python2.6/site-packages/pex/bin/pex.py", line 57, in configure_clp
    parser = OptionParser(usage=usage, version='%prog {}'.format(__version__))
ValueError: zero length field name in format

@wickman
Copy link
Contributor

wickman commented Feb 5, 2015

Ah, ok. I see. Thanks for the context. I'll get this published asap.

@wickman
Copy link
Contributor

wickman commented Feb 5, 2015

Published. Thanks for the prod.

@sholsapp
Copy link
Contributor Author

sholsapp commented Feb 5, 2015

Right on. Thank you for the quick response!

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 this pull request may close these issues.

2 participants