docs(#5402): add normalized-event guidance for BT feature authors#5404
docs(#5402): add normalized-event guidance for BT feature authors#5404fullsend-ai-coder[bot] wants to merge 1 commit into
Conversation
Add a new "Behaviour-test feature files and CEL triggers" section to AGENTS.md covering three areas that caused a silent bug in PR #5309: 1. Transition kind vocabulary table mapping normalized kinds to raw GitHub webhook action names, with the source of truth linked to docs/normative/normalized-event/v1/README.md. 2. Trigger pattern guidance recommending label_changed triggers for positive BT scenarios per ADR 0054 auth requirements. 3. Common pitfall callout for the synchronize vs synchronized mapping that caused the original bug. The section is placed after the forge abstraction guidance since CEL triggers operate on forge-neutral normalized events. Closes #5402
E2E tests did not runE2E tests run automatically for org/repo members and collaborators on pull requests. For other contributors, a maintainer must add the See E2E testing guide for details. |
|
🤖 Finished Review · ✅ Success · Started 9:25 AM UTC · Completed 9:38 AM UTC |
Site previewPreview: https://c26d839a-site.fullsend-ai.workers.dev Commit: |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
ReviewFindingsMedium
Low
Labels: PR adds documentation guidance for BT feature files and CEL triggers to AGENTS.md |
|
|
||
| ### Transition kind vocabulary | ||
|
|
||
| | Normalized kind | Raw GitHub action | Notes | |
There was a problem hiding this comment.
[medium] incomplete-vocabulary
The transition kind vocabulary table omits updated, a valid value in the transition.kind enum defined in the normative schema (normalized-event.schema.json) and documented in the normative README as "Legacy umbrella; prefer edited or synchronized for new adapters." While the section links to the normative README as source of truth, the table header "Transition kind vocabulary" implies completeness, and omitting a valid enum value could confuse authors who encounter updated in existing adapter output or fixtures.
Suggested fix: Add a row for updated with a note such as: updated | (various) | Legacy umbrella — prefer edited or synchronized for new triggers.
|
|
||
| ### When reviewing BT feature files | ||
|
|
||
| Flag CEL expressions that use raw GitHub webhook action names instead of |
There was a problem hiding this comment.
[medium] review-guidance-completeness
The "When reviewing BT feature files" subsection instructs reviewers to flag CEL expressions using raw webhook names but does not specify a severity level. Both comparable "When reviewing" guidance blocks in AGENTS.md include explicit severity levels (line 74: "medium-severity finding"; line 92: "medium-severity or higher finding"). Omitting the severity classification creates inconsistent review guidance.
Suggested fix: Add a severity level, e.g., "Flag ... as a medium-severity finding."
|
|
||
| **Composite action (`action.yml`):** The forge abstraction extends to `action.yml` bash scripts. New GitHub API operations in action steps should be implemented as `fullsend` CLI subcommands (under `internal/cli/`) that use `forge.Client`, not as inline `gh api` calls. Existing `gh api` calls in `action.yml` that predate this rule are grandfathered but should be migrated when touched. | ||
|
|
||
| ## Behaviour-test feature files and CEL triggers |
There was a problem hiding this comment.
[low] organizational-consistency
The new section uses ### subsections, which differs from its immediate neighbors ("Forge abstraction" and "Architecture Decision Records") that use bold-prefixed paragraphs. However, this pattern is used elsewhere in the document ("Go code," "Shell scripting"), so it is not unprecedented.
Summary
Add normalized-event schema reference to AGENTS.md so code and review agents use correct CEL transition kinds in BT feature files, preventing silent filter mismatches like the
synchronizevssynchronizedbug caught in PR #5309.Related Issue
Fixes #5402
Changes
synchronize→synchronizedpitfall explicitlylabel_changedtrigger pattern for ADR 0054 auth compliance in BT scenariosTesting
scan-secretspasses on changed filegitlintpasses on commit messagemake lint— pre-commit could not run in sandbox (network restriction); post-script runs authoritativelyChecklist
!for breaking changes)Closes #5402
Post-script verification
agent/5402-agents-cel-event-guidance)d9185cb4c47c583de659ff76e15a7ba167899d3a..HEAD)