Closed ghost closed 4 years ago
Hi, thank you very much for your offer.
I think we can make the code run under both Python 2 and Python 3. I've started with the modules in xc_utils, you can take a look to the last commit.
I was trying to make one of the simplest tests test_evalPy.py to run under Python3. I've not succeeded there is some problem when installing the c++ extensions; Python3 doesn't find them. Maybe you can take a look to the setup file. It puts the libraries in '/usr/local/lib/python3/dist-packages' but Python3 doesn't find them.
Regards. Luis.
You're welcome ;)
I will look at the file later, but as I can see from your comment, there's no address as '/usr/local/lib/python3/dist-packages'
at least in Debian-based distros. In Debian minor version of python should be included, something like: '/usr/local/lib/python3.5/dist-packages'
regards. Salman
Hi.
It's the line; 'pth_to_libs= get_python_lib(1,0,myPrefix)' in setup.py which returns the directory for the libraries: '/usr/local/lib/python2.7/dist-packages' when executed with Python 2 and '/usr/local/lib/python3/dist-packages' when executed with Python3. I'm using Ubuntu 18.04.
good luck luis with the move to Py3. On FreeCAD it took a huge amount of time ... but eventualle it was worth any second spent ont the move to Py3.
cheers bernd
Thanks Bernd.
The first thing I'm trying to do is to expose XC c++ modules to Py3 (i thought that it was a trivial step but, apparently, it is not so trivial...). On the bright side I think XC is simpler than FreeCAD.
Hi @lcpt , what is going on this migration? any effort? thanks.
Hi Ebrahim.
We've postponed the migration of the C++ modules to Python 3 until the release of Ubuntu 20.4 in April. I think that working with a distribution that comes with Python 3 as default will make things a lot easier. In the interim we are gently migrating the Python modules.
I've just finished with the migration of the xc_utils package. I'll continue with XC soon. It doesn't seem too difficult.
Done! It needed 18:09 hours of work, not so bad.
Migration to Python 3 is completed.
YEAH! It took much much more hours to port FreeCAD
FreeCAD is much more complex.
If you consider moving to Python 3 before Python 2's End-of-Life which is January 1, 2020. I would be more than happy to give a hand and help about it.