Make brainstorm companion idle timeout configurable#1689
Open
VeraPyuyi wants to merge 1 commit into
Open
Conversation
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.
What problem are you trying to solve?
Fixes #1237.
The brainstorming visual companion can silently expire in the middle of a real brainstorm. The previous idle timeout was 30 minutes, which is short for interactive design/review sessions where the user may step away, discuss options, or work in parallel. When the server stops, the browser just becomes unreachable and the agent can keep referring to a stale URL.
While testing the idle path, I also found that shutdown needed to close upgraded WebSocket sockets explicitly. With a browser connection open, the server could write
server-stoppedand removeserver-infobut keep the Node process alive.What does this PR change?
idle_timeout_msin startup JSON /state/server-info.--idle-timeout-minutes <minutes>toskills/brainstorming/scripts/start-server.shwith explicit validation.Is this change appropriate for the core library?
Yes. This changes the core brainstorming visual companion used by Superpowers itself, and addresses a general UX/reliability issue for all users of the visual companion. It does not add a new skill, harness, third-party service, or project-specific configuration.
What alternatives did you consider?
server-info. That helps diagnosis but does not address the overly short default or the shutdown edge case.Does this PR contain multiple unrelated changes?
No. The script, server, docs, and tests all support the same visual companion idle-timeout lifecycle fix.
Existing PRs
I did not find an open PR directly fixing the idle timeout default/configuration plus the WebSocket shutdown behavior. #1639 touches visual companion internals more broadly; #856 focuses on WebSocket reconnect/status; #1553 and #1504 are brainstorm-server robustness/security fixes in adjacent code paths.
Environment tested
New harness support (required if this PR adds a new harness)
Not applicable. This PR does not add a new harness.
Clean-session transcript for "Let's make a react todo list"
Evaluation
C:\Program Files\Git\bin\bash.exe tests/brainstorm-server/run-tests.sh-> passednpm test-> 27 passed, 0 failednode ws-protocol.test.js-> 32 passed, 0 failedbash start-server.test.sh-> 5 passed, 0 failedgit diff --check-> passedbash -n skills/brainstorming/scripts/start-server.sh tests/brainstorm-server/start-server.test.sh tests/brainstorm-server/run-tests.sh-> passedscripts/lint-shell.sh ...could not run locally becauseshellcheckis not installed on this machine.Rigor
superpowers:writing-skillsand completed adversarial pressure testing (paste results below)Pre-submit review found and I fixed these issues before opening the PR:
Human review