Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 23, 2026

The Daily CLI Performance workflow failed to run benchmarks due to missing Go toolchain. Rather than adding explicit setup steps, this uses the existing shared/go-make.md import to expose Go and Make commands through safe-inputs.

Changes

  • Added shared/go-make.md import to workflow frontmatter

    • Provides safeinputs-go and safeinputs-make tools to the Copilot agent
    • Tools wrap Go and Make commands with proper MCP integration
  • Updated benchmark execution instructions to use safe-input tools

    • Changed from direct bash (make bench 2>&1 | tee) to tool invocation pattern
    • Agent now uses: safeinputs-make with args: "bench"

Example

The agent instructions now specify:

**Step 2**: Run benchmarks using safeinputs-make

Use the **safeinputs-make** tool with args: "bench" to run the benchmark suite.

This will execute `make bench` which runs Go benchmarks and saves results to `bench_results.txt`.

The compiled workflow includes safe-input tool definitions for both go and make with shell script handlers that execute in the workflow environment.

Original prompt

This section details on the original issue you should resolve

<issue_title>[performance] Daily CLI Performance workflow missing Go toolchain setup</issue_title>
<issue_description>### Summary

The Daily CLI Performance workflow (.github/workflows/daily-cli-performance.md) cannot run benchmarks because it lacks the necessary Go toolchain setup. The workflow attempts to execute make bench but Go is not available in the execution environment.

Root Cause

The workflow configuration is missing a setup-go action before attempting to run benchmarks. The agent job runs on ubuntu-latest but doesn't include steps to:

  1. Install Go compiler
  2. Build the gh-aw binary
  3. Install development dependencies

Current Behavior

$ which go
bash: type: go: not found

$ make bench
Permission denied and could not request permission from user

Expected Behavior

The workflow should:

  1. Set up Go 1.21+ using actions/setup-go@v5
  2. Install dependencies with make deps
  3. Build the binary with make build
  4. Run benchmarks with make bench
  5. Store results in repo-memory

Proposed Solution

Add the following steps before the Copilot agent execution in .github/workflows/daily-cli-performance.md:

---
description: Daily CLI Performance - Runs benchmarks, tracks performance trends, and reports regressions
on:
  schedule: daily
  workflow_dispatch:
permissions:
  contents: read
  issues: read
  pull-requests: read
tracker-id: daily-cli-performance
engine: copilot
jobs:
  setup:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v5
      - uses: actions/setup-go@v5
        with:
          go-version: '1.21'
      - name: Install dependencies
        run: make deps
      - name: Build binary
        run: make build
      - name: Upload binary
        uses: actions/upload-artifact@v4
        with:
          name: gh-aw-binary
          path: gh-aw
tools:
  repo-memory:
    branch-name: memory/cli-performance
    description: "Historical CLI compilation performance benchmark results"
    file-glob: ["memory/cli-performance/*.json", "memory/cli-performance/*.jsonl", "memory/cli-performance/*.txt"]
    max-file-size: 512000
  bash:
  edit:
  github:
    toolsets: [default, issues]
safe-outputs:
  create-issue:
    title-prefix: "[performance] "
    labels: [performance, automation, cookie]
    max: 3
    group: true
  add-comment:
    max: 5
timeout-minutes: 20
strict: true
imports:
  - shared/reporting.md
---

Alternative approach: Modify the agent instructions to download and use pre-built binaries from the latest release, or use a self-hosted runner with Go pre-installed.

Impact

  • Current: Daily performance benchmarks cannot run, no trend analysis, no regression detection
  • After fix: Automated daily benchmarks will track performance over time and alert on regressions

Additional Context

  • Run ID: §21266633406
  • Workflow: .github/workflows/daily-cli-performance.md
  • Error: Go compiler not found in PATH, make commands fail with permission denied

Recommendation

This is a workflow configuration issue, not a code bug. The fix requires updating the workflow frontmatter to include proper build tooling setup before attempting to run benchmarks.

AI generated by Daily CLI Performance Agent

Comments on the Issue (you are @copilot in this section)

@pelikhan @copilot use the gh-make import and prompt the agent to use it

💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
@@ -47,20 +48,39 @@ Run daily performance benchmarks for workflow compilation, store results in cach
**Run ID**: ${{ github.run_id }}
**Memory Location**: `/tmp/gh-aw/repo-memory/default/`
Copy link
Contributor

Choose a reason for hiding this comment

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

@copilot remove line

Copilot AI changed the title [WIP] Add Go toolchain setup to Daily CLI Performance workflow Fix daily-cli-performance workflow by adding go-make import Jan 23, 2026
Copilot AI requested a review from pelikhan January 23, 2026 12:18
@pelikhan pelikhan marked this pull request as ready for review January 23, 2026 12:18
@pelikhan pelikhan merged commit 8550bf0 into main Jan 23, 2026
42 of 43 checks passed
@pelikhan pelikhan deleted the copilot/setup-go-toolchain branch January 23, 2026 12:18
Copilot stopped work on behalf of pelikhan due to an error January 23, 2026 12:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[performance] Daily CLI Performance workflow missing Go toolchain setup

2 participants