Skip to content

Use workflow frontmatter emoji for activation status comments - #53494

Merged
pelikhan merged 6 commits into
mainfrom
copilot/fix-status-comment-emoji
Aug 18, 2026
Merged

Use workflow frontmatter emoji for activation status comments#53494
pelikhan merged 6 commits into
mainfrom
copilot/fix-status-comment-emoji

Conversation

Copilot AI commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

Status comments for agentic workflows were always emitted with a rocket in the “run started” message, even when the workflow markdown defined a different emoji (e.g., 🤖). This change makes status comments honor the workflow’s configured emoji.

  • What changed

    • Wired frontmatter emoji into activation comment generation by exporting GH_AW_WORKFLOW_EMOJI in activation step env.
    • Updated run-started message rendering to use {emoji} with a default fallback to 🚀 when no workflow emoji is configured.
    • Passed workflow emoji through add_workflow_run_comment so created/reused status comments render the correct icon.
  • Behavioral impact

    • Workflows with emoji: 🤖 now post started-status comments prefixed with 🤖 instead of 🚀.
    • Existing workflows without a configured emoji keep current behavior via fallback.
  • Representative snippet

function getRunStartedMessage(ctx) {
  const normalizedEmoji = typeof ctx?.emoji === "string" && ctx.emoji.trim()
    ? ctx.emoji.trim()
    : "🚀";
  return renderConfiguredMessage(
    "runStarted",
    "{emoji} [{workflow_name}]({run_url}) has started processing this {event_type}",
    { ...ctx, emoji: normalizedEmoji }
  );
}

run: https://github.com/github/gh-aw/actions/runs/32080816855> Generated by 👨‍🍳 PR Sous Chef · gpt54 · 10.1 AIC · ⌖ 7.87 AIC · ⊞ 8.8K ·

Comment /souschef to run again

Copilot AI and others added 2 commits August 17, 2026 21:12
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title Use workflow markdown emoji in status comments Use workflow frontmatter emoji for activation status comments Aug 17, 2026
Copilot AI requested a review from pelikhan August 17, 2026 21:21
@pelikhan
pelikhan marked this pull request as ready for review August 17, 2026 21:35
Copilot AI balanced review requested due to automatic review settings August 17, 2026 21:35
@github-actions

github-actions Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

Design Decision Gate 🏗️ completed the design decision gate check.

No ADR enforcement needed: PR #53494 does not have the implementation label and has only 3 new lines of code in business logic directories (threshold: 100).

🏗️ ADR gate enforced by Design Decision Gate 🏗️

@github-actions

github-actions Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer

@github-actions

github-actions Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

Ponytail Reviewer completed successfully!

Lean already. Ship.

Generated by Ponytail Reviewer for #53494

@github-actions

github-actions Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

Test Quality Sentinel was cancelled during test quality analysis.

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs for details.

🧪 Test quality analysis by Test Quality Sentinel

@github-actions

github-actions Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

PR Code Quality Reviewer completed the code quality review.

🔎 Code quality review by PR Code Quality Reviewer

@github-actions

Copy link
Copy Markdown
Contributor

Comment Memory

reviewed_at: 2026-08-17T21:27:00Z
review_event: COMMENT
top_themes:
  - emoji plumbing is consistent end-to-end
  - fallback behavior preserved for workflows without emoji
  - no blocking issues found in changed lines
files_reviewed:
  - .github/workflows/agentic_commands.yml
  - actions/setup/js/add_workflow_run_comment.cjs
  - actions/setup/js/add_workflow_run_comment.test.cjs
  - actions/setup/js/messages_run_status.cjs
  - actions/setup/js/messages_run_status.test.cjs
  - pkg/workflow/compiler_activation_steps.go
comment_count: 0

Note

This comment is managed by comment memory.

It stores persistent context for this thread in the code block at the top of this comment.
Edit only the text inside the backtick fences; workflow metadata and the footer are regenerated automatically.

Learn more about comment memory

🔎 Code quality review by PR Code Quality Reviewer · gpt54 · 11.6 AIC · ⌖ 6.82 AIC · ⊞ 4.5K ·
Comment /review to run again

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verdict

I don't see a blocking correctness or maintainability problem in this diff.

Review notes
  • The emoji plumb-through is consistent from workflow frontmatter to activation comment rendering.
  • Existing behavior still falls back to 🚀 when no workflow emoji is configured.
  • Tests cover the new happy path in both the message formatter and the status-comment builder.
  • I did notice the test gap for whitespace-only emoji values, but the implementation already trims and falls back safely, so that's not enough to block this PR.

🔎 Code quality review by PR Code Quality Reviewer · gpt54 · 11.6 AIC · ⌖ 6.82 AIC · ⊞ 4.5K
Comment /review to run again

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Skills-Based Review 🧠

Applied /tdd and /codebase-design — approving with two minor observations.

📋 Key Themes & Highlights

Key Themes

  • Correct layering: the emoji flows naturally from Go compiler → env var → JS runtime → message template, consistent with how GH_AW_WORKFLOW_NAME and GH_AW_TRACKER_ID are threaded
  • Good defensive normalization: whitespace-only emoji strings fall back to 🚀 at the JS layer; non-empty guard at the Go layer avoids emitting an unnecessary env var
  • Test coverage: both new happy-path tests and the custom-template-with-{emoji} test are solid

Positive Highlights

  • ✅ Conditional env emission in Go (if ctx.data.FrontmatterEmoji != "") mirrors the existing TrackerID pattern exactly — easy to follow
  • ✅ Spread { ...ctx, emoji: normalizedEmoji } avoids mutating the caller's object
  • teardown correctly deletes GH_AW_WORKFLOW_EMOJI to prevent test bleed

Minor Observations (non-blocking)

  1. Whitespace-only emoji not tested at the env boundarymessages_run_status.test.cjs validates the trim-and-fallback logic inside getRunStartedMessage, but add_workflow_run_comment.test.cjs has no test for GH_AW_WORKFLOW_EMOJI = " " (should fall back to 🚀). Low risk since the normalization lives entirely in getRunStartedMessage, but an explicit integration test would close the gap.

  2. Custom template without {emoji} placeholder — there is no test asserting that a custom runStarted template that omits {emoji} still renders correctly when an emoji is present in context. The substitution mechanism silently drops unknown placeholders, so this is safe today, but a test would document the intentional behaviour.

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · sonnet46 · 28.7 AIC · ⌖ 12.8 AIC · ⊞ 7.8K
Comment /matt to run again

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The implementation is clean and well-structured. The three-layer change (Go compiler → env var → JS message builder) is correct. Backward compatibility is preserved via the 🚀 default fallback. The %q formatting in Go safely quotes the emoji value in generated YAML. Tests cover the new env var path and custom template support. No blocking issues found.

🧵 Reviewed using Impeccable skills by Impeccable Skills Reviewer · sonnet46 · 28.5 AIC · ⌖ 8.75 AIC · ⊞ 5.7K

@github-actions github-actions Bot mentioned this pull request Aug 17, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates activation status comments to use each workflow’s configured frontmatter emoji, retaining 🚀 as the fallback.

Changes:

  • Exports workflow emoji during activation.
  • Renders default and custom started messages with the emoji.
  • Adds JavaScript coverage and regenerates command metadata.
Show a summary per file
File Description
pkg/workflow/compiler_activation_steps.go Exports the frontmatter emoji.
actions/setup/js/messages_run_status.cjs Adds emoji-aware started-message rendering.
actions/setup/js/messages_run_status.test.cjs Tests rendering and custom templates.
actions/setup/js/add_workflow_run_comment.cjs Passes the environment emoji into rendering.
actions/setup/js/add_workflow_run_comment.test.cjs Tests emoji use in comment bodies.
.github/workflows/agentic_commands.yml Regenerates command help metadata.

Review details

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

  • Files reviewed: 6/6 changed files
  • Comments generated: 2
  • Review effort level: Balanced

Comment on lines +40 to +41
const normalizedEmoji = typeof ctx?.emoji === "string" && ctx.emoji.trim() ? ctx.emoji.trim() : "🚀";
return renderConfiguredMessage("runStarted", "{emoji} [{workflow_name}]({run_url}) has started processing this {event_type}", { ...ctx, emoji: normalizedEmoji });
Comment on lines +333 to +334
if ctx.data.FrontmatterEmoji != "" {
ctx.steps = append(ctx.steps, fmt.Sprintf(" GH_AW_WORKFLOW_EMOJI: %q\n", ctx.data.FrontmatterEmoji))
@pelikhan

Copy link
Copy Markdown
Collaborator

@copilot run pr-finisher skill

Copilot AI and others added 2 commits August 17, 2026 23:11
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>

Copilot AI commented Aug 17, 2026

Copy link
Copy Markdown
Contributor Author

@copilot run pr-finisher skill

Completed the PR-finisher pass in 5ea8a8f: addressed both actionable review gaps, ran the final local validation gate, and pushed the fix. CodeQL was invoked but timed out without findings.

@pelikhan

Copy link
Copy Markdown
Collaborator

/smoke-copilot

@github-actions

github-actions Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

📰 BREAKING: Smoke Copilot is now investigating this issue comment. Sources say the story is developing...

@pelikhan

Copy link
Copy Markdown
Collaborator

@copilot make it work for centralized slash commands and label commands as well

@gh-aw-bot

Copy link
Copy Markdown
Collaborator

@copilot Please review the latest feedback and finish this PR. Remaining maintainer-facing work:

  • branch refresh was requested for this PR; rebase or update the branch with the current base branch state if needed
  • reviewer follow-up is pending from the recent comment asking to "make it work for centralized slash commands and label commands as well"
  • then run the pr-finisher skill and report back with the changes made and validation run

Generated by 👨‍🍳 PR Sous Chef · gpt54 · 10.1 AIC · ⌖ 7.87 AIC · ⊞ 8.8K ·
Comment /souschef to run again

@github-actions

Copy link
Copy Markdown
Contributor

Smoke Test Summary (author: app/copilot-swe-agent, assignees: pelikhan, Copilot)

  • ✅ github tool (gh-proxy)
  • ✅ mcpscripts-gh
  • ❌ Serena find_symbol (Go missing in sandbox)
  • ✅ Playwright CLI
  • ✅ web-fetch
  • ✅ File+bash smoke file
  • ✅ Discussion interaction
  • ✅ Build (make build)
  • ✅ Artifact upload
  • ✅ Discussion create
  • ✅ Workflow dispatch
  • ✅ PR review tools
  • ✅ Comment memory
  • ✅ Sub-agent summarizer
  • ✅ Check run
  • ✅ LSP TypeScript (12 functions)

PR reviewed: "Use workflow frontmatter emoji for activation status comments"

Overall status: FAIL (1 test failed: Serena)

Warning

Firewall blocked 6 domains

The following domains were blocked by the firewall during workflow execution:

  • accounts.google.com
  • android.clients.google.com
  • clients2.google.com
  • contentautofill.googleapis.com
  • www.google.com
  • www.gstatic.com

To allow these domains, add them to the network.allowed list in your workflow frontmatter:

network:
  allowed:
    - defaults
    - "accounts.google.com"
    - "android.clients.google.com"
    - "clients2.google.com"
    - "contentautofill.googleapis.com"
    - "www.google.com"
    - "www.gstatic.com"

See Network Configuration for more information.

📰 BREAKING: Report filed by Smoke Copilot · auto · 36.5 AIC · ⌖ 2.3 AIC · ⊞ 9.1K ·
Comment /smoke-copilot to run again
Add label smoke to run again

@github-actions

Copy link
Copy Markdown
Contributor

Comment Memory

Copilot run fast
Testing gh-aw workflows
Green checks light the way

Note

This comment is managed by comment memory.

It stores persistent context for this thread in the code block at the top of this comment.
Edit only the text inside the backtick fences; workflow metadata and the footer are regenerated automatically.

Learn more about comment memory

Warning

Firewall blocked 6 domains

The following domains were blocked by the firewall during workflow execution:

  • accounts.google.com
  • android.clients.google.com
  • clients2.google.com
  • contentautofill.googleapis.com
  • www.google.com
  • www.gstatic.com

To allow these domains, add them to the network.allowed list in your workflow frontmatter:

network:
  allowed:
    - defaults
    - "accounts.google.com"
    - "android.clients.google.com"
    - "clients2.google.com"
    - "contentautofill.googleapis.com"
    - "www.google.com"
    - "www.gstatic.com"

See Network Configuration for more information.

📰 BREAKING: Report filed by Smoke Copilot · auto · 36.5 AIC · ⌖ 2.3 AIC · ⊞ 9.1K ·
Comment /smoke-copilot to run again
Add label smoke to run again

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Smoke test review: all good, ugh.

Warning

Firewall blocked 6 domains

The following domains were blocked by the firewall during workflow execution:

  • accounts.google.com
  • android.clients.google.com
  • clients2.google.com
  • contentautofill.googleapis.com
  • www.google.com
  • www.gstatic.com

To allow these domains, add them to the network.allowed list in your workflow frontmatter:

network:
  allowed:
    - defaults
    - "accounts.google.com"
    - "android.clients.google.com"
    - "clients2.google.com"
    - "contentautofill.googleapis.com"
    - "www.google.com"
    - "www.gstatic.com"

See Network Configuration for more information.

📰 BREAKING: Report filed by Smoke Copilot · auto · 36.5 AIC · ⌖ 2.3 AIC · ⊞ 9.1K
Comment /smoke-copilot to run again
Add label smoke to run again

Comments that could not be inline-anchored

.github/workflows/ace-editor.lock.yml:1

Smoke test: inline review comment (caveman test say hi).

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>

Copilot AI commented Aug 17, 2026

Copy link
Copy Markdown
Contributor Author

@copilot make it work for centralized slash commands and label commands as well

Implemented in 9a68fd4: centralized slash and label command routes now carry workflow emojis, create/update emoji-aware shared status comments, and have regenerated workflow metadata plus regression coverage.

Co-authored-by: gh-aw-bot <259018956+gh-aw-bot@users.noreply.github.com>

Copilot AI commented Aug 18, 2026

Copy link
Copy Markdown
Contributor Author

@copilot Please review the latest feedback and finish this PR. Remaining maintainer-facing work:

  • branch refresh was requested for this PR; rebase or update the branch with the current base branch st...

Updated the branch with current main in 497757b. The centralized slash and label command routes propagate each workflow emoji into their shared status comment. Validation passed with make fmt, make lint, targeted Go/JS tests, make recompile, and the final make agent-report-progress gate; the full make test exposed an unrelated base-branch integration assertion expecting a removed ripgrep install step. CodeQL timed out without findings.

@github-actions

Copy link
Copy Markdown
Contributor

PR Triage

Category: feature · Risk: medium · Score: 53/100

Breakdown: impact 30/50 · urgency 15/30 · quality 8/20

Recommended action: defer

Uses workflow frontmatter emoji for activation status comments; touches compiler code (central_slash_command_workflow.go, compiler_activation_steps.go) and regenerates 70+ .lock.yml files. mergeable_state: dirty — this PR has a merge conflict and needs a rebase before it can be usefully reviewed or merged. Deferring until conflicts are resolved.

Generated by 🔧 PR Triage Agent · auto · 46.6 AIC · ⌖ 1.9 AIC · ⊞ 8.3K ·

@pelikhan
pelikhan merged commit 3a88aab into main Aug 18, 2026
@pelikhan
pelikhan deleted the copilot/fix-status-comment-emoji branch August 18, 2026 00:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants