-
-
Notifications
You must be signed in to change notification settings - Fork 499
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Installing Home Assistant fails with "could not build wheels for cryptography" #5878
Comments
Known issue with piwheels, where most wheel builds with Rust as dependency currently fail. PR for fixing this is up already: piwheels/piwheels#328 If this is a new image, I suggest to use the ARMv6/64-bit image, where this issue doesn't exist. Otherwise, as a manual workaround, edit if [[ $G_HW_ARCH == [12] ]]
then
G_EXEC mkdir -p "$ha_home/.pip"
# Bullseye
if (( $G_DISTRO == 6 ))
then
# Create pip config to pull wheels from piwheels.org
G_EXEC eval "echo -e '[global]\nextra-index-url=https://www.piwheels.org/simple/' > $ha_home/.pip/pip.conf"
aDEPS+=('libopenjp2-7' 'libtiff5' 'libxcb1' 'libatlas3-base') # piwheels wheels require runtime libraries
else
# piwheels.org Python 3.9 wheels depend on shared libraries from Bullseye. Unset extra-index-url explicitly, as /etc/pip.conf could set it.
G_EXEC eval "echo -e '[global]\nextra-index-url=' > $ha_home/.pip/pip.conf"
# libjpeg-dev for Pillow, libatlas-base-dev for numpy
aDEPS+=('libjpeg-dev' 'libatlas-base-dev')
# Rust for cryptography
G_EXEC curl -sSfL 'https://sh.rustup.rs' -o rustup-init.sh
G_EXEC chmod +x rustup-init.sh
G_EXEC_OUTPUT=1 G_EXEC sudo -u "$ha_user" ./rustup-init.sh -y --profile minimal
G_EXEC_NOHALT=1 G_EXEC rm rustup-init.sh
fi
fi to if [[ $G_HW_ARCH == [12] ]]
then
G_EXEC mkdir -p "$ha_home/.pip"
# Rust
G_EXEC curl -sSfL 'https://sh.rustup.rs' -o rustup-init.sh
G_EXEC chmod +x rustup-init.sh
G_EXEC_OUTPUT=1 G_EXEC sudo -u "$ha_user" ./rustup-init.sh -y --profile minimal
G_EXEC_NOHALT=1 G_EXEC rm rustup-init.sh
# Bullseye
if (( $G_DISTRO == 6 ))
then
# Create pip config to pull wheels from piwheels.org
G_EXEC eval "echo -e '[global]\nextra-index-url=https://www.piwheels.org/simple/' > $ha_home/.pip/pip.conf"
aDEPS+=('libopenjp2-7' 'libtiff5' 'libxcb1' 'libatlas3-base') # piwheels wheels require runtime libraries
else
# piwheels.org Python 3.9 wheels depend on shared libraries from Bullseye. Unset extra-index-url explicitly, as /etc/pip.conf could set it.
G_EXEC eval "echo -e '[global]\nextra-index-url=' > $ha_home/.pip/pip.conf"
# libjpeg-dev for Pillow, libatlas-base-dev for numpy
aDEPS+=('libjpeg-dev' 'libatlas-base-dev')
fi
fi so Rust is installed as well on Bullseye into the pyenv environment. |
as an alternative, install Rust beforehand https://dietpi.com/forum/t/unable-to-upgrade-home-assistant-to-2021-10-x/5823/4 |
Ah, solved in the meantime with v8.12 since Rust is now installed on all ARMv6/7 systems. piwheels cannot be used anymore for HA since it shops Python 3.9 wheels while HA now uses/requires Python 3.10. |
You would need to update to latest DietPi version first. |
Am I not already on the latest version? How do I do that then? |
Latest version is 8.16.2: dietpi-update |
I typo'd |
pls open a new issue for your error and fill the bug report with relevant data. Pls add the full install log. |
Ok I have created #6306 |
Details:
Linux homebot 5.15.76-v7+ #1597 SMP Fri Nov 4 12:13:17 GMT 2022 armv7l GNU/Linux
sudo -u homeassistant dash -c . /home/homeassistant/pyenv-activate.sh pyenv install 3.9.15 pyenv local 3.9.15 pip3 install --no-cache-dir -U pip setuptools wheel [ -z '' ] || pip3 install --no-cache-dir exec pip3 install --no-cache-dir homeassistant
Steps to reproduce:
Extra details:
Additional logs:
The text was updated successfully, but these errors were encountered: