Closed fangohr closed 1 month ago
First brought up at https://discord.com/channels/1082332781146800168/1212673297347518464/1278619806240870431 .
While investigating it seems that cowpy
is placed in the ipython
site-packages.
I've quickly investigated and found the source of the issue. Whats actually (incorrectly) happening is that when you run pixi global install a b
you get two environments, one for a
, and one for b
. But both environments will contain the same packages!
However, it also looks like some people currently rely on this behavior...
But we are working on a complete revamp of pixi global
that will not exhibit this behavior so to not potentially break peoples workflow twice we'll wait for the revamp instead of providing a fix now.
The "solution" for this issue is for now to call pixi global install
for each individual spec instead of combining:
pixi global install ipython
pixi global install cowpy
instead of
pixi global install ipython cowpy
Hi @baszalmstra - thanks for investigating.
Ironically, I was also hoping that the current behaviour is the intended behaviour. (I was looking for a way to provide a global anaconda-like installation which I can recommend to students, and where we can ignore the complexity of environments etc for the first few weeks of learning Python.) Only when looking at the documentation and double checking with @ruben-arts and @wolfv at EuroScipy, I thought this might be bug and the team should be aware of it.
As long as this is on the radar of the pixi team, and we have the issue to document it, that's good. Feel free to close or keep open the ticket - whatever works best for your work flow. From my side, the reporting of the behaviour is completed.
The revamp will have logic where you can specify multiple packages for a single environment so I think that your use case should be covered. Information about the new design can be found here: https://pixi.sh/dev/design_proposals/pixi_global_manifest/
The new pixi global
in the v0.33.0
release fixes this.
Checks
[X] I have checked that this issue has not already been reported.
[X] I have confirmed this bug exists on the latest version of pixi, using
pixi --version
.Reproducible example
Build the docker image by putting the above into a
Dockerfile
and run in the same directorydocker build -t issuepixi .
.Issue description
As shown in the Dockerfile (as a clean environment we trust), it seems that the different
.pixi/venvs
can somehow interfere which each other.My hypothesis is that this connection between the different environments exists when they are installed together in a single
pixi global install
command.Expected behavior
In the container above,
ipython
should not be able to import cowpy if they are truly separated.