{
  "id": "python/flask-typerror-render-template-missing-argument",
  "signature": "TypeError: render_template() missing 1 required positional argument: 'template_name_or_list'",
  "signature_zh": "TypeError: render_template() 缺少 1 个必需的位置参数：'template_name_or_list'",
  "regex": "TypeError:\\ render_template\\(\\)\\ missing\\ 1\\ required\\ positional\\ argument:\\ 'template_name_or_list'",
  "domain": "python",
  "category": "type_error",
  "subcategory": null,
  "root_cause": "Calling render_template without any arguments; requires at least template name.",
  "root_cause_type": "generic",
  "root_cause_zh": "调用 render_template 时没有任何参数；至少需要模板名称。",
  "versions": [
    {
      "version": "3.x",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "Passing only context as positional argument",
      "why_fails": "First argument is template name, not context.",
      "fail_rate": 0.8,
      "condition": "",
      "sources": []
    },
    {
      "action": "Using *args incorrectly",
      "why_fails": "Misunderstanding function signature.",
      "fail_rate": 0.6,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Provide template name as first argument",
      "success_rate": 0.95,
      "how": "return render_template('index.html', name='Alice')",
      "condition": "",
      "sources": []
    },
    {
      "action": "Use named arguments",
      "success_rate": 0.9,
      "how": "return render_template(template_name_or_list='index.html', name='Alice')",
      "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.88,
  "fix_success_rate": 0.8,
  "resolvable": "true",
  "first_seen": "2024-03-22",
  "last_confirmed": "2025-01-01",
  "last_updated": "2025-01-01",
  "evidence_count": 0,
  "tags": [],
  "locale": "en",
  "aliases": []
}