Skip to main content

ezgb: easy git-bug for Python

A standalone Python library for working with git-bug repositories. It lets you list, create, query, and update bugs that are stored as native git objects -- no external database required.

Features

  • Fast reads -- bug data is read directly from git objects via pygit2 (libgit2 bindings). Listing uses the git-bug CLI cache when available (~100ms for hundreds of bugs).
  • Safe writes -- all mutations go through the git bug CLI, which keeps Lamport clocks and the operation DAG consistent.
  • Simple API -- one main class (GitBugRepo) with plain Python dataclasses for bugs, comments, and identities.

Quick example

from ezgb import GitBugRepo, Status

repo = GitBugRepo('/path/to/repo')

# List open bugs
for bug in repo.list_bugs(status=Status.OPEN):
    print(bug.title)

# Create a new bug
bug = repo.create_bug('Login page is broken', 'Steps to reproduce...')

# Add a comment
repo.add_comment(bug.id, 'I can reproduce this on Firefox 130.')

Requirements

  • Python 3.10 or later
  • pygit2 (libgit2 Python bindings)
  • git-bug v0.10+ on your $PATH (needed for write operations and fast cached listing)

Installation

git clone https://git.kernel.org/pub/scm/utils/ezgb/ezgb.git
cd ezgb
pip install -e .

Documentation

Full documentation is in the docs/ directory. Build it with:

pip install sphinx sphinx-rtd-theme
make -C docs html

Then open docs/_build/html/index.html in your browser.

Development checks

uv sync --all-groups
./ci.sh

The CI script runs Ruff, ty, mypy, pyright, and pytest. The test suite includes unit tests (using real git objects in temporary repos via pygit2) and integration tests that exercise the full stack including the git-bug binary.

Contributing

See CONTRIBUTING.md for details on submitting patches, coding style, and the Developer Certificate of Origin.

License

GPLv2 or later. See COPYING for the full text.

Metadata

Release files for ezgb 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ezgb 0.2.1
File Size Uploaded
ezgb-0.2.1.tar.gz 35.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ezgb 0.2.1
File Interpreter ABI Platform
ezgb-0.2.1-py3-none-any.whl Python 3 none any Details

Total release size: 60.2 kB

Release files / ezgb-0.2.1.tar.gz

Download URL ezgb-0.2.1.tar.gz
Size 35.2 kB
Tags Source
SHA-256 checksum
How to use checksums
7837ec0606c6c7ad657ab2ccd4295c7f1efaa357b456e7993ff30f454bb7fe4f
BLAKE2b-256 checksum
How to use checksums
f3d78c1134b28950ea6d8be91aa172717c6091639c59c5dee8f0d95e10e43cb9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / ezgb-0.2.1-py3-none-any.whl

Download URL ezgb-0.2.1-py3-none-any.whl
Size 25.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
7fdb90da0dd350419cef9ad3bbef1033c3161785f89b45a02208d517372394b5
BLAKE2b-256 checksum
How to use checksums
1338b6ef6fbb9d7d571fa56917e6256fc3c1437dde7cef598c2aeca5967c2238
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release history Release notifications | RSS feed

This release

0.2.1 This release

2 release files

0.2.0

2 release files

0.1.1

2 release files

0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page