farinacci/lispers.net

Support for Python 3

Closed this issue · 3 comments

rvs commented

It is becoming more and more difficult to get proper Python 2 support in most Linux distributions. Any plans for making sure that lisper.net codebase can run on Python3?

Roman, thanks for the request. I spent some time researching this today. You can find https://github.com/farinacci/lispers.net/blob/master/docs/converting-to-python3.txt that has a list of what I'll need to investigate. This will take some dedicated effort.

Here is what I plan to do:

(1) Now (or soon), on the master branch, I will make sure the 2.7.x is somewhat future-proof. I will commit changes to print statements and raw_input() calls.

(2) I have already ran pyflakes2 and pyflakes3 on code with some changes from python-modernize but I don't want to commit them without testing.

So the simple syntactic changes I can get in soon. Libraries have to be reinstalled so the build process needs changing. I also want to consider running the same code for a python2 build and a python3 build. Lets see if that can occur easily. Otherwise we'll branch and do python3 changes in a branch.

How does that sound?

rvs commented

Hey @farinacci -- thanks for looking into this -- much appreciated! Your list seems long, but not too daunting ;-)

Now, I'd love to be able to "run the same code for a python2 build and a python3 build" but I'm afraid I don't see how you can achieve it re: libraries. Or are you saying that it is just the source that will remain the same, but when you build a final binary distro tarball you will still pick python3 or python2?

@rvs, I am closing this issue since I have tested lispers.net in many use-cases for a few months. So I have considered the code converted to python3 and works with python2 by default. See instructions to build python3 images.