Skip to content

Add Vale prose checks for Python comments and docstrings - #75

Open
MrC8559 wants to merge 1 commit into
rxdt:mainfrom
MrC8559:feature/vale-prose-check
Open

MrC8559 wants to merge 1 commit into
rxdt:mainfrom
MrC8559:feature/vale-prose-check

Conversation

@MrC8559

@MrC8559 MrC8559 commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

Summary

Completes the prose half of #61 with Vale, building on the identifier-name work merged in #74.

  • checks Python comments plus module/class/function docstrings through a tree-sitter View;
  • leaves ordinary Python string literals alone;
  • adds two small project-owned advisory rules: plain-word substitutions and sentences over 30 words;
  • wires Vale into the default prose gate/category;
  • packages and hoists the Vale config/styles during harness init;
  • installs pinned Vale 3.22.0 in the existing Ubuntu/macOS/Windows CI matrix;
  • reports the rule and file/line location in actionable language.

Plain-English boundary

These are LoopGate's own advisory plain-English rules. This change:

  • ships no ASD word list;
  • does not claim ASD-STE100 conformance or certification;
  • keeps each rule mechanical and easy to explain.

Tests

Added focused regression coverage proving that:

  • module, class, and function docstrings are checked;
  • comments are checked;
  • ordinary string literals are not treated as prose;
  • a sentence over 30 words is reported once;
  • two separate shorter sentences are not incorrectly combined;
  • the Vale config/style files are included in the installed harness.

Validation

The exact 14-file implementation was validated in the fork before this clean one-commit branch was created.

Final fork workflow run #20 passed completely on Ubuntu, macOS, Windows, and dependency review. The gate included Vale plus the repository's existing audit, security, pytest/100%-coverage, Pyright, Ruff format/lint, Pylint, and complexity checks.

Running the prose gate across the repository produced 12 advisory sentence-length warnings in 18 Python files and no errors. The detailed output is posted on #61 as requested.

Closes #61

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Check comments and docstrings for plain English (names done)

1 participant