Skip to content

Update deps#374

Merged
threepointone merged 1 commit into
mainfrom
update-deps
Apr 20, 2026
Merged

Update deps#374
threepointone merged 1 commit into
mainfrom
update-deps

Conversation

@threepointone
Copy link
Copy Markdown
Collaborator

Summary

Dependency + test-infrastructure upgrade across the monorepo, mirroring the migration pattern from cloudflare/agents#1138.

Package-level changes (with changesets)

  • partysocket (patch): narrow Message type to ArrayBufferView<ArrayBuffer> so it matches DOM WebSocket.send() overloads under newer lib typings. Runtime behaviour unchanged.
  • partytracks (patch): internal-only type fixes for newer @cloudflare/workers-types:
    • Avoid typeof fetch in internal signatures (merges with Fetcher interface).
    • Rename internal fetcher option on fromFetch to fetchImpl (avoids colliding with RequestInit.fetcher?: Fetcher | null).
    • Cast Response#json() results (now unknown) before destructuring.
  • partysync (patch): rename Agent#connect(namespace, room)Agent#connectTo(namespace, room) to avoid colliding with DurableObject.connect?(socket: Socket) newly added to @cloudflare/workers-types.

Test infrastructure migration (Vitest 4 + @cloudflare/vitest-pool-workers 0.14)

Applies to partyserver, y-partyserver, partysub, partywhen:

  • defineWorkersConfigcloudflareTest Vite plugin with absolute paths via path.join(import.meta.dirname, ...).
  • ProvidedEnv module augmentation → centralized Cloudflare.Env namespace augmentation in per-package env.d.ts.
  • Test imports: env moved from cloudflare:test to cloudflare:workers.
  • tsconfig.json types path: @cloudflare/vitest-pool-workers@cloudflare/vitest-pool-workers/types.
  • New setup.ts files with beforeAll warmup (exports.default.fetch("http://warmup/")) to avoid cold-start timeouts.
  • partywhen-specific:
    • Added beforeEach task cleanup (since isolatedStorage / singleWorker pool options are gone; DO state now persists across tests).
    • Added resolve.alias for luxon to its CJS build (Vite's module runner was handing cron-parser's require("luxon") the ESM namespace with DateTime undefined).

Fixtures

  • globe: migrated to cobe v2 — onRender callback removed in favour of a requestAnimationFrame loop calling globe.update({ phi, markers }); RAF handle captured for cleanup.
  • Bumped fixture dependencies (react 19, cobe v2, nanoid, hono, tiptap, tldraw, valibot, etc.) and dev tooling.
  • Removed stale fixtures/socket-io-* package files.

Test plan

  • npm run check:type — all 41 tsconfig projects pass.
  • npm run check:test — 393/393 tests pass across 17 files in 6 packages.
  • npm run check:lint — 0 warnings, 0 errors.
  • npm run check:format — all 348 files properly formatted.
  • Manual sweep for stale references (defineWorkersConfig, ProvidedEnv, isolatedStorage, singleWorker, LegacyRef, onRender).

Made with Cursor

Add changesets for partysocket, partysync, and partytracks (type/naming/compat fixes). Bump fixture dependencies (react, react-dom, nanoid, cobe, hono, tiptap, tldraw, valibot, etc.), and update fixture dev tooling (include "vite/client" in tsconfig types and remove vite-plugin-devtools-json from vite configs). Update globe demo to work with cobe v2 (drive rendering via requestAnimationFrame instead of onRender, tidy refs), remove stale socket-io fixture package files, and add test scaffolding (env.d.ts/setup.ts/vitest configs) for partyserver, partywhen, and y-partyserver. Also apply related package-level changes (partysync agent rename and partytracks workers-types compatibility fixes) and update lockfile/dev dependency bumps.
@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Apr 20, 2026

🦋 Changeset detected

Latest commit: 6e6125f

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
partysocket Patch
partysync Patch
partytracks Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new Bot commented Apr 20, 2026

Open in StackBlitz

hono-party

npm i https://pkg.pr.new/cloudflare/partykit/hono-party@374

partyfn

npm i https://pkg.pr.new/cloudflare/partykit/partyfn@374

partyserver

npm i https://pkg.pr.new/cloudflare/partykit/partyserver@374

partysocket

npm i https://pkg.pr.new/cloudflare/partykit/partysocket@374

partysub

npm i https://pkg.pr.new/cloudflare/partykit/partysub@374

partysync

npm i https://pkg.pr.new/cloudflare/partykit/partysync@374

partytracks

npm i https://pkg.pr.new/cloudflare/partykit/partytracks@374

partywhen

npm i https://pkg.pr.new/cloudflare/partykit/partywhen@374

y-partyserver

npm i https://pkg.pr.new/cloudflare/partykit/y-partyserver@374

commit: 6e6125f

@threepointone threepointone merged commit c05d86a into main Apr 20, 2026
6 checks passed
@threepointone threepointone deleted the update-deps branch April 20, 2026 20:31
@github-actions github-actions Bot mentioned this pull request Apr 20, 2026
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.

1 participant