Closed saj closed 8 years ago
seems reasonable to me - would like to get some basic test coverage added for this area tho to help prevent future issues.
I've cut a new release at https://pypi.python.org/pypi/pex/1.1.9 with this fix. if anyone feels like adding better test coverage around this area for various known problematic packages, would gladly accept a PR - or otherwise I'll plan to circle back here.
thanks again @saj !
I think this is a regression introduced in #231, which was released in pex 1.1.7. I cannot reproduce this problem on pex 1.1.6. Affects Python 2 only.
Reproduce with:
Stack trace:
Even if we were to ignore the problem above, I don't think it is right to assume a UTF-8 encoding on all files.
From PEP 263:
From the same PEP:
Instead of opening
setup.py
as a text file and decoding it ourselves, it sounds like it should be possible to hand a binary stream directly to thecompile()
builtin and let Python deal with this muck.