Skip to main content

Detect AI-generated code patterns via static analysis

Project description

no-slop

Detect AI-generated code patterns via static analysis

Python 3.10+ mypy flake8
CI codecov PyPI
License: MIT

[!NOTE] Why mypy/flake8? Ruff and ty don't support external plugins (ruff#283, ty blog).

Install

pip install no-slop

Usage

mypy plugin (redundant type checks):

# pyproject.toml
[tool.mypy]
plugins = ["no_slop.mypy_plugin"]

flake8 plugin (style checks) - auto-registers on install:

flake8 your_project/

Unused defaults CLI:

no-slop-unused-defaults /path/to/project

What it detects

  • Redundant isinstance/hasattr/getattr/callable when types guarantee the result
  • Runtime checks on Any/untyped values (add types instead)
  • ASCII art, emojis, excessive docstrings
  • Default parameters never used by any call site

See docs.md for full documentation.

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

no_slop-0.3.0.tar.gz (22.2 kB view details)

Uploaded Source

Built Distribution

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

no_slop-0.3.0-py3-none-any.whl (19.8 kB view details)

Uploaded Python 3

File details

Details for the file no_slop-0.3.0.tar.gz.

File metadata

  • Download URL: no_slop-0.3.0.tar.gz
  • Upload date:
  • Size: 22.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for no_slop-0.3.0.tar.gz
Algorithm Hash digest
SHA256 d57ffc1be5dcfe19ae2274345b3484d4a90773c16780d6057a4a4efd675e647a
MD5 80d4cf133d5c6b0296cd8a37a791eb37
BLAKE2b-256 6d1851c7d9defcbad9d2043d36a493fa3ab12344063a0e0173f2215a3b896844

See more details on using hashes here.

Provenance

The following attestation bundles were made for no_slop-0.3.0.tar.gz:

Publisher: release.yml on HardMax71/no-slop

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file no_slop-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: no_slop-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 19.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for no_slop-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2820d4f428614ec259b4712137cce83d5e6931408541e7f8527b425ea46a0565
MD5 4a70439d916ef1ca9eacee597ef1e608
BLAKE2b-256 30f585e721df448a0c73248b4f5485aca0e325f452523fb8d37808aff130462a

See more details on using hashes here.

Provenance

The following attestation bundles were made for no_slop-0.3.0-py3-none-any.whl:

Publisher: release.yml on HardMax71/no-slop

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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