News for hackers. Stuff that matters.
Re:Ride the carousel of folly with a Python migration by zzleeper on Monday January 23, 2017 @11:38PM (#13468844)
About PyPI, it is a bit messy.

I backported a py3 project to use py2 (on behalf of a few users) and it was a real pain in the ass to have a wheel that allowed for both versions.

I ended up having a py3 build on github, and using a TravisCI build that ran pasteurize and pushed to PyPI that version. At this point, I don't even know what the travis.yml file is doing (100 lines), and regret a bit backporting the project.

Re:Ride the carousel of folly with a Python migration by slavik81 on Tuesday January 24, 2017 @01:40AM (#13469289)
What makes it difficult? My projects are all quite simple, but I do keep them compatible with both Python 2 and Python 3.

All I had to do was create a setup.cfg that said:

    [wheel]
    universal = 1
To build, I use:

    python setup.py sdist bdist_wheel
    twine upload -s dist/*
The .travis.yml is just 7 lines. https://github.com/cgmb/guardonce/blob/v2.0.0/.travis.yml
Re:Ride the carousel of folly with a Python migration by zzleeper on Tuesday January 24, 2017 @06:16AM (#13470483)
Are you using py3 exclusive features? If you are not, then you are not really using python 3 (tuple unpacking, etc.)

If you want to do both, then you need pasteurize, and end up with a travis mess: https://github.com/sergiocorreia/panflute/blob/master/.travi...

To be honest, for me the morale of the story is that supporting py2 is just not worth it. I am not going to use it, so why support it at all?

Re:Ride the carousel of folly with a Python migration by slavik81 on Tuesday January 24, 2017 @06:58AM (#13470652)
Interesting. I do stick to Python 2 features, but put in some work to ensure my programs are valid Python 3. I'm not a very skilled Python developer, so the simplicity of that strategy is attractive.

One thing that I notice is that your project is a library, while mine is a program. I wonder if that also plays a role.