@sentry/mcp-server 0.5.0 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api-client/client.cjs +1 -1
- package/dist/api-client/client.d.cts +3 -3
- package/dist/api-client/client.js +1 -1
- package/dist/api-client/client.test.cjs +1 -1
- package/dist/api-client/client.test.js +1 -1
- package/dist/api-client/index.cjs +1 -1
- package/dist/api-client/index.d.cts +3 -3
- package/dist/api-client/index.js +1 -1
- package/dist/api-client/schema.d.cts +1 -1
- package/dist/api-client/types.d.cts +2 -2
- package/dist/{client-GWxnTlSP.cjs → client-DQF6UreY.cjs} +3 -3
- package/dist/client-DQF6UreY.cjs.map +1 -0
- package/dist/{client-CpiyA8FR.js → client-vqrS5E_N.js} +3 -3
- package/dist/client-vqrS5E_N.js.map +1 -0
- package/dist/{client.d-ar2BvC_o.d.cts → client.d-JulFjrUM.d.cts} +6 -6
- package/dist/{client.d-ar2BvC_o.d.cts.map → client.d-JulFjrUM.d.cts.map} +1 -1
- package/dist/index.cjs +8 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +8 -8
- package/dist/index.js.map +1 -1
- package/dist/internal/formatting.d.cts +3 -3
- package/dist/{schema.d-DJThZSuo.d.cts → schema.d-vgLUM73w.d.cts} +219 -219
- package/dist/{schema.d-DJThZSuo.d.cts.map → schema.d-vgLUM73w.d.cts.map} +1 -1
- package/dist/{server-oefnmsHZ.js → server-BLE3CwEp.js} +6 -7
- package/dist/server-BLE3CwEp.js.map +1 -0
- package/dist/{server-D-JY6wPp.cjs → server-CqLaJq7P.cjs} +6 -7
- package/dist/server-CqLaJq7P.cjs.map +1 -0
- package/dist/server.cjs +3 -3
- package/dist/server.d.cts.map +1 -1
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +3 -3
- package/dist/{stdio-B31CD06F.js → stdio-BLheCcU0.js} +2 -2
- package/dist/{stdio-B31CD06F.js.map → stdio-BLheCcU0.js.map} +1 -1
- package/dist/{stdio-BsGPoQfx.cjs → stdio-DKNKrvTY.cjs} +2 -2
- package/dist/{stdio-BsGPoQfx.cjs.map → stdio-DKNKrvTY.cjs.map} +1 -1
- package/dist/test-setup.cjs +0 -37
- package/dist/test-setup.cjs.map +1 -1
- package/dist/test-setup.js +0 -37
- package/dist/test-setup.js.map +1 -1
- package/dist/{tools-Ck2CHZeM.cjs → tools-BdAFXSMG.cjs} +2 -2
- package/dist/{tools-Ck2CHZeM.cjs.map → tools-BdAFXSMG.cjs.map} +1 -1
- package/dist/{tools-_Y9eV4LR.js → tools-DZzt3LcX.js} +2 -2
- package/dist/{tools-_Y9eV4LR.js.map → tools-DZzt3LcX.js.map} +1 -1
- package/dist/tools.cjs +2 -2
- package/dist/tools.js +2 -2
- package/dist/tools.test.cjs +44 -21
- package/dist/tools.test.cjs.map +1 -1
- package/dist/tools.test.js +44 -21
- package/dist/tools.test.js.map +1 -1
- package/dist/transports/stdio.cjs +4 -4
- package/dist/transports/stdio.js +4 -4
- package/dist/{types.d-Z5OEf3rw.d.cts → types.d-Bq-AxlK6.d.cts} +2 -2
- package/dist/{types.d-Z5OEf3rw.d.cts.map → types.d-Bq-AxlK6.d.cts.map} +1 -1
- package/dist/{version-BFCcfCIj.cjs → version-DkTBZdhM.cjs} +2 -2
- package/dist/{version-BFCcfCIj.cjs.map → version-DkTBZdhM.cjs.map} +1 -1
- package/dist/version-S8A9iKsF.js +6 -0
- package/dist/{version-B5Fav38l.js.map → version-S8A9iKsF.js.map} +1 -1
- package/dist/version.cjs +1 -1
- package/dist/version.js +1 -1
- package/package.json +5 -5
- package/dist/client-CpiyA8FR.js.map +0 -1
- package/dist/client-GWxnTlSP.cjs.map +0 -1
- package/dist/server-D-JY6wPp.cjs.map +0 -1
- package/dist/server-oefnmsHZ.js.map +0 -1
- package/dist/version-B5Fav38l.js +0 -6
package/dist/tools.test.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tools.test.cjs","names":["TOOL_HANDLERS"],"sources":["../src/tools.test.ts"],"sourcesContent":["import { describe, it, expect } from \"vitest\";\nimport { TOOL_HANDLERS } from \"./tools\";\n\ndescribe(\"list_organizations\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_organizations;\n const result = await tool({\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n });\n expect(result).toMatchInlineSnapshot(`\n \"# Organizations\n\n ## **sentry-mcp-evals**\n\n **Web URL:** https://sentry.io/sentry-mcp-evals\n **Region URL:** https://us.sentry.io\n\n # Using this information\n\n - The organization's name is the identifier for the organization, and is used in many tools for \\`organizationSlug\\`.\n - If a tool supports passing in the \\`regionUrl\\`, you should also pass in the correct value there.\n \"\n `);\n });\n});\n\ndescribe(\"list_teams\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_teams;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Teams in **sentry-mcp-evals**\n\n - the-goats\n \"\n `);\n });\n});\n\ndescribe(\"list_projects\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_projects;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Projects in **sentry-mcp-evals**\n\n - **cloudflare-mcp**\n \"\n `);\n });\n});\n\ndescribe(\"list_issues\", () => {\n it(\"serializes with project\", async () => {\n const tool = TOOL_HANDLERS.list_issues;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n query: undefined,\n sortBy: \"last_seen\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issues in **sentry-mcp-evals/cloudflare-mcp**\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## CLOUDFLARE-MCP-42\n\n **Description**: Error: Tool list_issues is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-11T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-42\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about a specific issue by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n\n it(\"serializes without project\", async () => {\n const tool = TOOL_HANDLERS.list_issues;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n query: undefined,\n sortBy: \"last_seen\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issues in **sentry-mcp-evals**\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## CLOUDFLARE-MCP-42\n\n **Description**: Error: Tool list_issues is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-11T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-42\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about a specific issue by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n});\n\ndescribe(\"list_releases\", () => {\n it(\"works without project\", async () => {\n const tool = TOOL_HANDLERS.list_releases;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Releases in **sentry-mcp-evals**\n\n ## 8ce89484-0fec-4913-a2cd-e8e2d41dee36\n\n **Created**: 2025-04-13T19:54:21.764Z\n **First Event**: 2025-04-13T19:54:21.000Z\n **Last Event**: 2025-04-13T20:28:23.000Z\n **New Issues**: 0\n **Projects**: cloudflare-mcp\n\n # Using this information\n\n - You can reference the Release version in commit messages or documentation.\n - You can search for issues in a specific release using the \\`search_errors()\\` tool with the query \\`release:8ce89484-0fec-4913-a2cd-e8e2d41dee36\\`.\n \"\n `);\n });\n it(\"works with project\", async () => {\n const tool = TOOL_HANDLERS.list_releases;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Releases in **sentry-mcp-evals/cloudflare-mcp**\n\n ## 8ce89484-0fec-4913-a2cd-e8e2d41dee36\n\n **Created**: 2025-04-13T19:54:21.764Z\n **First Event**: 2025-04-13T19:54:21.000Z\n **Last Event**: 2025-04-13T20:28:23.000Z\n **New Issues**: 0\n **Projects**: cloudflare-mcp\n\n # Using this information\n\n - You can reference the Release version in commit messages or documentation.\n - You can search for issues in a specific release using the \\`search_errors()\\` tool with the query \\`release:8ce89484-0fec-4913-a2cd-e8e2d41dee36\\`.\n \"\n `);\n });\n});\n\ndescribe(\"list_tags\", () => {\n it(\"works\", async () => {\n const tool = TOOL_HANDLERS.list_tags;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Tags in **sentry-mcp-evals**\n\n - transaction\n - runtime.name\n - level\n - device\n - os\n - user\n - runtime\n - release\n - url\n - uptime_rule\n - server_name\n - browser\n - os.name\n - device.family\n - replayId\n - client_os.name\n - environment\n - service\n - browser.name\n\n # Using this information\n\n - You can reference tags in the \\`query\\` parameter of various tools: \\`tagName:tagValue\\`.\n \"\n `);\n });\n});\n\ndescribe(\"search_errors\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.search_errors;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n filename: undefined,\n transaction: undefined,\n query: undefined,\n sortBy: \"count\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Errors in **sentry-mcp-evals**\n\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Issue ID**: CLOUDFLARE-MCP-41\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n **Project**: test-suite\n **Last Seen**: 2025-04-07T12:23:39+00:00\n **Occurrences**: 2\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about an error by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n});\n\ndescribe(\"search_transactions\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.search_transactions;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n transaction: undefined,\n query: undefined,\n sortBy: \"duration\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Transactions in **sentry-mcp-evals**\n\n\n ## GET /trpc/bottleList\n\n **Span ID**: 07752c6aeb027c8f\n **Trace ID**: 6a477f5b0f31ef7b6b9b5e1dea66c91d\n **Span Operation**: http.server\n **Span Description**: GET /trpc/bottleList\n **Duration**: 12\n **Timestamp**: 2025-04-13T14:19:18+00:00\n **Project**: peated\n **URL**: https://sentry-mcp-evals.sentry.io/explore/traces/trace/6a477f5b0f31ef7b6b9b5e1dea66c91d\n\n ## GET /trpc/bottleList\n\n **Span ID**: 7ab5edf5b3ba42c9\n **Trace ID**: 54177131c7b192a446124daba3136045\n **Span Operation**: http.server\n **Span Description**: GET /trpc/bottleList\n **Duration**: 18\n **Timestamp**: 2025-04-13T14:19:17+00:00\n **Project**: peated\n **URL**: https://sentry-mcp-evals.sentry.io/explore/traces/trace/54177131c7b192a446124daba3136045\n\n \"\n `);\n });\n});\n\ndescribe(\"get_issue_summary\", () => {\n it(\"serializes with issueId\", async () => {\n const tool = TOOL_HANDLERS.get_issue_summary;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"CLOUDFLARE-MCP-41\",\n issueUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **Occurrences**: 25\n **Users Impacted**: 1\n **Status**: unresolved\n **Platform**: javascript\n **Project**: CLOUDFLARE-MCP\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n \"\n `);\n });\n\n it(\"serializes with issueUrl\", async () => {\n const tool = TOOL_HANDLERS.get_issue_summary;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: undefined,\n issueId: undefined,\n issueUrl: \"https://sentry-mcp-evals.sentry.io/issues/6507376925\",\n },\n );\n\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **Occurrences**: 25\n **Users Impacted**: 1\n **Status**: unresolved\n **Platform**: javascript\n **Project**: CLOUDFLARE-MCP\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n \"\n `);\n });\n});\n\ndescribe(\"get_issue_details\", () => {\n it(\"serializes with issueId\", async () => {\n const tool = TOOL_HANDLERS.get_issue_details;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"CLOUDFLARE-MCP-41\",\n issueUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## Event Specifics\n\n **Occurred At**: 2025-04-08T21:15:04.000Z\n **Error:**\n \\`\\`\\`\n Error: Tool list_organizations is already registered\n \\`\\`\\`\n\n **Stacktrace:**\n \\`\\`\\`\n index.js:7809:27\n index.js:8029:24 (OAuthProviderImpl.fetch)\n index.js:19631:28 (Object.fetch)\n \\`\\`\\`\n\n # Using this information\n\n - You can reference the IssueID in commit messages (e.g. \\`Fixes CLOUDFLARE-MCP-41\\`) to automatically close the issue when the commit is merged.\n - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.\n \"\n `);\n });\n\n it(\"serializes with issueUrl\", async () => {\n const tool = TOOL_HANDLERS.get_issue_details;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: undefined,\n issueId: undefined,\n issueUrl: \"https://sentry-mcp-evals.sentry.io/issues/6507376925\",\n },\n );\n\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## Event Specifics\n\n **Occurred At**: 2025-04-08T21:15:04.000Z\n **Error:**\n \\`\\`\\`\n Error: Tool list_organizations is already registered\n \\`\\`\\`\n\n **Stacktrace:**\n \\`\\`\\`\n index.js:7809:27\n index.js:8029:24 (OAuthProviderImpl.fetch)\n index.js:19631:28 (Object.fetch)\n \\`\\`\\`\n\n # Using this information\n\n - You can reference the IssueID in commit messages (e.g. \\`Fixes 6507376925\\`) to automatically close the issue when the commit is merged.\n - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.\n \"\n `);\n });\n});\n\ndescribe(\"create_team\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_team;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n name: \"the-goats\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New Team in **sentry-mcp-evals**\n\n **ID**: 4509109078196224\n **Slug**: the-goats\n **Name**: the-goats\n # Using this information\n\n - You should always inform the user of the Team Slug value.\n \"\n `);\n });\n});\n\ndescribe(\"create_project\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_project;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n teamSlug: \"the-goats\",\n name: \"cloudflare-mcp\",\n platform: \"javascript\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New Project in **sentry-mcp-evals**\n\n **ID**: 4509109104082945\n **Slug**: cloudflare-mcp\n **Name**: cloudflare-mcp\n **SENTRY_DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n\n # Using this information\n\n - You can reference the **SENTRY_DSN** value to initialize Sentry's SDKs.\n - You should always inform the user of the **SENTRY_DSN** and Project Slug values.\n \"\n `);\n });\n});\n\ndescribe(\"create_dsn\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_dsn;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n name: \"Default\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New DSN in **sentry-mcp-evals/cloudflare-mcp**\n\n **DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n **Name**: Default\n\n # Using this information\n\n - The \\`SENTRY_DSN\\` value is a URL that you can use to initialize Sentry's SDKs.\n \"\n `);\n });\n});\n\ndescribe(\"list_dsn\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_dsns;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# DSNs in **sentry-mcp-evals/cloudflare-mcp**\n\n ## Default\n **ID**: d20df0a1ab5031c7f3c7edca9c02814d\n **DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n\n # Using this information\n\n - The \\`SENTRY_DSN\\` value is a URL that you can use to initialize Sentry's SDKs.\n \"\n `);\n });\n});\n\ndescribe(\"begin_autofix\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.begin_autofix;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"PEATED-A8\",\n issueUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Autofix Started for Issue PEATED-A8\n\n **Run ID:**: 123\n\n This operation may take some time, so you should call \\`get_autofix_status()\\` to check the status of the analysis, and repeat the process until its finished.\n\n You should also inform the user that the operation may take some time, and give them updates whenever you check the status of the operation..\n\n \\`\\`\\`\n get_autofix_status(organizationSlug=\"sentry-mcp-evals\", issueId=\"PEATED-A8\")\n \\`\\`\\`\"\n `);\n });\n});\n\ndescribe(\"get_autofix_status\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.get_autofix_status;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"PEATED-A8\",\n issueUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Autofix Status for Issue PEATED-A8\n\n ## Analyzing the Issue\n\n **The \\`bottleById\\` query fails because the input ID (3216) doesn't exist in the database.\n **\n The exception details show that the \\`input\\` value at the time of the \\`TRPCError\\` in \\`bottleById.ts\\` was 3216, and the query likely failed because a bottle with ID 3216 was not found in the database.\n\n \\`\\`\\`\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n\n **However, the request also includes a different ID (16720) for \\`bottlePriceList\\`.\n **\n The root cause is likely a mismatch of input IDs within the batched TRPC request, where \\`bottlePriceList\\` expects bottle ID 16720, but \\`bottleById\\` receives a different ID (3216) leading to the \"Bottle not found\" error.\n\n \\`\\`\\`\n GET http://api.peated.com/trpc/bottlePriceList,bottleById\n \\`\\`\\`\n\n \\`\\`\\`json\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n \\`\\`\\`\n TRPCError: Bottle not found. (occurred in: GET /trpc/bottlePriceList,bottleById)\n \\`\\`\\`\n\n\n **This suggests a data consistency issue or incorrect client-side request.\n **\n The \\`TRPCError\\` originates from \\`bottleById.ts\\` with the input value being \\`3216\\`, indicating the procedure failed to find a bottle with that specific ID in the database.\n\n \\`\\`\\`\n <anonymous> in file /app/apps/server/src/trpc/routes/bottleById.ts [Line 33, column 13] (In app)\n .select({\n ...getTableColumns(bottles),\n })\n .from(bottleTombstones)\n .innerJoin(bottles, eq(bottleTombstones.newBottleId, bottles.id))\n .where(eq(bottleTombstones.bottleId, input));\n if (!bottle) {\n throw new TRPCError({ <-- SUSPECT LINE\n message: \"Bottle not found.\",\n code: \"NOT_FOUND\",\n });\n }\n }\n\n const createdBy = await db.query.users.findFirst({\n ---\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n\n\n ## Root Cause Analysis\n\n **The client initiates a batched TRPC request to the \\`/trpc/bottlePriceList,bottleById\\` endpoint, intending to fetch both the price list and details for a specific bottle.**\n\n This is the entry point where the client requests data from two different procedures in a single HTTP request. The server needs to correctly route and process the parameters for each procedure.\n\n **The TRPC server receives the batched request and begins processing the \\`bottlePriceList\\` procedure, intending to fetch the price list for bottle ID 16720.**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottlePriceList.ts\n .input(z.object({ bottle: z.number(), onlyValid: z.boolean().optional() }))\n .query(async function ({ input, ctx }) {\n const [bottle] = await db.select().from(bottles).where(eq(bottles.id, input.bottle));\n if (!bottle) { ... }\n \\`\\`\\`\n This procedure expects a 'bottle' parameter in the input, which is used to query the database.\n\n **The TRPC server also processes the \\`bottleById\\` procedure, but due to a parameter mapping issue or client-side error, it receives bottle ID 3216 as input instead of 16720.**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottleById.ts\n export default publicProcedure.input(z.number()).query(async function ({ input, ctx }) {\n let [bottle] = await db.select().from(bottles).where(eq(bottles.id, input));\n if (!bottle) { ... }\n \\`\\`\\`\n This procedure expects a numerical ID as input to find the bottle.\n\n **The \\`bottleById\\` procedure queries the \\`bottles\\` table for a bottle with ID 3216, but no such bottle exists.**\n\n The database query returns no results because bottle ID 3216 is not present in the \\`bottles\\` table.\n\n **The \\`bottleById\\` procedure then checks the \\`bottleTombstones\\` table to see if bottle ID 3216 has been tombstoned (redirected to a new ID), but no such tombstone exists.**\n\n The query to \\`bottleTombstones\\` also returns no results, indicating that bottle ID 3216 has not been redirected.\n\n **Since the \\`bottleById\\` procedure cannot find a bottle with ID 3216 in either the \\`bottles\\` or \\`bottleTombstones\\` tables, it throws a \\`TRPCError\\` with the message \"Bottle not found.\"**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottleById.ts\n if (!bottle) {\n throw new TRPCError({ message: \"Bottle not found.\", code: \"NOT_FOUND\" });\n }\n \\`\\`\\`\n This is where the error is thrown, indicating that the bottle could not be found.\n\n\n ## Planning Solution\n\n **The discrepancy between inputs suggests a potential issue with batch request handling.\n **\n The \\`TRPCError\\` occurred in \\`bottleById.ts\\` with an input of \\`3216\\`, while the request was initiated with a bottle ID of \\`16720\\`, indicating a mismatch in the bottle ID being processed.\n\n \\`\\`\\`\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n \\`\\`\\`\n GET http://api.peated.com/trpc/bottlePriceList,bottleById\n \\`\\`\\`\n\n\n **The client-side batch request construction is the most likely source of error.\n **\n The discrepancy between the bottle ID in the error message (16720) and the ID being processed (3216) strongly suggests a client-side parameter mapping issue in the batched TRPC request.\n\n To fix this, I propose the following steps:\n\n 1. **Inspect the Client-Side Code:** Identify the code responsible for constructing the TRPC batch request to \\`/trpc/bottlePriceList,bottleById\\`.\n\n 2. **Verify Parameter Mapping:** Ensure that both \\`bottlePriceList\\` and \\`bottleById\\` are receiving the correct bottle ID (which should be 16720 in this case).\n\n 3. **Correct Parameter Assignment:** If the parameters are being incorrectly assigned, modify the client-side code to ensure that both procedures receive the same, correct bottle ID.\n\n 4. **Add Logging (Client-Side):** Add temporary logging to the client-side code to confirm the parameters being sent to each procedure in the batch request. This will help verify the fix.\n\n \\`\\`\\`typescript\n // Example logging (add to the client-side code where the batch request is created)\n console.log(\"bottlePriceList input:\", { bottle: 16720 }); // Replace 16720 with the actual ID\n console.log(\"bottleById input:\", { bottle: 16720 }); // Replace 16720 with the actual ID\n \\`\\`\\`\n\n 5. **Test the Fix:** After applying the fix, test the affected functionality to ensure that the \"Bottle not found\" error is resolved and that both procedures are working correctly.\n\n 6. **Remove Logging:** Once the fix is verified, remove the temporary logging.\n\n This approach directly addresses the most likely cause of the issue and provides a clear path to resolution.\n\n\n **Ensuring consistent bottle IDs will likely resolve this inconsistency.\n **\n The error message references bottle ID 16720, but the exception details show the procedure was actually processing ID 3216, indicating a parameter mismatch in the batch request.\n\n To fix this, I recommend the following steps:\n\n 1. **Client-Side Investigation**:\n\n * Examine the client-side code where the TRPC batch request is constructed.\n * Verify that the same \\`bottleId\\` parameter is being passed to both \\`bottlePriceList\\` and \\`bottleById\\` procedures.\n * If the IDs are being passed correctly, inspect the network request payload to confirm the correct structure of the batched request.\n\n \\`\\`\\`typescript\n // Example (Hypothetical) Client-Side Code\n const bottleId = 16720; // Example bottle ID\n\n // Ensure both procedures receive the same bottleId\n const [priceList, bottleDetails] = await trpc.batch(() => [\n trpc.bottlePriceList.fetch({ bottle: bottleId }),\n trpc.bottleById.fetch(bottleId),\n ]);\n \\`\\`\\`\n\n 2. **Server-Side Logging (Temporary)**:\n\n * Add temporary logging to both \\`bottlePriceList\\` and \\`bottleById\\` procedures to log the received \\`input\\` value.\n * This will help confirm whether the server is receiving the correct IDs from the client.\n * **Important**: Remove these logs after debugging to avoid unnecessary overhead.\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottlePriceList.ts\n export default publicProcedure\n .input(\n z.object({\n bottle: z.number(),\n onlyValid: z.boolean().optional(),\n }),\n )\n .query(async function ({ input, ctx }) {\n console.log(\"bottlePriceList input:\", input); // Add this line\n // ... rest of the code\n });\n\n // apps/server/src/trpc/routes/bottleById.ts\n export default publicProcedure.input(z.number()).query(async function ({\n input,\n ctx,\n }) {\n console.log(\"bottleById input:\", input); // Add this line\n // ... rest of the code\n });\n \\`\\`\\`\n\n 3. **TRPC Batch Request Configuration**:\n\n * Review the TRPC batch link configuration on the client-side.\n * Ensure that the batching logic is correctly mapping parameters to the corresponding procedures.\n * If using a custom batching implementation, verify its correctness.\n\n 4. **Data Integrity Check**:\n\n * If the client-side code appears correct, investigate whether bottle ID 3216 should exist in the database.\n * Check the \\`bottles\\` table and \\`bottleTombstones\\` table for any entries related to bottle ID 3216.\n * If the bottle should exist but is missing, investigate potential data deletion or migration issues.\n\n 5. **Tombstone Logic**:\n\n * Double-check the logic for creating and using tombstones.\n * Ensure that when a bottle is deleted, a tombstone entry is created correctly, pointing to the new bottle (if any).\n\n 6. **Error Handling**:\n\n * While this isn't the primary fix, consider improving the error message in \\`bottleById.ts\\` to include more context.\n * Include the original requested bottle ID (if available) in the error message to aid debugging.\n\n 7. **Client-Side Retries**:\n\n * Implement a retry mechanism on the client-side for TRPC requests.\n * If a \"Bottle not found\" error occurs, retry the request a few times before giving up. This can help mitigate transient issues.\n\n By following these steps, you should be able to identify the root cause of the parameter mismatch and implement a fix that ensures consistent bottle IDs are passed to both TRPC procedures in the batch request.\n\n\n\n ## Solution\n\n Consolidate bottle and price data fetching into a single batched TRPC request using \\`Promise.all\\` to ensure ID consistency.\n\n **Create a shared utility function to fetch bottle details and price data together.**\n \\`\\`\\`typescript\n // In a shared utility function or component\n export async function getBottleWithPrices(bottleId: number) {\n const trpcClient = await getTrpcClient();\n \n // Use Promise.all to ensure both requests are part of the same batch\n // and receive the same parameters\n const [bottle, priceList] = await Promise.all([\n trpcClient.bottleById.fetch(bottleId),\n trpcClient.bottlePriceList.fetch({ bottle: bottleId }),\n ]);\n \n return { bottle, priceList };\n }\n \\`\\`\\`\n This code creates a function that uses \\`Promise.all\\` to fetch both bottle details and price data concurrently. This ensures that both TRPC procedures are part of the same batch and receive the same \\`bottleId\\`.\n\n **Modify the page components to use the shared utility function.**\n \\`\\`\\`typescript\n // Then in the page components:\n const { bottle, priceList } = await getBottleWithPrices(Number(bottleId));\n \\`\\`\\`\n This code replaces the separate calls to \\`bottleById\\` and \\`bottlePriceList\\` with a single call to the \\`getBottleWithPrices\\` function, ensuring that both components receive data for the same bottle.\n\n **Add a unit test that reproduces the issue.**\n null\n\n\n \"\n `);\n });\n});\n"],"mappings":";;;;;;;;;;;;;AAGA,sBAAS,sBAAsB,MAAM;AACnC,iBAAG,cAAc,YAAY;EAC3B,MAAM,OAAOA,4BAAc;EAC3B,MAAM,SAAS,MAAM,KAAK;GACxB,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,EAAC;AACF,mCAAO,OAAO,CAAC,uBAAuB;;;;;;;;;;;;;MAapC;CACH,EAAC;AACH,EAAC;AAEF,sBAAS,cAAc,MAAM;AAC3B,iBAAG,cAAc,YAAY;EAC3B,MAAM,OAAOA,4BAAc;EAC3B,MAAM,SAAS,MAAM,KACnB;GACE,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,GACD,EACE,kBAAkB,mBACnB,EACF;AACD,mCAAO,OAAO,CAAC,uBAAuB;;;;;MAKpC;CACH,EAAC;AACH,EAAC;AAEF,sBAAS,iBAAiB,MAAM;AAC9B,iBAAG,cAAc,YAAY;EAC3B,MAAM,OAAOA,4BAAc;EAC3B,MAAM,SAAS,MAAM,KACnB;GACE,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,GACD,EACE,kBAAkB,mBACnB,EACF;AACD,mCAAO,OAAO,CAAC,uBAAuB;;;;;MAKpC;CAC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;;;;;;;;;;;;;;;MAmRpC;CACH,EAAC;AACH,EAAC"}
|
|
1
|
+
{"version":3,"file":"tools.test.cjs","names":["TOOL_HANDLERS"],"sources":["../src/tools.test.ts"],"sourcesContent":["import { describe, it, expect } from \"vitest\";\nimport { TOOL_HANDLERS } from \"./tools\";\n\ndescribe(\"list_organizations\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_organizations;\n const result = await tool({\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n });\n expect(result).toMatchInlineSnapshot(`\n \"# Organizations\n\n ## **sentry-mcp-evals**\n\n **Web URL:** https://sentry.io/sentry-mcp-evals\n **Region URL:** https://us.sentry.io\n\n # Using this information\n\n - The organization's name is the identifier for the organization, and is used in many tools for \\`organizationSlug\\`.\n - If a tool supports passing in the \\`regionUrl\\`, you should also pass in the correct value there.\n \"\n `);\n });\n});\n\ndescribe(\"list_teams\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_teams;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Teams in **sentry-mcp-evals**\n\n - the-goats\n \"\n `);\n });\n});\n\ndescribe(\"list_projects\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_projects;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Projects in **sentry-mcp-evals**\n\n - **cloudflare-mcp**\n \"\n `);\n });\n});\n\ndescribe(\"list_issues\", () => {\n it(\"serializes with project\", async () => {\n const tool = TOOL_HANDLERS.list_issues;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n query: undefined,\n sortBy: \"last_seen\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issues in **sentry-mcp-evals/cloudflare-mcp**\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## CLOUDFLARE-MCP-42\n\n **Description**: Error: Tool list_issues is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-11T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-42\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about a specific issue by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n\n it(\"serializes without project\", async () => {\n const tool = TOOL_HANDLERS.list_issues;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n query: undefined,\n sortBy: \"last_seen\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issues in **sentry-mcp-evals**\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## CLOUDFLARE-MCP-42\n\n **Description**: Error: Tool list_issues is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-11T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-42\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about a specific issue by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n});\n\ndescribe(\"list_releases\", () => {\n it(\"works without project\", async () => {\n const tool = TOOL_HANDLERS.list_releases;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Releases in **sentry-mcp-evals**\n\n ## 8ce89484-0fec-4913-a2cd-e8e2d41dee36\n\n **Created**: 2025-04-13T19:54:21.764Z\n **First Event**: 2025-04-13T19:54:21.000Z\n **Last Event**: 2025-04-13T20:28:23.000Z\n **New Issues**: 0\n **Projects**: cloudflare-mcp\n\n # Using this information\n\n - You can reference the Release version in commit messages or documentation.\n - You can search for issues in a specific release using the \\`search_errors()\\` tool with the query \\`release:8ce89484-0fec-4913-a2cd-e8e2d41dee36\\`.\n \"\n `);\n });\n it(\"works with project\", async () => {\n const tool = TOOL_HANDLERS.list_releases;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Releases in **sentry-mcp-evals/cloudflare-mcp**\n\n ## 8ce89484-0fec-4913-a2cd-e8e2d41dee36\n\n **Created**: 2025-04-13T19:54:21.764Z\n **First Event**: 2025-04-13T19:54:21.000Z\n **Last Event**: 2025-04-13T20:28:23.000Z\n **New Issues**: 0\n **Projects**: cloudflare-mcp\n\n # Using this information\n\n - You can reference the Release version in commit messages or documentation.\n - You can search for issues in a specific release using the \\`search_errors()\\` tool with the query \\`release:8ce89484-0fec-4913-a2cd-e8e2d41dee36\\`.\n \"\n `);\n });\n});\n\ndescribe(\"list_tags\", () => {\n it(\"works\", async () => {\n const tool = TOOL_HANDLERS.list_tags;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Tags in **sentry-mcp-evals**\n\n - transaction\n - runtime.name\n - level\n - device\n - os\n - user\n - runtime\n - release\n - url\n - uptime_rule\n - server_name\n - browser\n - os.name\n - device.family\n - replayId\n - client_os.name\n - environment\n - service\n - browser.name\n\n # Using this information\n\n - You can reference tags in the \\`query\\` parameter of various tools: \\`tagName:tagValue\\`.\n \"\n `);\n });\n});\n\ndescribe(\"search_errors\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.search_errors;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n filename: undefined,\n transaction: undefined,\n query: undefined,\n sortBy: \"count\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Errors in **sentry-mcp-evals**\n\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Issue ID**: CLOUDFLARE-MCP-41\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n **Project**: test-suite\n **Last Seen**: 2025-04-07T12:23:39+00:00\n **Occurrences**: 2\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about an error by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n});\n\ndescribe(\"search_transactions\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.search_transactions;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n transaction: undefined,\n query: undefined,\n sortBy: \"duration\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Transactions in **sentry-mcp-evals**\n\n\n ## GET /trpc/bottleList\n\n **Span ID**: 07752c6aeb027c8f\n **Trace ID**: 6a477f5b0f31ef7b6b9b5e1dea66c91d\n **Span Operation**: http.server\n **Span Description**: GET /trpc/bottleList\n **Duration**: 12\n **Timestamp**: 2025-04-13T14:19:18+00:00\n **Project**: peated\n **URL**: https://sentry-mcp-evals.sentry.io/explore/traces/trace/6a477f5b0f31ef7b6b9b5e1dea66c91d\n\n ## GET /trpc/bottleList\n\n **Span ID**: 7ab5edf5b3ba42c9\n **Trace ID**: 54177131c7b192a446124daba3136045\n **Span Operation**: http.server\n **Span Description**: GET /trpc/bottleList\n **Duration**: 18\n **Timestamp**: 2025-04-13T14:19:17+00:00\n **Project**: peated\n **URL**: https://sentry-mcp-evals.sentry.io/explore/traces/trace/54177131c7b192a446124daba3136045\n\n \"\n `);\n });\n});\n\ndescribe(\"get_issue_summary\", () => {\n it(\"serializes with issueId\", async () => {\n const tool = TOOL_HANDLERS.get_issue_summary;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"CLOUDFLARE-MCP-41\",\n issueUrl: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **Occurrences**: 25\n **Users Impacted**: 1\n **Status**: unresolved\n **Platform**: javascript\n **Project**: CLOUDFLARE-MCP\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n \"\n `);\n });\n\n it(\"serializes with issueUrl\", async () => {\n const tool = TOOL_HANDLERS.get_issue_summary;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: undefined,\n issueId: undefined,\n issueUrl: \"https://sentry-mcp-evals.sentry.io/issues/6507376925\",\n regionUrl: undefined,\n },\n );\n\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **Occurrences**: 25\n **Users Impacted**: 1\n **Status**: unresolved\n **Platform**: javascript\n **Project**: CLOUDFLARE-MCP\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n \"\n `);\n });\n});\n\ndescribe(\"get_issue_details\", () => {\n it(\"serializes with issueId\", async () => {\n const tool = TOOL_HANDLERS.get_issue_details;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"CLOUDFLARE-MCP-41\",\n issueUrl: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## Event Specifics\n\n **Occurred At**: 2025-04-08T21:15:04.000Z\n **Error:**\n \\`\\`\\`\n Error: Tool list_organizations is already registered\n \\`\\`\\`\n\n **Stacktrace:**\n \\`\\`\\`\n index.js:7809:27\n index.js:8029:24 (OAuthProviderImpl.fetch)\n index.js:19631:28 (Object.fetch)\n \\`\\`\\`\n\n # Using this information\n\n - You can reference the IssueID in commit messages (e.g. \\`Fixes CLOUDFLARE-MCP-41\\`) to automatically close the issue when the commit is merged.\n - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.\n \"\n `);\n });\n\n it(\"serializes with issueUrl\", async () => {\n const tool = TOOL_HANDLERS.get_issue_details;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: undefined,\n issueId: undefined,\n issueUrl: \"https://sentry-mcp-evals.sentry.io/issues/6507376925\",\n regionUrl: undefined,\n },\n );\n\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## Event Specifics\n\n **Occurred At**: 2025-04-08T21:15:04.000Z\n **Error:**\n \\`\\`\\`\n Error: Tool list_organizations is already registered\n \\`\\`\\`\n\n **Stacktrace:**\n \\`\\`\\`\n index.js:7809:27\n index.js:8029:24 (OAuthProviderImpl.fetch)\n index.js:19631:28 (Object.fetch)\n \\`\\`\\`\n\n # Using this information\n\n - You can reference the IssueID in commit messages (e.g. \\`Fixes 6507376925\\`) to automatically close the issue when the commit is merged.\n - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.\n \"\n `);\n });\n});\n\ndescribe(\"create_team\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_team;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n name: \"the-goats\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New Team in **sentry-mcp-evals**\n\n **ID**: 4509109078196224\n **Slug**: the-goats\n **Name**: the-goats\n # Using this information\n\n - You should always inform the user of the Team Slug value.\n \"\n `);\n });\n});\n\ndescribe(\"create_project\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_project;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n teamSlug: \"the-goats\",\n name: \"cloudflare-mcp\",\n platform: \"javascript\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New Project in **sentry-mcp-evals**\n\n **ID**: 4509109104082945\n **Slug**: cloudflare-mcp\n **Name**: cloudflare-mcp\n **SENTRY_DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n\n # Using this information\n\n - You can reference the **SENTRY_DSN** value to initialize Sentry's SDKs.\n - You should always inform the user of the **SENTRY_DSN** and Project Slug values.\n \"\n `);\n });\n});\n\ndescribe(\"create_dsn\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_dsn;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n name: \"Default\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New DSN in **sentry-mcp-evals/cloudflare-mcp**\n\n **DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n **Name**: Default\n\n # Using this information\n\n - The \\`SENTRY_DSN\\` value is a URL that you can use to initialize Sentry's SDKs.\n \"\n `);\n });\n});\n\ndescribe(\"list_dsn\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_dsns;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# DSNs in **sentry-mcp-evals/cloudflare-mcp**\n\n ## Default\n **ID**: d20df0a1ab5031c7f3c7edca9c02814d\n **DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n\n # Using this information\n\n - The \\`SENTRY_DSN\\` value is a URL that you can use to initialize Sentry's SDKs.\n \"\n `);\n });\n});\n\ndescribe(\"begin_autofix\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.begin_autofix;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"PEATED-A8\",\n issueUrl: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Autofix Started for Issue PEATED-A8\n\n **Run ID:**: 123\n\n This operation may take some time, so you should call \\`get_autofix_status()\\` to check the status of the analysis, and repeat the process until its finished.\n\n You should also inform the user that the operation may take some time, and give them updates whenever you check the status of the operation..\n\n \\`\\`\\`\n get_autofix_status(organizationSlug=\"sentry-mcp-evals\", issueId=\"PEATED-A8\")\n \\`\\`\\`\"\n `);\n });\n});\n\ndescribe(\"get_autofix_status\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.get_autofix_status;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"PEATED-A8\",\n issueUrl: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Autofix Status for Issue PEATED-A8\n\n ## Analyzing the Issue\n\n **The \\`bottleById\\` query fails because the input ID (3216) doesn't exist in the database.\n **\n The exception details show that the \\`input\\` value at the time of the \\`TRPCError\\` in \\`bottleById.ts\\` was 3216, and the query likely failed because a bottle with ID 3216 was not found in the database.\n\n \\`\\`\\`\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n\n **However, the request also includes a different ID (16720) for \\`bottlePriceList\\`.\n **\n The root cause is likely a mismatch of input IDs within the batched TRPC request, where \\`bottlePriceList\\` expects bottle ID 16720, but \\`bottleById\\` receives a different ID (3216) leading to the \"Bottle not found\" error.\n\n \\`\\`\\`\n GET http://api.peated.com/trpc/bottlePriceList,bottleById\n \\`\\`\\`\n\n \\`\\`\\`json\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n \\`\\`\\`\n TRPCError: Bottle not found. (occurred in: GET /trpc/bottlePriceList,bottleById)\n \\`\\`\\`\n\n\n **This suggests a data consistency issue or incorrect client-side request.\n **\n The \\`TRPCError\\` originates from \\`bottleById.ts\\` with the input value being \\`3216\\`, indicating the procedure failed to find a bottle with that specific ID in the database.\n\n \\`\\`\\`\n <anonymous> in file /app/apps/server/src/trpc/routes/bottleById.ts [Line 33, column 13] (In app)\n .select({\n ...getTableColumns(bottles),\n })\n .from(bottleTombstones)\n .innerJoin(bottles, eq(bottleTombstones.newBottleId, bottles.id))\n .where(eq(bottleTombstones.bottleId, input));\n if (!bottle) {\n throw new TRPCError({ <-- SUSPECT LINE\n message: \"Bottle not found.\",\n code: \"NOT_FOUND\",\n });\n }\n }\n\n const createdBy = await db.query.users.findFirst({\n ---\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n\n\n ## Root Cause Analysis\n\n **The client initiates a batched TRPC request to the \\`/trpc/bottlePriceList,bottleById\\` endpoint, intending to fetch both the price list and details for a specific bottle.**\n\n This is the entry point where the client requests data from two different procedures in a single HTTP request. The server needs to correctly route and process the parameters for each procedure.\n\n **The TRPC server receives the batched request and begins processing the \\`bottlePriceList\\` procedure, intending to fetch the price list for bottle ID 16720.**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottlePriceList.ts\n .input(z.object({ bottle: z.number(), onlyValid: z.boolean().optional() }))\n .query(async function ({ input, ctx }) {\n const [bottle] = await db.select().from(bottles).where(eq(bottles.id, input.bottle));\n if (!bottle) { ... }\n \\`\\`\\`\n This procedure expects a 'bottle' parameter in the input, which is used to query the database.\n\n **The TRPC server also processes the \\`bottleById\\` procedure, but due to a parameter mapping issue or client-side error, it receives bottle ID 3216 as input instead of 16720.**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottleById.ts\n export default publicProcedure.input(z.number()).query(async function ({ input, ctx }) {\n let [bottle] = await db.select().from(bottles).where(eq(bottles.id, input));\n if (!bottle) { ... }\n \\`\\`\\`\n This procedure expects a numerical ID as input to find the bottle.\n\n **The \\`bottleById\\` procedure queries the \\`bottles\\` table for a bottle with ID 3216, but no such bottle exists.**\n\n The database query returns no results because bottle ID 3216 is not present in the \\`bottles\\` table.\n\n **The \\`bottleById\\` procedure then checks the \\`bottleTombstones\\` table to see if bottle ID 3216 has been tombstoned (redirected to a new ID), but no such tombstone exists.**\n\n The query to \\`bottleTombstones\\` also returns no results, indicating that bottle ID 3216 has not been redirected.\n\n **Since the \\`bottleById\\` procedure cannot find a bottle with ID 3216 in either the \\`bottles\\` or \\`bottleTombstones\\` tables, it throws a \\`TRPCError\\` with the message \"Bottle not found.\"**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottleById.ts\n if (!bottle) {\n throw new TRPCError({ message: \"Bottle not found.\", code: \"NOT_FOUND\" });\n }\n \\`\\`\\`\n This is where the error is thrown, indicating that the bottle could not be found.\n\n\n ## Planning Solution\n\n **The discrepancy between inputs suggests a potential issue with batch request handling.\n **\n The \\`TRPCError\\` occurred in \\`bottleById.ts\\` with an input of \\`3216\\`, while the request was initiated with a bottle ID of \\`16720\\`, indicating a mismatch in the bottle ID being processed.\n\n \\`\\`\\`\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n \\`\\`\\`\n GET http://api.peated.com/trpc/bottlePriceList,bottleById\n \\`\\`\\`\n\n\n **The client-side batch request construction is the most likely source of error.\n **\n The discrepancy between the bottle ID in the error message (16720) and the ID being processed (3216) strongly suggests a client-side parameter mapping issue in the batched TRPC request.\n\n To fix this, I propose the following steps:\n\n 1. **Inspect the Client-Side Code:** Identify the code responsible for constructing the TRPC batch request to \\`/trpc/bottlePriceList,bottleById\\`.\n\n 2. **Verify Parameter Mapping:** Ensure that both \\`bottlePriceList\\` and \\`bottleById\\` are receiving the correct bottle ID (which should be 16720 in this case).\n\n 3. **Correct Parameter Assignment:** If the parameters are being incorrectly assigned, modify the client-side code to ensure that both procedures receive the same, correct bottle ID.\n\n 4. **Add Logging (Client-Side):** Add temporary logging to the client-side code to confirm the parameters being sent to each procedure in the batch request. This will help verify the fix.\n\n \\`\\`\\`typescript\n // Example logging (add to the client-side code where the batch request is created)\n console.log(\"bottlePriceList input:\", { bottle: 16720 }); // Replace 16720 with the actual ID\n console.log(\"bottleById input:\", { bottle: 16720 }); // Replace 16720 with the actual ID\n \\`\\`\\`\n\n 5. **Test the Fix:** After applying the fix, test the affected functionality to ensure that the \"Bottle not found\" error is resolved and that both procedures are working correctly.\n\n 6. **Remove Logging:** Once the fix is verified, remove the temporary logging.\n\n This approach directly addresses the most likely cause of the issue and provides a clear path to resolution.\n\n\n **Ensuring consistent bottle IDs will likely resolve this inconsistency.\n **\n The error message references bottle ID 16720, but the exception details show the procedure was actually processing ID 3216, indicating a parameter mismatch in the batch request.\n\n To fix this, I recommend the following steps:\n\n 1. **Client-Side Investigation**:\n\n * Examine the client-side code where the TRPC batch request is constructed.\n * Verify that the same \\`bottleId\\` parameter is being passed to both \\`bottlePriceList\\` and \\`bottleById\\` procedures.\n * If the IDs are being passed correctly, inspect the network request payload to confirm the correct structure of the batched request.\n\n \\`\\`\\`typescript\n // Example (Hypothetical) Client-Side Code\n const bottleId = 16720; // Example bottle ID\n\n // Ensure both procedures receive the same bottleId\n const [priceList, bottleDetails] = await trpc.batch(() => [\n trpc.bottlePriceList.fetch({ bottle: bottleId }),\n trpc.bottleById.fetch(bottleId),\n ]);\n \\`\\`\\`\n\n 2. **Server-Side Logging (Temporary)**:\n\n * Add temporary logging to both \\`bottlePriceList\\` and \\`bottleById\\` procedures to log the received \\`input\\` value.\n * This will help confirm whether the server is receiving the correct IDs from the client.\n * **Important**: Remove these logs after debugging to avoid unnecessary overhead.\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottlePriceList.ts\n export default publicProcedure\n .input(\n z.object({\n bottle: z.number(),\n onlyValid: z.boolean().optional(),\n }),\n )\n .query(async function ({ input, ctx }) {\n console.log(\"bottlePriceList input:\", input); // Add this line\n // ... rest of the code\n });\n\n // apps/server/src/trpc/routes/bottleById.ts\n export default publicProcedure.input(z.number()).query(async function ({\n input,\n ctx,\n }) {\n console.log(\"bottleById input:\", input); // Add this line\n // ... rest of the code\n });\n \\`\\`\\`\n\n 3. **TRPC Batch Request Configuration**:\n\n * Review the TRPC batch link configuration on the client-side.\n * Ensure that the batching logic is correctly mapping parameters to the corresponding procedures.\n * If using a custom batching implementation, verify its correctness.\n\n 4. **Data Integrity Check**:\n\n * If the client-side code appears correct, investigate whether bottle ID 3216 should exist in the database.\n * Check the \\`bottles\\` table and \\`bottleTombstones\\` table for any entries related to bottle ID 3216.\n * If the bottle should exist but is missing, investigate potential data deletion or migration issues.\n\n 5. **Tombstone Logic**:\n\n * Double-check the logic for creating and using tombstones.\n * Ensure that when a bottle is deleted, a tombstone entry is created correctly, pointing to the new bottle (if any).\n\n 6. **Error Handling**:\n\n * While this isn't the primary fix, consider improving the error message in \\`bottleById.ts\\` to include more context.\n * Include the original requested bottle ID (if available) in the error message to aid debugging.\n\n 7. **Client-Side Retries**:\n\n * Implement a retry mechanism on the client-side for TRPC requests.\n * If a \"Bottle not found\" error occurs, retry the request a few times before giving up. This can help mitigate transient issues.\n\n By following these steps, you should be able to identify the root cause of the parameter mismatch and implement a fix that ensures consistent bottle IDs are passed to both TRPC procedures in the batch request.\n\n\n\n ## Solution\n\n Consolidate bottle and price data fetching into a single batched TRPC request using \\`Promise.all\\` to ensure ID consistency.\n\n **Create a shared utility function to fetch bottle details and price data together.**\n \\`\\`\\`typescript\n // In a shared utility function or component\n export async function getBottleWithPrices(bottleId: number) {\n const trpcClient = await getTrpcClient();\n \n // Use Promise.all to ensure both requests are part of the same batch\n // and receive the same parameters\n const [bottle, priceList] = await Promise.all([\n trpcClient.bottleById.fetch(bottleId),\n trpcClient.bottlePriceList.fetch({ bottle: bottleId }),\n ]);\n \n return { bottle, priceList };\n }\n \\`\\`\\`\n This code creates a function that uses \\`Promise.all\\` to fetch both bottle details and price data concurrently. This ensures that both TRPC procedures are part of the same batch and receive the same \\`bottleId\\`.\n\n **Modify the page components to use the shared utility function.**\n \\`\\`\\`typescript\n // Then in the page components:\n const { bottle, priceList } = await getBottleWithPrices(Number(bottleId));\n \\`\\`\\`\n This code replaces the separate calls to \\`bottleById\\` and \\`bottlePriceList\\` with a single call to the \\`getBottleWithPrices\\` function, ensuring that both components receive data for the same bottle.\n\n **Add a unit test that reproduces the issue.**\n null\n\n\n \"\n `);\n });\n});\n"],"mappings":";;;;;;;;;;;;;AAGA,sBAAS,sBAAsB,MAAM;AACnC,iBAAG,cAAc,YAAY;EAC3B,MAAM,OAAOA,4BAAc;EAC3B,MAAM,SAAS,MAAM,KAAK;GACxB,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,EAAC;AACF,mCAAO,OAAO,CAAC,uBAAuB;;;;;;;;;;;;;MAapC;CACH,EAAC;AACH,EAAC;AAEF,sBAAS,cAAc,MAAM;AAC3B,iBAAG,cAAc,YAAY;EAC3B,MAAM,OAAOA,4BAAc;EAC3B,MAAM,SAAS,MAAM,KACnB;GACE,aAAa;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,MAAM,KACnB;GACE,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,GACD;GACE,kBAAkB;GAClB,SAAS;GACT;GACA;EACD,EACF;AACD,mCAAO,OAAO,CAAC,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAmRpC;CACH,EAAC;AACH,EAAC"}
|
package/dist/tools.test.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import "./schema-BzPfPMq7.js";
|
|
2
|
-
import "./client-
|
|
2
|
+
import "./client-vqrS5E_N.js";
|
|
3
3
|
import "./types-H-TSmRpm.js";
|
|
4
4
|
import "./api-client-9mzrj2HY.js";
|
|
5
5
|
import "./formatting-Bacfde0I.js";
|
|
6
6
|
import "./issue-helpers-Cx6bFCUv.js";
|
|
7
7
|
import "./logging-Cxm8lQvg.js";
|
|
8
|
-
import { TOOL_HANDLERS } from "./tools-
|
|
8
|
+
import { TOOL_HANDLERS } from "./tools-DZzt3LcX.js";
|
|
9
9
|
import { describe, it } from "./dist-Bewd5-7a.js";
|
|
10
10
|
import { globalExpect } from "./vi.ClIskdbk-Dd6dTM3O.js";
|
|
11
11
|
|
|
@@ -41,7 +41,10 @@ describe("list_teams", () => {
|
|
|
41
41
|
accessToken: "access-token",
|
|
42
42
|
userId: "1",
|
|
43
43
|
organizationSlug: null
|
|
44
|
-
}, {
|
|
44
|
+
}, {
|
|
45
|
+
organizationSlug: "sentry-mcp-evals",
|
|
46
|
+
regionUrl: void 0
|
|
47
|
+
});
|
|
45
48
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
46
49
|
"# Teams in **sentry-mcp-evals**
|
|
47
50
|
|
|
@@ -57,7 +60,10 @@ describe("list_projects", () => {
|
|
|
57
60
|
accessToken: "access-token",
|
|
58
61
|
userId: "1",
|
|
59
62
|
organizationSlug: null
|
|
60
|
-
}, {
|
|
63
|
+
}, {
|
|
64
|
+
organizationSlug: "sentry-mcp-evals",
|
|
65
|
+
regionUrl: void 0
|
|
66
|
+
});
|
|
61
67
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
62
68
|
"# Projects in **sentry-mcp-evals**
|
|
63
69
|
|
|
@@ -77,7 +83,8 @@ describe("list_issues", () => {
|
|
|
77
83
|
organizationSlug: "sentry-mcp-evals",
|
|
78
84
|
projectSlug: "cloudflare-mcp",
|
|
79
85
|
query: void 0,
|
|
80
|
-
sortBy: "last_seen"
|
|
86
|
+
sortBy: "last_seen",
|
|
87
|
+
regionUrl: void 0
|
|
81
88
|
});
|
|
82
89
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
83
90
|
"# Issues in **sentry-mcp-evals/cloudflare-mcp**
|
|
@@ -115,7 +122,8 @@ describe("list_issues", () => {
|
|
|
115
122
|
organizationSlug: "sentry-mcp-evals",
|
|
116
123
|
projectSlug: void 0,
|
|
117
124
|
query: void 0,
|
|
118
|
-
sortBy: "last_seen"
|
|
125
|
+
sortBy: "last_seen",
|
|
126
|
+
regionUrl: void 0
|
|
119
127
|
});
|
|
120
128
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
121
129
|
"# Issues in **sentry-mcp-evals**
|
|
@@ -153,7 +161,8 @@ describe("list_releases", () => {
|
|
|
153
161
|
organizationSlug: null
|
|
154
162
|
}, {
|
|
155
163
|
organizationSlug: "sentry-mcp-evals",
|
|
156
|
-
projectSlug: void 0
|
|
164
|
+
projectSlug: void 0,
|
|
165
|
+
regionUrl: void 0
|
|
157
166
|
});
|
|
158
167
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
159
168
|
"# Releases in **sentry-mcp-evals**
|
|
@@ -181,7 +190,8 @@ describe("list_releases", () => {
|
|
|
181
190
|
organizationSlug: null
|
|
182
191
|
}, {
|
|
183
192
|
organizationSlug: "sentry-mcp-evals",
|
|
184
|
-
projectSlug: "cloudflare-mcp"
|
|
193
|
+
projectSlug: "cloudflare-mcp",
|
|
194
|
+
regionUrl: void 0
|
|
185
195
|
});
|
|
186
196
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
187
197
|
"# Releases in **sentry-mcp-evals/cloudflare-mcp**
|
|
@@ -211,7 +221,8 @@ describe("list_tags", () => {
|
|
|
211
221
|
organizationSlug: null
|
|
212
222
|
}, {
|
|
213
223
|
organizationSlug: "sentry-mcp-evals",
|
|
214
|
-
projectSlug: void 0
|
|
224
|
+
projectSlug: void 0,
|
|
225
|
+
regionUrl: void 0
|
|
215
226
|
});
|
|
216
227
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
217
228
|
"# Tags in **sentry-mcp-evals**
|
|
@@ -256,7 +267,8 @@ describe("search_errors", () => {
|
|
|
256
267
|
filename: void 0,
|
|
257
268
|
transaction: void 0,
|
|
258
269
|
query: void 0,
|
|
259
|
-
sortBy: "count"
|
|
270
|
+
sortBy: "count",
|
|
271
|
+
regionUrl: void 0
|
|
260
272
|
});
|
|
261
273
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
262
274
|
"# Errors in **sentry-mcp-evals**
|
|
@@ -291,7 +303,8 @@ describe("search_transactions", () => {
|
|
|
291
303
|
projectSlug: void 0,
|
|
292
304
|
transaction: void 0,
|
|
293
305
|
query: void 0,
|
|
294
|
-
sortBy: "duration"
|
|
306
|
+
sortBy: "duration",
|
|
307
|
+
regionUrl: void 0
|
|
295
308
|
});
|
|
296
309
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
297
310
|
"# Transactions in **sentry-mcp-evals**
|
|
@@ -333,7 +346,8 @@ describe("get_issue_summary", () => {
|
|
|
333
346
|
}, {
|
|
334
347
|
organizationSlug: "sentry-mcp-evals",
|
|
335
348
|
issueId: "CLOUDFLARE-MCP-41",
|
|
336
|
-
issueUrl: void 0
|
|
349
|
+
issueUrl: void 0,
|
|
350
|
+
regionUrl: void 0
|
|
337
351
|
});
|
|
338
352
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
339
353
|
"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**
|
|
@@ -360,7 +374,8 @@ describe("get_issue_summary", () => {
|
|
|
360
374
|
}, {
|
|
361
375
|
organizationSlug: void 0,
|
|
362
376
|
issueId: void 0,
|
|
363
|
-
issueUrl: "https://sentry-mcp-evals.sentry.io/issues/6507376925"
|
|
377
|
+
issueUrl: "https://sentry-mcp-evals.sentry.io/issues/6507376925",
|
|
378
|
+
regionUrl: void 0
|
|
364
379
|
});
|
|
365
380
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
366
381
|
"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**
|
|
@@ -389,7 +404,8 @@ describe("get_issue_details", () => {
|
|
|
389
404
|
}, {
|
|
390
405
|
organizationSlug: "sentry-mcp-evals",
|
|
391
406
|
issueId: "CLOUDFLARE-MCP-41",
|
|
392
|
-
issueUrl: void 0
|
|
407
|
+
issueUrl: void 0,
|
|
408
|
+
regionUrl: void 0
|
|
393
409
|
});
|
|
394
410
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
395
411
|
"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**
|
|
@@ -431,7 +447,8 @@ describe("get_issue_details", () => {
|
|
|
431
447
|
}, {
|
|
432
448
|
organizationSlug: void 0,
|
|
433
449
|
issueId: void 0,
|
|
434
|
-
issueUrl: "https://sentry-mcp-evals.sentry.io/issues/6507376925"
|
|
450
|
+
issueUrl: "https://sentry-mcp-evals.sentry.io/issues/6507376925",
|
|
451
|
+
regionUrl: void 0
|
|
435
452
|
});
|
|
436
453
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
437
454
|
"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**
|
|
@@ -474,7 +491,8 @@ describe("create_team", () => {
|
|
|
474
491
|
organizationSlug: null
|
|
475
492
|
}, {
|
|
476
493
|
organizationSlug: "sentry-mcp-evals",
|
|
477
|
-
name: "the-goats"
|
|
494
|
+
name: "the-goats",
|
|
495
|
+
regionUrl: void 0
|
|
478
496
|
});
|
|
479
497
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
480
498
|
"# New Team in **sentry-mcp-evals**
|
|
@@ -500,7 +518,8 @@ describe("create_project", () => {
|
|
|
500
518
|
organizationSlug: "sentry-mcp-evals",
|
|
501
519
|
teamSlug: "the-goats",
|
|
502
520
|
name: "cloudflare-mcp",
|
|
503
|
-
platform: "javascript"
|
|
521
|
+
platform: "javascript",
|
|
522
|
+
regionUrl: void 0
|
|
504
523
|
});
|
|
505
524
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
506
525
|
"# New Project in **sentry-mcp-evals**
|
|
@@ -528,7 +547,8 @@ describe("create_dsn", () => {
|
|
|
528
547
|
}, {
|
|
529
548
|
organizationSlug: "sentry-mcp-evals",
|
|
530
549
|
projectSlug: "cloudflare-mcp",
|
|
531
|
-
name: "Default"
|
|
550
|
+
name: "Default",
|
|
551
|
+
regionUrl: void 0
|
|
532
552
|
});
|
|
533
553
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
534
554
|
"# New DSN in **sentry-mcp-evals/cloudflare-mcp**
|
|
@@ -552,7 +572,8 @@ describe("list_dsn", () => {
|
|
|
552
572
|
organizationSlug: null
|
|
553
573
|
}, {
|
|
554
574
|
organizationSlug: "sentry-mcp-evals",
|
|
555
|
-
projectSlug: "cloudflare-mcp"
|
|
575
|
+
projectSlug: "cloudflare-mcp",
|
|
576
|
+
regionUrl: void 0
|
|
556
577
|
});
|
|
557
578
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
558
579
|
"# DSNs in **sentry-mcp-evals/cloudflare-mcp**
|
|
@@ -578,7 +599,8 @@ describe("begin_autofix", () => {
|
|
|
578
599
|
}, {
|
|
579
600
|
organizationSlug: "sentry-mcp-evals",
|
|
580
601
|
issueId: "PEATED-A8",
|
|
581
|
-
issueUrl: void 0
|
|
602
|
+
issueUrl: void 0,
|
|
603
|
+
regionUrl: void 0
|
|
582
604
|
});
|
|
583
605
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
584
606
|
"# Autofix Started for Issue PEATED-A8
|
|
@@ -605,7 +627,8 @@ describe("get_autofix_status", () => {
|
|
|
605
627
|
}, {
|
|
606
628
|
organizationSlug: "sentry-mcp-evals",
|
|
607
629
|
issueId: "PEATED-A8",
|
|
608
|
-
issueUrl: void 0
|
|
630
|
+
issueUrl: void 0,
|
|
631
|
+
regionUrl: void 0
|
|
609
632
|
});
|
|
610
633
|
globalExpect(result).toMatchInlineSnapshot(`
|
|
611
634
|
"# Autofix Status for Issue PEATED-A8
|
package/dist/tools.test.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tools.test.js","names":[],"sources":["../src/tools.test.ts"],"sourcesContent":["import { describe, it, expect } from \"vitest\";\nimport { TOOL_HANDLERS } from \"./tools\";\n\ndescribe(\"list_organizations\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_organizations;\n const result = await tool({\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n });\n expect(result).toMatchInlineSnapshot(`\n \"# Organizations\n\n ## **sentry-mcp-evals**\n\n **Web URL:** https://sentry.io/sentry-mcp-evals\n **Region URL:** https://us.sentry.io\n\n # Using this information\n\n - The organization's name is the identifier for the organization, and is used in many tools for \\`organizationSlug\\`.\n - If a tool supports passing in the \\`regionUrl\\`, you should also pass in the correct value there.\n \"\n `);\n });\n});\n\ndescribe(\"list_teams\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_teams;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Teams in **sentry-mcp-evals**\n\n - the-goats\n \"\n `);\n });\n});\n\ndescribe(\"list_projects\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_projects;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Projects in **sentry-mcp-evals**\n\n - **cloudflare-mcp**\n \"\n `);\n });\n});\n\ndescribe(\"list_issues\", () => {\n it(\"serializes with project\", async () => {\n const tool = TOOL_HANDLERS.list_issues;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n query: undefined,\n sortBy: \"last_seen\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issues in **sentry-mcp-evals/cloudflare-mcp**\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## CLOUDFLARE-MCP-42\n\n **Description**: Error: Tool list_issues is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-11T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-42\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about a specific issue by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n\n it(\"serializes without project\", async () => {\n const tool = TOOL_HANDLERS.list_issues;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n query: undefined,\n sortBy: \"last_seen\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issues in **sentry-mcp-evals**\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## CLOUDFLARE-MCP-42\n\n **Description**: Error: Tool list_issues is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-11T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-42\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about a specific issue by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n});\n\ndescribe(\"list_releases\", () => {\n it(\"works without project\", async () => {\n const tool = TOOL_HANDLERS.list_releases;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Releases in **sentry-mcp-evals**\n\n ## 8ce89484-0fec-4913-a2cd-e8e2d41dee36\n\n **Created**: 2025-04-13T19:54:21.764Z\n **First Event**: 2025-04-13T19:54:21.000Z\n **Last Event**: 2025-04-13T20:28:23.000Z\n **New Issues**: 0\n **Projects**: cloudflare-mcp\n\n # Using this information\n\n - You can reference the Release version in commit messages or documentation.\n - You can search for issues in a specific release using the \\`search_errors()\\` tool with the query \\`release:8ce89484-0fec-4913-a2cd-e8e2d41dee36\\`.\n \"\n `);\n });\n it(\"works with project\", async () => {\n const tool = TOOL_HANDLERS.list_releases;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Releases in **sentry-mcp-evals/cloudflare-mcp**\n\n ## 8ce89484-0fec-4913-a2cd-e8e2d41dee36\n\n **Created**: 2025-04-13T19:54:21.764Z\n **First Event**: 2025-04-13T19:54:21.000Z\n **Last Event**: 2025-04-13T20:28:23.000Z\n **New Issues**: 0\n **Projects**: cloudflare-mcp\n\n # Using this information\n\n - You can reference the Release version in commit messages or documentation.\n - You can search for issues in a specific release using the \\`search_errors()\\` tool with the query \\`release:8ce89484-0fec-4913-a2cd-e8e2d41dee36\\`.\n \"\n `);\n });\n});\n\ndescribe(\"list_tags\", () => {\n it(\"works\", async () => {\n const tool = TOOL_HANDLERS.list_tags;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Tags in **sentry-mcp-evals**\n\n - transaction\n - runtime.name\n - level\n - device\n - os\n - user\n - runtime\n - release\n - url\n - uptime_rule\n - server_name\n - browser\n - os.name\n - device.family\n - replayId\n - client_os.name\n - environment\n - service\n - browser.name\n\n # Using this information\n\n - You can reference tags in the \\`query\\` parameter of various tools: \\`tagName:tagValue\\`.\n \"\n `);\n });\n});\n\ndescribe(\"search_errors\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.search_errors;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n filename: undefined,\n transaction: undefined,\n query: undefined,\n sortBy: \"count\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Errors in **sentry-mcp-evals**\n\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Issue ID**: CLOUDFLARE-MCP-41\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n **Project**: test-suite\n **Last Seen**: 2025-04-07T12:23:39+00:00\n **Occurrences**: 2\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about an error by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n});\n\ndescribe(\"search_transactions\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.search_transactions;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n transaction: undefined,\n query: undefined,\n sortBy: \"duration\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Transactions in **sentry-mcp-evals**\n\n\n ## GET /trpc/bottleList\n\n **Span ID**: 07752c6aeb027c8f\n **Trace ID**: 6a477f5b0f31ef7b6b9b5e1dea66c91d\n **Span Operation**: http.server\n **Span Description**: GET /trpc/bottleList\n **Duration**: 12\n **Timestamp**: 2025-04-13T14:19:18+00:00\n **Project**: peated\n **URL**: https://sentry-mcp-evals.sentry.io/explore/traces/trace/6a477f5b0f31ef7b6b9b5e1dea66c91d\n\n ## GET /trpc/bottleList\n\n **Span ID**: 7ab5edf5b3ba42c9\n **Trace ID**: 54177131c7b192a446124daba3136045\n **Span Operation**: http.server\n **Span Description**: GET /trpc/bottleList\n **Duration**: 18\n **Timestamp**: 2025-04-13T14:19:17+00:00\n **Project**: peated\n **URL**: https://sentry-mcp-evals.sentry.io/explore/traces/trace/54177131c7b192a446124daba3136045\n\n \"\n `);\n });\n});\n\ndescribe(\"get_issue_summary\", () => {\n it(\"serializes with issueId\", async () => {\n const tool = TOOL_HANDLERS.get_issue_summary;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"CLOUDFLARE-MCP-41\",\n issueUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **Occurrences**: 25\n **Users Impacted**: 1\n **Status**: unresolved\n **Platform**: javascript\n **Project**: CLOUDFLARE-MCP\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n \"\n `);\n });\n\n it(\"serializes with issueUrl\", async () => {\n const tool = TOOL_HANDLERS.get_issue_summary;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: undefined,\n issueId: undefined,\n issueUrl: \"https://sentry-mcp-evals.sentry.io/issues/6507376925\",\n },\n );\n\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **Occurrences**: 25\n **Users Impacted**: 1\n **Status**: unresolved\n **Platform**: javascript\n **Project**: CLOUDFLARE-MCP\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n \"\n `);\n });\n});\n\ndescribe(\"get_issue_details\", () => {\n it(\"serializes with issueId\", async () => {\n const tool = TOOL_HANDLERS.get_issue_details;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"CLOUDFLARE-MCP-41\",\n issueUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## Event Specifics\n\n **Occurred At**: 2025-04-08T21:15:04.000Z\n **Error:**\n \\`\\`\\`\n Error: Tool list_organizations is already registered\n \\`\\`\\`\n\n **Stacktrace:**\n \\`\\`\\`\n index.js:7809:27\n index.js:8029:24 (OAuthProviderImpl.fetch)\n index.js:19631:28 (Object.fetch)\n \\`\\`\\`\n\n # Using this information\n\n - You can reference the IssueID in commit messages (e.g. \\`Fixes CLOUDFLARE-MCP-41\\`) to automatically close the issue when the commit is merged.\n - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.\n \"\n `);\n });\n\n it(\"serializes with issueUrl\", async () => {\n const tool = TOOL_HANDLERS.get_issue_details;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: undefined,\n issueId: undefined,\n issueUrl: \"https://sentry-mcp-evals.sentry.io/issues/6507376925\",\n },\n );\n\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## Event Specifics\n\n **Occurred At**: 2025-04-08T21:15:04.000Z\n **Error:**\n \\`\\`\\`\n Error: Tool list_organizations is already registered\n \\`\\`\\`\n\n **Stacktrace:**\n \\`\\`\\`\n index.js:7809:27\n index.js:8029:24 (OAuthProviderImpl.fetch)\n index.js:19631:28 (Object.fetch)\n \\`\\`\\`\n\n # Using this information\n\n - You can reference the IssueID in commit messages (e.g. \\`Fixes 6507376925\\`) to automatically close the issue when the commit is merged.\n - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.\n \"\n `);\n });\n});\n\ndescribe(\"create_team\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_team;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n name: \"the-goats\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New Team in **sentry-mcp-evals**\n\n **ID**: 4509109078196224\n **Slug**: the-goats\n **Name**: the-goats\n # Using this information\n\n - You should always inform the user of the Team Slug value.\n \"\n `);\n });\n});\n\ndescribe(\"create_project\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_project;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n teamSlug: \"the-goats\",\n name: \"cloudflare-mcp\",\n platform: \"javascript\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New Project in **sentry-mcp-evals**\n\n **ID**: 4509109104082945\n **Slug**: cloudflare-mcp\n **Name**: cloudflare-mcp\n **SENTRY_DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n\n # Using this information\n\n - You can reference the **SENTRY_DSN** value to initialize Sentry's SDKs.\n - You should always inform the user of the **SENTRY_DSN** and Project Slug values.\n \"\n `);\n });\n});\n\ndescribe(\"create_dsn\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_dsn;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n name: \"Default\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New DSN in **sentry-mcp-evals/cloudflare-mcp**\n\n **DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n **Name**: Default\n\n # Using this information\n\n - The \\`SENTRY_DSN\\` value is a URL that you can use to initialize Sentry's SDKs.\n \"\n `);\n });\n});\n\ndescribe(\"list_dsn\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_dsns;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# DSNs in **sentry-mcp-evals/cloudflare-mcp**\n\n ## Default\n **ID**: d20df0a1ab5031c7f3c7edca9c02814d\n **DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n\n # Using this information\n\n - The \\`SENTRY_DSN\\` value is a URL that you can use to initialize Sentry's SDKs.\n \"\n `);\n });\n});\n\ndescribe(\"begin_autofix\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.begin_autofix;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"PEATED-A8\",\n issueUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Autofix Started for Issue PEATED-A8\n\n **Run ID:**: 123\n\n This operation may take some time, so you should call \\`get_autofix_status()\\` to check the status of the analysis, and repeat the process until its finished.\n\n You should also inform the user that the operation may take some time, and give them updates whenever you check the status of the operation..\n\n \\`\\`\\`\n get_autofix_status(organizationSlug=\"sentry-mcp-evals\", issueId=\"PEATED-A8\")\n \\`\\`\\`\"\n `);\n });\n});\n\ndescribe(\"get_autofix_status\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.get_autofix_status;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"PEATED-A8\",\n issueUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Autofix Status for Issue PEATED-A8\n\n ## Analyzing the Issue\n\n **The \\`bottleById\\` query fails because the input ID (3216) doesn't exist in the database.\n **\n The exception details show that the \\`input\\` value at the time of the \\`TRPCError\\` in \\`bottleById.ts\\` was 3216, and the query likely failed because a bottle with ID 3216 was not found in the database.\n\n \\`\\`\\`\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n\n **However, the request also includes a different ID (16720) for \\`bottlePriceList\\`.\n **\n The root cause is likely a mismatch of input IDs within the batched TRPC request, where \\`bottlePriceList\\` expects bottle ID 16720, but \\`bottleById\\` receives a different ID (3216) leading to the \"Bottle not found\" error.\n\n \\`\\`\\`\n GET http://api.peated.com/trpc/bottlePriceList,bottleById\n \\`\\`\\`\n\n \\`\\`\\`json\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n \\`\\`\\`\n TRPCError: Bottle not found. (occurred in: GET /trpc/bottlePriceList,bottleById)\n \\`\\`\\`\n\n\n **This suggests a data consistency issue or incorrect client-side request.\n **\n The \\`TRPCError\\` originates from \\`bottleById.ts\\` with the input value being \\`3216\\`, indicating the procedure failed to find a bottle with that specific ID in the database.\n\n \\`\\`\\`\n <anonymous> in file /app/apps/server/src/trpc/routes/bottleById.ts [Line 33, column 13] (In app)\n .select({\n ...getTableColumns(bottles),\n })\n .from(bottleTombstones)\n .innerJoin(bottles, eq(bottleTombstones.newBottleId, bottles.id))\n .where(eq(bottleTombstones.bottleId, input));\n if (!bottle) {\n throw new TRPCError({ <-- SUSPECT LINE\n message: \"Bottle not found.\",\n code: \"NOT_FOUND\",\n });\n }\n }\n\n const createdBy = await db.query.users.findFirst({\n ---\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n\n\n ## Root Cause Analysis\n\n **The client initiates a batched TRPC request to the \\`/trpc/bottlePriceList,bottleById\\` endpoint, intending to fetch both the price list and details for a specific bottle.**\n\n This is the entry point where the client requests data from two different procedures in a single HTTP request. The server needs to correctly route and process the parameters for each procedure.\n\n **The TRPC server receives the batched request and begins processing the \\`bottlePriceList\\` procedure, intending to fetch the price list for bottle ID 16720.**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottlePriceList.ts\n .input(z.object({ bottle: z.number(), onlyValid: z.boolean().optional() }))\n .query(async function ({ input, ctx }) {\n const [bottle] = await db.select().from(bottles).where(eq(bottles.id, input.bottle));\n if (!bottle) { ... }\n \\`\\`\\`\n This procedure expects a 'bottle' parameter in the input, which is used to query the database.\n\n **The TRPC server also processes the \\`bottleById\\` procedure, but due to a parameter mapping issue or client-side error, it receives bottle ID 3216 as input instead of 16720.**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottleById.ts\n export default publicProcedure.input(z.number()).query(async function ({ input, ctx }) {\n let [bottle] = await db.select().from(bottles).where(eq(bottles.id, input));\n if (!bottle) { ... }\n \\`\\`\\`\n This procedure expects a numerical ID as input to find the bottle.\n\n **The \\`bottleById\\` procedure queries the \\`bottles\\` table for a bottle with ID 3216, but no such bottle exists.**\n\n The database query returns no results because bottle ID 3216 is not present in the \\`bottles\\` table.\n\n **The \\`bottleById\\` procedure then checks the \\`bottleTombstones\\` table to see if bottle ID 3216 has been tombstoned (redirected to a new ID), but no such tombstone exists.**\n\n The query to \\`bottleTombstones\\` also returns no results, indicating that bottle ID 3216 has not been redirected.\n\n **Since the \\`bottleById\\` procedure cannot find a bottle with ID 3216 in either the \\`bottles\\` or \\`bottleTombstones\\` tables, it throws a \\`TRPCError\\` with the message \"Bottle not found.\"**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottleById.ts\n if (!bottle) {\n throw new TRPCError({ message: \"Bottle not found.\", code: \"NOT_FOUND\" });\n }\n \\`\\`\\`\n This is where the error is thrown, indicating that the bottle could not be found.\n\n\n ## Planning Solution\n\n **The discrepancy between inputs suggests a potential issue with batch request handling.\n **\n The \\`TRPCError\\` occurred in \\`bottleById.ts\\` with an input of \\`3216\\`, while the request was initiated with a bottle ID of \\`16720\\`, indicating a mismatch in the bottle ID being processed.\n\n \\`\\`\\`\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n \\`\\`\\`\n GET http://api.peated.com/trpc/bottlePriceList,bottleById\n \\`\\`\\`\n\n\n **The client-side batch request construction is the most likely source of error.\n **\n The discrepancy between the bottle ID in the error message (16720) and the ID being processed (3216) strongly suggests a client-side parameter mapping issue in the batched TRPC request.\n\n To fix this, I propose the following steps:\n\n 1. **Inspect the Client-Side Code:** Identify the code responsible for constructing the TRPC batch request to \\`/trpc/bottlePriceList,bottleById\\`.\n\n 2. **Verify Parameter Mapping:** Ensure that both \\`bottlePriceList\\` and \\`bottleById\\` are receiving the correct bottle ID (which should be 16720 in this case).\n\n 3. **Correct Parameter Assignment:** If the parameters are being incorrectly assigned, modify the client-side code to ensure that both procedures receive the same, correct bottle ID.\n\n 4. **Add Logging (Client-Side):** Add temporary logging to the client-side code to confirm the parameters being sent to each procedure in the batch request. This will help verify the fix.\n\n \\`\\`\\`typescript\n // Example logging (add to the client-side code where the batch request is created)\n console.log(\"bottlePriceList input:\", { bottle: 16720 }); // Replace 16720 with the actual ID\n console.log(\"bottleById input:\", { bottle: 16720 }); // Replace 16720 with the actual ID\n \\`\\`\\`\n\n 5. **Test the Fix:** After applying the fix, test the affected functionality to ensure that the \"Bottle not found\" error is resolved and that both procedures are working correctly.\n\n 6. **Remove Logging:** Once the fix is verified, remove the temporary logging.\n\n This approach directly addresses the most likely cause of the issue and provides a clear path to resolution.\n\n\n **Ensuring consistent bottle IDs will likely resolve this inconsistency.\n **\n The error message references bottle ID 16720, but the exception details show the procedure was actually processing ID 3216, indicating a parameter mismatch in the batch request.\n\n To fix this, I recommend the following steps:\n\n 1. **Client-Side Investigation**:\n\n * Examine the client-side code where the TRPC batch request is constructed.\n * Verify that the same \\`bottleId\\` parameter is being passed to both \\`bottlePriceList\\` and \\`bottleById\\` procedures.\n * If the IDs are being passed correctly, inspect the network request payload to confirm the correct structure of the batched request.\n\n \\`\\`\\`typescript\n // Example (Hypothetical) Client-Side Code\n const bottleId = 16720; // Example bottle ID\n\n // Ensure both procedures receive the same bottleId\n const [priceList, bottleDetails] = await trpc.batch(() => [\n trpc.bottlePriceList.fetch({ bottle: bottleId }),\n trpc.bottleById.fetch(bottleId),\n ]);\n \\`\\`\\`\n\n 2. **Server-Side Logging (Temporary)**:\n\n * Add temporary logging to both \\`bottlePriceList\\` and \\`bottleById\\` procedures to log the received \\`input\\` value.\n * This will help confirm whether the server is receiving the correct IDs from the client.\n * **Important**: Remove these logs after debugging to avoid unnecessary overhead.\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottlePriceList.ts\n export default publicProcedure\n .input(\n z.object({\n bottle: z.number(),\n onlyValid: z.boolean().optional(),\n }),\n )\n .query(async function ({ input, ctx }) {\n console.log(\"bottlePriceList input:\", input); // Add this line\n // ... rest of the code\n });\n\n // apps/server/src/trpc/routes/bottleById.ts\n export default publicProcedure.input(z.number()).query(async function ({\n input,\n ctx,\n }) {\n console.log(\"bottleById input:\", input); // Add this line\n // ... rest of the code\n });\n \\`\\`\\`\n\n 3. **TRPC Batch Request Configuration**:\n\n * Review the TRPC batch link configuration on the client-side.\n * Ensure that the batching logic is correctly mapping parameters to the corresponding procedures.\n * If using a custom batching implementation, verify its correctness.\n\n 4. **Data Integrity Check**:\n\n * If the client-side code appears correct, investigate whether bottle ID 3216 should exist in the database.\n * Check the \\`bottles\\` table and \\`bottleTombstones\\` table for any entries related to bottle ID 3216.\n * If the bottle should exist but is missing, investigate potential data deletion or migration issues.\n\n 5. **Tombstone Logic**:\n\n * Double-check the logic for creating and using tombstones.\n * Ensure that when a bottle is deleted, a tombstone entry is created correctly, pointing to the new bottle (if any).\n\n 6. **Error Handling**:\n\n * While this isn't the primary fix, consider improving the error message in \\`bottleById.ts\\` to include more context.\n * Include the original requested bottle ID (if available) in the error message to aid debugging.\n\n 7. **Client-Side Retries**:\n\n * Implement a retry mechanism on the client-side for TRPC requests.\n * If a \"Bottle not found\" error occurs, retry the request a few times before giving up. This can help mitigate transient issues.\n\n By following these steps, you should be able to identify the root cause of the parameter mismatch and implement a fix that ensures consistent bottle IDs are passed to both TRPC procedures in the batch request.\n\n\n\n ## Solution\n\n Consolidate bottle and price data fetching into a single batched TRPC request using \\`Promise.all\\` to ensure ID consistency.\n\n **Create a shared utility function to fetch bottle details and price data together.**\n \\`\\`\\`typescript\n // In a shared utility function or component\n export async function getBottleWithPrices(bottleId: number) {\n const trpcClient = await getTrpcClient();\n \n // Use Promise.all to ensure both requests are part of the same batch\n // and receive the same parameters\n const [bottle, priceList] = await Promise.all([\n trpcClient.bottleById.fetch(bottleId),\n trpcClient.bottlePriceList.fetch({ bottle: bottleId }),\n ]);\n \n return { bottle, priceList };\n }\n \\`\\`\\`\n This code creates a function that uses \\`Promise.all\\` to fetch both bottle details and price data concurrently. This ensures that both TRPC procedures are part of the same batch and receive the same \\`bottleId\\`.\n\n **Modify the page components to use the shared utility function.**\n \\`\\`\\`typescript\n // Then in the page components:\n const { bottle, priceList } = await getBottleWithPrices(Number(bottleId));\n \\`\\`\\`\n This code replaces the separate calls to \\`bottleById\\` and \\`bottlePriceList\\` with a single call to the \\`getBottleWithPrices\\` function, ensuring that both components receive data for the same bottle.\n\n **Add a unit test that reproduces the issue.**\n null\n\n\n \"\n `);\n });\n});\n"],"mappings":";;;;;;;;;;;;AAGA,SAAS,sBAAsB,MAAM;AACnC,IAAG,cAAc,YAAY;EAC3B,MAAM,OAAO,cAAc;EAC3B,MAAM,SAAS,MAAM,KAAK;GACx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AAY;EAC3B,MAAM,OAAO,cAAc;EAC3B,MAAM,SAAS,MAAM,KACnB;GACE,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,GACD;GACE,kBAAkB;GAClB,SAAS;GACT;EACD,EACF;AACD,eAAO,OAAO,CAAC,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAmRpC;CACH,EAAC;AACH,EAAC"}
|
|
1
|
+
{"version":3,"file":"tools.test.js","names":[],"sources":["../src/tools.test.ts"],"sourcesContent":["import { describe, it, expect } from \"vitest\";\nimport { TOOL_HANDLERS } from \"./tools\";\n\ndescribe(\"list_organizations\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_organizations;\n const result = await tool({\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n });\n expect(result).toMatchInlineSnapshot(`\n \"# Organizations\n\n ## **sentry-mcp-evals**\n\n **Web URL:** https://sentry.io/sentry-mcp-evals\n **Region URL:** https://us.sentry.io\n\n # Using this information\n\n - The organization's name is the identifier for the organization, and is used in many tools for \\`organizationSlug\\`.\n - If a tool supports passing in the \\`regionUrl\\`, you should also pass in the correct value there.\n \"\n `);\n });\n});\n\ndescribe(\"list_teams\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_teams;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Teams in **sentry-mcp-evals**\n\n - the-goats\n \"\n `);\n });\n});\n\ndescribe(\"list_projects\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_projects;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Projects in **sentry-mcp-evals**\n\n - **cloudflare-mcp**\n \"\n `);\n });\n});\n\ndescribe(\"list_issues\", () => {\n it(\"serializes with project\", async () => {\n const tool = TOOL_HANDLERS.list_issues;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n query: undefined,\n sortBy: \"last_seen\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issues in **sentry-mcp-evals/cloudflare-mcp**\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## CLOUDFLARE-MCP-42\n\n **Description**: Error: Tool list_issues is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-11T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-42\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about a specific issue by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n\n it(\"serializes without project\", async () => {\n const tool = TOOL_HANDLERS.list_issues;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n query: undefined,\n sortBy: \"last_seen\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issues in **sentry-mcp-evals**\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## CLOUDFLARE-MCP-42\n\n **Description**: Error: Tool list_issues is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-11T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-42\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about a specific issue by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n});\n\ndescribe(\"list_releases\", () => {\n it(\"works without project\", async () => {\n const tool = TOOL_HANDLERS.list_releases;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Releases in **sentry-mcp-evals**\n\n ## 8ce89484-0fec-4913-a2cd-e8e2d41dee36\n\n **Created**: 2025-04-13T19:54:21.764Z\n **First Event**: 2025-04-13T19:54:21.000Z\n **Last Event**: 2025-04-13T20:28:23.000Z\n **New Issues**: 0\n **Projects**: cloudflare-mcp\n\n # Using this information\n\n - You can reference the Release version in commit messages or documentation.\n - You can search for issues in a specific release using the \\`search_errors()\\` tool with the query \\`release:8ce89484-0fec-4913-a2cd-e8e2d41dee36\\`.\n \"\n `);\n });\n it(\"works with project\", async () => {\n const tool = TOOL_HANDLERS.list_releases;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Releases in **sentry-mcp-evals/cloudflare-mcp**\n\n ## 8ce89484-0fec-4913-a2cd-e8e2d41dee36\n\n **Created**: 2025-04-13T19:54:21.764Z\n **First Event**: 2025-04-13T19:54:21.000Z\n **Last Event**: 2025-04-13T20:28:23.000Z\n **New Issues**: 0\n **Projects**: cloudflare-mcp\n\n # Using this information\n\n - You can reference the Release version in commit messages or documentation.\n - You can search for issues in a specific release using the \\`search_errors()\\` tool with the query \\`release:8ce89484-0fec-4913-a2cd-e8e2d41dee36\\`.\n \"\n `);\n });\n});\n\ndescribe(\"list_tags\", () => {\n it(\"works\", async () => {\n const tool = TOOL_HANDLERS.list_tags;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Tags in **sentry-mcp-evals**\n\n - transaction\n - runtime.name\n - level\n - device\n - os\n - user\n - runtime\n - release\n - url\n - uptime_rule\n - server_name\n - browser\n - os.name\n - device.family\n - replayId\n - client_os.name\n - environment\n - service\n - browser.name\n\n # Using this information\n\n - You can reference tags in the \\`query\\` parameter of various tools: \\`tagName:tagValue\\`.\n \"\n `);\n });\n});\n\ndescribe(\"search_errors\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.search_errors;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n filename: undefined,\n transaction: undefined,\n query: undefined,\n sortBy: \"count\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Errors in **sentry-mcp-evals**\n\n\n ## CLOUDFLARE-MCP-41\n\n **Description**: Error: Tool list_organizations is already registered\n **Issue ID**: CLOUDFLARE-MCP-41\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n **Project**: test-suite\n **Last Seen**: 2025-04-07T12:23:39+00:00\n **Occurrences**: 2\n\n # Using this information\n\n - You can reference the Issue ID in commit messages (e.g. \\`Fixes <issueID>\\`) to automatically close the issue when the commit is merged.\n - You can get more details about an error by using the tool: \\`get_issue_details(organizationSlug=\"sentry-mcp-evals\", issueId=<issueID>)\\`\n \"\n `);\n });\n});\n\ndescribe(\"search_transactions\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.search_transactions;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: undefined,\n transaction: undefined,\n query: undefined,\n sortBy: \"duration\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Transactions in **sentry-mcp-evals**\n\n\n ## GET /trpc/bottleList\n\n **Span ID**: 07752c6aeb027c8f\n **Trace ID**: 6a477f5b0f31ef7b6b9b5e1dea66c91d\n **Span Operation**: http.server\n **Span Description**: GET /trpc/bottleList\n **Duration**: 12\n **Timestamp**: 2025-04-13T14:19:18+00:00\n **Project**: peated\n **URL**: https://sentry-mcp-evals.sentry.io/explore/traces/trace/6a477f5b0f31ef7b6b9b5e1dea66c91d\n\n ## GET /trpc/bottleList\n\n **Span ID**: 7ab5edf5b3ba42c9\n **Trace ID**: 54177131c7b192a446124daba3136045\n **Span Operation**: http.server\n **Span Description**: GET /trpc/bottleList\n **Duration**: 18\n **Timestamp**: 2025-04-13T14:19:17+00:00\n **Project**: peated\n **URL**: https://sentry-mcp-evals.sentry.io/explore/traces/trace/54177131c7b192a446124daba3136045\n\n \"\n `);\n });\n});\n\ndescribe(\"get_issue_summary\", () => {\n it(\"serializes with issueId\", async () => {\n const tool = TOOL_HANDLERS.get_issue_summary;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"CLOUDFLARE-MCP-41\",\n issueUrl: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **Occurrences**: 25\n **Users Impacted**: 1\n **Status**: unresolved\n **Platform**: javascript\n **Project**: CLOUDFLARE-MCP\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n \"\n `);\n });\n\n it(\"serializes with issueUrl\", async () => {\n const tool = TOOL_HANDLERS.get_issue_summary;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: undefined,\n issueId: undefined,\n issueUrl: \"https://sentry-mcp-evals.sentry.io/issues/6507376925\",\n regionUrl: undefined,\n },\n );\n\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **Occurrences**: 25\n **Users Impacted**: 1\n **Status**: unresolved\n **Platform**: javascript\n **Project**: CLOUDFLARE-MCP\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n \"\n `);\n });\n});\n\ndescribe(\"get_issue_details\", () => {\n it(\"serializes with issueId\", async () => {\n const tool = TOOL_HANDLERS.get_issue_details;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"CLOUDFLARE-MCP-41\",\n issueUrl: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## Event Specifics\n\n **Occurred At**: 2025-04-08T21:15:04.000Z\n **Error:**\n \\`\\`\\`\n Error: Tool list_organizations is already registered\n \\`\\`\\`\n\n **Stacktrace:**\n \\`\\`\\`\n index.js:7809:27\n index.js:8029:24 (OAuthProviderImpl.fetch)\n index.js:19631:28 (Object.fetch)\n \\`\\`\\`\n\n # Using this information\n\n - You can reference the IssueID in commit messages (e.g. \\`Fixes CLOUDFLARE-MCP-41\\`) to automatically close the issue when the commit is merged.\n - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.\n \"\n `);\n });\n\n it(\"serializes with issueUrl\", async () => {\n const tool = TOOL_HANDLERS.get_issue_details;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: undefined,\n issueId: undefined,\n issueUrl: \"https://sentry-mcp-evals.sentry.io/issues/6507376925\",\n regionUrl: undefined,\n },\n );\n\n expect(result).toMatchInlineSnapshot(`\n \"# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**\n\n **Description**: Error: Tool list_organizations is already registered\n **Culprit**: Object.fetch(index)\n **First Seen**: 2025-04-03T22:51:19.403Z\n **Last Seen**: 2025-04-12T11:34:11.000Z\n **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41\n\n ## Event Specifics\n\n **Occurred At**: 2025-04-08T21:15:04.000Z\n **Error:**\n \\`\\`\\`\n Error: Tool list_organizations is already registered\n \\`\\`\\`\n\n **Stacktrace:**\n \\`\\`\\`\n index.js:7809:27\n index.js:8029:24 (OAuthProviderImpl.fetch)\n index.js:19631:28 (Object.fetch)\n \\`\\`\\`\n\n # Using this information\n\n - You can reference the IssueID in commit messages (e.g. \\`Fixes 6507376925\\`) to automatically close the issue when the commit is merged.\n - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.\n \"\n `);\n });\n});\n\ndescribe(\"create_team\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_team;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n name: \"the-goats\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New Team in **sentry-mcp-evals**\n\n **ID**: 4509109078196224\n **Slug**: the-goats\n **Name**: the-goats\n # Using this information\n\n - You should always inform the user of the Team Slug value.\n \"\n `);\n });\n});\n\ndescribe(\"create_project\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_project;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n teamSlug: \"the-goats\",\n name: \"cloudflare-mcp\",\n platform: \"javascript\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New Project in **sentry-mcp-evals**\n\n **ID**: 4509109104082945\n **Slug**: cloudflare-mcp\n **Name**: cloudflare-mcp\n **SENTRY_DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n\n # Using this information\n\n - You can reference the **SENTRY_DSN** value to initialize Sentry's SDKs.\n - You should always inform the user of the **SENTRY_DSN** and Project Slug values.\n \"\n `);\n });\n});\n\ndescribe(\"create_dsn\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.create_dsn;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n name: \"Default\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# New DSN in **sentry-mcp-evals/cloudflare-mcp**\n\n **DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n **Name**: Default\n\n # Using this information\n\n - The \\`SENTRY_DSN\\` value is a URL that you can use to initialize Sentry's SDKs.\n \"\n `);\n });\n});\n\ndescribe(\"list_dsn\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.list_dsns;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n projectSlug: \"cloudflare-mcp\",\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# DSNs in **sentry-mcp-evals/cloudflare-mcp**\n\n ## Default\n **ID**: d20df0a1ab5031c7f3c7edca9c02814d\n **DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945\n\n # Using this information\n\n - The \\`SENTRY_DSN\\` value is a URL that you can use to initialize Sentry's SDKs.\n \"\n `);\n });\n});\n\ndescribe(\"begin_autofix\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.begin_autofix;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"PEATED-A8\",\n issueUrl: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Autofix Started for Issue PEATED-A8\n\n **Run ID:**: 123\n\n This operation may take some time, so you should call \\`get_autofix_status()\\` to check the status of the analysis, and repeat the process until its finished.\n\n You should also inform the user that the operation may take some time, and give them updates whenever you check the status of the operation..\n\n \\`\\`\\`\n get_autofix_status(organizationSlug=\"sentry-mcp-evals\", issueId=\"PEATED-A8\")\n \\`\\`\\`\"\n `);\n });\n});\n\ndescribe(\"get_autofix_status\", () => {\n it(\"serializes\", async () => {\n const tool = TOOL_HANDLERS.get_autofix_status;\n const result = await tool(\n {\n accessToken: \"access-token\",\n userId: \"1\",\n organizationSlug: null,\n },\n {\n organizationSlug: \"sentry-mcp-evals\",\n issueId: \"PEATED-A8\",\n issueUrl: undefined,\n regionUrl: undefined,\n },\n );\n expect(result).toMatchInlineSnapshot(`\n \"# Autofix Status for Issue PEATED-A8\n\n ## Analyzing the Issue\n\n **The \\`bottleById\\` query fails because the input ID (3216) doesn't exist in the database.\n **\n The exception details show that the \\`input\\` value at the time of the \\`TRPCError\\` in \\`bottleById.ts\\` was 3216, and the query likely failed because a bottle with ID 3216 was not found in the database.\n\n \\`\\`\\`\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n\n **However, the request also includes a different ID (16720) for \\`bottlePriceList\\`.\n **\n The root cause is likely a mismatch of input IDs within the batched TRPC request, where \\`bottlePriceList\\` expects bottle ID 16720, but \\`bottleById\\` receives a different ID (3216) leading to the \"Bottle not found\" error.\n\n \\`\\`\\`\n GET http://api.peated.com/trpc/bottlePriceList,bottleById\n \\`\\`\\`\n\n \\`\\`\\`json\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n \\`\\`\\`\n TRPCError: Bottle not found. (occurred in: GET /trpc/bottlePriceList,bottleById)\n \\`\\`\\`\n\n\n **This suggests a data consistency issue or incorrect client-side request.\n **\n The \\`TRPCError\\` originates from \\`bottleById.ts\\` with the input value being \\`3216\\`, indicating the procedure failed to find a bottle with that specific ID in the database.\n\n \\`\\`\\`\n <anonymous> in file /app/apps/server/src/trpc/routes/bottleById.ts [Line 33, column 13] (In app)\n .select({\n ...getTableColumns(bottles),\n })\n .from(bottleTombstones)\n .innerJoin(bottles, eq(bottleTombstones.newBottleId, bottles.id))\n .where(eq(bottleTombstones.bottleId, input));\n if (!bottle) {\n throw new TRPCError({ <-- SUSPECT LINE\n message: \"Bottle not found.\",\n code: \"NOT_FOUND\",\n });\n }\n }\n\n const createdBy = await db.query.users.findFirst({\n ---\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n\n\n ## Root Cause Analysis\n\n **The client initiates a batched TRPC request to the \\`/trpc/bottlePriceList,bottleById\\` endpoint, intending to fetch both the price list and details for a specific bottle.**\n\n This is the entry point where the client requests data from two different procedures in a single HTTP request. The server needs to correctly route and process the parameters for each procedure.\n\n **The TRPC server receives the batched request and begins processing the \\`bottlePriceList\\` procedure, intending to fetch the price list for bottle ID 16720.**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottlePriceList.ts\n .input(z.object({ bottle: z.number(), onlyValid: z.boolean().optional() }))\n .query(async function ({ input, ctx }) {\n const [bottle] = await db.select().from(bottles).where(eq(bottles.id, input.bottle));\n if (!bottle) { ... }\n \\`\\`\\`\n This procedure expects a 'bottle' parameter in the input, which is used to query the database.\n\n **The TRPC server also processes the \\`bottleById\\` procedure, but due to a parameter mapping issue or client-side error, it receives bottle ID 3216 as input instead of 16720.**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottleById.ts\n export default publicProcedure.input(z.number()).query(async function ({ input, ctx }) {\n let [bottle] = await db.select().from(bottles).where(eq(bottles.id, input));\n if (!bottle) { ... }\n \\`\\`\\`\n This procedure expects a numerical ID as input to find the bottle.\n\n **The \\`bottleById\\` procedure queries the \\`bottles\\` table for a bottle with ID 3216, but no such bottle exists.**\n\n The database query returns no results because bottle ID 3216 is not present in the \\`bottles\\` table.\n\n **The \\`bottleById\\` procedure then checks the \\`bottleTombstones\\` table to see if bottle ID 3216 has been tombstoned (redirected to a new ID), but no such tombstone exists.**\n\n The query to \\`bottleTombstones\\` also returns no results, indicating that bottle ID 3216 has not been redirected.\n\n **Since the \\`bottleById\\` procedure cannot find a bottle with ID 3216 in either the \\`bottles\\` or \\`bottleTombstones\\` tables, it throws a \\`TRPCError\\` with the message \"Bottle not found.\"**\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottleById.ts\n if (!bottle) {\n throw new TRPCError({ message: \"Bottle not found.\", code: \"NOT_FOUND\" });\n }\n \\`\\`\\`\n This is where the error is thrown, indicating that the bottle could not be found.\n\n\n ## Planning Solution\n\n **The discrepancy between inputs suggests a potential issue with batch request handling.\n **\n The \\`TRPCError\\` occurred in \\`bottleById.ts\\` with an input of \\`3216\\`, while the request was initiated with a bottle ID of \\`16720\\`, indicating a mismatch in the bottle ID being processed.\n\n \\`\\`\\`\n Variable values at the time of the exception::\n {\n \"input\": 3216\n }\n \\`\\`\\`\n\n \\`\\`\\`\n GET http://api.peated.com/trpc/bottlePriceList,bottleById\n \\`\\`\\`\n\n\n **The client-side batch request construction is the most likely source of error.\n **\n The discrepancy between the bottle ID in the error message (16720) and the ID being processed (3216) strongly suggests a client-side parameter mapping issue in the batched TRPC request.\n\n To fix this, I propose the following steps:\n\n 1. **Inspect the Client-Side Code:** Identify the code responsible for constructing the TRPC batch request to \\`/trpc/bottlePriceList,bottleById\\`.\n\n 2. **Verify Parameter Mapping:** Ensure that both \\`bottlePriceList\\` and \\`bottleById\\` are receiving the correct bottle ID (which should be 16720 in this case).\n\n 3. **Correct Parameter Assignment:** If the parameters are being incorrectly assigned, modify the client-side code to ensure that both procedures receive the same, correct bottle ID.\n\n 4. **Add Logging (Client-Side):** Add temporary logging to the client-side code to confirm the parameters being sent to each procedure in the batch request. This will help verify the fix.\n\n \\`\\`\\`typescript\n // Example logging (add to the client-side code where the batch request is created)\n console.log(\"bottlePriceList input:\", { bottle: 16720 }); // Replace 16720 with the actual ID\n console.log(\"bottleById input:\", { bottle: 16720 }); // Replace 16720 with the actual ID\n \\`\\`\\`\n\n 5. **Test the Fix:** After applying the fix, test the affected functionality to ensure that the \"Bottle not found\" error is resolved and that both procedures are working correctly.\n\n 6. **Remove Logging:** Once the fix is verified, remove the temporary logging.\n\n This approach directly addresses the most likely cause of the issue and provides a clear path to resolution.\n\n\n **Ensuring consistent bottle IDs will likely resolve this inconsistency.\n **\n The error message references bottle ID 16720, but the exception details show the procedure was actually processing ID 3216, indicating a parameter mismatch in the batch request.\n\n To fix this, I recommend the following steps:\n\n 1. **Client-Side Investigation**:\n\n * Examine the client-side code where the TRPC batch request is constructed.\n * Verify that the same \\`bottleId\\` parameter is being passed to both \\`bottlePriceList\\` and \\`bottleById\\` procedures.\n * If the IDs are being passed correctly, inspect the network request payload to confirm the correct structure of the batched request.\n\n \\`\\`\\`typescript\n // Example (Hypothetical) Client-Side Code\n const bottleId = 16720; // Example bottle ID\n\n // Ensure both procedures receive the same bottleId\n const [priceList, bottleDetails] = await trpc.batch(() => [\n trpc.bottlePriceList.fetch({ bottle: bottleId }),\n trpc.bottleById.fetch(bottleId),\n ]);\n \\`\\`\\`\n\n 2. **Server-Side Logging (Temporary)**:\n\n * Add temporary logging to both \\`bottlePriceList\\` and \\`bottleById\\` procedures to log the received \\`input\\` value.\n * This will help confirm whether the server is receiving the correct IDs from the client.\n * **Important**: Remove these logs after debugging to avoid unnecessary overhead.\n\n \\`\\`\\`typescript\n // apps/server/src/trpc/routes/bottlePriceList.ts\n export default publicProcedure\n .input(\n z.object({\n bottle: z.number(),\n onlyValid: z.boolean().optional(),\n }),\n )\n .query(async function ({ input, ctx }) {\n console.log(\"bottlePriceList input:\", input); // Add this line\n // ... rest of the code\n });\n\n // apps/server/src/trpc/routes/bottleById.ts\n export default publicProcedure.input(z.number()).query(async function ({\n input,\n ctx,\n }) {\n console.log(\"bottleById input:\", input); // Add this line\n // ... rest of the code\n });\n \\`\\`\\`\n\n 3. **TRPC Batch Request Configuration**:\n\n * Review the TRPC batch link configuration on the client-side.\n * Ensure that the batching logic is correctly mapping parameters to the corresponding procedures.\n * If using a custom batching implementation, verify its correctness.\n\n 4. **Data Integrity Check**:\n\n * If the client-side code appears correct, investigate whether bottle ID 3216 should exist in the database.\n * Check the \\`bottles\\` table and \\`bottleTombstones\\` table for any entries related to bottle ID 3216.\n * If the bottle should exist but is missing, investigate potential data deletion or migration issues.\n\n 5. **Tombstone Logic**:\n\n * Double-check the logic for creating and using tombstones.\n * Ensure that when a bottle is deleted, a tombstone entry is created correctly, pointing to the new bottle (if any).\n\n 6. **Error Handling**:\n\n * While this isn't the primary fix, consider improving the error message in \\`bottleById.ts\\` to include more context.\n * Include the original requested bottle ID (if available) in the error message to aid debugging.\n\n 7. **Client-Side Retries**:\n\n * Implement a retry mechanism on the client-side for TRPC requests.\n * If a \"Bottle not found\" error occurs, retry the request a few times before giving up. This can help mitigate transient issues.\n\n By following these steps, you should be able to identify the root cause of the parameter mismatch and implement a fix that ensures consistent bottle IDs are passed to both TRPC procedures in the batch request.\n\n\n\n ## Solution\n\n Consolidate bottle and price data fetching into a single batched TRPC request using \\`Promise.all\\` to ensure ID consistency.\n\n **Create a shared utility function to fetch bottle details and price data together.**\n \\`\\`\\`typescript\n // In a shared utility function or component\n export async function getBottleWithPrices(bottleId: number) {\n const trpcClient = await getTrpcClient();\n \n // Use Promise.all to ensure both requests are part of the same batch\n // and receive the same parameters\n const [bottle, priceList] = await Promise.all([\n trpcClient.bottleById.fetch(bottleId),\n trpcClient.bottlePriceList.fetch({ bottle: bottleId }),\n ]);\n \n return { bottle, priceList };\n }\n \\`\\`\\`\n This code creates a function that uses \\`Promise.all\\` to fetch both bottle details and price data concurrently. This ensures that both TRPC procedures are part of the same batch and receive the same \\`bottleId\\`.\n\n **Modify the page components to use the shared utility function.**\n \\`\\`\\`typescript\n // Then in the page components:\n const { bottle, priceList } = await getBottleWithPrices(Number(bottleId));\n \\`\\`\\`\n This code replaces the separate calls to \\`bottleById\\` and \\`bottlePriceList\\` with a single call to the \\`getBottleWithPrices\\` function, ensuring that both components receive data for the same bottle.\n\n **Add a unit test that reproduces the issue.**\n null\n\n\n \"\n `);\n });\n});\n"],"mappings":";;;;;;;;;;;;AAGA,SAAS,sBAAsB,MAAM;AACnC,IAAG,cAAc,YAAY;EAC3B,MAAM,OAAO,cAAc;EAC3B,MAAM,SAAS,MAAM,KAAK;GACxB,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,EAAC;AACF,eAAO,OAAO,CAAC,uBAAuB;;;;;;;;;;;;;MAapC;CACH,EAAC;AACH,EAAC;AAEF,SAAS,cAAc,MAAM;AAC3B,IAAG,cAAc,YAAY;EAC3B,MAAM,OAAO,cAAc;EAC3B,MAAM,SAAS,MAAM,KACnB;GACE,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,GACD;GACE,kBAAkB;GAClB;EACD,EACF;AACD,eAAO,OAAO,CAAC,uBAAuB;;;;;MAKpC;CACH,EAAC;AACH,EAAC;AAEF,SAAS,iBAAiB,MAAM;AAC9B,IAAG,cAAc,YAAY;EAC3B,MAAM,OAAO,cAAc;EAC3B,MAAM,SAAS,MAAM,KACnB;GACE,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,GACD;GACE,kBAAkB;GAClB;EACD,EACF;AACD,eAAO,OAAO,CAAC,uBAAuB;;;;;MAKpC;CACH,EAAC;AACH,EAAC;AAEF,SAAS,eAAe,MAAM;AAC5B,IAAG,2BAA2B,YAAY;EACxC,MAAM,OAAO,cAAc;EAC3B,MAAM,SAAS,MAAM,KACnB;GACE,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,GACD;GACE,kBAAkB;GAClB,aAAa;GACb;GACA,QAAQ;GACR;EACD,EACF;AACD,eAAO,OAAO,CAAC,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;MAwBpC;CACH,EAAC;AAEF,IAAG,8BAA8B,YAAY;EAC3C,MAAM,OAAO,cAAc;EAC3B,MAAM,SAAS,MAAM,KACnB;GACE,aAAa;GACb,QAA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AS,iBAAiB,MAAM;AAC9B,IAAG,cAAc,YAAY;EAC3B,MAAM,OAAO,cAAc;EAC3B,MAAM,SAAS,MAAM,KACnB;GACE,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,GACD;GACE,kBAAkB;GAClB,SAAS;GACT;GACA;EACD,EACF;AACD,eAAO,OAAO,CAAC,uBAAuB;;;;;;;;;;;;MAYpC;CACH,EAAC;AACH,EAAC;AAEF,SAAS,sBAAsB,MAAM;AACnC,IAAG,cAAc,YAAY;EAC3B,MAAM,OAAO,cAAc;EAC3B,MAAM,SAAS,MAAM,KACnB;GACE,aAAa;GACb,QAAQ;GACR,kBAAkB;EACnB,GACD;GACE,kBAAkB;GAClB,SAAS;GACT;GACA;EACD,EACF;AACD,eAAO,OAAO,CAAC,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAmRpC;CACH,EAAC;AACH,EAAC"}
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
require('../schema-BnXdl41H.cjs');
|
|
2
|
-
require('../client-
|
|
2
|
+
require('../client-DQF6UreY.cjs');
|
|
3
3
|
require('../types-o3zWarRp.cjs');
|
|
4
4
|
require('../api-client-CEBuz3Zu.cjs');
|
|
5
5
|
require('../formatting-BTSvl7n7.cjs');
|
|
6
6
|
require('../issue-helpers-CdWMhVWJ.cjs');
|
|
7
7
|
require('../logging-BEMgC5SA.cjs');
|
|
8
|
-
require('../tools-
|
|
8
|
+
require('../tools-BdAFXSMG.cjs');
|
|
9
9
|
require('../schema-_xqdSRLo.cjs');
|
|
10
10
|
require('../toolDefinitions-C0t6Y5Su.cjs');
|
|
11
11
|
require('../resources-BAE7VVZZ.cjs');
|
|
12
12
|
require('../promptDefinitions-OnJHLqrZ.cjs');
|
|
13
13
|
require('../prompts--QCiXmR2.cjs');
|
|
14
|
-
require('../server-
|
|
15
|
-
const require_stdio = require('../stdio-
|
|
14
|
+
require('../server-CqLaJq7P.cjs');
|
|
15
|
+
const require_stdio = require('../stdio-DKNKrvTY.cjs');
|
|
16
16
|
|
|
17
17
|
exports.startStdio = require_stdio.startStdio
|