Skip to content

Exempt nopep8 as a Leading Directive in the Prose Gate - #2833

Merged
ptr727 merged 3 commits into
developfrom
feature/nopep8-not-prose
Oct 11, 2026
Merged

ptr727 merged 3 commits into
developfrom
feature/nopep8-not-prose

Conversation

@ptr727

@ptr727 ptr727 commented Oct 11, 2026

Copy link
Copy Markdown
Owner

Adds nopep8 (any letter case) to the prose gate's NOT_PROSE pattern beside noqa, so a comment line opening on it is exempt from comment-wrap, comment-case and comment-added exactly as noqa is. Removes the nopep8 alternative from TOOL_DIRECTIVE, which was unreachable once NOT_PROSE is tested first.

This answers an open Copilot finding on the develop to main promotion PR.

Known items, each with its class:

  • The nopep8 exemption gives up the sentence-end guard is_tool_directive applied, and is not limited to Python files. This matches how noqa already behaves (intended parity, not a regression).
  • No test row pins the lowercase # nopep8 spelling for comment-case (introduced, minor; the existing rows are capitalised).

Closes on promotion: none (finding on the promotion PR only).

🤖 Generated with Claude Code

ptr727 and others added 2 commits October 11, 2026 11:15
NOT_PROSE named noqa but not nopep8, so a leading nopep8 directive line
holding two sentences was judged by comment-wrap and comment-case.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
NOT_PROSE now exempts nopep8 from every comment rule, as it does noqa, so
the TOOL_DIRECTIVE entry could never be reached.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI lite review requested due to automatic review settings October 11, 2026 18:26
@coderabbitai

coderabbitai Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: Repository: ptr727/ProjectTemplate/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 64fedc76-b784-43aa-be8b-0d292d57605a

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Add regression coverage for lowercase leading # nopep8 spelling.

1 open finding
What changed in this PR

Updates the prose gate so leading nopep8 directives receive the same exemption as noqa.

Changes:

  • Adds case-insensitive nopep8 matching to NOT_PROSE.
  • Removes the redundant TOOL_DIRECTIVE alternative.
  • Adds regression coverage for directive exemptions.
File Summary
tests/​test_prose_lint.py Adds nopep8 exemption coverage; lowercase spelling coverage is still needed.
.github/​actions/​prose-gate/​prose_lint.py Updates directive classification patterns.

🧠 Review effort: Lite


💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread tests/test_prose_lint.py
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codecov

codecov Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 60.26%. Comparing base (3bb3c95) to head (f5d0322).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #2833   +/-   ##
========================================
  Coverage    60.26%   60.26%           
========================================
  Files           16       16           
  Lines         8489     8489           
========================================
  Hits          5116     5116           
  Misses        3373     3373           
Flag Coverage Δ
python-3.13 60.26% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ptr727

ptr727 commented Oct 11, 2026

Copy link
Copy Markdown
Owner Author

A recorded local strict-review pass covers head f5d03225040e13bf54c62ac99de433a36aef07ef, the content this pull request carries at that commit against develop, and it recorded 0 findings.

@ptr727
ptr727 merged commit 4035555 into develop Oct 11, 2026
13 checks passed
@ptr727
ptr727 deleted the feature/nopep8-not-prose branch October 11, 2026 18:39
ptr727 added a commit that referenced this pull request Oct 11, 2026
…ilure Reporting Fixes to Main (#2816)

## Summary

Promotes these pull requests from develop to main:

- #2832 Require Every CLI Script to Answer Help and Refuse Unknown
Arguments
- #2833 Exempt nopep8 as a Leading Directive in the Prose Gate
- #2815 Bind the Workspace-Edit Rule Only to an Agent Running Inside VS
Code
- #2813 Record HomeAssistant-Config's Incidental Python as a driftNote
- #2827 Read nopep8 in Any Letter Case in the Prose Gate
- #2825 Spend a Head Refusal a Later Genuine Round on That Head Answers
- #2819 Read noqa and CSpell Directives in Any Letter Case
- #2814 Judge the Prose in Front of a Trailing noqa or pylint Directive
- #2811 Name Why a Windows Tool Install Failed and Print Docker's Status
in UTF-8
- #2808 Read a Tool Name as a Prose Gate Directive Only Where It Opens
the Comment
- #2802 Name a File the Prose Gate Cannot Decode in Its Scope Line
- #2800 Read a First-Line Comment After a Byte Order Mark as Leading in
Every Language
- #2797 Name a Python File the Prose Gate Cannot Parse in Its Scope Line
- #2794 Let the Unattended Orchestrator Retry a Transient Dispatch
Failure
- #2792 Close the Remaining Blocked-Promotion Gaps in the Unattended
Worker
- #2790 Read a Carried Change Set Past the Compare Endpoint's 300-File
Ceiling
- #2784 Let a Round on the Head Outrank pr_review.py wait's Repo-Wide
Quota Reading
- #2782 Say What pr_review.py wait --min-rounds Counts and Name It at
the Timeout
- #2778 Share the Bounded Step Reader Across the Test Harnesses
- #2776 Pin the Prose Gate's Override Wiring by Structure
- #2773 Exempt a List Item's Label Separator from the Dash Rule for
Every Marker and Bold Spelling
- #2771 Strip a List Item's Opening Label for Every Marker and Bold
Spelling in the Prose Gate
- #2768 Page pr_review.py's Changed-File List Past 100 So a Large
Promotion Can State Coverage
- #2765 Let an Attested Local Pass Cover a Head Beside a Table-Less
Copilot Round

Closes #2285
Closes #2820
Closes #2818
Closes #2809
Closes #2807
Closes #1659
Closes #2796
Closes #2798
Closes #2163
Closes #1984
Closes #2614
Closes #2767
Closes #2781
Closes #2741
Closes #2775
Closes #1665
Closes #2770
Closes #2738
Closes #2758
Closes #2739

🤖 Generated with [Claude Code](https://claude.com/claude-code)
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.

2 participants