Skip to content

fork release 1: three r185 struct shape

Choose a tag to compare

@johnfewell johnfewell released this 25 Oct 14:24

Superseded by fork-release-2, which is built on the 0.19.1 / 0.9.1 release commit b1a4d628 and is a drop-in replacement for the npm packages. This release is built on upstream main and stays published for reference.

Correction (2026-10-25): an earlier version of these notes said pnpm writes URL tarballs to the lockfile with no integrity hash. That was wrong. It came from a pnpm cache primed by a failed install. With an empty cache, the lockfile records sha512 integrity for URL tarballs.

Patched builds of @takram/three-geospatial and @takram/three-atmosphere that work with three r185, which changed what struct() returns. This is an unofficial fork release. Upstream is takram-design-engineering/three-geospatial.

Source

  • Upstream base: b012ad06d858fc035d88aacfd73f092f93c994e4 (upstream main, 2026-05-27)
  • Patch commits on fork/release-1 (cherry-picked from PR takram-design-engineering#118, fix/three-r185-struct-layout, which sits on the same base):
    • 4a5da2ad11c63a5ad3b70daca2889682eb6429bb Support the struct() return shape of three r185
    • 0b801159c1048fe68aed57d12dbdde23cdee2320 Detect the r185 struct proxy without type assertions, drop the tests
    • c40936fe491cb41af0aa43c924e11066ac79ea34 fork release 1: version metadata
  • Net change against the base: packages/atmosphere/src/webgpu/AtmosphereContextBase.ts and packages/core/src/webgpu/FnLayout.ts (+27/-5), plus the two version fields.

The base is upstream main, not the 0.19.1 / 0.9.1 npm release commit (b1a4d628). The base is 127 commits past that release, and the core and atmosphere sources differ by 50 files (+1325/-949). For example, bufferGeometry was removed from core, and stars and RenderTargetNode were added.

Assets

File Version SHA-256
takram-three-geospatial-0.9.1+fork.1.tgz 0.9.1+fork.1 2891fa0d39113edb987be09547cd904ae2b3e66d4c4e5c0b90b78b6709313696
takram-three-atmosphere-0.19.1+fork.1.tgz 0.19.1+fork.1 b059c70fc4205d9886a12cca1c92ad41dc697cc1dcb692edea95368b9a1b151a

Built with node 22.23.3 (.nvmrc lts/jod) and pnpm 9.15.9: pnpm install --frozen-lockfile, pnpm exec nx run core:build, pnpm exec nx run atmosphere:build, then npm pack in dist/packages/<name>.

Versions

The package names are unchanged. A version with build metadata (+fork.1) still satisfies ^0.19.1 / ^0.9.1 and sorts the same as the release it is based on. pnpm 11.8 accepts it, though its install summary prints the version without the metadata. Use only one copy of atmosphere per app: instanceof AtmosphereContext breaks if two copies are installed.

Use

Override both names, never just one. Atmosphere depends on geospatial, so overriding only atmosphere still installs the unpatched npm core. In pnpm 11 the overrides go in pnpm-workspace.yaml.

Since pnpm 10.26, blockExoticSubdeps is on by default. When both names point at URLs, the geospatial dependency inside atmosphere is a URL sub-dependency, and the install fails with ERR_PNPM_EXOTIC_SUBDEP. Three setups were tested and pass on pnpm 11.8.0:

  1. Both names point at URLs, and the guard is turned off for the whole project.

    blockExoticSubdeps: false
    overrides:
      '@takram/three-atmosphere': 'https://github.com/johnfewell/three-geospatial/releases/download/fork-release-1/takram-three-atmosphere-0.19.1%2Bfork.1.tgz'
      '@takram/three-geospatial': 'https://github.com/johnfewell/three-geospatial/releases/download/fork-release-1/takram-three-geospatial-0.9.1%2Bfork.1.tgz'
  2. Atmosphere points at its URL, and geospatial points at a local copy of its 200 KB tarball (file:). The guard stays on.

  3. Both names point at local copies of the tarballs (file:), checked against the SHA-256 values above. The guard stays on, and the lockfile pins sha512 integrity for both.

Consumer evidence (CPU only, stock three 0.185.1 with no patch, node 24.16.0, pnpm 11.8.0)

  • With overrides pointing at these tarballs, pnpm install exits 0 with no peer warning. pnpm peers check reports "No peer dependency issues found", including for a probe package that declares peers ^0.19.1 / ^0.9.1. vite build exits 0. import('@takram/three-atmosphere/webgpu') succeeds in node (32 exports, geospatial 73). FnLayout with a struct type works, and the built bundle runs in node and prints 32 73.
  • Negative control, the npm 0.19.1 / 0.9.1 packages without overrides: vite build still exits 0, but importing fails with TypeError: Cannot read properties of undefined (reading 'name') at layer0: Re.layout.name. FnLayout with a struct type throws Unsupported layout type: [object Function], and the built bundle fails with the same TypeError.
  • Peer-check control: a probe package that wants ^0.20.0 makes pnpm peers check exit 1, which shows the check can fail.