You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have checked that this issue has not already been reported.
I have confirmed this bug exists on the latest version of pixi, using pixi --version.
Reproducible example
Setup a project, add and install conda deps, then replace one conda dep with pypi dep.
pixi init test
cd test
pixi add python flask
pixi add --pypi flask
pixi remove flask --no-lockfile-update # Or remove by hand
pixi install
This should have resulted in a pypi package for flask but there are no pypi dependencies found.
❯ pixi list
Package Version Build Size Kind Source
...
flask 3.0.3 pyhd8ed1ab_0 78.9 KiB conda flask-3.0.3-pyhd8ed1ab_0.conda
...
Issue description
We normally want this behavior if a package is both defined as a conda dependency and a pypi dependency. But since our logic for the satisfiability also checks the locked conda packages against the pypi requirements these packages stay.
The crux is this part of the satisfiability function:
Because the (conda_locked_package) identifier satisfies the pypi requirement this function continues and adds the package as a FoundPackage::Conda() which should be only correct if there was already a conda package asking for this.
Expected behavior
I expect the same behavior as when you rm pixi.lock and then pixi install, that flask is a pypi package.
❯ pixi list
Package Version Build Size Kind Source
...
flask 3.0.3 329.2 KiB pypi flask-3.0.3-py3-none-any.http.whl
...
The text was updated successfully, but these errors were encountered:
@skayred The trick would be to remove conda version from the lock-file by hand. Which invalidates the lock-file, and should reproduce the correct lock-file. It's a one time thing while you move from conda to pypi so it should reappear.
That said why would you want numpy from pypi? #curious 😄
@ruben-arts thanks, I will try that! For the numpy - it seems that there is some issue with numpy and PyInstaller combo on Windows, although I am not 100% sure it happens because of conda-based numpy
Checks
I have checked that this issue has not already been reported.
I have confirmed this bug exists on the latest version of pixi, using
pixi --version
.Reproducible example
Setup a project, add and install conda deps, then replace one conda dep with pypi dep.
This should have resulted in a pypi package for
flask
but there are no pypi dependencies found.Issue description
We normally want this behavior if a package is both defined as a conda dependency and a pypi dependency. But since our logic for the satisfiability also checks the locked conda packages against the pypi requirements these packages stay.
The crux is this part of the satisfiability function:
pixi/src/lock_file/satisfiability.rs
Lines 700 to 708 in d50d0d5
Because the (conda_locked_package)
identifier
satisfies the pypi requirement this function continues and adds the package as aFoundPackage::Conda()
which should be only correct if there was already a conda package asking for this.Expected behavior
I expect the same behavior as when you
rm pixi.lock
and thenpixi install
, thatflask
is a pypi package.The text was updated successfully, but these errors were encountered: