Claude Code chats survive server restarts in a detachable host
A pipelines-claude-host process owns each claude -p CLI and its pipes, spools its stream-json output with offsets and serves a private Unix socket. The server detaches on shutdown and reattaches on start, replaying the spool to rebuild turns, approvals, questions, background tasks and the live model. Explicit close, idle release and CLI exit stop the host; a crashed host falls back to --resume with a notice.
This commit is contained in:
@@ -305,7 +305,7 @@ class SetupNativeTests(unittest.TestCase):
|
||||
with self.assertRaisesRegex(ValueError, "Node.js 18"):
|
||||
installer.configure_web(Path(directory) / "prefix", setup_native.arguments([]))
|
||||
|
||||
def test_build_installs_only_server_and_cli_with_trimpath(self):
|
||||
def test_build_installs_only_server_cli_and_claude_host_with_trimpath(self):
|
||||
with tempfile.TemporaryDirectory() as directory:
|
||||
recorder = Recorder()
|
||||
installer = self.installer(directory, recorder)
|
||||
@@ -313,11 +313,12 @@ class SetupNativeTests(unittest.TestCase):
|
||||
installer.prepare_layout(prefix)
|
||||
installer.build(prefix)
|
||||
builds = [call for call in recorder.calls if call[:2] == ["go", "build"]]
|
||||
self.assertEqual(len(builds), 2)
|
||||
self.assertEqual(len(builds), 3)
|
||||
for call in builds:
|
||||
self.assertIn("-trimpath", call)
|
||||
self.assertTrue(any(call[-1] == "./cmd/pipelines-server" for call in builds))
|
||||
self.assertTrue(any(call[-1] == "./cmd/pipelines" for call in builds))
|
||||
self.assertTrue(any(call[-1] == "./cmd/pipelines-claude-host" for call in builds))
|
||||
self.assertFalse(any("pipelines-tui" in part for call in recorder.calls for part in call))
|
||||
|
||||
def test_layout_creates_private_prefix_and_copies_manage(self):
|
||||
|
||||
Reference in New Issue
Block a user