Comments (5)
That is strange, could you run the command with -v? That will tell us why the lockfile is out of date.
from pixi.
Interesting.
So going back to prior version of pyproject.toml, and re-generating lock via v0.20.1
$ ~/.pixi/bin/pixi --version
pixi 0.20.1
$ rm pixi.lock
$ ~/.pixi/bin/pixi install
✔ Project in <abc> is ready to use!
Now validating lock file via a task run
$ ~/.pixi/bin/pixi --version
pixi 0.20.1
$ ~/.pixi/bin/pixi run --locked --environment <abc> some-task
$ echo $?
0
Now trying pixi v0.21.1
$ pixi --version
pixi 0.21.1
$ pixi run --locked --environment <abc> some-task
× lock-file not up-to-date with the project
$ pixi run -v --locked --environment <abc> some-task
...
INFO pixi::lock_file::outdated: environment '<xyz>' is out of date because the channels in the lock-file do not match the environments channels
× lock-file not up-to-date with the project
is an entirely different environment than .
I will see if I can get to a minimally reproducable pixi.toml or pyproject.toml.
from pixi.
This seems to reproduce:
# pyproject.toml
[project]
name = "pixi-example"
requires-python = ">=3.11"
[tool.pixi.project]
name = "pixi-example"
channels = ["conda-forge"]
platforms = ["linux-64", "osx-arm64"]
[tool.pixi.tasks]
[tool.pixi.feature.prod]
channels = ["conda-forge", "pytorch"]
[tool.pixi.feature.prod.dependencies]
python = "3.11.*"
[tool.pixi.feature.empty.dependencies]
[tool.pixi.environments]
default = {features = ["prod"], solve-group = "default"}
prod = {features = ["prod"], solve-group = "default"}
empty = {features = ["empty"], solve-group = "default"}
$ ~/.pixi/bin/pixi --version
pixi 0.20.1
$ ~/.pixi/bin/pixi install
✔ Project in /<abc>/pixi-example is ready to use!
$ ~/.pixi/bin/pixi install --locked
✔ Project in /<abc>/pixi-example is ready to use!
$ pixi --version
pixi 0.21.1
$ pixi install --locked --verbose
INFO pixi::config: Global config not found at /etc/pixi/config.toml
INFO pixi::config: Global config not found at /<abc>/.config/pixi/config.toml
INFO pixi::config: Global config not found at /<abc>/Library/Application Support/pixi/config.toml
INFO pixi::config: Global config not found at /<abc>/.pixi/config.toml
INFO pixi::environment: verifying prefix location is unchanged, with prefix file: /<abc>/pixi-example/.pixi/envs/default/conda-meta/pixi_env_prefix
INFO pixi::lock_file::outdated: environment 'empty' is out of date because the channels in the lock-file do not match the environments channels
× lock-file not up-to-date with the project
from pixi.
So i re-generated lock file via v0.21.1, and saw the empty
environment has the same channels as the prod
/default
:
environments:
default:
channels:
- url: https://conda.anaconda.org/conda-forge/
- url: https://conda.anaconda.org/pytorch/
...
empty:
channels:
- url: https://conda.anaconda.org/conda-forge/
- url: https://conda.anaconda.org/pytorch/
...
prod:
channels:
- url: https://conda.anaconda.org/conda-forge/
- url: https://conda.anaconda.org/pytorch/
I noticed I had them share the same solve group. So attempted a version with that modified:
empty = {features = ["empty"], solve-group = "empty"}
Now --locked
validation works with v0.21.1 on a v0.20.1 generated lock file.
from pixi.
Ah right! There was indeed a bug in older versions where the channels were not properly recorded for an environment in the presence of solve groups.
from pixi.
Related Issues (20)
- failed to link 'share/terminfo/h/hp70092A' in wsl2 ubuntu when UTF-8 character included in directory HOT 7
- Inconsistent lockfile with pypi-dependencies: conda dep appears twice in packages
- `pixi shell-hook -e default` doesn't work HOT 1
- pixi list / tree filter for explicit dependencies only HOT 3
- [pypi-dependencies] resolution fails when "extra-index-urls" is provided in [pypi-options] HOT 4
- Cannot Authenticate to Google Artifact Registry HOT 39
- Pixi equivalent of conda constructor HOT 2
- Expose different uv index resolution strategies HOT 1
- uv installed with pixi global install uv does not correctly detect activated conda environments HOT 6
- override `project.conda-pypi-map` not work when need to update lock file
- `pypi-options` not taken over to environments like `channels` when no-default-feature is enabled. HOT 9
- Add docs to pixi in a devcontainer
- UV cache error in read-only filesystems. HOT 3
- Git package dependencies fail on systems without global git installation HOT 5
- Install error extra-url HOT 4
- Can't install pypi package by version, but success if by path HOT 7
- Bulk of documentation hard to find
- sort output from `pixi global list`
- Suggestions for `pixi info` and `pixi task list` terminal ouput HOT 1
- npm install -g typescript-language-server Not adding executables to path HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pixi.