Conversation
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.
Problem
mainis at 1.5.3 whiledevhas accumulated all staged work since. Per the staging workflow,mainonly moves on a version-bump merge — this is that merge, releasing 1.6.0 (minor: real features).Solution
Merge
devintomainand tagv1.6.0(triggersrelease.yml→.vsix+ GitHub release). Merge commit, not squash — first dev→main release under the staging workflow; preserving shared history keeps every future dev→main merge conflict-free.devstrictly containsmain(the dependency commits landed on main first and were merged back), so this merge introduces exactly the dev-side work.Contents
c0265e1#4984d50631#5014c4b5ed#499<mark>, longest-first)1525d52#5000ac27640beff8c#51021ec58eArchitecture (view management, the largest piece)
Follows the existing three-layer RPC design end to end: sidebar actions (
views.js, new) →HostBridgemethods (getViewDefinition/validateViewDefinition/previewViewDefinition/createView/editView/dropView) →DatabaseOperationsimplemented in both the WASM engine and the native worker, plus the web-demo worker. In VS Code, Edit opens the SELECT body as a writable virtual.sqldocument through the existingSQLiteFileSystemProvider(sentinel row id__view__.sql), giving native SQL highlighting and a save hook; the web demo falls back to the modal editor. A newview-utils.tslexer extracts the SELECT body from storedCREATE VIEWSQL (comment/quote/bracket-aware) for presentation only — validation is never string-based. All three operations record undo/redo modifications with before/after definitions.Per-file changes
WasmDatabaseEngine.ts,nativeWorker.ts,sqlite-db.ts,types.ts,view-utils.tsnew,workerFactory.ts,loggingDatabaseOperations.ts), host (hostBridge.ts,virtualFileSystem.ts), UI (views.jsnew,sidebar.js,state.js,api.js,web-api.js,viewer.js,web-viewer.js, template + CSS), generated bundles, web-demo worker, 6 test files.grid.js,grid-data.js,filters.js,dnd.js,viewer.js+web-viewer.js(separate copies, both updated), bundles.package.json/lockfile pairs,dependabot.ymlgates,.gitignore.package.jsonversion,CHANGELOG.md.Security
.vsix); the website carried the real exposure (next×8 CVEs — SSRF, middleware bypass, cache confusion, DoS — andsharpbelow the libvips fix line, forced via override) and is redeployed. Reviewer note:npm auditin /website still prints a brace-expansion cascade — flattened-range false positive; GitHub per-branch data confirms patched (do not "fix" via the suggested eslint-config-next downgrade).escapeIdentifier(); schema lookups parameterized; user SQL compiled via single-statementEXPLAINin a SELECT-only context (trailing statements cannot execute, DML cannot hide in a FROM-subquery); previewLIMITclamped engine-side (≤100); SAVEPOINT +safeRollbackatomicity (no rawBEGIN— nests under outer transactions); destructive confirmations (drop view, discardINSTEAD OFtriggers) live host-side, out of the webview's reach; new UI renders viatextContentonly under the nonce CSP.Test plan
node scripts/build.mjs+tsc --noEmit+ unit tests — 470/470 (454 pre-existing + 16 new view tests: create, trigger preservation, trigger-loss warning path, drop confirmation plumbing, rollback-on-invalid-definition leaving view + triggers intact) + website production build.viewer.htmlbundles are byte-identical to a fresh deterministic build (also heals main's stale-bundle drift from the 1.5.3 release).v1.6.0→release.ymlbuilds the.vsixand publishes the GitHub release; verify assets, then close [Feature]: Create and Edit Views #510 as shipped.🤖 Generated with Claude Code
Summary by CodeRabbit