Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
80 commits
Select commit Hold shift + click to select a range
fafbc2e
feat!: use guarded Git commands for repository storage
codex Oct 1, 2026
4d12e1a
ci: build supported Git for Cygwin tests
codex Oct 1, 2026
c319edc
test: handle symlinked Git directories in refresh checks
codex Oct 1, 2026
f794b2e
fix: preserve repository and object paths across platforms
codex Oct 1, 2026
ac0254d
test: cover Cygwin index filename restrictions
codex Oct 1, 2026
e4588c2
test: preserve hidden gitfiles when preparing submodule aliases
codex Oct 1, 2026
9a0a864
test: clean up read-only submodule object files on Windows
codex Oct 1, 2026
52bb051
fix(submodule): close repositories owned by update operations
codex Oct 1, 2026
c827542
ci: install supported Git in the normal Cygwin layout
codex Oct 1, 2026
df6d9de
test(downstream): run released Bandit baseline tests against this che…
codex Oct 1, 2026
72ce3fc
test(downstream): validate the latest MLflow Git integration
codex Oct 1, 2026
be865fe
test(downstream): exercise released LangChain GitLoader integration
codex Oct 1, 2026
f3d9b20
test(downstream): cover SWE-bench cloning across Git storage formats
codex Oct 1, 2026
eda44a9
test(downstream): run DataHub Git integration for its latest release
codex Oct 1, 2026
4e8857a
feat(gix): select the released backend through an installation extra
codex Oct 1, 2026
69bba7b
feat(gix): read object headers with native lookup
codex Oct 1, 2026
e005af3
feat(gix): stream small objects from native storage
codex Oct 1, 2026
fc02a24
feat(gix): resolve revisions and repository metadata natively
codex Oct 1, 2026
8ab427b
feat(gix): enumerate tree entries natively
codex Oct 1, 2026
a8e1f5b
feat(gix): resolve symbolic reference targets natively
codex Oct 1, 2026
c6b2272
feat(gix): enumerate reference names natively
codex Oct 1, 2026
bd41042
feat(gix): query merged repository configuration natively
codex Oct 1, 2026
02e30df
feat(gix): list worktree metadata natively
codex Oct 1, 2026
4e7dfb9
feat(gix): find merge bases and test ancestry natively
codex Oct 1, 2026
aac218d
feat(gix): count reachable commits natively
codex Oct 1, 2026
8a665e3
feat(gix): iterate first-parent commit history natively
codex Oct 1, 2026
73a1445
feat(gix): read index entries natively
codex Oct 1, 2026
3e11c51
feat(gix): query the index version natively
codex Oct 1, 2026
4152ed3
feat(gix): hash and store objects natively
codex Oct 1, 2026
27eeb35
feat(gix): write index trees with the native editor
codex Oct 1, 2026
b5e8e95
feat(gix): serialize trees with native object storage
codex Oct 1, 2026
2655c5f
feat(gix): initialize private indexes from trees natively
codex Oct 1, 2026
43280a4
feat(gix): persist index edits through native snapshots
codex Oct 1, 2026
a62661b
feat(gix): create unsigned UTF-8 commits natively
codex Oct 1, 2026
f8443cb
feat(gix): read reference logs natively
codex Oct 1, 2026
450985b
feat(gix): resolve supported committer identities through Gix
codex Oct 1, 2026
5ac5310
feat(gix): update supported reference targets natively
codex Oct 1, 2026
574d198
feat(gix): compute raw tree diffs natively
codex Oct 1, 2026
92ce25e
feat(gix): compute commit statistics natively
codex Oct 1, 2026
83413d4
feat(gix): discover untracked files natively
codex Oct 1, 2026
a63ce33
feat(gix): check ignored paths natively
codex Oct 1, 2026
ce6de9c
feat(gix): check repository dirtiness natively
codex Oct 1, 2026
f417027
build(gix): preserve the extra in local source distributions
codex Oct 1, 2026
8337c0a
fix(gix): omit dangling symbolic references from enumeration
codex Oct 1, 2026
463b3ca
fix(gix): defer compatibility object formats to Git
codex Oct 1, 2026
37615e8
docs(gix): document release setup and native conversion gaps
codex Oct 1, 2026
41e4bde
test: avoid repository setup for actor and exception tests
codex Oct 6, 2026
c3822ec
test: prepare historical dependency sources once on demand
codex Oct 6, 2026
09a8668
test: copy prepared submodule baselines for each case
codex Oct 6, 2026
d0b39fd
test: reuse prepared submodule rejection layouts
codex Oct 6, 2026
d5be340
test: reuse a prepared revision graph with isolated copies
codex Oct 6, 2026
437ddc1
test: read historical trees without cloning a checkout
codex Oct 6, 2026
c1be99f
test: copy prepared no-fetch source and submodule repositories
codex Oct 6, 2026
42e56ce
docs: record fixture optimization validation and suite timings
codex Oct 6, 2026
6727c74
test(perf): benchmark repository journeys across CLI and GixPython
codex Oct 7, 2026
244fd08
ci: compare CLI and GixPython repository benchmarks
codex Oct 7, 2026
84a1983
docs(perf): record measured CLI and GixPython repository journeys
codex Oct 7, 2026
47356cd
test(gix): count CLI process launches and enforce benchmark ceilings
codex Oct 7, 2026
7bedb21
perf(gix): retain native repository handles on `Repo`
codex Oct 7, 2026
a503fc7
perf(gix): open repositories with supported native metadata
codex Oct 7, 2026
8e94b11
docs(perf): preserve pre-audit retained-handle measurements
codex Oct 7, 2026
9d7f9fc
refactor(gix): centralize retained repository access on `Repo`
codex Oct 7, 2026
8e4fd7c
perf(gix): resolve fixed metadata paths from the native Git directory
codex Oct 7, 2026
6385caa
perf(gix): reuse object streams for serialization readback
codex Oct 7, 2026
3051e96
perf(gix): read absent references without CLI fallbacks
codex Oct 7, 2026
83e1109
perf(gix): validate reference names without opening Git
codex Oct 7, 2026
4a78e94
perf(gix): discover gitfiles through canonical native repositories
codex Oct 7, 2026
c532afd
perf(gix): resolve revision path metadata without cat-file
codex Oct 7, 2026
68223c1
perf(gix): parse submodule inventory and cached fields natively
codex Oct 7, 2026
28551f2
docs(gix): record remaining configuration binding requirements
codex Oct 7, 2026
a3f26fd
perf(cmd): share minimum Git version checks across wrappers
codex Oct 7, 2026
547ce49
test(gix): keep hook lookup and execution on Git
codex Oct 7, 2026
a0ab8c4
test(perf): track native repository reads and required fallbacks
codex Oct 7, 2026
b45c526
docs(gix): track strict Git compatibility and verified measurements
codex Oct 7, 2026
5d8aeb3
ci(downstream): test releases with CLI and Gix backends
codex Oct 7, 2026
ff32fb7
perf(repo): batch repository metadata queries
codex Oct 7, 2026
df2e647
fix(gix): preserve Git compatibility on Windows
codex Oct 7, 2026
21a6c6a
ci(gix): add Ubuntu and macOS jobs with Cargo caching
codex Oct 8, 2026
c3a2832
fix: stabilize Windows submodules and temporary test cleanup
codex Oct 8, 2026
ee242ae
perf(tests): reduce Windows submodule process overhead
Byron Oct 8, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
144 changes: 0 additions & 144 deletions .basedpyright/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,75 +8,9 @@
"endColumn": 45,
"lineCount": 1
}
},
{
"code": "reportArgumentType",
"range": {
"startColumn": 41,
"endColumn": 48,
"lineCount": 1
}
},
{
"code": "reportArgumentType",
"range": {
"startColumn": 32,
"endColumn": 39,
"lineCount": 1
}
},
{
"code": "reportCallIssue",
"range": {
"startColumn": 25,
"endColumn": 46,
"lineCount": 1
}
},
{
"code": "reportArgumentType",
"range": {
"startColumn": 30,
"endColumn": 39,
"lineCount": 1
}
}
],
"./git/db.py": [
{
"code": "reportIncompatibleMethodOverride",
"range": {
"startColumn": 8,
"endColumn": 12,
"lineCount": 1
}
},
{
"code": "reportIncompatibleMethodOverride",
"range": {
"startColumn": 8,
"endColumn": 14,
"lineCount": 1
}
}
],
"./git/index/base.py": [
{
"code": "reportArgumentType",
"range": {
"startColumn": 30,
"endColumn": 36,
"lineCount": 1
}
},
{
"code": "reportArgumentType",
"range": {
"startColumn": 28,
"endColumn": 34,
"lineCount": 1
}
},
{
"code": "reportArgumentType",
"range": {
Expand Down Expand Up @@ -186,14 +120,6 @@
"endColumn": 25,
"lineCount": 1
}
},
{
"code": "reportArgumentType",
"range": {
"startColumn": 52,
"endColumn": 84,
"lineCount": 1
}
}
],
"./git/objects/tag.py": [
Expand Down Expand Up @@ -274,32 +200,6 @@
}
}
],
"./git/refs/log.py": [
{
"code": "reportArgumentType",
"range": {
"startColumn": 30,
"endColumn": 34,
"lineCount": 1
}
},
{
"code": "reportAttributeAccessIssue",
"range": {
"startColumn": 17,
"endColumn": 22,
"lineCount": 1
}
},
{
"code": "reportArgumentType",
"range": {
"startColumn": 28,
"endColumn": 30,
"lineCount": 1
}
}
],
"./git/refs/reference.py": [
{
"code": "reportIncompatibleVariableOverride",
Expand All @@ -310,16 +210,6 @@
}
}
],
"./git/refs/symbolic.py": [
{
"code": "reportAttributeAccessIssue",
"range": {
"startColumn": 15,
"endColumn": 20,
"lineCount": 1
}
}
],
"./git/refs/tag.py": [
{
"code": "reportIncompatibleMethodOverride",
Expand All @@ -339,22 +229,6 @@
}
],
"./git/remote.py": [
{
"code": "reportAttributeAccessIssue",
"range": {
"startColumn": 26,
"endColumn": 38,
"lineCount": 1
}
},
{
"code": "reportAttributeAccessIssue",
"range": {
"startColumn": 26,
"endColumn": 38,
"lineCount": 1
}
},
{
"code": "reportAttributeAccessIssue",
"range": {
Expand All @@ -373,14 +247,6 @@
}
],
"./git/repo/base.py": [
{
"code": "reportReturnType",
"range": {
"startColumn": 15,
"endColumn": 28,
"lineCount": 1
}
},
{
"code": "reportTypedDictNotRequiredAccess",
"range": {
Expand Down Expand Up @@ -446,16 +312,6 @@
}
}
],
"./git/repo/fun.py": [
{
"code": "reportReturnType",
"range": {
"startColumn": 11,
"endColumn": 20,
"lineCount": 1
}
}
],
"./test/deprecation/test_basic.py": [
{
"code": "reportUnusedExpression",
Expand Down
78 changes: 78 additions & 0 deletions .github/workflows/backend-benchmark.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
name: Backend benchmark

on:
push:
branches: [main]
pull_request:
workflow_dispatch:

permissions:
contents: read

jobs:
compare-backends:
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 0
persist-credentials: false
- uses: actions/setup-python@v7
with:
python-version: "3.12"
- name: Ensure Git 2.52 or newer
run: |
if ! dpkg --compare-versions "$(git version | awk '{print $3}')" ge 2.52; then
sudo add-apt-repository --yes ppa:git-core/ppa
sudo apt-get update
sudo apt-get install --yes git
fi
- name: Install separate backends with the same interpreter
run: |
python -m venv .bench-cli
python -m venv .bench-gix
.bench-cli/bin/python -m pip install . -r test/performance/benchmark-requirements.txt
.bench-gix/bin/python -m pip install '.[gix]' -r test/performance/benchmark-requirements.txt
- name: Prepare an existing repository outside the timed operations
env:
BENCH_REPO: ${{ runner.temp }}/benchmark-repo
GIT_CONFIG_NOSYSTEM: "1"
GIT_CONFIG_GLOBAL: /dev/null
run: |
git init --object-format=sha1 --ref-format=files "$BENCH_REPO"
git -C "$BENCH_REPO" fetch --no-tags "$GITHUB_WORKSPACE" 6ba2c0a2f9ee7feffd7e079621c4845820180c9a
git -C "$BENCH_REPO" checkout -b benchmark FETCH_HEAD
git -C "$BENCH_REPO" config core.excludesFile /dev/null
git -C "$BENCH_REPO" config core.attributesFile /dev/null
git -C "$BENCH_REPO" config core.fsmonitor false
git -C "$BENCH_REPO" config core.untrackedCache false
git -C "$BENCH_REPO" config gc.auto 0
git -C "$BENCH_REPO" config maintenance.auto false
mkdir "$BENCH_REPO/.benchmark-cache"
touch "$BENCH_REPO/.benchmark-cache/probe" "$BENCH_REPO/benchmark-untracked.txt"
echo '.benchmark-cache/' >> "$BENCH_REPO/.git/info/exclude"
mkdir benchmark-results
- name: Measure GixPython operations, opening and discovery first
run: |
.bench-gix/bin/python -m test.performance.bench_repository \
--repo "$RUNNER_TEMP/benchmark-repo" --expect-backend gix -o benchmark-results/gix.json
- name: Measure CLI operations, opening and discovery
run: |
.bench-cli/bin/python -m test.performance.bench_repository \
--repo "$RUNNER_TEMP/benchmark-repo" --expect-backend cli -o benchmark-results/cli.json
- name: Check parity and publish comparison
run: |
.bench-gix/bin/python -m test.performance.compare_backends \
benchmark-results/cli.json benchmark-results/gix.json \
--cli-budget test/performance/cli-budget.json > benchmark-results/comparison.md
cat benchmark-results/comparison.md >> "$GITHUB_STEP_SUMMARY"
.bench-gix/bin/python -m pyperf compare_to \
benchmark-results/cli.json benchmark-results/gix.json --table --table-format md \
>> "$GITHUB_STEP_SUMMARY"
- name: Retain raw timings and comparison
if: always()
uses: actions/upload-artifact@v7
with:
name: backend-benchmark
path: benchmark-results/
16 changes: 15 additions & 1 deletion .github/workflows/cygwin-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,25 @@ jobs:
- name: Install Cygwin
uses: cygwin/cygwin-install-action@v6
with:
packages: curl git python39 python-setuptools-wheel
packages: >-
curl gcc-core git libcurl-devel libexpat-devel libiconv-devel
libssl-devel make python39 python-setuptools-wheel zlib-devel
add-to-path: false # No need to change $PATH outside the Cygwin environment.

- name: Arrange for verbose output
run: |
# Arrange for verbose output but without shell environment setup details.
echo 'set -x' >~/.bash_profile

- name: Build minimum supported Cygwin Git
run: |
# Cygwin's packaged Git is older than our minimum supported version.
git clone --depth 1 --branch v2.52.0 -- https://github.com/git/git.git /tmp/git-source
# Use Cygwin's normal prefix: GitPython checks for uname next to git.
make -C /tmp/git-source -j2 prefix=/usr NO_GETTEXT=YesPlease NO_TCLTK=YesPlease NO_PERL=YesPlease install
hash -r
test "$(git version)" = 'git version 2.52.0'

- name: Special configuration for Cygwin git
run: |
git config --global --add safe.directory "$(pwd)"
Expand Down Expand Up @@ -87,6 +98,9 @@ jobs:
run: |
pip install ./smmap ./gitdb '.[test]'

- name: Verify Cygwin Git detection
run: python -c 'from git import Git; assert Git.is_cygwin()'

- name: Show POSIX file ownership
# Cygwin's `ls -ld` reports the NTFS Owner SID via Cygwin's SID-to-uid
# mapping (well-known SIDs by their RID, machine-local accounts by
Expand Down
38 changes: 38 additions & 0 deletions .github/workflows/downstream.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Downstream compatibility

on:
push:
branches: [main]
pull_request:
workflow_dispatch:

permissions:
contents: read

jobs:
test:
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
fail-fast: false
matrix:
project: [langchain, mlflow, bandit, swebench, datahub]
backend: [gix, cli]
steps:
- uses: actions/checkout@v7
with:
persist-credentials: false
- name: Ensure Git 2.52 or newer
run: |
if ! dpkg --compare-versions "$(git version | awk '{print $3}')" ge 2.52; then
sudo add-apt-repository --yes ppa:git-core/ppa
sudo apt-get update
sudo apt-get install --yes git
fi
- name: Install uv
uses: astral-sh/setup-uv@c18668ad3cf93ea998bef934396af7bb5c839dc7 # v10.2.0
with:
version: '0.12.13'
enable-cache: false
- name: Test latest release against this checkout
run: uv run test/downstream/run.py "${{ matrix.project }}" --backend "${{ matrix.backend }}"
42 changes: 42 additions & 0 deletions .github/workflows/git-cli.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Minimum Git CLI

on:
push:
branches: [main]
pull_request:
workflow_dispatch:

permissions:
contents: read

jobs:
git-2-52:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/checkout@v7
with:
repository: git/git
ref: v2.52.0
path: .git-source
- uses: actions/setup-python@v7
with:
python-version: '3.12'
- name: Build minimum supported Git
working-directory: .git-source
run: |
make -j2 prefix="$RUNNER_TEMP/git" NO_GETTEXT=YesPlease NO_TCLTK=YesPlease NO_PERL=YesPlease NO_CURL=YesPlease install
echo "$RUNNER_TEMP/git/bin" >> "$GITHUB_PATH"
- name: Install GitPython and test dependencies
run: python -m pip install ./smmap ./gitdb '.[test]'
- name: Verify native format and safety contracts
env:
GIT_CONFIG_NOSYSTEM: '1'
GIT_CONFIG_GLOBAL: /dev/null
GIT_AUTHOR_NAME: GitPython Tests
GIT_AUTHOR_EMAIL: tests@example.invalid
GIT_COMMITTER_NAME: GitPython Tests
GIT_COMMITTER_EMAIL: tests@example.invalid
run: |
git version
python -m pytest --no-cov --tb=short test/test_cli_objects_index.py test/test_cli_safety.py test/test_reflog.py test/test_config.py test/test_remote_cli.py test/test_submodule.py::test_submodule_cli_lifecycle
Loading
Loading