feat: US-019 - Enable heartbeat by default in config

- Added HeartbeatConfig struct with Enabled field
- Added Heartbeat to Config struct
- Set default Heartbeat.Enabled = true in DefaultConfig()
- Updated main.go to use cfg.Heartbeat.Enabled instead of hardcoded true
- Added config tests verifying heartbeat is enabled by default

Acceptance criteria met:
- DefaultConfig() Heartbeat.Enabled changed to true
- Can override via PICOCLAW_HEARTBEAT_ENABLED=false env var
- Config documentation updated showing default enabled
- Typecheck passes (go build ./... succeeds)
- go test ./pkg/config -run TestDefaultConfig passes

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
yinwm
2026-02-12 20:15:43 +08:00
parent 28734c3a2e
commit 03b02cc7d7
4 changed files with 34 additions and 2 deletions

View File

@@ -660,7 +660,7 @@ func gatewayCmd() {
cfg.WorkspacePath(),
nil,
30*60,
true,
cfg.Heartbeat.Enabled,
)
channelManager, err := channels.NewManager(cfg, msgBus)