alliedvision / VimbaPython

Old Allied Vision Vimba Python API. The successor to this API is VmbPy
BSD 2-Clause "Simplified" License
93 stars 40 forks source link

VimbaPython Install.sh fails to detect python with appropriate pip #135

Closed KevinWorsley-bi closed 1 year ago

KevinWorsley-bi commented 1 year ago

Hey there,

I'm attempting to install VimbaPython using the Vimba SDK, following the provided documentation, and the VimbaPython Install.sh script fails to install, returning error Error: No compatible Python version with pip support found. Abort.

I am using a clean installation of Ubuntu 22.04.01 LTS. No virtual environment is used.

I install pyenv, and switch globally to Python 3.7.14. I then install the Vimba SDK, which Install.sh works fine. I then follow the instructions laid out in the VimbaPython documentation. python --version returns Python 3.7.14, and I downgrade pip to 21.1.2 as per the instructions. This works fine, and python -m pip --version returns pip 21.1.2 from /home/USER_DIR/.pyenv/versions/3.7.14/lib/python3.7/site-packages/pip (python 3.7)

I then run ./Install.sh -d, and receive error No virtual environment detected Searching for python in /usr/local/sbin /usr/local/bin /usr/sbin /usr/bin /sbin /bin /snap/bin Error: No compatible Python version with pip support found. Abort. I notice that by using pyenv, the python installation is actually located in /home/USER_DIR/.pyenv/versions/3.7.14/bin, and the debug message doesn't list the .pyenv that it searched for a python installation. Do you have any guidance on tweaking the script or other troubleshooting?

Thanks very much.

KevinWorsley-bi commented 1 year ago

I spoke to a rep from the support email and was able to successfully install without using pyenv under Ubuntu 22.04 and Python 3.10.6. Just switch every command in the documentation from command python to command python3 (you may need to sudo apt-get install pip). Instead of running the Install.sh script, run python3 -m pip install . from the .../Vimba_6_0/VimbaPython/Source directory. This manually invokes the setup.py script, builds the wheel and installed it properly.