{
  "id": "python/unittest-assertcount-equal-error",
  "signature": "AssertionError: expected call not found.\nExpected: mock(1)\nActual: mock(2)",
  "signature_zh": "断言错误：预期调用未找到。预期：mock(1)，实际：mock(2)",
  "regex": "AssertionError:\\ expected\\ call\\ not\\ found\\.\\\nExpected:\\ mock\\(1\\)\\\nActual:\\ mock\\(2\\)",
  "domain": "python",
  "category": "runtime_error",
  "subcategory": null,
  "root_cause": "使用 assert_called_with 检查 mock 调用时，参数不匹配",
  "root_cause_type": "generic",
  "root_cause_zh": "使用 assert_called_with 检查 mock 调用时，参数不匹配",
  "versions": [
    {
      "version": "3.12",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "只检查调用次数，不检查参数",
      "fail_rate": 0.6,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "可能不符合测试意图",
      "fail_rate": 0.3,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "",
      "success_rate": 0.9,
      "how": "print(mock.call_args_list) 然后修正预期",
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "success_rate": 0.8,
      "how": "mock.assert_any_call(1)",
      "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.85,
  "fix_success_rate": 0.8,
  "resolvable": "true",
  "first_seen": "2024-09-20",
  "last_confirmed": "2025-01-01",
  "last_updated": "2025-01-01",
  "evidence_count": 0,
  "tags": [],
  "locale": "en",
  "aliases": []
}