Skip to content

Two people pressing Enter and typing at the document end sometimes leave one extra character #800

Open

Description

@HMarzban

Problem

Two people who press Enter and type at the same document end, at the same moment, sometimes end with one extra character. Both clients still converge on the same text, so nothing diverges, but the text is not exactly what was typed.

Found 2026-11-16 in the #701 browser checks: 1 of 15 runs on y-tiptap 3.3.0 with Tiptap 3.33.1, and 1 of 15 runs on y-tiptap 3.0.10 with Tiptap 3.32.2. It also showed once in content-safety check 2 (two browsers). So it is older than the #701 bump.

What is known

  • Setup: local make dev-local, two Playwright Chromium 156 contexts, users A and B, one scratch pad. Each user pressed Enter at the document end, then typed a short marker, at the same time.
  • In the bad runs the final text held one character more than the two markers. Both editors and the stored head agreed.
  • Not yet known: which character is doubled, whether it comes from the Enter split or the typing, and whether the server, y-tiptap or ProseMirror's input handling adds it.

Benchmark

Field Value
Metric Runs where the final text equals exactly what was typed, of n concurrent Enter-and-type runs at the document end
Before 14 of 15 on each version (2026-11-16, local, Playwright Chromium 156)
After not measured yet
Pass rule 50 of 50, or a named cause that shows the extra character is expected CRDT behaviour

Steps

  1. Agent in the repo: turn the Take y-tiptap 3.3.0 with Tiptap 3.33.1 and drop the local y-tiptap patch #701 two-browser script into a repro with n = 50, and log both users' steps and the Yjs updates for each bad run.
  2. Agent in the repo: name the doubled character and the layer that adds it.
  3. Then propose a fix, or explain why it is expected and close.

Evidence: the #701 check results (comment #701 (comment)).

Activity

  1. added this to the v2.3.7 milestone on Nov 16, 2026
  2. added
    bug
    Editor
    on Nov 16, 2026
  3. modified the milestones: v2.3.7, v2.4.0 on Nov 16, 2026
  4. HMarzban commented on Nov 16, 2026

    @HMarzban
    CollaboratorAuthor

    Moved to v2.4.0 by the 2026-11-16 review (maintainer approved). Both clients converge, so this is not data loss, and no v2.3.7 change caused it.

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

    Editorbug

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions