Fix Serena MCP test tool discovery in smoke test workflow#1195
Conversation
|
@claude[agent] update the mcp test to use the right tool names. try to find the best matches for activate_project, find_symbol |
…oject and serena-find_symbol Co-authored-by: lpcox <15877973+lpcox@users.noreply.github.com>
Updated the smoke test to use The tools are referenced with the server name prefix using hyphens, which should resolve the discoverability issue where the Copilot agent couldn't find the Serena tools. Commit: fd32b0a Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
There was a problem hiding this comment.
Pull request overview
This pull request fixes a tool discovery issue in the smoke-copilot workflow where Serena MCP server tools were not being discovered due to incorrect naming conventions. The fix updates tool references to use the server-toolname pattern required by the MCP Gateway routed mode when multiple MCP servers are configured.
Changes:
- Updated Serena tool names from unprefixed (
activate_project,find_symbol) to server-prefixed format (serena-activate_project,serena-find_symbol) - Upgraded gh-aw version from v0.47.1 to v0.47.4 with associated lock file recompilation
- Updated GitHub MCP Server from v0.30.3 to v0.31.0
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| .github/workflows/smoke-copilot.md | Fixed Serena MCP tool names to use server-prefixed format (serena-activate_project, serena-find_symbol) for proper tool discovery in routed mode |
| .github/workflows/smoke-copilot.lock.yml | Recompiled workflow with gh-aw v0.47.4, updated dependency versions (GitHub Copilot CLI 0.0.412, GitHub MCP Server v0.31.0), and added environment variables for GitHub token propagation |
Comments suppressed due to low confidence (1)
.github/workflows/smoke-copilot.lock.yml:1349
- The MCP_GATEWAY_DOCKER_COMMAND should reference
ghcr.io/github/gh-aw-mcpg:latestinstead of:v0.1.4. The workflow builds a local container tagged as:latest(line 340), and this command needs to use that locally built container. Using:v0.1.4here will cause the workflow to use an older pinned version instead of the freshly built local version, defeating the purpose of the local build step.
export MCP_GATEWAY_DOCKER_COMMAND='docker run -i --rm --network host -v /var/run/docker.sock:/var/run/docker.sock -e MCP_GATEWAY_PORT -e MCP_GATEWAY_DOMAIN -e MCP_GATEWAY_API_KEY -e MCP_GATEWAY_PAYLOAD_DIR -e DEBUG -e MCP_GATEWAY_LOG_DIR -e GH_AW_MCP_LOG_DIR -e GH_AW_SAFE_OUTPUTS -e GH_AW_SAFE_OUTPUTS_CONFIG_PATH -e GH_AW_SAFE_OUTPUTS_TOOLS_PATH -e GH_AW_ASSETS_BRANCH -e GH_AW_ASSETS_MAX_SIZE_KB -e GH_AW_ASSETS_ALLOWED_EXTS -e DEFAULT_BRANCH -e GITHUB_MCP_SERVER_TOKEN -e GITHUB_MCP_LOCKDOWN -e GITHUB_REPOSITORY -e GITHUB_SERVER_URL -e GITHUB_SHA -e GITHUB_WORKSPACE -e GITHUB_TOKEN -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RUN_ATTEMPT -e GITHUB_JOB -e GITHUB_ACTION -e GITHUB_EVENT_NAME -e GITHUB_EVENT_PATH -e GITHUB_ACTOR -e GITHUB_ACTOR_ID -e GITHUB_TRIGGERING_ACTOR -e GITHUB_WORKFLOW -e GITHUB_WORKFLOW_REF -e GITHUB_WORKFLOW_SHA -e GITHUB_REF -e GITHUB_REF_NAME -e GITHUB_REF_TYPE -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GH_AW_SAFE_INPUTS_PORT -e GH_AW_SAFE_INPUTS_API_KEY -e GH_AW_SAFE_OUTPUTS_PORT -e GH_AW_SAFE_OUTPUTS_API_KEY -e GH_AW_GH_TOKEN -e GH_DEBUG -e GH_TOKEN -v /tmp/gh-aw/mcp-payloads:/tmp/gh-aw/mcp-payloads:rw -v /opt:/opt:ro -v /tmp:/tmp:rw -v '"${GITHUB_WORKSPACE}"':'"${GITHUB_WORKSPACE}"':rw ghcr.io/github/gh-aw-mcpg:v0.1.4'
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| await determineAutomaticLockdown(github, context, core); | ||
| - name: Download container images | ||
| run: bash /opt/gh-aw/actions/download_docker_images.sh alpine:latest ghcr.io/github/gh-aw-firewall/agent:0.20.2 ghcr.io/github/gh-aw-firewall/api-proxy:0.20.2 ghcr.io/github/gh-aw-firewall/squid:0.20.2 ghcr.io/github/gh-aw-mcpg:latest ghcr.io/github/github-mcp-server:v0.30.3 ghcr.io/github/serena-mcp-server:latest mcr.microsoft.com/playwright/mcp node:lts-alpine | ||
| run: bash /opt/gh-aw/actions/download_docker_images.sh alpine:latest ghcr.io/github/gh-aw-firewall/agent:0.20.2 ghcr.io/github/gh-aw-firewall/api-proxy:0.20.2 ghcr.io/github/gh-aw-firewall/squid:0.20.2 ghcr.io/github/gh-aw-mcpg:v0.1.4 ghcr.io/github/github-mcp-server:v0.31.0 ghcr.io/github/serena-mcp-server:latest mcr.microsoft.com/playwright/mcp node:lts-alpine |
There was a problem hiding this comment.
The MCP Gateway container version should be :latest instead of :v0.1.4. The workflow builds a local container tagged as ghcr.io/github/gh-aw-mcpg:latest (line 340), but this download step references :v0.1.4, which means the locally built container won't be used. This is inconsistent with other workflows like language-support-tester.lock.yml which correctly use :latest throughout. The lock file needs to be recompiled with the correct version, or the source .md file may need adjustment.
This issue also appears on line 1349 of the same file.
| run: bash /opt/gh-aw/actions/download_docker_images.sh alpine:latest ghcr.io/github/gh-aw-firewall/agent:0.20.2 ghcr.io/github/gh-aw-firewall/api-proxy:0.20.2 ghcr.io/github/gh-aw-firewall/squid:0.20.2 ghcr.io/github/gh-aw-mcpg:v0.1.4 ghcr.io/github/github-mcp-server:v0.31.0 ghcr.io/github/serena-mcp-server:latest mcr.microsoft.com/playwright/mcp node:lts-alpine | |
| run: bash /opt/gh-aw/actions/download_docker_images.sh alpine:latest ghcr.io/github/gh-aw-firewall/agent:0.20.2 ghcr.io/github/gh-aw-firewall/api-proxy:0.20.2 ghcr.io/github/gh-aw-firewall/squid:0.20.2 ghcr.io/github/gh-aw-mcpg:latest ghcr.io/github/github-mcp-server:v0.31.0 ghcr.io/github/serena-mcp-server:latest mcr.microsoft.com/playwright/mcp node:lts-alpine |
- [x] Fix Serena tools configuration in smoke-copilot.md (change nested languages structure to array format) - [x] Recompile smoke-copilot workflow to regenerate lock file - [x] Verify the fix matches working configurations in other workflows - [x] Store memory about correct Serena tool configuration format <!-- START COPILOT ORIGINAL PROMPT --> <details> <summary>Original prompt</summary> > > ---- > > *This section details on the original issue you should resolve* > > <issue_title>Smoke Test: Copilot - 22243401416</issue_title> > <issue_description>## Smoke Test Results > > | Test | Status | > |------|--------| > | GitHub MCP - Last 2 merged PRs | ✅ PR #1195 "Fix Serena MCP test tool discovery in smoke test workflow", PR #1186 "Eliminate duplicate code in server HTTP endpoint registration" | > | Safe Inputs GH CLI - 2 PRs | ✅ PR #1196 "[WIP] Refactor semantic function clustering for code organization" | > | Serena MCP - activate_project + find_symbol | ❌ Tools not available in this agent context | > | Make Build | ✅ `make build` succeeded, `awmg` binary produced | > | Playwright - github.com title | ✅ Title contains "GitHub" | > | File Writing | ✅ `/tmp/gh-aw/agent/smoke-test-copilot-22243401416.txt` created | > | Bash Tool | ✅ File read back successfully | > | Discussion Interaction | ✅ Comment added to discussion #45 | > | Agentic Workflows MCP Status | ✅ smoke-copilot: compiled=Yes, triggers=PR/reaction/schedule | > > ## Overall Status:⚠️ PARTIAL PASS (8/9 tests passed, Serena tools unavailable) > > **Run URL**: https://github.com/github/gh-aw-mcpg/actions/runs/22243401416 > **Timestamp**: 2026-02-20T22:21 UTC > > > > > > 📰 *BREAKING: Report filed by [Smoke Copilot](https://github.com/github/gh-aw-mcpg/actions/runs/22243401416)* > > - [x] expires <!-- gh-aw-expires: 2026-02-21T00:23:33.836Z --> on Feb 21, 2026, 12:23 AM UTC > > <!-- gh-aw-agentic-workflow: Smoke Copilot, engine: copilot, run: https://github.com/github/gh-aw-mcpg/actions/runs/22243401416 --> > > <!-- gh-aw-workflow-id: smoke-copilot --></issue_description> > > <agent_instructions>Figure out why serena is not passing</agent_instructions> > > ## Comments on the Issue (you are @claude[agent] in this section) > > <comments> > </comments> > </details> <!-- START COPILOT CODING AGENT SUFFIX --> - Fixes #1198
Investigation of smoke test run #22238913503 reveals the Serena MCP test failure is a false negative - the server operates correctly but the Copilot agent cannot discover its tools due to incorrect tool naming.
Root Cause
Serena MCP server initializes successfully:
create_text_file,read_file,execute_shell_command,prepare_for_new_conversation,replace_content)activate_projectandfind_symbolare available in the exposed toolsetAgent reports tools unavailable without attempting invocation:
Issue: The smoke test referenced tools without the server name prefix (
activate_project,find_symbol), but the Copilot agent framework expects theserver-toolnamepattern for proper tool discovery in routed mode.Changes Made
Updated
.github/workflows/smoke-copilot.mdto use correct tool naming convention:activate_project→serena-activate_projectfind_symbol→serena-find_symbolThis matches the naming pattern used by other MCP tools in the workflow (e.g.,
safeinputs-gh,safeinputs-make) where tools are prefixed with their MCP server name using hyphens.Analysis
Confirmed Working:
ghcr.io/github/serena-mcp-server:latest/home/runner/work/gh-aw-mcpg/gh-aw-mcpg/.serena/project.ymlFixed Issue:
server-toolnameconvention required by the agent framework for tool discoverabilityNote: Playwright test failure (network timeout to github.com) is expected due to firewall constraints, not a code issue.
Original prompt