MATLAB Answers

ROS rosinit python package install error

55 views (last 30 days)
Mike
Mike on 6 Feb 2021
Answered: Mike on 7 Feb 2021
Hi
I'm trying to get familar with the ROS toolbox, but so far I can't get it up and running in Matlab. I'm trying to initialize ROS with the command 'rosinit' and get the following error.
>> rosinit
Launching ROS Core...
Adding required Python packages to virtual environment....Done.
Could not install the required Python packages. System error message: Collecting catkin_pkg
Collecting empy
Collecting docutils
Collecting pyparsing
Collecting python_dateutil
Collecting pyyaml
Collecting rosdep
Collecting rosdistro
Collecting rosinstall
Collecting rosinstall_generator
Collecting rospkg
Requirement already satisfied: setuptools in
./.matlab/R2020b/ros1/glnxa64/venv/lib/python2.7/site-packages
Collecting six
Collecting vcstools
Collecting wstool
Collecting defusedxml
Collecting netifaces
[31m Could not find a version that satisfies the requirement netifaces (from versions:
)[0m
[31mNo matching distribution found for netifaces[0m
. Use pyenv function to set the path to the Python executable and retry the command.
I already have installed python 2.7 and running 'pyenv' the following is shown.
>> pyenv
ans =
PythonEnvironment with properties:
Version: "2.7"
Executable: "/usr/local/bin/python"
Library: ""
Home: "/usr/local"
Status: NotLoaded
ExecutionMode: InProcess

Accepted Answer

Mike
Mike on 7 Feb 2021
For anyone strugling with a similar issue I simply fixed it by installing the strugling python package with the command:
pip install netifaces

More Answers (0)

Products


Release

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!