Repository navigation
Share a database as a web studio (Labs) - #283
Merged
Merged
Conversation
…'s Share as web studio
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
A link that opens a database in the web studio on any device, for anyone it's sent to, through the relay at stroke.click (stroke-app/stroke-web#61, deployed). End-to-end encrypted: AES-256-GCM with a key that exists only in the link's
#fragment; the relay passes ciphertext.strokedb 0.3.0 (
cli/)--shareprints a share link alongside the local studio (needs Node 22+ for WebSocket);--writelets it edit.BEGIN READ ONLY…ROLLBACK; MySQL insideSTART TRANSACTION READ ONLY…ROLLBACK; SQLite opens the file read-only. On top, the console accepts reading statements only (isReadingSql), and edit routes are absent.makeRoutesis shared by the local bridge and the relay host;relay.jsholds the room socket and reconnects with backoff.Desktop app
studio-share.js), on the connection it has open. SQL goes through a newshare_execute_sqlcommand, which is the MCP server's path: the access classifier (one reading statement), then the engine's read-only transaction. The share pauses if another database is in front, and ends on disconnect or when the Labs switch goes off.Tested
crm.db; a second browser browsed 500 rows; DELETE,select 1; delete …and row edits were refused; Stop sharing took the room offline.cargo build, svelte-check, design-lint, 1800 vitest and the CLI tests pass.