Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 16, 2026

Compiles .github/workflows/mcp-gateway-log-analyzer.md into a GitHub Action that analyzes MCP Gateway logs from gh-aw repository workflows and creates issues for detected errors with reproducible test cases.

Changes

  • Workflow Configuration: Fixed permissions for strict mode (removed issues: write, added issues: read and pull-requests: read)
  • Test Case Generation (Step 5): Added instructions for the AI agent to create:
    • Go test case templates with testify assertions
    • Bash reproduction scripts for command-line reproducible errors
    • Integration test scenarios for multi-component failures
    • Test case summary tables categorized by priority
  • Issue Template Enhancement: Extended issue body to include test cases section with code snippets, reproduction steps, and suggested test file locations
  • Compiled Artifact: Generated .github/workflows/mcp-gateway-log-analyzer.lock.yml (1522 lines) via gh aw compile

Workflow Behavior

The workflow runs daily (or on-demand) and:

  1. Fetches workflow runs from githubnext/gh-aw for the last 24 hours
  2. Downloads and analyzes MCP Gateway logs from artifacts
  3. Categorizes errors (Critical/High/Medium/Low priority)
  4. Creates test cases for Critical and High priority reproducible errors
  5. Opens a single GitHub issue with findings and test cases (max 1 per run)
  6. Silently succeeds if no errors found

Example Test Case Output

// TestCase: Gateway Startup Failure
// Category: Critical
// Related Error: "failed to start container: image not found"

func TestGatewayContainerImageNotFound(t *testing.T) {
    // Arrange
    config := &Config{
        Servers: map[string]ServerConfig{
            "test": {Container: "invalid/image:tag"},
        },
    }
    
    // Act
    _, err := StartGateway(config)
    
    // Assert
    require.Error(t, err)
    assert.Contains(t, err.Error(), "image not found")
}

✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

…rkflow

Co-authored-by: lpcox <15877973+lpcox@users.noreply.github.com>
Copilot AI changed the title [WIP] Add MCP Gateway Log Analyzer action to repository Add MCP Gateway Log Analyzer workflow with test case reproduction Jan 16, 2026
Copilot AI requested a review from lpcox January 16, 2026 22:21
@lpcox lpcox marked this pull request as ready for review January 16, 2026 22:22
@lpcox lpcox merged commit 014d837 into main Jan 16, 2026
@lpcox lpcox deleted the copilot/add-mcp-gateway-log-analyzer-action branch January 16, 2026 22:23
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.

2 participants