Skip to content

fix(console): long-name rule keeps -digit, emoji and opening quotes with their neighbours - #2935

Merged
freeqaz merged 4 commits into
mainfrom
ux-fixes-129-rule
Oct 19, 2026
Merged

freeqaz merged 4 commits into
mainfrom
ux-fixes-129-rule

Conversation

@freeqaz

@freeqaz freeqaz commented Oct 19, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

The long-name rule (UNBROKEN_RUN in apps/controller/src/console/agents/list.mjs) decides which Agent names may break anywhere. It missed several runs that Chromium keeps on one line, so those names stayed unmarked and widened the Agents table (bughunt-127 findings 2000, 2001 and 2002):

  • 2000: a hyphen-minus before a digit. Chromium breaks there only when an ASCII letter or digit comes before it and an ASCII digit after it (a-1, 1000-1001), or when the digit is fullwidth. отчёт-2026, é-1 and Devanagari or Arabic-Indic dates (-२०२६) do not break. The rule treated all of them as breaks.
  • 2001: 93 emoji have line-break class AL, not ID (for example ⚡ ✅ ✨ ⭐ ➕ 🔗), so Chromium keeps them with their neighbours like letters. The rule broke on every emoji. It also missed opening quotes and similar characters (« ‘ “ ‹ › ⁄ ; ։ ، U+FEFF) that Chromium keeps after a hyphen, soft hyphen, dash or wide space.
  • 2002: a hyphen or dash that starts a word after a no-break space, figure space, narrow no-break space or non-breaking hyphen holds its letter (LB20a counts these as word starts).

Change

  • New LETTER_EMOJI class: the AL-class emoji, counted like letters. The ideograph-before-joiner alternative skips them (and combining marks), so no character matches two alternatives.
  • New OPENING class, held after a hyphen-minus and after a wide space, soft hyphen or dash, next to CLOSING.
  • The hyphen-minus-before-digit rule is now two non-overlapping alternatives: after a non-ASCII-alphanumeric it holds any digit but a fullwidth one; after an ASCII letter or digit it holds any digit but an ASCII or fullwidth one. A combining mark on the hyphen holds even an ASCII digit, as in Chromium. The Arabic-Indic special case folds into this.
  • LB20a word starts include U+00A0, U+2007, U+2011 and U+202F.

The check stays linear: a scan of every code point, with each neighbour shape the rule looks at, finds no character that matches two alternatives and no combining mark that starts one. New timing payloads cover letter emoji before word joiners, Devanagari digits after letters, and word joiners before opening quotes. Each takes under 5 ms.

Verification

Storybook: new story Pages/Agents → Long name held by emoji, quotes and digits (agentsLongNameMixed). It shows a 200-character name of Cyrillic words, digits after hyphens, quoted words and ⚡ that Chromium cannot break.

  • 1440: before before 1440 after after 1440
  • 390: before before 390 after after 390

Before, at 1440 the name is unmarked, so it widens the table and pushes every other column out of view. After, it wraps within the width of its ID and all columns show. At 390 the stacked row wraps either way. The media was committed in a0a681a and dropped in the next commit, so the squash carries none.

Risks

Low. This changes presentation only. It decides which names get agent-name-unbroken, which lets a long name break anywhere instead of widening the table. A wrong "marked" costs a narrower box. A wrong "unmarked" is the pre-existing behaviour.

…ith their neighbours

The long-name rule missed runs Chromium keeps on one line, so such names
widened the Agents table:

- a hyphen-minus before a digit holds unless an ASCII letter or digit
  comes before and an ASCII digit after, or the digit is fullwidth
  (finding 2000: Cyrillic, Devanagari, Arabic-Indic);
- 93 emoji whose line-break class is AL hold like letters, and opening
  quotes and the like hold after a hyphen, dash or wide space (2001);
- a dash that starts a word after a no-break space or non-breaking
  hyphen holds its letter, and no-break characters keep a run (2002).

45 new rows, each measured against Chromium's layout; 17 fail on main.
The alternatives still never overlap, so the check stays linear; new
timing payloads cover letter emoji, Devanagari digits and quotes.
@freeqaz
freeqaz requested a review from a team as a code owner October 19, 2026 11:51
@clawsweeper

clawsweeper Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper

clawsweeper Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

ClawSweeper status: review started.

I am starting a fresh review of this pull request: fix(console): long-name rule keeps -digit, emoji and opening quotes with their neighbours This is item 1/1 in the current shard. Shard 0/1.

This temporary status tracks the active review worker. The completed review will appear in the durable ClawSweeper review comment.

Crustacean status: shell secured, claws on keyboard, evidence pebbles being sorted.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 19, 2026
Internal review: main held '-' plus a combining mark before an
Arabic-Indic digit, and the split hyphen-minus rules required the digit
right after the hyphen. Chromium holds a marked hyphen before any digit
but a fullwidth one, even after an ASCII letter ('a-' + U+0301 + '1').
Four measured rows pin it. Comments now say the infix separators and
U+FEFF sit in OPENING, and that only ASCII digits break after '-'.
@freeqaz

freeqaz commented Oct 19, 2026

Copy link
Copy Markdown
Collaborator Author

Free's clanker here. The head moved to bc5a98e after the review started on ad1c641 (internal-review nits: a combining mark on a hyphen-minus holds the digit after it, with four rows measured against Chromium, plus comment fixes). Asking for a review of the current head.

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added P2 Normal priority bug or improvement with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 19, 2026
@clawsweeper

clawsweeper Bot commented Oct 19, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR extends the Agents list’s long-name rule to recognize additional digit, emoji, quote, and no-break-space combinations.

Example: At 1440 px, an Agent has a 200-character name repeating отчёт-2026-«build»⚡deploy⚡.

  • Before: The name widens the table and pushes the other columns outside the visible area.
  • After: The name wraps within 310 px and all five columns remain visible.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) A focused, source-supported repair with meaningful browser coverage and useful screenshots, held below a pass by the repository’s incomplete visual evidence gate.
Proof confidence 🦐 gold shrimp (3/6) Real behavior proof is not required for maintainer- or bot-authored pull requests.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Some valid long Agent names push the remaining desktop table columns out of view.
Reason: The scoped cases have visible user impact, and the maintainer-authored direction continues the same owner’s existing selective wrapping design.

Merge readiness

✅ Ready for maintainer review

Keep open: this maintainer-authored PR addresses demonstrated Agent-name wrapping failures that remain on main; no introduced correctness defect was found.

Priority: P2
Reviewed head: bc5a98e9a7301120a3729c16b7177ad2a2d3ed8c

Before merge

None.

Findings

None.

Tests

  • Missing end-to-end proof: Attach final-source screenshots and a short walkthrough of the mixed-name Storybook scenario as native GitHub media, as required by the console evidence policy.
Agent review details

How this fits together

The console renders Agent names from list results, classifies long unbroken runs, and applies the existing CSS wrapping class to keep those names from widening the table.

flowchart TB
A[Agent list results] --> B[Agent name link]
B --> C[Unbroken run rule]
C --> D[Wrapping class]
D --> E[Console table layout]
Loading

Technical review

Best possible solution:

Retain the focused classifier repair and its independent browser-layout coverage within the existing selective wrapping design.

Do we have a high-confidence way to reproduce the issue?

Current-main source exposes the missed character combinations, and the inspected desktop before/after screenshots demonstrate the reported overflow; no target code was executed during this review.

Is this the best way to solve the issue?

The patch extends the established owner, preserves the threshold and CSS behavior, and checks classifications against Chromium layout while retaining timing coverage against backtracking.

AGENTS.md: found but not applied because it conflicted with ClawSweeper's review contract.

Codex review notes: model internal, reasoning medium; reviewed against acc8257ba1ca.

Provenance checked

  • Selective name wrapping and measured break classification keeps the original intent (d717962: Bound unbreakable names without changing ordinary table layout; the subsequent measured classifier refined which names need the class.)
  • Non-overlapping regex alternatives keeps the original intent (e7c2e6b: Prevent joiner-containing names from causing exponential backtracking during list rendering and search.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Labels

Label changes:

  • add P2: Certain valid Agent names obscure desktop table columns, with a limited presentation-only blast radius.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Label justifications:

  • P2: Certain valid Agent names obscure desktop table columns, with a limited presentation-only blast radius.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Complete the final-source visual evidence described in realBehaviorProof.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed October 19, 2026, 8:39 AM ET / 12:39 UTC.

@freeqaz
freeqaz merged commit 61ec422 into main Oct 19, 2026
62 of 63 checks passed
@freeqaz
freeqaz deleted the ux-fixes-129-rule branch October 19, 2026 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P2 Normal priority bug or improvement with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant