disinto/gardener/recipes/chicken-egg-ci.toml
openhands d6e91b2466 fix: address review feedback — recipe engine robustness and correctness
- Bug: chicken-egg-ci create-per-file-issues was aliased to shellcheck-only
  function. Added generic playbook_lint_per_file() that handles any linter
  output format. Renamed action to lint-per-file.
- Bug: cascade-rebase fired retry-merge synchronously after async rebase.
  Removed retry-merge and re-approve from recipe — rebase settles, CI reruns,
  normal flow handles merge on subsequent cycle.
- Warning: jq calls on PR data lacked || true under set -euo pipefail. Fixed.
- Warning: playbook_rebase_pr and playbook_retrigger_ci incremented
  _PB_SUB_CREATED before confirming API success. Now check HTTP status code.
- Warning: Python import tomllib fails on < 3.11. Added try/except fallback
  to tomli package.
- Nit: failures_on_unchanged regex broadened to handle generic linter formats
  (file.sh:line:col patterns in addition to ShellCheck's "In file line N:").
- Info: match_recipe now logs Python stderr on error instead of silently
  falling back to generic recipe.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-18 03:05:09 +00:00

25 lines
953 B
TOML

# gardener/recipes/chicken-egg-ci.toml — PR introduces CI step that fails on pre-existing code
#
# Trigger: New .woodpecker/*.yml in PR + lint/check step + failures on unchanged files
# Playbook: make step non-blocking, create per-file issues, create follow-up to remove bypass
name = "chicken-egg-ci"
description = "PR introduces a CI pipeline/linting step that fails on pre-existing code"
priority = 10
[trigger]
pr_files = '\.woodpecker/.*\.yml$'
step_name = '(?i)(lint|shellcheck|check)'
failures_on_unchanged = true
[[playbook]]
action = "make-step-non-blocking"
description = "Make failing step non-blocking (|| true) in the PR"
[[playbook]]
action = "lint-per-file"
description = "Create per-file fix issues for pre-existing violations (generic linter support)"
[[playbook]]
action = "create-followup-remove-bypass"
description = "Create follow-up issue to remove || true once fixes land"