From 4e94da52fecf4ea5646b23c4a905c9b0a59cad5a Mon Sep 17 00:00:00 2001 From: Glen Maddern Date: Tue, 25 Mar 2025 09:44:30 +1100 Subject: [PATCH] adding a PID to the authorize step, we're definitely getting two processes --- src/lib/utils.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/lib/utils.ts b/src/lib/utils.ts index 0340315..2b09f57 100644 --- a/src/lib/utils.ts +++ b/src/lib/utils.ts @@ -2,6 +2,8 @@ import { OAuthClientProvider, UnauthorizedError } from '@modelcontextprotocol/sd import { SSEClientTransport } from '@modelcontextprotocol/sdk/client/sse.js' import { Transport } from '@modelcontextprotocol/sdk/shared/transport.js' +const pid = process.pid + /** * Creates a bidirectional proxy between two transports * @param params The transport connections to proxy between @@ -63,7 +65,7 @@ export async function connectToRemoteServer( authProvider: OAuthClientProvider, waitForAuthCode: () => Promise, ): Promise { - console.error('Connecting to remote server:', serverUrl) + console.error(`[${pid}] Connecting to remote server: ${serverUrl}`) const url = new URL(serverUrl) const transport = new SSEClientTransport(url, { authProvider })