{
  "id": "go/os-exec-command-timeout",
  "signature": "exec: command timed out",
  "signature_zh": "exec: 命令超时",
  "regex": "exec:\\ command\\ timed\\ out",
  "domain": "go",
  "category": "system_error",
  "subcategory": null,
  "root_cause": "An external command executed with exec.CommandContext exceeds the context deadline, causing the process to be killed.",
  "root_cause_type": "generic",
  "root_cause_zh": "使用 exec.CommandContext 执行的外部命令超过上下文截止时间，导致进程被终止。",
  "versions": [
    {
      "version": "1.21",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "May hang indefinitely, consuming resources.",
      "fail_rate": 0.8,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Doesn't solve the root cause; may still timeout for long-running commands.",
      "fail_rate": 0.6,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "",
      "success_rate": 0.9,
      "how": "ctx, cancel := context.WithTimeout(context.Background(), 10*time.Second); defer cancel(); cmd := exec.CommandContext(ctx, \"sleep\", \"30\"); if err := cmd.Run(); err != nil { ... }",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": null,
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.86,
  "fix_success_rate": 0.8,
  "resolvable": "true",
  "first_seen": "2024-07-08",
  "last_confirmed": "2025-01-01",
  "last_updated": "2025-01-01",
  "evidence_count": 0,
  "tags": [],
  "locale": "en",
  "aliases": []
}