Tasks
This section is for Byron only. Models continuing this PR must not add, remove, check, uncheck, rename, or reorder checkboxes here.
Everything below this line was generated by Codex (model version unavailable).
Created by Codex on behalf of Byron. Byron will review before this is ready to merge.
This repository-owner follow-up verifies checkout protection for a security report against released GitPython 3.2.1. Current main already contains the class-wide branch operand validation from 212573bf; this PR locks in the additional input variants and documents that contract.
Extend the existing operand and real-clone regressions to cover more option spellings under both unsafe-option settings. Rejection must happen before a Git process launches and preserve the branch, commit, index status, uncommitted file content, and untracked-file status. Document UnsafeOptionError and that branch validation remains active with allow_unsafe_options=True.
Advisory summary
GHSA-f8wj-prgh-h9j7 is a draft advisory with medium severity. The report concerns PyPI package GitPython and tested version 3.2.1. The advisory's structured affected range and patched version are unset, and no CVE is assigned. This description omits reproduction details from the draft advisory. This PR does not publish the advisory or assign a patched release.
Validation
- The three additional cloned-branch cases fail with the unaltered
Head.checkout() method from tag 3.2.1 (c179357b) loaded into the current harness in a disposable process. This is method-level reproduction, not a full installed-release test.
- The affected
test/test_positional_args.py and test/test_refs.py modules pass 184 tests and 24 subtests on each backend through test/run-local.py. All four cloned-branch cases also pass on each backend after the final fixture edit.
- Python 3.12.14, Git 2.54.0, and GixPython 0.3.0 on macOS; Ruff lint/format, ShellCheck, and whitespace checks pass.
- Git reference
6de20f6 (v2.56.0-116-g6de20f6092): check_branch_ref() and t/t1402-check-ref-format.sh reject leading-dash branch names. A separator before the branch would select path checkout semantics.
- The required
codex review --commit 671ea00 invocation failed before review startup because the sandbox blocked app-server initialization. An independent Codex agent review of the committed change found no actionable issues.
Commit: 671ea00 — test(refs): cover all option-shaped checkout branch operands.
All 67 hosted CI checks pass for 671ea00, including the Linux/macOS/Windows matrix, GixPython, supported-runtime imports, Cygwin, Alpine, lint, documentation, downstream integrations, and the backend benchmark. No CI fixes or retries were needed. There are no review comments or unresolved review threads at completion.
Release preparation and advisory publication remain outside this PR.