fix(ADA-79): WS keepalive + disconnect-banner debounce + friendly diagnostic#87
Merged
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d0246a8290
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Address Codex review on #87. The keepalive introduced a new `heartbeat` variant of the `ServerConfigStreamEvent` union. Older / version-skewed clients (the mobile app and stale cached web bundles both bundle the shared client-runtime and contracts) decode this union with a closed schema, so an unknown `heartbeat` frame fails decoding ~30s into the connection and tears down the whole `subscribeServerConfig` subscription — exactly the version-skew scenario the version-mismatch banner in this PR is meant to tolerate. Negotiate support instead of emitting unconditionally: - add an optional, additive `supportsHeartbeat` flag to the `subscribeServerConfig` payload (older clients omit it; older servers ignore it on decode — backward compatible both directions); - the server only merges heartbeat frames when the client opts in (`shouldSendServerConfigHeartbeat`), so clients that cannot decode the variant never receive it; - both client-runtime consumers opt in via a single shared `SERVER_CONFIG_SUBSCRIPTION_INPUT` constant, so the subscription stays a single shared stream per environment (no split subscription). Also stop heartbeats from re-emitting the unchanged projection: a quiet session previously pushed the current `ServerConfigProjection` downstream on every 30s tick. `projectServerConfig` now emits no downstream value for heartbeat frames (transport keepalive only). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fresh PR superseding #84 (queue-contended, no review in 33min). WS keepalive + disconnect-banner debounce + dismissable ede_diagnostic. HIGH user value; Adam waiting. SERVER-SIDE (WS keepalive) → include in next redeploy batch.