phpserialize on Python 3

I was playing around with phpserialize and found out that phpserialize doesn’t work on Python 3.

However, I put together a GitHub fork that works with Python 3 (and also has tests, especially for Unicode which is the real gotcha when porting from Python 2.x to Python 3.x):

To use this, I put

-e git+git://github.com/msabramo/phpserialize.git@python3.x#egg=phpserialize

in my pip requirements file.

For Tox (a recent find and a very nice tool), this needs to be tweaked because it uses ConfigParser to parse its ini file and ConfigParser swallows the stuff after the # as a comment (I could find no way to escape the #; others have noticed this too). So in my tox.ini I used:


https://github.com/msabramo/phpserialize/tarball/python3.x

for the deps setting.

Full tox.ini for the curious:

Leave a Reply

Your email address will not be published.

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>