Repository navigation
[AI-3615] Log why dispatch and stream sockets closed #2271
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
3194268
feat(api): log why dispatch and stream sockets closed
kanat 75fb7e6
Merge remote-tracking branch 'origin/main' into kanat/ai-3615-dispatc…
kanat d904bca
fix(api): a dispatch write refused after the worker's close is its close
kanat e74e584
fix(api): a session socket write refused after the caller's close is …
kanat f4521e5
test(api): a start frame with bytes after its JSON still starts
kanat 5325248
docs(router): a stream start refused 1008 is also an unknown target o…
kanat fde1b5f
Merge remote-tracking branch 'origin/main' into kanat/ai-3615-dispatc…
kanat 5b755c1
AI-3615: test the host_tools reply write against a close frame
kanat 728c309
Merge origin/main into AI-3615
kanat 8663d3e
Merge branch 'main' into kanat/ai-3615-dispatch-stream-close-reason
kanat File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[Should fix] R2.1: mutant
socketEnd{cause: clientGone}at this reply write survives (I replaced each writeEnd site alone and ran SocketCloseLog+SocketEnd; only the pong, session event and relay event sites are killed). This one is reachable like the pong: add to SocketCloseLogSuite, 25 rounds:I ran it: passes on head x3, fails x3 under this mutant. The other survivors (ready at 169, pings at 220, sessionws.go:340, relayws.go:256, tool call/call/message at 196/206/214) are not reachable without a clock or a deterministic race with the close; list them as untested in the PR body and leave them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in 5b755c1: SocketCloseLogSuite/TestADispatchWorkersCloseFrameAfterHostToolsIsLoggedWithItsCode (host_tools then close 4005, 25 rounds). Passes x3 on head; with the reply write at dispatchws.go:186 mutated to clientGone it fails x3. The 7 unreachable sites are listed in the PR body.