jdx/mise · error
{err}
Error message
{err} What it means
Raised while collecting a task's transitive dependencies (Task::all_depends). The task struct carries a stored workspace_dependency_error that was set earlier during workspace dependency resolution — either because the workspace project graph/provider could not be loaded while '^' upstream dependencies were declared, or because '^' was used outside depends. This site re-raises that stored message instead of resolving deps.
Source
Thrown at src/task/mod.rs:1622
RunEntry::Script(s) => Some(s.clone()),
_ => None,
})
.collect()
}
pub(crate) fn all_depends(&self, tasks: &BTreeMap<String, Task>) -> Result<Vec<Task>> {
let tasks_ref = build_task_ref_map(tasks.iter());
let mut visited = HashSet::from([self.name.clone()]);
self.all_depends_recursive(&tasks_ref, &mut visited)
}
fn all_depends_recursive(
&self,
tasks: &BTreeMap<String, &Task>,
visited: &mut HashSet<String>,
) -> Result<Vec<Task>> {
if let Some(err) = &self.workspace_dependency_error {
bail!("{err}");
}
let mut depends: Vec<Task> = self
.depends
.iter()
.chain(self.depends_post.iter())
.filter(|td| !dep_has_usage_ref(td))
.map(|td| match_tasks_with_context(tasks, td, Some(self)))
.flatten_ok()
.filter_ok(|t| t.name != self.name)
.collect::<Result<Vec<_>>>()?;
// Collect transitive dependencies without following the same task twice.
// Cycle detection happens after the runtime graph has resolved wait_for,
// depends_post direction, usage templates, args, and environment variants.
for dep in depends.clone() {
if !visited.insert(dep.name.clone()) {
continue;
}View on GitHub (pinned to 6f52dcdf99)
Solutions
- Read the full message: it embeds the original failure (provider discovery or graph load error) — fix that root cause first
- Add or repair the workspace manifest the provider needs (valid workspaces field in package.json, [workspace] members in Cargo.toml, etc.) at the repository root
- If the project is not in a workspace, drop the '^' prefix and use a plain task name or an explicit '//path:task' dependency
- Ensure no '^' entries sit in wait_for or depends_post — the caret syntax is only legal in depends
Example fix
# mise.toml — before
[tasks.build]
depends = ["^compile"]
# workspace has no package.json / [workspace] manifest -> provider discovery fails
# after (option 1: fix the workspace so '^' resolves)
# root package.json: { "workspaces": ["apps/*", "libs/*"] }
# after (option 2: depend explicitly)
[tasks.build]
depends = ["//libs/core:compile"] Defensive patterns
Strategy: validation
Validate before calling
# pre-flight in CI before running mise tasks: test -f package.json || test -f Cargo.toml || echo 'WARN: no workspace manifest; ^deps will fail' grep -n '"\^' mise.toml **/mise.toml 2>/dev/null && echo 'check ^deps: workspace graph must load'
Try / catch
When shelling out to mise: capture stderr, match the 'failed to resolve upstream task dependencies' prefix, and fail the job with the underlying provider error rather than retrying.
Prevention
- Keep a valid workspace manifest (package.json workspaces / Cargo [workspace]) at the repo root when using '^' deps
- Never use '^' outside depends
- Run 'mise doctor' after workspace restructuring
When it happens
Trigger: A task declares depends = ["^build"] and mise previously failed to load the workspace project graph (provider discovery failed, e.g. no recognizable package-manager manifest, or the graph load itself errored via set_workspace_task_dependency_error). Any later call to all_depends — mise run with dependency traversal, mise tasks tree, dependency-ordered listing — hits the stored Option<String> and bails with it.
Common situations: Monorepo where the root package.json/cargo.toml/pyproject.toml is missing or malformed so no workspace provider is detected; using '^deps' in a project that is not part of a recognized workspace; mixing '^' into wait_for or depends_post; CI checkout that skips the workspace manifest files.
Related errors
- failed to discover workspace providers: {error}
- '{}' depends on unknown '{}'
- ^task dependencies are supported only in depends
- relative path syntax '{}' is not supported, use '//{}' or '
- missing task name in monorepo path '{}', use '{}:<task>' or
AI-assisted analysis of jdx/mise@6f52dcdf99 (2026-08-22).
Data as JSON: /api/errors/a39a7d24c0adf001.
Report an issue: GitHub.