Skip to content

fix: satisfy lock-file when feature-level index-url is set#6065

Merged
ruben-arts merged 2 commits into
prefix-dev:mainfrom
baszalmstra:claude/fix-lockfile-index-url-ho5l2
May 11, 2026
Merged

fix: satisfy lock-file when feature-level index-url is set#6065
ruben-arts merged 2 commits into
prefix-dev:mainfrom
baszalmstra:claude/fix-lockfile-index-url-ho5l2

Conversation

@baszalmstra
Copy link
Copy Markdown
Contributor

Description

A manifest PyPI requirement with no per-package index was treated as "the user wants the default PyPI index" during satisfiability. With a feature-level pypi-options.index-url, the lock-file records the custom URL on each package while the requirement carries no index, so pixi install --locked failed with '<pkg>' requires index <default> but the lock-file has <url>.

Compare the locked package URL against the lock-file's environment-level indexes: (already verified to match the manifest by verify_pypi_indexes) instead of hard-coding default PyPI.

Fixes #6060

How Has This Been Tested?

  • Unit tests in pypi.rs:
  • End-to-end fixture: tests/data/satisfiability/pypi-feature-level-index-url/

AI Disclosure

  • This PR contains AI-generated content.
    • I have tested any AI-generated content in my PR.
    • I take responsibility for any AI-generated content in my PR.

Tools: Claude Code

Checklist:

  • I have performed a self-review of my own code
  • I have added sufficient tests to cover my changes.

…fix-dev#6060)

A manifest PyPI requirement with no per-package `index` was treated as
"the user wants the default PyPI index" during satisfiability. With a
feature-level `pypi-options.index-url`, the lock-file records the
custom URL on each package while the requirement carries no `index`,
so `pixi install --locked` failed with
`'<pkg>' requires index <default> but the lock-file has <url>`.

Compare the locked package URL against the lock-file's environment-
level `indexes:` (already verified to match the manifest by
`verify_pypi_indexes`) instead of hard-coding default PyPI. Empty
falls back to the default PyPI URL.

Fixes prefix-dev#6060

https://claude.ai/code/session_01THyoQmYv9CuRfyPw3VVxTw
@baszalmstra
Copy link
Copy Markdown
Contributor Author

@ruben-arts THis is ready!

Copy link
Copy Markdown
Contributor

@ruben-arts ruben-arts left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can confirm this works! Thanks

@ruben-arts ruben-arts enabled auto-merge (squash) May 11, 2026 12:01
@ruben-arts ruben-arts merged commit 2e5c512 into prefix-dev:main May 11, 2026
38 checks passed
@sheevy
Copy link
Copy Markdown

sheevy commented May 11, 2026

Thanks for this. Would to be possible to release this soon, as it's a regression, which unfortunately falls just after the lock file format change?

@wolfv
Copy link
Copy Markdown
Member

wolfv commented May 11, 2026

Definitely planning to make a release tomorrow. Do you need it earlier than that? Sorry for the regression.

@sheevy
Copy link
Copy Markdown

sheevy commented May 11, 2026

Thanks for this. Not at all, I just pinned the pixi version in setup-pixi: pixi-version: v0.67.2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[0.68.0] Unable to use --locked with a non-default index-url

5 participants