{"record":{"id":"2916adbe96c04a0c","repo":"denoland/deno","slug":"an-internal-error-occurred","errorCode":null,"errorMessage":"an internal error occurred","messagePattern":"an internal error occurred","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cli/tools/info.rs","lineNumber":616,"sourceCode":"          writer,\n          \"{} {}\",\n          colors::bold(\"size:\"),\n          display::human_size(total_size),\n        )?;\n        writeln!(writer)?;\n        let root_node = self.build_module_info(root, false);\n        root_node.print(writer)?;\n        Ok(())\n      }\n      Err(err) => {\n        if let ModuleErrorKind::Missing { .. } = err.as_kind() {\n          bail!(\"module could not be found\");\n        } else {\n          bail!(\"{:#}\", err);\n        }\n      }\n      Ok(None) => {\n        bail!(\"an internal error occurred\");\n      }\n    }\n  }\n\n  fn build_dep_info(&mut self, dep: &Dependency) -> Vec<DisplayTreeNode> {\n    let mut children = Vec::with_capacity(2);\n    if !dep.maybe_code.is_none()\n      && let Some(child) = self.build_resolved_info(&dep.maybe_code, false)\n    {\n      children.push(child);\n    }\n    if !dep.maybe_type.is_none()\n      && let Some(child) = self.build_resolved_info(&dep.maybe_type, true)\n    {\n      children.push(child);\n    }\n    children\n  }","sourceCodeStart":598,"sourceCodeEnd":634,"githubUrl":"https://github.com/denoland/deno/blob/9ad36f7a2cce60488e6ec52283efb32efddaf93a/cli/tools/info.rs#L598-L634","documentation":"In `deno info`, the root specifier resolved successfully, the graph did not report an error for it, yet try_get returned Ok(None) — the module is neither present nor errored. This state is unreachable by construction, so the code bails with a generic internal-error marker. It signals a bug in Deno's graph bookkeeping, not a user mistake.","triggerScenarios":"Requires graph.resolve() and graph.try_get() to disagree about the root module — only possible via an internal graph-construction bug or memory/logic corruption; there is no CLI input that legitimately produces it.","commonSituations":"Practically never seen; if it appears, it is usually on pre-release/nightly builds where graph invariants were recently changed.","solutions":["Update to the latest stable Deno release","If reproducible, file an issue at github.com/denoland/deno/issues with the specifier, deno.json, and `deno --version` output"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":"Treat 'an internal error occurred' from deno info as a Deno bug: retry after updating Deno (`deno upgrade`); if it persists, capture `deno --version` and the specifier and file an issue.","preventionTips":["Prefer stable Deno releases for daily work over nightlies","Keep a repro (deno.json + entry file) ready when reporting internal errors"],"tags":["info","internal","unreachable","bug"],"backgroundTag":null,"analyzedSha":"9ad36f7a2cce60488e6ec52283efb32efddaf93a","analyzedAt":"2026-08-20T13:07:44.778Z","contentChangedAt":"2026-08-20T13:07:44.778Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}