fix(browser): make observation start replay idempotent - #45
Merged
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.
Core retransmits the one-way
browser.observer.commandstart while it waits for thestartedlifecycle event. The Worker treated each retransmission as a new observer, so the recovery path Core added turned into a self-conflict.The Worker now records the
command_idalongside the lease and returns early when both match the observation already opening, so a delivery replay does not replace the stream or report that the same observer conflicts with itself.This is also a release blocker: the root repository's
mainalready pins this commit as itsopenlinker-clisubmodule pointer, and the commit was never pushed, so a recursive clone or a CI submodule checkout frommaincurrently fails on a SHA that does not exist on the remote.TestObservationStartReplayIsIdempotentcovers the replay;go test ./pkg/agentexec/ ./pkg/browserprotocol/ ./pkg/browserruntime/passes.🤖 Generated with Claude Code