Skip to content

feat(daemon): cross-platform IPC transport for Windows support - #31

Merged
wangxingjun778 merged 2 commits into
mainfrom
feat/core_loop
Aug 6, 2026
Merged

feat(daemon): cross-platform IPC transport for Windows support#31
wangxingjun778 merged 2 commits into
mainfrom
feat/core_loop

Conversation

@wangxingjun778

Copy link
Copy Markdown
Member
  • Introduce DaemonTransport protocol with UnixSocketTransport (macOS/Linux) and TcpLoopbackTransport (Windows) implementations
  • Replace direct asyncio.start_unix_server/open_unix_connection with transport abstraction in server.py, client.py, lifecycle.py
  • Unify lease.py process probe with lifecycle._process_alive (kernel32 on Windows)
  • Add Windows creationflags (CREATE_NEW_PROCESS_GROUP | DETACHED_PROCESS) to spawn_daemon, matching dashboard/launcher.py pattern
  • Add SIGBREAK handler and CREATE_NEW_PROCESS_GROUP to host.py ObservationDaemon for graceful Windows shutdown
  • Unify start_new_session handling in shell_tools.py and terminal_session.py
  • Fix POSIX ProcessGroup.terminate() to clear _pgid after signal

macOS/Linux behavior unchanged: UnixSocketTransport wraps existing code with zero logic change. All 1540 tests pass.

- Introduce DaemonTransport protocol with UnixSocketTransport (macOS/Linux)
  and TcpLoopbackTransport (Windows) implementations
- Replace direct asyncio.start_unix_server/open_unix_connection with
  transport abstraction in server.py, client.py, lifecycle.py
- Unify lease.py process probe with lifecycle._process_alive (kernel32 on Windows)
- Add Windows creationflags (CREATE_NEW_PROCESS_GROUP | DETACHED_PROCESS)
  to spawn_daemon, matching dashboard/launcher.py pattern
- Add SIGBREAK handler and CREATE_NEW_PROCESS_GROUP to host.py
  ObservationDaemon for graceful Windows shutdown
- Unify start_new_session handling in shell_tools.py and terminal_session.py
- Fix POSIX ProcessGroup.terminate() to clear _pgid after signal

macOS/Linux behavior unchanged: UnixSocketTransport wraps existing code
with zero logic change. All 1540 tests pass.
@wangxingjun778
wangxingjun778 merged commit c148a11 into main Aug 6, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant