{
  "id": "java/gradle-missing-source-set",
  "signature": "Source set 'main' not found in project ':app'. Please make sure the java plugin is applied.",
  "signature_zh": "在项目 ':app' 中未找到源集 'main'。请确保已应用 java 插件。",
  "regex": "Source\\ set\\ 'main'\\ not\\ found\\ in\\ project\\ ':app'\\.\\ Please\\ make\\ sure\\ the\\ java\\ plugin\\ is\\ applied\\.",
  "domain": "java",
  "category": "build_error",
  "subcategory": null,
  "root_cause": "The Java plugin is not applied to the project, so the default source sets 'main' and 'test' are not available.",
  "root_cause_type": "generic",
  "root_cause_zh": "未对项目应用 Java 插件，因此默认源集 'main' 和 'test' 不可用。",
  "versions": [
    {
      "version": "7+",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "Manually defining the source set without the Java plugin",
      "why_fails": "The Java plugin provides necessary tasks and configurations; manual definition may lead to missing tasks.",
      "fail_rate": 0.8,
      "condition": "",
      "sources": []
    },
    {
      "action": "Using the 'java-library' plugin instead of 'java'",
      "why_fails": "The 'java-library' plugin extends 'java', so it also works, but the error may persist if not applied.",
      "fail_rate": 0.5,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Apply the Java plugin to the project",
      "success_rate": 0.95,
      "how": "plugins { id 'java' }",
      "condition": "",
      "sources": []
    },
    {
      "action": "Apply the 'java-library' plugin if the project is a library",
      "success_rate": 0.95,
      "how": "plugins { id 'java-library' }",
      "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": "2025-02-14",
  "last_confirmed": "2025-01-01",
  "last_updated": "2025-01-01",
  "evidence_count": 0,
  "tags": [],
  "locale": "en",
  "aliases": []
}