jdx/mise · error · AmbiguousRequestBinding
lockfile contains multiple optionless resolutions for
Error message
lockfile contains multiple optionless resolutions for {short}@{specifier} What it means
This is the legacy-fallback form of the ambiguity check: when no request-bound entry matched, mise looks for optionless (legacy-format) entries for the same short@specifier that may keep a version pin. If more than one such optionless entry exists, the pin itself is ambiguous, so mise raises AmbiguousRequestBinding rather than guessing which pinned version to keep.
Solutions
- Deduplicate the optionless entries for that tool@specifier, keeping one pin, then rerun.
- Run `mise lock --upgrade` at the monorepo root to fully rebind legacy entries into the current format.
- Regenerate the lockfile (`mise lock`) so the mixed legacy entries are consolidated.
Defensive patterns
Strategy: validation
Validate before calling
# detect duplicate optionless entries for a tool before running mise
yq '[.tools.node[] | select(has("options") | not)] | length' mise.lock # expect <= 1 Prevention
- Complete monorepo format migration (`mise lock --upgrade`) before merging branches.
- Regenerate rather than hand-merge lockfiles containing legacy entries.
- Avoid mixing version-0 lockfiles into version-1 files across branches.
When it happens
Trigger: A lockfile that mixes version-0 legacy entries into a version-1 file (e.g. after a partial monorepo migration) contains two or more optionless rows for the same tool and specifier; hand-edited or conflict-resolved lockfiles duplicating legacy entries.
Common situations: Mixed-format monorepo state mid-migration where multiple branches contributed unbound legacy entries; manually consolidated lockfiles after a bad merge; older lockfiles imported repeatedly.
Understand the failure class
Background: Schema validation failed / invalid input schema: payload rejected because its shape doesn't match the expected schema — this error's family across 28 libraries.
Related errors
- lockfile contains multiple resolutions for
- additional_artifacts must be an array in lockfile
- ambiguous variants for
- aube lockfile mapping keys must be strings
- aube lockfile must contain a mapping
AI-assisted analysis of jdx/mise@533346cc37 (2026-09-17).
Data as JSON: /api/errors/96732af045bcc3f2.
Report an issue: GitHub.
Appendix: source
Thrown at src/lockfile.rs:4285
let (legacy, legacy_error) =
matching_request_bindings(lockfile.as_ref(), short, specifier, |tool| {
Ok(
binding_options(tool)?.is_some_and(|(options, allow_fallback)| {
allow_fallback && !options.is_empty() && tool.options.is_empty()
}),
)
});
match legacy.as_slice() {
[] => {}
[found] => {
trace!(
"[{short}@{specifier}] found {} in lockfile without options, keeping the version pin and dropping its artifact data",
found.version
);
return Ok(binding_options(found)?
.map(|(options, _)| lockfile_tool_with_request_options(found, &options)));
}
_ => bail!(AmbiguousRequestBinding(format!(
"lockfile contains multiple optionless resolutions for {short}@{specifier}"
))),
}
// Mixed-format monorepo migration can temporarily place legacy
// entries without bindings in a version-1 file. Keep those pins
// reachable until a successful full format upgrade binds them.
let version_matches = |v: &LockfileTool| {
v.specifiers.is_empty()
&& lockfile_version_matches(prefix, &v.version)
&& (!require_prefix_boundary
|| lockfile_version_matches_prefix_boundary(prefix, &v.version))
};
let matching = tools
.iter()
.filter(|v| version_matches(v) && &v.options == request_options)
.collect_vec();
if let Some(found) = select_unbound_lockfile_tool(matching, backend, selection_options)?View on GitHub (pinned to 533346cc37)