Skip to content

v0.84.1: the local-dev media fix completed

Choose a tag to compare

@glw907 glw907 released this 09 Jul 02:51

Completes 0.84.0's local-dev promise. A second miniflare serialization site, missed by 0.84.0 and caught by the first consumer verification, still failed every /media read under vite dev.

Fixed

  • The media route's second local-dev serialization site. The route called writeHttpMetadata(headers) on the object R2 returned; under miniflare's getPlatformProxy that object is an RPC stub whose method call cannot marshal a live Headers argument, so every /media read still 500'd under a consumer's vite dev. The route now builds response headers from the object's plain httpMetadata fields and never calls a method on the returned object. Verified end-to-end on a consumer checkout: seed, vite dev, and a media GET returns 200 with the stored content type. The devMediaFallback deletion note in 0.84.0's changelog applies as of this release.
  • cairn-media-seed stores each object's content type (derived from the manifest extension, passed as wrangler r2 object put --content-type), so local dev serves the same Content-Type production does instead of the route's octet-stream fallback. If you seeded with 0.84.0, re-run npx cairn-media-seed after upgrading.

Consumers must: nothing.