Skip to content

Commit 06d5688

Browse files
authored
Update runt schema upsert fix (#216)
* Update @runt/schema to include upsert fixes Use commit d360a01c14d76f638d9545b44487c17b9cafb8b4 which includes: - onConflict handling for NotebookInitialized materializer - onConflict handling for all other insert operations This resolves UNIQUE constraint errors when multiple clients (headless runtime + web client) initialize the same notebook. * Update to use key-value notebook metadata approach - Update @runt/schema to commit 305edf9 with key-value metadata - Remove notebook initialization logic from Root.tsx - Update NotebookViewer.tsx to use notebookMetadata table - Update DebugPanel to display metadata as key-value pairs - No more initialization race conditions or UNIQUE constraint errors - Notebook metadata is set on-demand via notebookMetadataSet events * Fix types and remove manual type assertions - Use full commit hash to ensure proper cache invalidation - Remove 'as Array<{ key: string; value: string }>' type assertions - Import and use NotebookMetadataData type properly - Fix readonly vs mutable type issues - All types now properly inferred from schema * Update @runt/schema to b2f5f12 with debug table rename - Update to commit b2f5f1264cd1ddf51c881192aef6791a968f2b8b - Includes rename of debugPin table to debug (removes dash from table name) - Eliminates SQL compatibility issues with dashes in table names * Fix tests to use notebookMetadata instead of notebook table - Update edge-cases.test.ts to query metadata and find title - Update execution-flow.test.ts to use metadataQuery$ and check metadata changes - Keep existing notebookInitialized event calls (they work via materializer) - All 60 tests now passing ✅
1 parent 232eed0 commit 06d5688

7 files changed

Lines changed: 492 additions & 528 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060
"@radix-ui/react-separator": "^1.1.7",
6161
"@radix-ui/react-slot": "^1.2.3",
6262
"@radix-ui/react-tooltip": "^1.1.6",
63-
"@runt/schema": "jsr:^0.6.2",
63+
"@runt/schema": "github:runtimed/runt#b2f5f1264cd1ddf51c881192aef6791a968f2b8b&path:/packages/schema",
6464
"@tanstack/react-virtual": "^3.13.12",
6565
"@types/react-syntax-highlighter": "^15.5.13",
6666
"@uiw/codemirror-theme-github": "^4.23.14",

0 commit comments

Comments
 (0)