Skip to content

[TT-18717] Build the MCP qualification mock from tyk-mock-mcp-server main - #177

Closed
konrad-sol wants to merge 1 commit into
mainfrom
TT-18717-mcp-mock-main
Closed

konrad-sol wants to merge 1 commit into
mainfrom
TT-18717-mcp-mock-main

Conversation

@konrad-sol

Copy link
Copy Markdown
Collaborator

Moves the mock checkout in mcp-qualification.yml from 29fefa17 to b239c88 (tyk-mock-mcp-server main).

b239c88 includes tyk-mock-mcp-server#12: tool handlers read their own request's headers. At 29fefa17 the mock kept the last request's headers in one global, so with the MCP tests now running in parallel (tyk-analytics#6479) header tests fail at random, e.g. test_multiple_tool_headers ("Header 'X-Tool-Header-1' not found").

29fefa17 is an ancestor of b239c88; the range also brings in #5 (go-sdk v1.7) and CI-only commits.

Consumers pin this workflow by SHA, so nothing changes until they bump. #6479 points at this branch's commit to verify; it will move to the merged commit.

🤖 Generated with Claude Code

…main

b239c88 includes #12: tool handlers read their own request's headers.
The previous pin shared the last request's headers across concurrent
calls, so header tests fail at random now that the MCP tests run in
parallel (tyk-analytics#6479).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@konrad-sol
konrad-sol requested a review from a team November 10, 2026 18:48
@github-actions

Copy link
Copy Markdown

zizmor findings

Severity Count
High 96
Medium 91
Low 2
Info 11

Full details are in the workflow run.

@probelabs

probelabs Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

This pull request updates the version of the tyk-mock-mcp-server used in the mcp-qualification.yml reusable workflow. The change updates the pinned commit from 29fefa17 to b239c88, which corresponds to the main branch of the mock server repository.

The primary motivation for this update is to fix a race condition that was causing flaky tests. The previous version of the mock server was not thread-safe for parallel test execution, as it stored request headers in a global variable. The new version resolves this by ensuring each handler reads headers from its own request, thus stabilizing the tests.

Files Changed Analysis

  • .github/workflows/mcp-qualification.yml: A single-line change modifying the ref parameter in an actions/checkout step. This points the workflow to a newer, more stable commit of the tyk-mock-mcp-server test dependency.

Architecture & Impact Assessment

  • What this PR accomplishes: It fixes a test flakiness issue in the mcp-qualification workflow by updating a test dependency to a version that correctly handles parallel requests.
  • Key technical changes: The git reference for the TykTechnologies/tyk-mock-mcp-server repository is updated to a newer commit.
  • Affected system components: The change is isolated to the CI/CD pipeline, specifically the mcp-qualification.yml reusable workflow. It has no impact on production code but improves the reliability of integration tests for projects that consume this workflow.
graph TD
    A["mcp-qualification.yml workflow"] --> B{"actions/checkout step"};
    B --> C["Dependency: tyk-mock-mcp-server"];
    subgraph C
        direction LR
        D[Old Commit: 29fefa17] --|Update to|--> E[New Commit: b239c88];
    end
    subgraph "Reason for Change"
        F[Old version had race condition in parallel tests] --> G[New version is thread-safe];
    end
    E --> G;

Loading

Scope Discovery & Context Expansion

The mcp-qualification.yml file defines a reusable workflow (on: workflow_call) intended for use by other repositories to run MCP qualification tests. As the PR description notes, consumers pin this workflow by a specific commit SHA. This means the fix will only be adopted by downstream projects when they explicitly update the reference to this repository in their own CI configurations. This PR unblocks those projects and allows them to benefit from more stable CI runs.

Metadata
  • Review Effort: 1 / 5
  • Primary Label: bug

Powered by Visor from Probelabs

Last updated: 2026-11-10T18:50:25.590Z | Triggered by: pr_opened | Commit: 5d30345

💡 TIP: You can chat with Visor using /visor ask <your question>

@probelabs

probelabs Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

Security Issues (1)

Severity Location Issue
🟡 Warning .github/workflows/mcp-qualification.yml:145
The commit hash for the `TykTechnologies/tyk-mock-mcp-server` dependency is being updated. While pinning dependencies to a specific commit is a security best practice, this update introduces new code into the build process. According to the pull request description, this change pulls in fixes and also updates a transitive dependency to `go-sdk v1.7`. Any new code, including transitive dependencies, introduces a potential supply chain risk. If the new dependency code contains vulnerabilities or is malicious, it could compromise the CI environment and access secrets available to the job, such as the GitHub App token.
💡 SuggestionEnsure that the code changes in the `TykTechnologies/tyk-mock-mcp-server` repository between commit `29fefa17` and `b239c88` have been reviewed for security vulnerabilities. This review should cover both the direct code changes and the updated `go-sdk` dependency. Running vulnerability scans on the `tyk-mock-mcp-server` repository is recommended to detect any known vulnerabilities in its code or dependencies.

Security Issues (1)

Severity Location Issue
🟡 Warning .github/workflows/mcp-qualification.yml:145
The commit hash for the `TykTechnologies/tyk-mock-mcp-server` dependency is being updated. While pinning dependencies to a specific commit is a security best practice, this update introduces new code into the build process. According to the pull request description, this change pulls in fixes and also updates a transitive dependency to `go-sdk v1.7`. Any new code, including transitive dependencies, introduces a potential supply chain risk. If the new dependency code contains vulnerabilities or is malicious, it could compromise the CI environment and access secrets available to the job, such as the GitHub App token.
💡 SuggestionEnsure that the code changes in the `TykTechnologies/tyk-mock-mcp-server` repository between commit `29fefa17` and `b239c88` have been reviewed for security vulnerabilities. This review should cover both the direct code changes and the updated `go-sdk` dependency. Running vulnerability scans on the `tyk-mock-mcp-server` repository is recommended to detect any known vulnerabilities in its code or dependencies.
\n\n ### ✅ Architecture Check Passed

No architecture issues found – changes LGTM.

✅ Performance Check Passed

No performance issues found – changes LGTM.


Powered by Visor from Probelabs

Last updated: 2026-11-10T18:49:57.388Z | Triggered by: pr_opened | Commit: 5d30345

💡 TIP: You can chat with Visor using /visor ask <your question>

@konrad-sol

Copy link
Copy Markdown
Collaborator Author

Not needed: the MCP qualification job is being removed (TykTechnologies/gromit#582); MCP tests move into tyk-pro api-tests (TykTechnologies/tyk-analytics#6479).

@konrad-sol konrad-sol closed this Nov 12, 2026
@konrad-sol
konrad-sol deleted the TT-18717-mcp-mock-main branch November 12, 2026 10:59
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.

1 participant