Skip to content

[2.0 / next] isPending(s) reads true for a signal whose writes net to its committed value in the tick an action opens a hold (D-8) #4485

Closed

Description

@ryansolid

On next @ ab3d2ad, writes that net to a signal's committed value pend it when they happen in the same tick as an action that holds another write. A render effect reading isPending(s) shows true for the whole hold. It then runs once more at the landing with the same values.

const [s, setS] = createSignal(1);
const [x, setX] = createSignal(0);
createRoot(() => {
  createRenderEffect(x, () => {});
  createRenderEffect(() => [s(), isPending(s)], v => runs.push(v));
});
flush();
let release;
action(function* () {
  setX(1);
  setS(2);
  setS(1); // nets to the committed 1
  yield new Promise(r => (release = r));
})();
await tick(); // runs: [[1, true]]   ← isPending(s) is true; unowned isPending(s) is false
release();
await tick(); // runs: [[1, true], [1, false]]

The same thing happens when setS(2); setS(1) runs on the mainline just before the action, in the same tick. When the netted writes come in a later tick, or there is no hold at all, the reader shows [1, false] and is not re-run at the landing.

Rule. D-8: "A tick whose writes net to the slot's committed value made no proposal: the slot is not held, pends nothing." So isPending(s) should be false, and the screen should be [[1, false]].

Where. The re-run is the seat table's row V2: the stagedScreen seam in read runs before any netted check and lists the reader as a stale reader of the flush's hold. I haven't traced where the true verdict comes from yet. Found while reviewing #4472. It is in the same family as #4469's landing re-runs.

Activity

  1. added 2 commits that reference this issue on Oct 30, 2026
  2. ryansolid commented on Oct 30, 2026

    @ryansolid
    MemberAuthor

    Fixed on next by #4498 (b5077ea); it ships in the next RC.


    Generated by Claude Code

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions