@@ -56,23 +56,25 @@ modules:
5656 ` repository.py ` , ` callbacks.py ` , ` config.py ` , ` index.py ` , ` remotes.py ` ,
5757 ` settings.py ` , ` submodules.py ` , ` transaction.py ` , ` filter.py ` , ` blob.py ` ,
5858 ` blame.py ` , ` branches.py ` , ` credentials.py ` , ` errors.py ` , ` options.py ` ,
59- ` packbuilder.py ` , ` references.py ` , ` refspec.py ` , ` utils.py ` , ` enums.py ` .
59+ ` packbuilder.py ` , ` rebase.py ` , ` references.py ` , ` refspec.py ` , ` utils.py ` ,
60+ ` enums.py ` .
6061
6162- ** ` test/ ` ** — pytest suite with fixture-based repository handling.
6263- ** ` docs/ ` ** — Sphinx documentation (RTD theme).
6364
6465## Key Configuration Files
6566
6667- ** ` setup.py ` ** — setuptools entry point. Builds both the C extension
67- (` src/*.c ` ) and the CFFI extension (` pygit2/_run.py:ffi ` ).
68+ (` src/*.c ` ) and the CFFI extension (` pygit2/_run.py:ffi ` ). On Windows it
69+ also copies ` git2.dll ` into the package (see ` BuildWithDLLs ` ).
6870- ** ` pyproject.toml ` ** — Build-system requirements, ` cibuildwheel `
6971 configuration, ` ruff ` settings, and ` codespell ` settings.
7072- ** ` setup.cfg ` ** — Legacy pycodestyle configuration.
7173- ** ` pytest.ini ` ** — pytest configuration (` --capture=no -ra --verbose ` ,
7274 ` testpaths = test/ ` ).
7375- ** ` mypy.ini ` ** — mypy configuration with strict settings.
7476- ** ` mypy-stubtest.ini ` ** — mypy configuration for ` stubtest ` against
75- ` _pygit2.pyi ` .
77+ ` _pygit2.pyi ` (at the repo root) .
7678- ** ` requirements.txt ` ** — Runtime/build requirements (` cffi>=2.0 ` ,
7779 ` setuptools ` for Python >= 3.12).
7880- ** ` requirements-test.txt ` ** — Test requirements (` pytest ` , ` pytest-cov ` ).
@@ -107,14 +109,12 @@ make
107109# Or manually:
108110LIBSSH2_VERSION=1.11.1 LIBGIT2_VERSION=1.9.6 sh build.sh
109111
110- # Build inplace and run the tests
111- sh build.sh test
112-
113- # Build a wheel, install it, and run the tests
112+ # Build a wheel and bundle the shared libraries into it
114113sh build.sh wheel
114+ sh build.sh bundle
115115
116- # Run tests with coverage
117- sh build.sh test # build.sh adds --cov=pygit2
116+ # Build inplace and run the tests with coverage (build.sh adds --cov=pygit2)
117+ sh build.sh test
118118
119119# Run mypy type checking
120120sh build.sh mypy
@@ -169,7 +169,9 @@ make -C docs html # requires sphinx-rtd-theme
169169 - Run ` ruff format ` and ` ruff check ` on changed files before committing.
170170 CI runs ` ruff format --diff ` and ` ruff check ` ; formatting failures will
171171 fail the build.
172- - ** Type checker** : mypy (strict settings enabled; see ` mypy.ini ` )
172+ - ** Type checker** : mypy (strict settings enabled; see ` mypy.ini ` ). Test
173+ modules additionally require typed defs and calls (` disallow_untyped_defs ` ,
174+ ` disallow_untyped_calls ` under ` [mypy-test.*] ` ).
173175- All Python source files must include the standard GPLv2 copyright header.
174176- ` pygit2/__init__.py ` is large because it re-exports a large surface of
175177 constants and classes; follow existing patterns when adding new public
@@ -235,13 +237,15 @@ def f(a, b):
235237GitHub Actions workflows live in ` .github/workflows/ ` :
236238
237239- ** ` tests.yml ` ** — Runs on s390x via QEMU (` uraimo/run-on-arch-action ` ).
238- Allowed to fail; see issue #812 .
240+ Allowed to fail ( ` continue-on-error ` ) ; see issue #812 .
239241- ** ` lint.yml ` ** — Runs ` ruff format --diff ` , ` ruff check ` , and
240242 ` sh build.sh mypy ` .
241- - ** ` wheels.yml ` ** — Uses ` cibuildwheel ` to build wheels for Linux (amd64,
242- arm64, ppc64le, musl), macOS (intel, arm64, PyPy), and Windows (x64, x86,
243- arm64). It also builds an sdist, runs a ` twine check ` , publishes to PyPI,
244- and creates a GitHub Release on version tags (` v* ` ).
243+ - ** ` wheels.yml ` ** — Uses ` cibuildwheel ` (` ~=3.3 ` ) to build wheels for Linux
244+ (amd64, arm64, ppc64le and riscv64 via QEMU, musl), macOS (intel, arm64,
245+ PyPy), and Windows (x64, x86, arm64). It also builds an sdist, runs a
246+ ` twine check ` (skipped on version tags), publishes to PyPI, and creates a
247+ GitHub Release on version tags (` v* ` ), with release notes parsed from
248+ ` CHANGELOG.md ` by ` .github/workflows/parse_release_notes.py ` .
245249- ** ` codespell.yml ` ** — Spell checking with the codespell action.
246250
247251The ` cibuildwheel ` configuration in ` pyproject.toml ` pins:
@@ -250,8 +254,10 @@ The `cibuildwheel` configuration in `pyproject.toml` pins:
250254- ` LIBSSH2_VERSION="1.11.1" `
251255- ` OPENSSL_VERSION="3.5.4" `
252256
253- and skips ` *musllinux_ppc64le ` plus testing on ` *-*linux_ppc64le ` and
254- ` pp*-macosx_arm64 ` .
257+ and skips ` *musllinux_ppc64le ` plus testing on ` *-*linux_ppc64le ` ,
258+ ` *-*linux_riscv64 ` and ` pp*-macosx_arm64 ` . On Windows it uses the
259+ ` Visual Studio 18 2026 ` CMake generator for x64/x86 and
260+ ` Visual Studio 17 2022 ` for ARM64.
255261
256262## Security Considerations
257263
@@ -264,6 +270,11 @@ and skips `*musllinux_ppc64le` plus testing on `*-*linux_ppc64le` and
264270- Valgrind support: see ` docs/development.rst ` and
265271 ` misc/valgrind-python.supp ` for memory-leak debugging instructions.
266272
273+ ## Git Commits
274+
275+ - Commits created by an AI agent must end with the ` Assisted-by: ` trailer.
276+ Human-authored commits do not need it.
277+
267278## Useful Notes for Agents
268279
269280- ** Do not assume libgit2 is installed globally.** Check for ` LIBGIT2 ` or use
0 commit comments