{
  "id": "nextjs/use-cache-no-store-fetch",
  "signature": "Error: fetch failed with 'no-store' and 'use cache' directive conflict",
  "signature_zh": "错误：fetch 使用了 'no-store' 与 'use cache' 指令冲突",
  "regex": "fetch failed with 'no-store' and 'use cache' directive conflict",
  "domain": "nextjs",
  "category": "config_error",
  "subcategory": null,
  "root_cause": "When a component or function uses the 'use cache' directive to enable caching, but the fetch call inside it uses 'cache: no-store', Next.js throws an error because the two caching strategies are incompatible.",
  "root_cause_type": "generic",
  "root_cause_zh": "当组件或函数使用 'use cache' 指令启用缓存，但内部的 fetch 调用使用了 'cache: no-store' 时，Next.js 会抛出错误，因为两种缓存策略不兼容。",
  "versions": [
    {
      "version": "next@15.0.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "next@15.1.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "This disables caching for the entire component, which may degrade performance and is not always necessary.",
      "fail_rate": 0.6,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "This forces caching even when fresh data is needed, leading to stale responses.",
      "fail_rate": 0.8,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Remove 'cache: no-store' from the fetch call and rely on the 'use cache' directive for caching behavior. If fresh data is needed, use revalidation options like 'next: { revalidate: 0 }'.",
      "success_rate": 0.9,
      "how": "Remove 'cache: no-store' from the fetch call and rely on the 'use cache' directive for caching behavior. If fresh data is needed, use revalidation options like 'next: { revalidate: 0 }'.",
      "condition": "",
      "sources": []
    },
    {
      "action": "Move the fetch call outside the 'use cache' scope by extracting it to a separate function without the directive.",
      "success_rate": 0.8,
      "how": "Move the fetch call outside the 'use cache' scope by extracting it to a separate function without the directive.",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "从 fetch 调用中移除 'cache: no-store'，依赖 'use cache' 指令的缓存行为。如果需要新鲜数据，使用 'next: { revalidate: 0 }' 等重新验证选项。",
    "将 fetch 调用移到 'use cache' 作用域之外，提取到没有该指令的单独函数中。"
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": "https://nextjs.org/docs/app/api-reference/directives/use-cache",
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.85,
  "fix_success_rate": 0.9,
  "resolvable": "true",
  "first_seen": "2025-01-10",
  "last_confirmed": "2024-06-01",
  "last_updated": "2024-06-01",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}