You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: AGENTS.md
+16-21Lines changed: 16 additions & 21 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -772,40 +772,35 @@ go test -race ./...
772
772
773
773
### Expression Transformations in Workflows
774
774
775
-
**Automatic Activation Output Transformations:**
775
+
**Deprecated: `needs.activation.outputs.*` in Workflow Markdown**
776
776
777
-
The compiler automatically transforms certain `needs.activation.outputs.*` expressions to `steps.sanitized.outputs.*` for compatibility with the activation job context.
777
+
Use `steps.sanitized.outputs.text/title/body` directly in workflow markdown prompts:
778
778
779
-
**Why this transformation occurs:**
779
+
-`${{ steps.sanitized.outputs.text }}` — sanitized full context
780
+
-`${{ steps.sanitized.outputs.title }}` — sanitized issue/PR title
781
+
-`${{ steps.sanitized.outputs.body }}` — sanitized issue/PR body
780
782
781
-
The prompt is generated **within the activation job**, which means it cannot reference its own `needs.activation.*`outputs (a job cannot reference its own needs outputs in GitHub Actions). The compiler automatically rewrites these expressions to reference the `sanitized` step, which computes sanitized versions of the triggering content.
783
+
**Why the `steps.sanitized.*`form is required:**
782
784
783
-
**Transformations:**
785
+
The prompt is generated **within the activation job**, which means it cannot reference its own `needs.activation.*` outputs (a job cannot reference its own needs outputs in GitHub Actions). The `sanitized` step within the activation job computes sanitized versions of the triggering content.
786
+
787
+
**Backward compatibility:**
788
+
789
+
The compiler still accepts the old form (`needs.activation.outputs.text/title/body`) and automatically rewrites it to `steps.sanitized.outputs.*`, but emits a deprecation warning. Use `steps.sanitized.outputs.*` directly in all new and updated workflows.
- Only `text`, `title`, and `body` outputs are transformed
790
-
- Other activation outputs (`comment_id`, `comment_repo`, `slash_command`) are NOT transformed
791
-
- Transformation uses word boundary checking to prevent incorrect partial matches (e.g., `text_custom` is not transformed)
792
-
- This is particularly important for runtime-import, where markdown can change without recompilation
793
-
794
-
**Example:**
795
-
796
-
```markdown
797
-
Analyze this content: "${{ needs.activation.outputs.text }}"
798
-
```
799
-
800
-
Is automatically transformed to:
801
-
802
-
```markdown
803
-
Analyze this content: "${{ steps.sanitized.outputs.text }}"
804
-
```
797
+
- Only `text`, `title`, and `body` outputs are affected; use `needs.activation.outputs.*` for `comment_id`, `comment_repo`, `slash_command` etc. in _downstream_ jobs
798
+
- Backward-compat transformation uses word boundary checking (e.g., `text_custom` is not transformed)
805
799
806
800
**Implementation:**
807
801
- Transformation happens in `pkg/workflow/expression_extraction.go::transformActivationOutputs()`
808
802
- Applied during expression extraction from markdown
803
+
- Deprecation warnings emitted to stderr during compilation
809
804
- Transformations are logged for debugging when `DEBUG=workflow:expression_extraction`
Create tracking issue with link to original, component identifier, summary, suggested priority, and labels `from-component-alpha` and `tracking-issue`.
51
51
```
@@ -179,7 +179,7 @@ safe-outputs:
179
179
Analyze new issues and create tracking issues in appropriate repositories.
Analyze issue severity and route to appropriate tracker: security issues to `myorg/security-tracker`, features to `myorg/feature-tracker`, bugs to `myorg/bug-tracker`, or infrastructure to `myorg/ops-tracker`. Include original link, triage reasoning, priority, affected components, and SLA targets.
Copy file name to clipboardExpand all lines: docs/src/content/docs/patterns/issue-ops.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -42,10 +42,10 @@ safe-outputs:
42
42
43
43
## Accessing Issue Context
44
44
45
-
Access sanitized issue content through `needs.activation.outputs.text`, which combines title and description while removing security risks (@mentions, URIs, injections):
45
+
Access sanitized issue content through `steps.sanitized.outputs.text`, which combines title and description while removing security risks (@mentions, URIs, injections):
46
46
47
47
```yaml wrap
48
-
Analyze this issue: "${{ needs.activation.outputs.text }}"
48
+
Analyze this issue: "${{ steps.sanitized.outputs.text }}"
0 commit comments