Skip to main content

PyCodemark – a full-featured code review tool for Python.

Project description

PyCodemark

PyPI version Python Version License Build


Overview

PyCodemark is a full-featured Python code review tool that automatically detects style issues, missing docstrings, and other code quality problems.
It supports terminal, JSON, and SARIF output for CI/CD integration and is extensible via plugins.


Features

  • Detect missing docstrings, PEP8 violations, and clarity issues
  • JSON and SARIF output for CI pipelines
  • Plugin system for custom checks
  • Pre-commit integration
  • Configurable via pyproject.toml
  • Works with Python 3.13+

Installation

Clone the repository:

git clone https://github.com/roshanguptamca/pycodemark.git
cd pycodemark

Create a Python 3.13 virtual environment:

python3.13 -m venv venv 
source venv/bin/activate
poetry install

Quick Start

Quick Start with PyCodemark

PyCodemark is a full-featured Python code review tool that detects style issues, missing docstrings, and other code quality problems. It supports terminal, JSON, and SARIF output for CI integration.

Installation

Install PyCodemark via pip:

pip install pycodemark

Or with Poetry:

poetry add pycodemark 

Run a basic code review:

codemark review src/
codemark review src/ --format json
codemark review src/ --format sarif    

Plugins

Extend PyCodemark by adding custom checks under src/codemark/plugins/. Each plugin must implement: ```python` def run(file_path, config): """Return a list of issues detected in the file.""" return []

Pre-commit Integration

Add to your .pre-commit-config.yaml:
```yaml repos:
  - repo: local
    hooks:
      - id: codemark
        name: codemark-review
        entry: codemark review --format terminal
        language: system
        types: [python]     
```

Then run:
```bashpre-commit install
```pre-commit install

CI/CD Integration (GitHub Actions)

You can integrate PyCodemark in CI pipelines with SARIF reporting. Example workflow file: .github/workflows/codemark.yml

Runs PyCodemark on every push or pull request

Uploads SARIF results to GitHub for code scanning

Provides automated code quality checks

Configuration

Configure PyCodemark via pyproject.toml:

[tool.pycodemark]
max_line_length = 88
rules = ["PEP8", "clarity", "docstrings"]
exclude = ["tests/", "migrations/"]

Makefile Commands:

  • make lint: Run code linting
  • make venv # Create virtual environment
  • make install # Install dependencies via Poetry
  • make build # Build package
  • make test # Run tests
  • make lint # Run linter
  • make lint-fix # Automatically fix lint issues
  • make review # Run terminal review
  • make review-json # Run review with JSON output
  • make review-sarif # Run review with SARIF output
  • make publish # Publish to PyPI

Download Documentation: PDF HTML

License

MIT License © Roshan Gupta

---

If you want, I can also provide a **one-liner command** so you can generate this README automatically on your Mac without manually copying it.  

Do you want me to do that next?

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pycodemark-0.2.2.tar.gz (5.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pycodemark-0.2.2-py3-none-any.whl (8.3 kB view details)

Uploaded Python 3

File details

Details for the file pycodemark-0.2.2.tar.gz.

File metadata

  • Download URL: pycodemark-0.2.2.tar.gz
  • Upload date:
  • Size: 5.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.13.5 Darwin/25.0.0

File hashes

Hashes for pycodemark-0.2.2.tar.gz
Algorithm Hash digest
SHA256 8c4c4b9d85c68cea32715f1580ed079b1e96e6b4d877dcf2a6ec3ac9787d4e4b
MD5 83e71a963f6a2727dbca9fd4d24a2fa6
BLAKE2b-256 c0870bad264e1b145f635ae9771bd7b1681271d33dcb2bd9002e794b147f92e1

See more details on using hashes here.

File details

Details for the file pycodemark-0.2.2-py3-none-any.whl.

File metadata

  • Download URL: pycodemark-0.2.2-py3-none-any.whl
  • Upload date:
  • Size: 8.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.13.5 Darwin/25.0.0

File hashes

Hashes for pycodemark-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 6c7611e2c631ff8fef042b1a4326e9187f3a249392474b1d162f959ec3bf7dde
MD5 eb771779983ed9dea206dcf6ccc5684f
BLAKE2b-256 8f63db6dbd3a5fa195b20bba61106567601abbe3c34bf5af6d674458db0f07f8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page