Skip to content

Conversation

@rgbkrk
Copy link
Member

@rgbkrk rgbkrk commented Sep 5, 2025

WIP

I brought the runt schema over so I could change its dep as well, see how this could look.

cc @schickling

I let Zed's Claude Sonnet integration go to town on this with https://dev.docs.livestore.dev/llms-full.txt after giving it some guardrails.

This is a temporary copy of @runt/schema to facilitate the LiveStore 0.4.0-dev.7 upgrade.
It will be removed once the upgrade is complete and we can reference the updated schema package.
- Replace @runt/schema imports with @/runt-schema
- Remove @runt/schema dependency from package.json
- Rename mod.ts to index.ts for proper module resolution
- All TypeScript compilation now passes
- Update all LiveStore packages to 0.4.0-dev.7
- Fix .first() calls to include required behaviour: 'fallback' property
- Update sync backend API from handleWebSocket to handleSyncRequest/getSyncRequestSearchParams
- Update client sync API from makeCfSync to makeWsSync
- Update Durable Object class name from WebSocketServer to SyncBackendDO
- All TypeScript compilation passes

Note: Some peer dependency warnings remain for Effect packages - these are expected
with the dev release and don't prevent functionality.
- Successfully upgraded all LiveStore packages to 0.4.0-dev.7
- Fixed all TypeScript API changes (.first() calls, sync backend API)
- Upgraded Vite to 7.1.4 as required by LiveStore devtools
- All TypeScript compilation passes

Note: Build currently fails due to Effect ecosystem compatibility issue
in @livestore/utils expecting RpcClientError from @effect/rpc.
This appears to be an internal LiveStore dev package issue that should
be resolved in a future LiveStore release.
- Update @effect/rpc to 0.69.2 to fix missing RpcClientError export
- Update @effect/platform to 0.90.7 for compatibility
- Add direct dependencies to override transitive version conflicts
- Fix formatting in runt-schema files

This resolves the build failures from incompatible Effect package versions
that were causing missing exports in @effect/ai and @livestore/utils.
Removes explicit @livestore/livestore and @livestore/react from vite's
optimizeDeps.include to prevent cache conflicts after dependency updates.
This resolves ERR_ABORTED 504 (Outdated Optimize Dep) errors.
…ject binding

- Update effect package to 3.17.13 to resolve DoCtx compatibility issues
- Configure sync handler to use WEBSOCKET_SERVER binding name
- Fix LiveStore 0.4.0-dev.7 Durable Object name mismatch
@rgbkrk
Copy link
Member Author

rgbkrk commented Sep 5, 2025

Looking good for new notebooks.

image

Old notebooks I'm running into a litany of errors.

✘ [ERROR] [13:45:57.445 ws-rpc-server] InvalidPushError: { "cause": ServerAheadError: { "minimumExpectedNum": 0, "providedNum": 506 } } InvalidPushError: { "cause": ServerAheadError: { "minimumExpectedNum": 0, "providedNum": 506 } }

      at InvalidPushError.make
  (file:///Users/kylekelley/code/src/github.com/runtimed/anode/node_modules/.pnpm/[email protected]/node_modules/effect/src/Schema.ts:9514:14)
      at f
  (file:///Users/kylekelley/code/src/github.com/runtimed/anode/node_modules/.pnpm/@[email protected]_676275bee9841bcab5beb100ee1da758/node_modules/@livestore/sync-cf/src/cf-worker/do/push.ts:146:51)
      at effect_instruction_i0
  (file:///Users/kylekelley/code/src/github.com/runtimed/anode/node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/core.ts:1078:35)
      at null.<anonymous>
  (file:///Users/kylekelley/code/src/github.com/runtimed/anode/node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/fiberRuntime.ts:1146:41)
      at [object Object]

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants