Skip to content

PR checks: the template's placeholder lines do not count as answers - #1042

Closed
DavidM1911 wants to merge 1 commit into
xcl-dev:mainfrom
DavidM1911:prcheck-template-hints
Closed

DavidM1911 wants to merge 1 commit into
xcl-dev:mainfrom
DavidM1911:prcheck-template-hints

Conversation

@DavidM1911

@DavidM1911 DavidM1911 commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

The placeholder lines in .github/pull_request_template.md counted as content, so an unedited template passed the Tested and AI use checks (and a lone - passed Not tested). check() now extracts each section's text, strips HTML comments and ignores blank lines, lone - bullets and the template's hint lines; a section with nothing else is reported empty.

Fixes #965

What is in it

  • scripts/pr_check.py: section_text() + filled() replace the \S-after-heading test; PLACEHOLDER names the template's hint lines.
  • scripts/test_pr_check.py: TemplateSectionTests — untouched template refused in all three sections, filled template passes, comments/lone bullets don't count, - none under AI use is a real answer.

Tested

Not tested

AI use

  • Devin (Cognition), model SWE-2: wrote the change and the tests, ran them

@DavidM1911

Copy link
Copy Markdown
Contributor Author

Note for whoever triages: two other open PRs target #965 — #991 (stacked on #527, moves the hints into HTML comments) and #1037 (placeholder detection in check(), also adds scripts/test_pr_check.py). This one is independent of #527 and covers the lone - under Not tested too; pick whichever fits.

AI use: Devin (Cognition, SWE-2).

An unedited pull_request_template.md passed the Tested and AI use checks because the hint lines counted as content (xcl-dev#965). Section checks now ignore HTML comments, blank lines, lone '-' bullets and the template's placeholder hints; test_pr_check.py covers the untouched and filled template. A lone '-' under Not tested is now refused too (the part of xcl-dev#527 this overlaps).
@DavidM1911
DavidM1911 force-pushed the prcheck-template-hints branch from a3a859e to df32229 Compare November 24, 2026 11:02
@ivall

ivall commented Nov 24, 2026

Copy link
Copy Markdown
Collaborator

Thanks. #965 is fixed by #1037 (merged in dc6a283), which was opened first. This branch is also based on an old main (97 commits behind) and adds scripts/test_pr_check.py as a new file, which would replace the tests there now. Closing as a duplicate.

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.

PR checks: an untouched PR template passes the Tested and AI use checks

2 participants