I’ve done that many times. It redownloads robotpy but does not fix the error
Here’s an error for the command pip install -U pyfrc. It is the same error for the installation of many other packages like robotpy-hal.
Installing build dependencies: finished with status ‘error’
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3.7 /home/first/.local/lib/python3.7/site-packages/pip install --ignore-installed --no-user --prefix /tmp/pip-build-env-3esqufkp/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple – ‘robotpy-build>=2020.1.5,<2021.0.0’ ‘robotpy-wpiutil>=2020.2.2.0,<2021.0.0’
cwd: None
What OS are you on?
Ubuntu 16.04
What version of pip?
Also, are you trying to install code on the robot, or on your computer? Or both?
pip 20.0.2 python 3.7
Are you trying to install code on the robot, or on your computer? Or both?
Also, what’s the output of pip3 list?
apturl 0.5.2
bcrypt 3.1.7
beautifulsoup4 4.4.1
blinker 1.3
Brlapi 0.6.4
cffi 1.14.0
chardet 2.3.0
checkbox-support 0.22
command-not-found 0.3
cryptography 2.8
defer 1.0.6
docutils 0.12
feedparser 5.1.3
guacamole 0.9.2
header2whatever 0.4.2
html5lib 0.999
httplib2 0.9.1
idna 2.0
Jinja2 2.8
language-selector 0.1
lockfile 0.12.2
louis 2.6.4
lxml 3.5.0
Mako 1.0.3
MarkupSafe 0.23
oauthlib 1.0.3
onboard 1.2.0
padme 1.1.1
paramiko 2.7.1
pexpect 4.0.1
Pillow 3.1.2
pip 20.0.2
pip-autoremove 0.9.1
plainbox 0.25
ply 3.11
ptyprocess 0.5
pyasn1 0.1.9
pycparser 2.19
pycups 1.9.73
pycurl 7.43.0
pydantic 1.4
Pygments 2.1
pygobject 3.20.0
PyJWT 1.3.0
PyNaCl 1.3.0
pyparsing 2.0.3
python-apt 1.1.0b1+ubuntu0.16.4.8
python-daemon 2.0.5
python-debian 0.1.27
python-systemd 231
pyxdg 0.25
PyYAML 5.3
reportlab 3.3.0
requests 2.9.1
robotpy-build 2020.1.8
robotpy-cppheaderparser 5.0.2
robotpy-installer 2020.0.5
roman 2.0.0
schematics 2.1.0
sessioninstaller 0.0.0
setuptools 45.2.0
setuptools-scm 3.3.3
six 1.10.0
sphinxify 0.6.1
ssh-import-id 5.5
system-service 0.3
toml 0.10.0
toposort 1.5
ubuntu-drivers-common 0.0.0
ufw 0.35
unattended-upgrades 0.1
unity-scope-calculator 0.1
unity-scope-chromiumbookmarks 0.1
unity-scope-colourlovers 0.1
unity-scope-devhelp 0.1
unity-scope-firefoxbookmarks 0.1
unity-scope-gdrive 0.7
unity-scope-manpages 0.1
unity-scope-openclipart 0.1
unity-scope-texdoc 0.1
unity-scope-tomboy 0.1
unity-scope-virtualbox 0.1
unity-scope-yelp 0.1
unity-scope-zotero 0.1
unity-tweak-tool 0.0.7
urllib3 1.13.1
usb-creator 0.3.0
wheel 0.29.0
xdiagnose 3.8.4.1
xkit 0.0.0
XlsxWriter 0.7.3
xvfbwrapper 0.2.4
Ok, I’m guessing that you’re trying to install robotpy locally? Robotpy installer is for installing robotpy on the robot, so it won’t help you in this instance.
We don’t publish Linux wheels on pypi, so the error you’re encountering is pip trying to build the wheels manually. Unfortunately, this requires a C++ compiler that is newer than the one that is available for Ubuntu 16. I’ll update the linux-specific documentation tonight.
Is there a reason you’re using Ubuntu 16? We do have wheels available for Ubuntu 18 (though not on pypi).
I would love linux specific docs for this, thanks. Also this worked before for 2019 so at this point I’m trying to figure out what I changed from last year.
2019 did not require a C++ compiler, everything was pure python and worked pretty much everywhere. We’ve switched to C++ wrappers around WPILib, so everything this year is quite different. I’ve written a bit about this in our docs.
In particular, because WPILib requires a C++17 compiler, it’s a non-trivial task to publish compiled versions of RobotPy components for Linux.
Thanks
A little more research shows that I have g++ 5.4 and it support c++17. However, the compile during the install of robotpy-cscore, for example, the ‘make’ invocation of g++ does not contain the required flag to use c++17. Is there a way to stop the ‘python setup.py’, fix the makefile and continue on?
robotpy-cscore uses a separate build from the other wpilib components.
Unfortunately, WPILib is not compatible with Ubuntu 16.04, I just tried it. Even if you were able to get the compilation to work, you’ll end up with the following error or something similar:
OSError: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.22' not found (required by /usr/local/lib/python3.7/dist-packages/wpiutil/lib/libwpiutil.so)`
If you don’t have the option to upgrade to Ubuntu 18.04, you could potentially install RobotPy in an Ubuntu 18.04 docker image. However there are drawbacks – in particular it would be quite difficult to get the simulation GUI working on the docker image, though technically possible.
That’s very nice of you to try. Thank you.
I just updated the documentation to mention Linux specific notes, including links to our precompiled wheels.
https://robotpy.readthedocs.io/en/stable/install/pyfrc.html#install-linux
I switched to a windows 7 computer and I am now experiencing the same issues trying to install robotpy-ctre on the rio. I ran the command
py -3 robotpy-installer download robotpy-ctre and got problems with no robotpy-build and all that again. Shouldn’t the wheels for windows be built?
Yes, Windows should work fine, as long as you’re using a 64-bit version of Python.
py -m pip install -U pyfrc robotpy-ctre
Will install local packages on Windows. If you get a 404 file not found error, you are using a 32-bit Python and need to install a 64-bit python instead.