MCPcopy Create free account
hub / github.com/Noumena-Network/code / updateReconnectingStatus

Function updateReconnectingStatus

src/bridge/bridgeUI.ts:408–426  ·  view source on GitHub ↗
(delayStr: string, elapsedStr: string)

Source from the content-addressed store, hash-verified

406 },
407
408 updateReconnectingStatus(delayStr: string, elapsedStr: string): void {
409 stopConnecting()
410 clearStatusLines()
411 currentState = 'reconnecting'
412
413 // QR code above the status line
414 if (qrVisible) {
415 for (const line of qrLines) {
416 writeStatus(`${chalk.dim(line)}\n`)
417 }
418 }
419
420 const frame =
421 BRIDGE_SPINNER_FRAMES[connectingTick % BRIDGE_SPINNER_FRAMES.length]!
422 connectingTick++
423 writeStatus(
424 `${chalk.yellow(frame)} ${chalk.yellow('Reconnecting')} ${chalk.dim('\u00b7')} ${chalk.dim(`retrying in ${delayStr}`)} ${chalk.dim('\u00b7')} ${chalk.dim(`disconnected ${elapsedStr}`)}\n`,
425 )
426 },
427
428 updateFailedStatus(error: string): void {
429 stopConnecting()

Callers

nothing calls this directly

Calls 3

stopConnectingFunction · 0.85
clearStatusLinesFunction · 0.85
writeStatusFunction · 0.85

Tested by

no test coverage detected