{
  "id": "python/pydantic-field-default-factory-error",
  "signature": "pydantic.errors.ConfigError: default_factory must be a callable",
  "signature_zh": "pydantic.errors.ConfigError: default_factory 必须是可调用对象",
  "regex": "pydantic\\.errors\\.ConfigError:\\ default_factory\\ must\\ be\\ a\\ callable",
  "domain": "python",
  "category": "config_error",
  "subcategory": null,
  "root_cause": "The default_factory argument in Field is not a callable (e.g., a list or int), causing ConfigError.",
  "root_cause_type": "generic",
  "root_cause_zh": "Field 中的 default_factory 参数不是可调用对象（例如列表或整数），导致 ConfigError。",
  "versions": [
    {
      "version": "2.x",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "List is not callable, must be a function like list.",
      "fail_rate": 0.9,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Lambda must be callable, but syntax errors possible.",
      "fail_rate": 0.6,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "",
      "success_rate": 0.95,
      "how": "Use default_factory=list or lambda: []",
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "success_rate": 0.85,
      "how": "Use default=[] instead of default_factory",
      "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.87,
  "fix_success_rate": 0.8,
  "resolvable": "true",
  "first_seen": "2024-04-22",
  "last_confirmed": "2025-01-01",
  "last_updated": "2025-01-01",
  "evidence_count": 0,
  "tags": [],
  "locale": "en",
  "aliases": []
}