--- id: tox-gh version: "1.8.0" license: MIT license_treatment: permissive maintenance: active --- # tox-gh — Seamless integration of tox into GitHub Actions. License: permissive · Maintenance: active · Downloads: 113.3K/mo ## What it is and what it does tox-gh is a plugin for tox that bridges the gap between tox's local environment management and GitHub Actions' matrix-based parallelism. It reads a configuration section mapping Python versions to tox environments, detects which Python version is running in the current GitHub Actions job, and automatically selects the corresponding environments to run—eliminating the need to manually coordinate between your Actions matrix and your tox configuration. The plugin works by intercepting tox's environment selection logic when running inside GitHub Actions (detected via the GITHUB_ACTIONS environment variable). You define a mapping in your tox configuration (tox.toml, tox.ini, or pyproject.toml) that says "on Python 3.13, run these environments; on Python 3.12, run those," and tox-gh handles the rest. It supports freethreaded Python builds, multiple environments per version, and explicit overrides via environment variables or command-line flags. Use it for: - Run different test suites (unit tests, type checking, linting) on each Python version without duplicating workflow logic - Test against multiple Django or dependency versions in parallel by mapping factored environments to Python versions - Automatically test freethreaded Python builds (3.13t, 3.14t) alongside standard CPython in the same matrix - Reduce GitHub Actions job count by running multiple tox environments sequentially within a single job per Python version - Migrate existing tox-based projects to GitHub Actions without rewriting test configuration ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. tox-gh automatically selects and runs the appropriate tox environments for each Python version in a GitHub Actions matrix, enabling parallel test execution across multiple workers. Yes. tox-gh solves a real coordination problem between tox and GitHub Actions with zero security issues, active maintenance, and permissive licensing. Install it if you use tox for local testing and want to run the same environments in GitHub Actions without manual synchronization. The low install friction and recent activity make it a straightforward addition to any tox-based project. ## Install pip install tox-gh uv add tox-gh poetry add tox-gh ## Installing tox-gh Before you install: Low install friction with a pure Python wheel distribution. The package is actively maintained with a recent release and depends only on tox and typing-extensions, both standard tools in the Python testing ecosystem. License in practice: MIT license permits unrestricted use, modification, and distribution in both open-source and proprietary projects with minimal obligations. Quickstart: # Install pip install tox tox-gh # Add to tox.toml: [gh.python] "3.13" = ["py313"] "3.12" = ["py312"] # In GitHub Actions workflow, run: tox Requires tox 4 with a tox.toml, tox.ini, or pyproject.toml configuration file; only activates when running inside GitHub Actions (detected via GITHUB_ACTIONS environment variable). Verify before relying: - Whether tox-gh works with tox versions prior to 4.x, given the description mentions 'tox 4' as a prerequisite - Performance characteristics when running dozens of environments across a matrix - Compatibility with GitHub Actions runners other than ubuntu-latest ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 113.3K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags tox github actions integration, parallel testing github actions, python version matrix testing, tox environment selection automation, ci cd testing orchestration, github actions test runner, matrix job environment mapping, ci-cd, github-actions, testing-automation [View on SkillFed](https://skillfed.io/packages/tox-gh) · [View on PyPI](https://pypi.org/project/tox-gh/)