{
  "id": "git/submodule-commit-not-found",
  "signature": "fatal: Path '<submodule-path>' does not point to a valid commit: <hash>",
  "signature_zh": "致命：路径 '<子模块路径>' 未指向有效的提交：<哈希>",
  "regex": "fatal: Path '[^']+' does not point to a valid commit: [a-f0-9]+",
  "domain": "git",
  "category": "config_error",
  "subcategory": null,
  "root_cause": "A submodule reference points to a commit hash that does not exist in the submodule's repository, often due to force-pushing or rebasing in the submodule without updating the parent.",
  "root_cause_type": "generic",
  "root_cause_zh": "子模块引用指向了一个在子模块仓库中不存在的提交哈希，通常是由于在子模块中进行了强制推送或变基而没有更新父仓库。",
  "versions": [
    {
      "version": "git 2.40.1",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "git 2.41.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "git 2.42.2",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "This updates to the latest remote commit, not the missing hash; it changes the submodule version and may break compatibility with the parent project.",
      "fail_rate": 0.6,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Re-adding the submodule requires the same commit hash; if the hash is missing from the remote, the error persists.",
      "fail_rate": 0.5,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Update the submodule reference to a valid commit: 'cd <submodule-path> && git fetch origin && git checkout <valid-hash>', then commit the change in the parent repo",
      "success_rate": 0.85,
      "how": "Update the submodule reference to a valid commit: 'cd <submodule-path> && git fetch origin && git checkout <valid-hash>', then commit the change in the parent repo",
      "condition": "",
      "sources": []
    },
    {
      "action": "If the missing commit is from a force-push, ask the submodule maintainer to restore it, or update the parent to point to a different commit using 'git submodule set-url' and 'git add'",
      "success_rate": 0.78,
      "how": "If the missing commit is from a force-push, ask the submodule maintainer to restore it, or update the parent to point to a different commit using 'git submodule set-url' and 'git add'",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "Update the submodule reference to a valid commit: 'cd <submodule-path> && git fetch origin && git checkout <valid-hash>', then commit the change in the parent repo",
    "If the missing commit is from a force-push, ask the submodule maintainer to restore it, or update the parent to point to a different commit using 'git submodule set-url' and 'git add'"
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": "https://git-scm.com/docs/git-submodule",
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.87,
  "fix_success_rate": 0.82,
  "resolvable": "true",
  "first_seen": "2024-05-12",
  "last_confirmed": "2024-06-01",
  "last_updated": "2024-06-01",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}