MCPcopy Create free account
hub / github.com/TraderAlice/OpenAlice / respawnNow

Method respawnNow

src/workspaces/persistent-session.ts:214–226  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

212 }
213
214 private respawnNow(): void {
215 this.respawnTimer = null;
216 if (this.disposed) return;
217 try {
218 this.term = this.spawnChild();
219 this.log.info('session.respawned', { pid: this.term.pid });
220 this.sendControl({ type: 'lifecycle', kind: 'child-respawn', pid: this.term.pid });
221 } catch (err) {
222 this.log.error('session.respawn_failed', { err });
223 this.sendControl({ type: 'exit', code: -1, signal: null });
224 this.dispose('respawn failed');
225 }
226 }
227
228 get pid(): number {
229 return this.term.pid;

Callers 1

onChildExitMethod · 0.95

Calls 5

spawnChildMethod · 0.95
sendControlMethod · 0.95
disposeMethod · 0.95
infoMethod · 0.80
errorMethod · 0.65

Tested by

no test coverage detected