MCPcopy
hub / github.com/microsoft/vscode-js-debug / handleConnection

Method handleConnection

src/dapDebugServer.ts:217–229  ·  view source on GitHub ↗

Processes an incoming connection.

(info: ISessionInfo)

Source from the content-addressed store, hash-verified

215
216 /** Processes an incoming connection. */
217 public handleConnection(info: ISessionInfo) {
218 if (!('__pendingTargetId' in info.launchParams) || !info.launchParams.__pendingTargetId) {
219 throw new Error(`Incoming session is missing __pendingTargetId`);
220 }
221
222 const targetId = info.launchParams.__pendingTargetId;
223 const session = this.sessions.get(targetId);
224 if (!session) {
225 throw new Error(`__pendingTargetId ${targetId} not found`);
226 }
227
228 session.resolve(info);
229 }
230}
231
232function startDebugServer(options: net.ListenOptions) {

Callers 1

startDebugServerFunction · 0.95

Calls 2

resolveMethod · 0.80
getMethod · 0.65

Tested by

no test coverage detected