Help with PP linux and python...

More
14 Mar 2020 05:12 #160128 by pbreed
I want to run my robot code (see toolchanger a differnt way) on the same machine that is running pathpilot.

The Stock tormach pathpilot runs on 17.03 with the rt extensions.
The robot needs Python 3.7
The stock python3 on the Tormach image is 3.4.2

The robot needs numpy that needs at least python 3.5
I've managed to install python3.7 on the Tormach, but pip/ pip3 just does not work.
So I cant install prerequisites like numpy etc....

Googling there is much discussion about pip3 python3.7 being broken on 16.04 seems like it has the same issue on 17.03

I'm really really lost here... I've spent about two days on this trying all the proposed fixes and I'm lost.

Anyone here have any ideas?

Please Log in or Create an account to join the conversation.

More
14 Mar 2020 05:27 #160132 by rodw
What does sudo apt-get install python3-pip do?

IF it helps, I tried to use pip on Windows to install something during the week and it asked me to install the Windows C library at which point I knew I was in trouble but I did what it said and got no further so decided to wait until I was on Linux to try that script!

Please Log in or Create an account to join the conversation.

More
14 Mar 2020 06:07 #160135 by pbreed
Says its already the newest version...
but its bound/attached to the python3.4 version...
I need at least 3.5 and prefrably 3.7

To install 3.7 I needed do add the ppa dead snakes repository...

3.7 Runs, pip for 3.7 does

Before I started I first did
sudo apt-get update
sudo apt-get upgrade

etc...


It seems that my virtual box image of my pp install acts exactly the same way...
I'll take an hour or so in the morning to do all the upgrades to the pp install v-box to make them match and then report back here...

Please Log in or Create an account to join the conversation.

More
14 Mar 2020 06:49 #160138 by pbreed
So with 3.7 installed:
operator@tormachpcnc:~$ python3.7 -m pip install numpy
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 183, in _run_module_as_main
mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
File "/usr/lib/python3.7/runpy.py", line 142, in _get_module_details
return _get_module_details(pkg_main_name, error)
File "/usr/lib/python3.7/runpy.py", line 109, in _get_module_details
__import__(pkg_name)
File "/usr/lib/python3/dist-packages/pip/__init__.py", line 59, in <module>
from pip.log import logger
File "/usr/lib/python3/dist-packages/pip/log.py", line 9, in <module>
import colorama, pkg_resources
File "<frozen importlib._bootstrap>", line 983, in _find_and_load
File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 668, in _load_unlocked
File "<frozen importlib._bootstrap>", line 638, in _load_backward_compatible
File "/usr/share/python-wheels/setuptools-3.3-py2.py3-none-
any.whl/pkg_resources.py", line 1479, in <module>
register_loader_type(importlib_bootstrap.SourceFileLoader, DefaultProvider)
AttributeError: module 'importlib._bootstrap' has no attribute 'SourceFileLoader'


If I try from pip3

operator@tormachpcnc:~$ pip3 install numpy
Downloading/unpacking numpy
Downloading numpy-1.18.1.zip (5.4MB): 5.4MB downloaded
Running setup.py (path:/tmp/pip_build_operator/numpy/setup.py) egg_info for package numpy
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/tmp/pip_build_operator/numpy/setup.py", line 32, in <module>
raise RuntimeError("Python version >= 3.5 required.")
RuntimeError: Python version >= 3.5 required.
Complete output from command python setup.py egg_info:
Traceback (most recent call last):

File "<string>", line 17, in <module>

File "/tmp/pip_build_operator/numpy/setup.py", line 32, in <module>

raise RuntimeError("Python version >= 3.5 required.")

RuntimeError: Python version >= 3.5 required.

Cleaning up...

The above happens even after changing the python3 sym link to point a 3.7


If I remove python3-pip and reinstall...
(after the symlink i changed:)

I get the exact same result pip is tied to python 3.4

Please Log in or Create an account to join the conversation.

Moderators: cncbasher
Time to create page: 0.154 seconds
Powered by Kunena Forum