WP001 rule text doesn't match the syntax of its founding case #15
Notifications
Total Time Spent: 3 minutes
oleks
3 minutes
No due date set.
Dependencies
No dependencies set.
Reference: oleks/pipetree#15
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Why: WP001 is specified in
specs/001-woodpecker-ci-linter/research.md§R6 as: "Bareevent: push+ bareevent: pull_requestin one pipeline-levelwhen:list".The founding case (
oleks/oracle-adb-backend, pre-fix, blob at commitca797106a1852e0415e1241ce6f7b42a41334648,.woodpecker/test.yaml) did not use that shape. It used a single entry with a list value:Verified by direct blob read via
tea api, not inferred.Consequence: a detector implemented literally against WP001's current wording — matching two separate
- event:entries — would not fire on the very config that motivated the rule. Both syntactic shapes admit push+pull_request unscoped and both double-run.Note the source factbook (
oleks/claude-plugin-cicd-insights,FACTBOOK-woodpecker-hygiene.md§3.1) had this tagged[INFERRED]and stated it wrongly; that factbook has now been corrected in commit2272890.Acceptance:
specs/001-woodpecker-ci-linter/research.md§R6 updated to cover both the two-bare-entries shape AND the single-entry-with-list-value shapeBoth acceptance boxes done, pushed to
main(4f68045,32ee583).internal/analyze/lint.go,4f68045): WP001 now takes theunion of events across unscoped entries (an entry whose only key is
event) and fires when that union contains bothpushandpull_request. One test, both shapes — two bare entries, and thesingle-entry
event: [push, pull_request, manual]form. Fixtures forboth firing shapes plus three non-firing cases
(
wp001_eventlist_fires.yaml,wp001_eventlist_clean.yaml, …).research.md§R6 + new §R6.1,32ee583): the row nolonger says "bare … + bare …", and §R6.1 states the union rule with the
evidence trail and why the widening is a superset rather than a
behaviour change.
Measured against the retired xonsh script across 165 fleet configs: 9
exact agreements, 4 configs it missed — all the list-valued shape,
including
oleks/pipetree's own.woodpecker.yaml— and 1 itfalse-positived on (
gitea-mcp, where a block-styleis invisible to its key regex, which needs a value on the same line, so a
properly scoped entry reads as bare). Reproduced in isolation: block
style fires, the equivalent
branch: [main]flow style does not. Thatfalse positive is filed separately.
So detection is a strict superset of the script minus one false positive
— retiring it loses nothing.
Thanks for reading the pre-fix blob; the
[INFERRED]factbook claimwould otherwise have shipped straight into the detector.
⏱ worked | 13-08-26 | session oleks/3b3844a4 | +3min | session-total 3min | elapsed from local-record