pyci-check
Fast Python syntax and import checker designed for CI/CD and Git hooks.
Features
- ⚡ High-performance parallel processing - Uses ThreadPoolExecutor
- 🔍 Dual-layer checking - Syntax (AST) + Import (static/dynamic)
- 🎯 Flexible scope - Check entire project, directories, or specific files
- 🔧 Auto-integrates ruff config - Reads from
pyproject.toml - 🪝 Git hooks support - Append mode, preserves existing hooks
- 📦 Zero external dependencies - Uses only Python standard library
- 🌐 Multi-language - English, Traditional Chinese, Simplified Chinese
Installation
pip install pyci-check
Or with uv (recommended):
# Preferred (adds to pyproject.toml)
uv add pyci-check
# Or direct install
uv pip install pyci-check
Quick Start
# Check entire project (syntax + import static analysis)
pyci-check check
# Check syntax only
pyci-check syntax
# Check imports (static, safe)
pyci-check imports
# Install Git pre-commit hook
pyci-check install-hooks
Main Commands
check [paths...]- Run all checks (syntax + import)syntax [paths...]- Check Python syntax onlyimports [paths...]- Check import dependencies onlyinstall-hooks- Install Git hooks (append mode)uninstall-hooks- Remove pyci-check's Git hooks
Common Options
--quiet- Reduce output--fail-fast- Stop on first error--venv PATH- Specify virtual environment--i-understand-this-will-execute-code- Enable dynamic import checking
Configuration
Configure in pyproject.toml:
[tool.pyci-check]
language = "en" # or "zh_TW", "zh_CN"
import-timeout = 30
# Auto-reads ruff config
[tool.ruff]
src = ["src", "tests"]
exclude = [".venv", "build", "dist"]
Documentation
Full documentation available on GitHub:
- Full README - Complete guide with examples
- Usage Guide - Detailed usage and configuration
- Validation Docs - Check documentation with examples
- 中文文档 - Traditional Chinese
- 简体中文 - Simplified Chinese
CI/CD Integration
GitHub Actions
- name: Check Python syntax and imports
run: |
pip install pyci-check
pyci-check check
With ruff
pyci-check check # Syntax + import checking
ruff check --fix # Lint + auto-fix
ruff format # Format
License
MIT License
Links
- Homepage: https://github.com/coseto6125/pyci-check
- Documentation: https://github.com/coseto6125/pyci-check/blob/main/docs/en/USAGE.md
- Bug Reports: https://github.com/coseto6125/pyci-check/issues
- Changelog: https://github.com/coseto6125/pyci-check/releases
Metadata
Release files for pyci-check 0.3.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pyci_check-0.3.5.tar.gz | 131.8 kB | Without provenance | Details for pyci_check-0.3.5.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pyci_check-0.3.5-py3-none-any.whl | Python 3 | none | any | Details for pyci_check-0.3.5-py3-none-any.whl |
Total release size: 191.0 kB
Release files / pyci_check-0.3.5.tar.gz
| Download URL | pyci_check-0.3.5.tar.gz |
|---|---|
| Size | 131.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1e40f9b153573be76274a1593b451a797a035bed0f7c0fa36e6750793b89df45
|
|
BLAKE2b-256 checksum How to use checksums |
103f3296a81d0e522c76a99cd7d4d03c0f13ad15fe75e96ffe2db3f703ccff62
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / pyci_check-0.3.5-py3-none-any.whl
| Download URL | pyci_check-0.3.5-py3-none-any.whl |
|---|---|
| Size | 59.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
cfa74eb54657692aa7da2f10ce66238db3de85a84659a480b8dbf4997690ff21
|
|
BLAKE2b-256 checksum How to use checksums |
c29b6c38511a4b526ff6284bf5480e434fcd40386e33c4e58218a16b9fab843c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Security for pyci-check 0.3.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.