jdx/mise · error · eyre::Report
failed to discover workspace providers: {error}
Error message
failed to discover workspace providers: {error} What it means
`Config::workspace_project_graph()` builds the provider-neutral workspace project graph used by experimental monorepo support. If provider discovery itself recorded an error, mise re-raises it wrapped in this message; the `{error}` suffix carries the root cause, such as a workspace manifest that failed to parse or a workspace detection command that exited non-zero.
Source
Thrown at src/config/mod.rs:648
let cf = find_monorepo_config(&self.config_files)?;
let monorepo = cf.monorepo();
Some((
cf.get_path().to_path_buf(),
monorepo.and_then(|config| config.lockfile),
monorepo
.map(|config| config.config_roots.clone())
.unwrap_or_default(),
))
}
/// Discovers the provider-neutral workspace project graph and applies the
/// explicit overrides from the active monorepo root.
pub(crate) fn workspace_project_graph(
&self,
) -> Result<Arc<crate::task::workspace::WorkspaceProjectGraph>> {
let graph = self.workspace_project_graph_for_task_loading()?;
if let Some(error) = graph.provider_discovery_error() {
bail!("failed to discover workspace providers: {error}");
}
Ok(graph)
}
/// Resolves workspace-global task inputs using the active monorepo root context.
pub(crate) async fn monorepo_global_task_inputs(self: &Arc<Self>) -> Result<Vec<String>> {
let monorepo_config = find_monorepo_config(&self.config_files)
.ok_or_else(|| eyre!("no config file in scope sets monorepo_root = true"))?;
let monorepo_root = monorepo_config
.project_root()
.ok_or_else(|| eyre!("monorepo root config has no project root"))?
.to_path_buf();
let configs = self
.config_files
.values()
.filter(|cf| cf.config_root() == monorepo_root)
.collect::<Vec<_>>();
let task_inputs = ResolvedTaskInputs::from_configs(&configs);View on GitHub (pinned to 6f52dcdf99)
Solutions
- Read the text after the colon — it contains the underlying provider error; fix that root cause (repair the workspace manifest, install the missing package manager)
- Re-run with MISE_DEBUG=1 MISE_TRACE=1 to get the full error chain and backtrace from the failing provider
- Temporarily set experimental=false or remove the [monorepo] block to confirm workspace discovery is the trigger
- If the manifest is valid and discovery still fails, report a bug with the debug output
Defensive patterns
Strategy: validation
Validate before calling
python3 -c 'import tomllib; tomllib.load(open("Cargo.toml","rb"))' && \
node -e 'JSON.parse(require("fs").readFileSync("package.json"))' && \
python3 -c 'import yaml,sys; yaml.safe_load(open("pnpm-workspace.yaml"))' 2>/dev/null; echo 'manifests parse ok' Prevention
- Parse all workspace manifests (package.json, pnpm-workspace.yaml, Cargo.toml) in CI before enabling experimental monorepo support
- Keep the workspace package manager installed in CI images so provider detection commands can run
- Treat provider_discovery_error suffixes as the real error — always read past the colon
- Pin a known-good mise version when using experimental workspace features
When it happens
Trigger: Running monorepo-aware commands (workspace task loading, project graph queries) with `experimental = true` and a `[monorepo]` config while a workspace provider fails discovery — e.g. a malformed pnpm-workspace.yaml / package.json workspaces field / Cargo.toml workspace section, or the workspace package manager missing from PATH.
Common situations: Enabling experimental monorepo features on a repo with a broken or half-migrated workspace manifest; CI images lacking the package manager that the workspace provider shells out to; YAML/TOML syntax errors introduced during refactoring.
Related errors
- {err}
- mise oci: no project mise config found in the current direct
- [experimental] No age recipients provided. Use --age-recipie
- [monorepo].config_roots is required for monorepo operations
- [monorepo].config_roots did not match any config roots
AI-assisted analysis of jdx/mise@6f52dcdf99 (2026-08-22).
Data as JSON: /api/errors/a5967ccd6e29ea4c.
Report an issue: GitHub.