{"version":"2.1.271","anchor":"hook-dispatch-keepalive-hold-gated-off-by-default","canonical_anchor":"hook-dispatch-keepalive-hold-gated-off-by-default","heading":"Keepalive holds remote sessions open while hooks run","tier":"soon","area":"Hooks","scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.271\/e\/hook-dispatch-keepalive-hold-gated-off-by-default","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.271","markdown":"### Keepalive holds remote sessions open while hooks run\n\nRemote\/CCR sessions now hold a keepalive open while a hook runs, gated behind a flag, to avoid idle timeouts on slow hooks\n\n**What**\n\nA new internal mechanism (referred to internally as `rWt`\/`Uri`) keeps a remote session's activity\/keepalive signal open for as long as a hook (an automated script Claude Code runs at certain points) is executing. The hold duration is calculated from the hook's own timeout setting plus a fixed pad, so a slow-running hook doesn't cause the connection to be treated as idle.\n\n- It excludes certain hook types from this hold: `PermissionRequest`, `Notification`, `SessionEnd`, and `MessageDisplay` hooks.\n\n- It requires the `CLAUDE_CODE_REMOTE_SEND_KEEPALIVES` setting to be enabled.\n\n- It is further gated by a growthbook feature flag, so it is off by default.\n\n- If a hold ends up exceeding its computed budget, a `session_activity_hook_hold_expired` warning is logged.\n\n**Why**\n\nThis is meant to stop a remote or CCR (cloud\/bridge) session from idle-timing-out just because a hook it's waiting on is taking a while to finish. Since it's gated off by default, most users won't notice any behavior change yet.\n\n- Flag `tengu_ccr_hook_keepalive_enabled`: Not enough to say (read for one account on one subscription tier against v2.1.271; this account: no value returned, anonymous baseline: no value returned, compiled default: off) These values were read against a different version of Claude Code, so treat them as the nearest reading available instead of one taken on this release.\n- Area: Hooks\n- Names: `CLAUDE_CODE_REMOTE_SEND_KEEPALIVES`\n- Tier: Nothing to try yet\n- Useful: 2\/5\n- Signal: 3\/5\n- Present in the build but not switched on"}