{
  "id": "pip/vcs-install-no-branch-tag",
  "signature": "ERROR: VCS install did not find a branch or tag to checkout. The repository at 'https://github.com/user/repo.git' has no branches or tags.",
  "signature_zh": "错误：VCS 安装未找到要检出的分支或标签。仓库 'https://github.com/user/repo.git' 没有分支或标签。",
  "regex": "ERROR: VCS install did not find a branch or tag to checkout\\. The repository at 'https?://[^']+' has no branches or tags\\.",
  "domain": "pip",
  "category": "install_error",
  "subcategory": null,
  "root_cause": "A Git repository specified in a pip VCS requirement (e.g., git+https://...) is empty or has no commits, branches, or tags, so pip cannot determine which revision to checkout.",
  "root_cause_type": "generic",
  "root_cause_zh": "在 pip VCS 需求中指定的 Git 仓库（例如 git+https://...）为空或没有提交、分支或标签，因此 pip 无法确定要检出的修订版本。",
  "versions": [
    {
      "version": "pip 23.1",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "pip 23.2",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "pip 24.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "Pip cannot checkout a branch that does not exist in the remote repository.",
      "fail_rate": 0.7,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Local path installs work, but the error is about VCS specifically; the workaround requires using a local path correctly.",
      "fail_rate": 0.4,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Initialize the repository with at least one commit and a branch: git init; git add .; git commit -m 'initial'; git branch -M main; git push -u origin main",
      "success_rate": 0.85,
      "how": "Initialize the repository with at least one commit and a branch: git init; git add .; git commit -m 'initial'; git branch -M main; git push -u origin main",
      "condition": "",
      "sources": []
    },
    {
      "action": "Use a local path install instead of VCS: pip install /path/to/local/repo",
      "success_rate": 0.9,
      "how": "Use a local path install instead of VCS: pip install /path/to/local/repo",
      "condition": "",
      "sources": []
    },
    {
      "action": "Specify a commit hash explicitly with @: pip install git+https://github.com/user/repo.git@abc123def456",
      "success_rate": 0.8,
      "how": "Specify a commit hash explicitly with @: pip install git+https://github.com/user/repo.git@abc123def456",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "初始化仓库至少包含一个提交和一个分支：git init; git add .; git commit -m 'initial'; git branch -M main; git push -u origin main",
    "使用本地路径安装代替 VCS：pip install /path/to/local/repo",
    "显式指定提交哈希：pip install git+https://github.com/user/repo.git@abc123def456"
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": "https://pip.pypa.io/en/stable/topics/vcs-support/",
  "official_doc_section": null,
  "error_code": "ERROR",
  "verification_tier": "ai_generated",
  "confidence": 0.82,
  "fix_success_rate": 0.75,
  "resolvable": "partial",
  "first_seen": "2023-08-22",
  "last_confirmed": "2024-06-01",
  "last_updated": "2024-06-01",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}