Skip to content

finding(test-env): the 7 anonSeedScope-5746 enumeration assertions all go RED on Node 26 — the localStorage probe sees zero writes #7271

Description

@hotlong

Spotted while running the app-shell suite for objectui#7253. Not caused by that change: measured with every file that PR touches checked out at origin/main, the same 7 tests fail identically.

Measurement

packages/app-shell/src/console/__tests__/anonSeedScope-5746.enumeration.test.tsx, run alone from the repo root:

node result
v22.22.3 (what .github/workflows/ci.yml pins, node-version: '22.x') Test Files 1 passed / Tests 7 passed
v26.7.0 Test Files 1 failed / Tests 7 failed

Every failure is the same shape — the instrument sees nothing:

S0 counter-probe — the instrument can see a write that is known to happen
AssertionError: expected 0 to be greater than 0
  anonSeedScope-5746.enumeration.test.tsx:319  expect(writes().length).toBeGreaterThan(0)

S0 is the file's own counter-probe, so this is not "the measured behaviour changed" — it is "no objectui:metadata:* write is observed at all", which takes S1..S6 down with it. The run also prints, once per worker:

ExperimentalWarning: localStorage is not available because --localstorage-file was not provided.

Node 22 does not print that line; Node 22+ ships an experimental global localStorage, and the suspicion worth checking first is that on the newer runtime it reaches the code under test ahead of the happy-dom one the probe instruments.

Why it is worth a card even though CI is green

The failure mode is the one this file was written against: S1..S6 read as PASSING VACUOUSLY the moment the probe stops seeing writes, and only S0 stands between that and a silently vacuous security suite. Today S0 does its job loudly. The risk is the day someone bumps the CI node version — the seven assertions that pin "no @anon seed is written / user B never renders user A's permission-filtered list" go red together, and the cheapest reading of seven simultaneous failures is "the probe is stale, relax it".

Related, not duplicate: objectui#5828 is the observation this file pins; this is about the instrument, not the behaviour.

Not investigated

Whether other localStorage-instrumented suites in this repo share the sensitivity — only this file was measured.

Activity

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

Metadata

Metadata

Assignees

Labels

domain:uiobjectui ui stream: fix lands on the published library or apps — objectui execution seatfindingpm:dispatchedpriority:p2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions