MCPcopy Create free account
hub / github.com/tiann/hapi / reportSessionStarted

Function reportSessionStarted

cli/src/agent/sessionFactory.ts:121–133  ·  view source on GitHub ↗
(sessionId: string, metadata: Metadata)

Source from the content-addressed store, hash-verified

119}
120
121async function reportSessionStarted(sessionId: string, metadata: Metadata): Promise<void> {
122 try {
123 logger.debug(`[START] Reporting session ${sessionId} to runner`)
124 const result = await notifyRunnerSessionStarted(sessionId, metadata)
125 if (result?.error) {
126 logger.debug(`[START] Failed to report to runner (may not be running):`, result.error)
127 } else {
128 logger.debug(`[START] Reported session ${sessionId} to runner`)
129 }
130 } catch (error) {
131 logger.debug('[START] Failed to report to runner (may not be running):', error)
132 }
133}
134
135export async function bootstrapSession(options: SessionBootstrapOptions): Promise<SessionBootstrapResult> {
136 const workingDirectory = options.workingDirectory ?? getInvokedCwd()

Callers 2

bootstrapSessionFunction · 0.85
bootstrapExistingSessionFunction · 0.85

Calls 2

debugMethod · 0.80

Tested by

no test coverage detected