Repository navigation
fix(backend): resolve remote versions with each request's own options - #14476
JamBalaya56562 wants to merge 1 commit into
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Merge Risk: ⚪ Minimal · up to
|
[Medium impact] The PR appears safe to merge; no blocking issues were found. SummaryRemote version matching now uses each request’s own options instead of inheriting unset options from the first configured entry.
Reviews (3) · Last reviewed commit: "fix(backend): resolve remote versions wi..." · Reviewed by Greptile |
d41ab15 to
1ec808a
Compare
Co-authored-by: Taku Kodama <79110363+risu729@users.noreply.github.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1ec808a to
fe9b56e
Compare
|
@jdx Thanks for enabling auto-merge on this!
The binary's Other untrusted PRs hit the same error since about 01:40 UTC today: #14487, #14483 and #14454. This PR's last three runs failed the same way. Earlier untrusted runs, such as #14426 at 01:21, still linked. AI-assisted — Tool: Claude Code; model: anthropic/claude-opus-5-5; version: unavailable. |
When a tool lists several versions, each entry is meant to resolve with its own options. An option that only the first entry sets leaked into the later ones:
The second entry does not ask for prereleases, but
1resolved to1.25.0-pre. Written on its own, the same entry resolves to1.24.2. A bare string entry such as"1"after the first one was affected the same way.Version resolution looked up options through the config, which takes the first entry's options for the whole tool and layers the request's own options over them. Any key the request leaves unset came from the first entry. Resolution now passes each request's own options when it lists matching remote versions, for prefix requests, exact pins and the date-filter fallback, and when it answers them from the mise-versions index. The
latestlookup already did so.This takes over the core of #11720 by @risu729, which pr-closer closed after 7 days without contributor activity. They are credited as co-author. #11720 also reworked
mise latest,mise upgradeand the backend's option wrappers. Those parts are left out, and so are the lookups that have no request to take options from (sub-N:bases and the date-filter error message), which still use the config.Validation
e2e/backend/test_github_multi_entry_options, against a local stand-in for the GitHub API that servesv1.0.0and a prereleasev1.1.0-pre:1resolves to1.0.0.{ version = "latest", prerelease = true },1still resolves to1.0.0, andlatestto1.1.0-pre.rust:1container, the test fails with the released 2026.10.10 (expected '1.0.0'in the multi-entry case, where only1.1.0-preis listed) and passes with this branch.test_github_ls_remote_skips_assetlessandtest_github_ls_remote_inline_optsalso pass.cargo clippy --workspace --all-features --all-targets -- -D warningspasses.MISE_TRACE=1 mise lsshowed the zed case above resolving the second entry to1.25.0-pre, and the entry alone to1.24.2. A bare"1"after the first entry also resolved to1.25.0-pre.AI-assisted — Tool: Claude Code; model: anthropic/claude-opus-5-5; version: unavailable.
🤖 Generated with Claude Code
Summary by CodeRabbit