-
Notifications
You must be signed in to change notification settings - Fork 1
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
Fix breaking Python image #15
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this definitely a safe approach? I'm not super clued up on Python, but since this isn't just a throw away container that's used for CI, I'm wondering if we should pay attention to the error and not try to install the tools that are managed by APT via pip.
These are python packages. Don't think they're managed by apt. I think the reason it complains is that we don't use virtualenvs but install it globally. In this case, it's fine, we want to. |
The reason I was asking was because I did some skimming this morning, and it sounded like the reason they introduced this behaviour was to avoid conflicts between pip and OS level package managers (here's the full design doc: https://peps.python.org/pep-0668/). There's an article explaining how to solve the issue here, and the first option it provides is to install the Python package that is causing an issue with I get your point that it's fine to install the packages globally because this is a docker image, but the reason I'm asking the question is that I don't think Again, maybe that's fine, but just wanting to double check since we're explicitly working against something that's meant to protect against problems here. At the least I think we need to add a comment explaining why we had to add this flag, and why it's ok in this circumstance. |
f6868f7
to
a10f550
Compare
Signed-off-by: peterdeme <[email protected]>
a10f550
to
94abd34
Compare
--break-system-packages
flag to Python imageThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Description of the change
Python/pip doesn't like to install packages globally anymore. Apparently, you need to provide a new argument since Py 3.11.
Type of change
Checklists
Development
Code review