Repository navigation
Conversation
This was referenced Oct 14, 2026
hweihwang
marked this pull request as ready for review
October 14, 2026 08:03
hweihwang
force-pushed
the
fix/reject-outdated-clients
branch
from
October 21, 2026 06:59
cf4227c to
9fcead3
Compare
A browser tab still running Whiteboard 2.x after the upgrade drops element types it does not know, such as sticky notes, and the server builds the saved scene from the incoming elements. Its saves would remove them. - The server answers a scene write without schemaVersion 2 with 400 client_upgrade_required, after the permission checks and before the sync lock (2.0 treats the lock's 409 as saved), and writes nothing. - 3.0 clients send schemaVersion 2 with every write and scene broadcast, and ignore scene broadcasts without it. A restore broadcast only asks peers to reload from the server, so it is followed from any client. - Once a 3.0 client sees such a broadcast, it saves too and sends the full scene to new joiners, because the elected saver may be the 2.x tab. - A client that lost the connection writes to the server again only after it merged the saved board (retried until it loads), because the 2.x tab's scene that used to bring it up to date is now ignored. An upload still waiting in the sync worker is dropped at the disconnect, and a periodic save reads the scene only after waiting for its token. Its local copy is still kept up to date. - The recording hook removed every connect and disconnect listener of the socket, so the collaboration code never noticed a lost connection. It now removes only its own listeners. Following now also stops when the followed user left while this client was disconnected. Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Hoang Pham <hoangmaths96@gmail.com>
hweihwang
force-pushed
the
fix/reject-outdated-clients
branch
from
October 22, 2026 12:33
9fcead3 to
d8d1678
Compare
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.
Stacked on #1161; merge together with it.
A tab still running 2.x after the upgrade drops sticky notes when it saves. This stops that:
400 client_upgrade_required).Also fixes the recording code removing the collaboration code's connection listeners.
Tested with PHPUnit, vitest and Playwright on stable31, stable32 and master, and by hand with a 2.1 tab next to a 3.0 tab.