18 lines
1.5 KiB
Markdown
18 lines
1.5 KiB
Markdown
# 2026-03-04 Session Notes
|
|
|
|
## Daemon Restart → OpenClaw Sync Implementation
|
|
|
|
Started implementation of a new feature to keep OpenClaw and Signet daemon restarts in sync. PR #114 (fix/memory-plugin-error-reporting) was closed because it violated the codebase's "result types over exceptions" convention and didn't address the actual goal Jake described—syncing openclaw restarts with daemon restarts.
|
|
|
|
The implementation adds OpenClaw restart detection and prompting to the CLI restart flow. When `signet daemon restart` runs, the CLI now detects if OpenClaw is configured, prompts the user to restart it as well, and optionally executes a configured restart command.
|
|
|
|
Key design decisions:
|
|
- Services config lives in AgentManifest as an optional `services.openclaw` block
|
|
- User configures restart command in `~/.agents/agent.yaml` under `services.openclaw.restart_command`
|
|
- Two helper functions: `isOpenClawDetected()` (uses existing OpenClawConnector.getDiscoveredConfigPaths()) and `restartOpenClaw()` (executes command with 15s timeout via spawnSync)
|
|
- Added `--no-openclaw` flag to both daemon restart and top-level restart commands
|
|
- Graceful degradation: no prompt if OpenClaw not detected, shows config instructions if detected but not configured
|
|
|
|
Files modified: `packages/core/src/types.ts` (add services config) and `packages/cli/src/cli.ts` (add helpers, modify doRestart and TUI restart case, add command options).
|
|
|
|
Verification plan includes testing all scenarios: detection, configuration prompt, spinner feedback, and flag behavior. |