JetsonHacksNano / ServoKit

Install the Adafruit ServoKit Circuit Python library on the NVIDIA Jetson Nano Developer Kit
MIT License
58 stars 34 forks source link

Error installing installGamePad.sh #2

Open lunarminer opened 4 years ago

lunarminer commented 4 years ago

Hello, I have been following the tutorial video and I get the following error when I try to install the installGamePad.sh. etbot@jetbot:~/ServoKit$ sudo ./installGamePad.sh Collecting approxeng.input Using cached https://files.pythonhosted.org/packages/1c/27/418500122ddff3e29355c5f248b20690555102c59037961968583262ae55/approxeng.input-2.4.2.tar.gz Complete output from command python setup.py egg_info: Traceback (most recent call last): File "", line 1, in File "/tmp/pip-build-47_8c_g3/approxeng.input/setup.py", line 2, in from setuptools import setup, find_namespace_packages ImportError: cannot import name 'find_namespace_packages'

----------------------------------------

Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-47_8c_g3/approxeng.input/

Pices-26 commented 4 years ago

You need to fix it manually. Clone the whole repo of approxeng. Go into it, then src/python. Inside of that folder you will see approxeng folder. Copy the ps4 controller setup into approxeng/input. Then copy the whole folder into /usr/local/lib/python3.6/dist-packages. You will need to sudo cp just so it will let you.

andrewssobral commented 3 years ago

I fixed it by doing:

sudo -H pip3 install setuptools --upgrade

Here are the logs:

andrews@jetson-agx:~/Projects/jetson-hacks$ sudo -H pip3 install setuptools --upgrade
Collecting setuptools
  Downloading https://files.pythonhosted.org/packages/56/0f/52135ff086dd42b10636a205170f50a0a8dcd0d648835abdd3a8c0bc06ac/setuptools-58.0.2-py3-none-any.whl (816kB)
    100% |████████████████████████████████| 819kB 1.2MB/s 
Installing collected packages: setuptools
  Found existing installation: setuptools 39.0.1
    Not uninstalling setuptools at /usr/lib/python3/dist-packages, outside environment /usr
Successfully installed setuptools-58.0.2
andrews@jetson-agx:~/Projects/jetson-hacks$ sudo -H pip3 install approxeng.input
Collecting approxeng.input
  Using cached https://files.pythonhosted.org/packages/23/a5/3dd51d43369b07671ad98c8fb4f13d13dae7190be16b497b4fead37214d1/approxeng.input-2.6.3.tar.gz
Collecting evdev==1.2.0 (from approxeng.input)
  Downloading https://files.pythonhosted.org/packages/fe/6e/3fa84a43571dec4d00dc26befccc9867b6b3263651531cbc1345f718860f/evdev-1.2.0.tar.gz
Collecting pyyaml==5.4 (from approxeng.input)
  Downloading https://files.pythonhosted.org/packages/b5/fd/15638de2da0a5aa91c095718444624aa565f766fc178249ca6faa372f71a/PyYAML-5.4.tar.gz (174kB)
    100% |████████████████████████████████| 184kB 4.3MB/s 
Collecting importlib-resources (from approxeng.input)
  Downloading https://files.pythonhosted.org/packages/f2/6c/2f3b930513bb971172ffceb63cf4e910944e57451724e69b1dec97cfefa6/importlib_resources-5.2.2-py3-none-any.whl
Collecting zipp>=3.1.0; python_version < "3.10" (from importlib-resources->approxeng.input)
  Downloading https://files.pythonhosted.org/packages/92/d9/89f433969fb8dc5b9cbdd4b4deb587720ec1aeb59a020cf15002b9593eef/zipp-3.5.0-py3-none-any.whl
Building wheels for collected packages: approxeng.input, evdev, pyyaml
  Running setup.py bdist_wheel for approxeng.input ... done
  Stored in directory: /root/.cache/pip/wheels/7f/d9/3e/1014d801c3932afb8646571019422907477e36159e9a19c405
  Running setup.py bdist_wheel for evdev ... done
  Stored in directory: /root/.cache/pip/wheels/05/f9/96/72f2a2385b675af9e80b05582472178948c2d36aab8c0380df
  Running setup.py bdist_wheel for pyyaml ... done
  Stored in directory: /root/.cache/pip/wheels/44/b8/7d/ebf87a5dfb63248d2e26442f798999ed39d61bd07d6ac3b222
Successfully built approxeng.input evdev pyyaml
Installing collected packages: evdev, pyyaml, zipp, importlib-resources, approxeng.input
  Found existing installation: PyYAML 3.12
    Not uninstalling pyyaml at /usr/lib/python3/dist-packages, outside environment /usr
Successfully installed approxeng.input-2.6.3 evdev-1.2.0 importlib-resources-5.2.2 pyyaml-5.4 zipp-3.5.0
andrews@jetson-agx:~/Projects/jetson-hacks$