GNS3 / gns3-registry

GNS3 devices registry
GNU General Public License v3.0
323 stars 387 forks source link

Docker image pyats fails to build on latest ubuntu 24.04 (noble) #879

Closed b-ehlers closed 1 month ago

b-ehlers commented 1 month ago

Docker image pyats is based on ubuntu:latest, which is version 24.04 (noble) since a couple of days. This ubuntu version uses a new pip, which refuses to replace files installed by apt.

Here an excerpt from the build log, the full log is at https://github.com/GNS3/gns3-registry/actions/runs/8906797643/job/24459523600

#17 [13/14] RUN python3 -m pip install --upgrade pip wheel setuptools
#17 0.321 error: externally-managed-environment
#17 0.321 
#17 0.321 × This environment is externally managed
#17 0.321 ╰─> To install Python packages system-wide, try apt install
#17 0.321     python3-xyz, where xyz is the package you are trying to
#17 0.321     install.
#17 0.321     
#17 0.321     If you wish to install a non-Debian-packaged Python package,
#17 0.321     create a virtual environment using python3 -m venv path/to/venv.
#17 0.321     Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
#17 0.321     sure you have python3-full installed.
#17 0.321     
#17 0.321     If you wish to install a non-Debian packaged Python application,
#17 0.321     it may be easiest to use pipx install xyz, which will manage a
#17 0.321     virtual environment for you. Make sure you have pipx installed.
#17 0.321     
#17 0.321     See /usr/share/doc/python3.12/README.venv for more information.
#17 0.321 
#17 0.321 note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages.
#17 0.321 hint: See PEP 668 for the detailed specification.
#17 ERROR: process "/bin/sh -c python3 -m pip install --upgrade pip wheel setuptools" did not complete successfully: exit code: 1

Until this is fixed (for example by the maintainer @xander-petty12093), the docker build tool should no longer build it. Therefore I will create a PR disabling building this docker image.

llevier commented 1 month ago

Hello I also faced this situation, simply a python bug easy to solve: find /usr/lib -name EXTERNALLY-MANAGED -exec rm -f {} \; From this, python will work as before :-)