PyDriller
Framework for MSR
What it is and what it does
PyDriller is a Python framework for mining software repositories, built on gitpython to traverse and analyze Git history. It lets you programmatically extract structured data about commits, developers, file changes, and code diffs from any Git repository—local or remote—without writing raw Git commands yourself. The framework handles the parsing and object model so you work with clean Python objects representing commits, authors, and file modifications.
It's commonly used in software engineering research, code quality analysis, and repository auditing. The package depends on gitpython for Git operations, pytz for timezone handling, and lizard for optional code complexity metrics. It supports Python 3.5 and later, with active maintenance and no known security vulnerabilities.
Use it for:
- Extract commit history and metadata for software engineering research or empirical studies on development patterns.
- Analyze file change frequency and developer contributions to identify code hotspots and team dynamics.
- Build automated code review or quality monitoring tools that examine diffs and commit patterns over time.
- Generate repository statistics and reports on project evolution, commit volume, and contributor activity.
- Audit repository history for compliance, security, or documentation purposes without manual Git log parsing.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
PyDriller extracts commit history, developer metadata, modified files, diffs, and source code information from Git repositories for analysis and mining.
Yes. PyDriller is actively maintained, has no security vulnerabilities, installs with low friction, and offers a clean Python API for Git analysis. It's well-suited for anyone building repository analysis tools, conducting software engineering research, or automating repository audits. The permissive Apache License poses no barrier to adoption.
Install
pydriller on PyPI
pip
pip install pydrilleruv
uv add pydrillerpoetry
poetry add pydrillerInstalling PyDriller
Before you install
Low friction install with a pure-Python wheel distribution. Active maintenance with a recent release 44 days ago and ongoing repository activity.
License in practice
Apache License permits commercial and private use with minimal restrictions, making it suitable for most projects without licensing concerns.
Quickstart
pip install pydriller
from pydriller import Repository
for commit in Repository('https://github.com/ishepard/pydriller').traverse_commits():
print(commit.hash, commit.msg, commit.author.name)
Verify before relying
- Whether the package handles very large repositories efficiently or has performance limitations on scale.
- Specific Git version requirements or compatibility constraints beyond Python version support.
Package facts
| License | Apache License (permissive) |
| Python support | supports the current Python release (>=3.5) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 4 — gitpython, pytz, types-pytz, lizard |
| Maintenance | actively maintained — 44 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 314,790/month — #7,696 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: pydriller-2.10-py3-none-any.whl
Tags
More Python Modules packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
PyYAMLPyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
annotated-typesProvides reusable metadata objects for use with…
permissive · top 100 on PyPI
typing-inspectionProvides runtime tools to inspect and…
permissive · top 100 on PyPI
diff-coverCompares test coverage reports against git…
permissive · top 1,000 on PyPI
GitPythonGitPython provides high-level and low-level…
permissive · top 1,000 on PyPI
bar-raiserBar-Raiser creates GitHub checks with inline…
permissive · top 15,000 on PyPI
gitlintGitlint is a command-line tool that validates…
permissive · top 5,000 on PyPI
gitdb2Provides low-level read and write access to…
unclear · top 15,000 on PyPI
gitlint-coreLints Git commit messages against configurable…
permissive · top 5,000 on PyPI
gitdbGitDB provides low-level read and write access…
permissive · top 1,000 on PyPI
scancode-toolkitScanCode Toolkit detects licenses, copyrights,…
permissive · top 15,000 on PyPI
truffleHogScans Git repositories and other sources for…
unclear · top 15,000 on PyPI
pyelftoolspyelftools parses and analyzes ELF binary files…
permissive · top 5,000 on PyPI