{
  "id": "python/flask-build-error-endpoint",
  "signature": "werkzeug.routing.exceptions.BuildError: Could not build url for endpoint 'user_profile'. Did you mean 'user' instead?",
  "signature_zh": "werkzeug.routing.exceptions.BuildError: 无法为端点 'user_profile' 构建 URL。你是不是想用 'user'？",
  "regex": "werkzeug\\.routing\\.exceptions\\.BuildError:\\ Could\\ not\\ build\\ url\\ for\\ endpoint\\ 'user_profile'\\.\\ Did\\ you\\ mean\\ 'user'\\ instead\\?",
  "domain": "python",
  "category": "runtime_error",
  "subcategory": null,
  "root_cause": "url_for() references an endpoint name that does not exist or is misspelled relative to the registered view function name.",
  "root_cause_type": "generic",
  "root_cause_zh": "url_for() 引用的端点名称不存在，或与注册的视图函数名称拼写不一致。",
  "versions": [
    {
      "version": "3.x",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "Breaks on app mounted under a prefix or behind a proxy; loses url_for's escaping.",
      "fail_rate": 0.7,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Unrelated to endpoint name resolution.",
      "fail_rate": 0.85,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "",
      "success_rate": 0.95,
      "how": "@app.route('/profile')\ndef user_profile(): ...\nurl_for('user_profile')",
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "success_rate": 0.9,
      "how": "print(app.url_map)",
      "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-02-27",
  "last_confirmed": "2025-01-01",
  "last_updated": "2025-01-01",
  "evidence_count": 0,
  "tags": [],
  "locale": "en",
  "aliases": []
}