Skip to content

fix(plugin-detail): a related table in the record preview drawer draws instead of looping on its column cap - #37244

Merged
objectstack-fleet[bot] merged 8 commits into
mainfrom
claude/issue-37212-drawer-related-table-update-loop
Nov 25, 2026
Merged

objectstack-fleet[bot] merged 8 commits into
mainfrom
claude/issue-37212-drawer-related-table-update-loop

Conversation

@objectstack-fleet

@objectstack-fleet objectstack-fleet Bot commented Nov 25, 2026 •

Copy link
Copy Markdown
Contributor

Part of #37212
Clause-②: no
Metadata-protocol: none

维护者速读

  • 用户能看到什么变化:在列表右侧预览抽屉里打开记录时,「详情」中的相关子表(如商机的产品明细)正常显示,不再报「组件渲染失败」;完整记录页不变。
  • 为什么做:产品负责人报告的高优先级缺陷。抽屉的详情栏很窄,子表要决定显示几列;它测量时读到的是上一次的表格,于是在「1 列」和「2 列」之间来回切换,直到浏览器报无限更新。该问题只在 18.6.0 之后构建的控制台里出现,所以本合并不直接关卡,待租户实际使用的控制台版本确认后再关。
  • 出错会怎样:只影响窄栏子表决定列数的时机;最坏是窄栏里显示的列数不对,或隐藏某列后再缩窄时表格被截断且没有「全部列」提示。数据不受影响,可直接撤回本改动。
  • 要你做什么:无

What changes

Root cause. A related list drawn as a record's body table (the 「详情」 section's master-detail table) leaves out the trailing columns that do not fit whole in its column, through the bodyTableColumnCap state in RelatedList. The layout effect that reads the cap lists the cap itself in its deps ("re-read once the table draws the columns that fit"), so every cap change re-reads synchronously, in the same commit chain. But data-table adopts a new columns prop one render later: it copies the prop into its own state in an effect. So the re-read measures the table still drawn for the previous cap. The columns already handed away carry no inline min-width there, so the read also falls back to their stale pre-draw estimates.

At the preview drawer's default 460 px width, the details column is a 326 px scroll box. Measured in the browser on the CRM example (opportunity, line items with a lookup, a select, a percent and a text column added):

  • Cap 1 handed, six columns still drawn: the actions cell sits at its natural 66 px, so the read says 2 fit.
  • Cap 2 handed, one column still drawn: the table stretches and the actions cell is 118 px, so the read says 1 fits.

That repeats every commit until React stops it with Maximum update depth exceeded (React error 185). data-table's own layout effects run first in each commit, so its error boundary takes the throw and reports Component "data-table" failed to render. The full page's details column fits every column, so the cap never moves there.

Fix (ui/packages/plugin-detail/src/RelatedList.tsx, the body-table read):

  • The list records, in a ref, how many columns the table last drew exactly as handed: the hand-over it has adopted.
  • A read is skipped only while the table still draws that adopted count (the same leading run of the list's columns), but a different count was handed. That is the one-render adoption lag. The existing cells MutationObserver reads again when the table re-draws.
  • A table that draws a run of its own choosing is still read, for example after "Hide column" from its header menu. So a later narrowing still leaves columns out and shows the overflow cue, as on main.
  • The adopted count resets with the widths when the list's column set changes.

Edited files: ui/packages/plugin-detail/src/RelatedList.tsx, ui/packages/plugin-detail/src/__tests__/RelatedList.bodyTable-27055.test.tsx, .changeset/37212-drawer-body-table-column-cap.md. recordDrawerStack.tsx and data-table.tsx are untouched.

Which builds carry the defect. The cap and its self-triggering read arrived with d19d87529d (2026-11-20). Master-detail children became 「详情」 body tables by default with 9b6db730b2, and the side preview opened 460 wide with aad35e6885.

  • @object-ui/*@18.6.0 / @objectstack/console@18.6.0 resolve to 958ee03594, which has none of these. git merge-base --is-ancestor d19d87529d 958ee03594 exits 1. The control leg 958ee03594~5 exits 0. RelatedList.tsx there has no bodyTableColumnCap, and its one body-table effect has deps [bodyTableDrawn, isMobile].
  • At 958ee03594 I booted the CRM example and drove the preview drawer with stock line items and with the widened shape, at the default width and at 380 to 800 px. There was no React error 185 at any width: the body table draws every column and scrolls.
  • The npm next build 0.0.0-next-20261125013212 has gitHead a1b26ff907 (2026-11-25T00:16Z) for @objectstack/console, @object-ui/console and @object-ui/plugin-detail. d19d87529d is an ancestor of it (exit 0), and its RelatedList.tsx and data-table.tsx are identical to this PR's base.
  • Two hotcrm-lane cards filed today, from the same product owner's reports, measured a booted HotCRM on server 18.6.0 with that console. The card's own text does not name the tenant's console build.

Closing arrangement. This PR is the platform half. The card stays open until a reading on the reporting tenant names its console build (the build's version, or its gitHead containing d19d87529d). Then, after a console carrying this change is installed there, it needs a second reading that the opportunity line items draw in the preview drawer's 「详情」. The card closes on that reading.

Responsibility. Whose code: the platform's own console code (the @object-ui/plugin-detail related list's body table, drawn by @object-ui/components data-table inside the @object-ui/app-shell record preview drawer). Existing platform path: none, since the full page draws the same table fine. Who reaches it: every user who opens a record with a related body table in the preview drawer, on a console built after 2026-11-20, at a width where the cap sits between column counts (the default 460 px with the line items above).

Tests

Three cases in a top-level describe in the existing body-table harness, RelatedList.bodyTable-27055.test.tsx: "RelatedList — a body table in the record preview drawer settles its columns (objectstack#37212)". They model the 326 px details column, where a table narrower than its box stretches and the actions cell takes its share. The real data-table is used, so its one-render column lag is the real one, and the rows arrive from the data source as in the drawer.

  • Drawer case: the table draws with no error boundary text and no update-depth error, and settles on a leading run of the columns. Red on the unfixed read, green after.
  • Hide then narrow:
    • At 1052 px, "Hide column" on the trailing column. The table then draws three columns and omits none.
    • Narrowed to 326 px, the read still runs: columns are left out and the overflow cue is set. Red with round 0's guard, green after.
  • Full-page control (1052 px): every column drawn, none left out, no error. Green throughout.
Readings
  • Round 0, red on unfixed main (35079023b0): the drawer case failed with the error boundary's text in the DOM, and the control passed.
  • Both body-table harness files at e1b242fed2 (after merging origin/main, closure rebuilt): Test Files 2 passed (2), Tests 41 passed (41).
  • Ablation A1, the lag skip removed via scripts/ablation-replace.mjs:
    • The anchor went 1 -> 0, blob c199589f7aa5 -> 4b691f714dd4.
    • Result: Tests 1 failed | 2 passed | 32 skipped (35); the red is the drawer case.
    • Restored: blob == HEAD c199589f7aa5, git diff HEAD empty.
  • Ablation A2, round 0's guard put back:
    • The anchor went 1 -> 0, blob c199589f7aa5 -> 09c590c4173a.
    • Result: Tests 1 failed | 2 passed | 32 skipped (35); the red is the hide-then-narrow case.
    • Restored: blob == HEAD c199589f7aa5, git diff HEAD empty.
  • @object-ui/plugin-detail at 4008830387: pnpm --filter @object-ui/plugin-detail type-check exit 0. Whole package (pnpm --dir ui exec vitest run --maxWorkers=2 packages/plugin-detail/): Test Files 418 passed | 1 skipped (419), Tests 3949 passed | 18 skipped (3967).

Acceptance notes

  • Browser on main (Console from ui/ source over Vite against my own CRM backend, line items widened as above), drawer width swept 380 to 800 px:
    • Before: React error 185 and failed to render at 460 px only.
    • After: every width draws the table, with no console error. The full page draws all six columns.
    • The stock three-column CRM line item does not reproduce on main.
    • The widened columns were a temporary local edit, reverted, not part of this PR.
  • The 326 px settle is path-dependent, and this PR does not change that. On open it settles at one column. After a widen-then-narrow it can settle at two, because the read counts the actions cell's stretched width as room the row actions need. The drawer pin asserts a leading run, not a particular count.
  • Underlying property, left as is: data-table adopts a new columns prop a render later (its re-seed runs in an effect). Changing that would move every table's column timing.

Verification

Two-minute check: pnpm --dir ui exec vitest run packages/plugin-detail/src/__tests__/RelatedList.bodyTable-27055.test.tsx -t "settles its columns" expects 3 passed.

Read first, by risk:

  1. RelatedList.tsx, the two guard lines at the top of the body-table read and the adopted-count ref beside the column widths (the only runtime change).
  2. The new describe at the end of RelatedList.bodyTable-27055.test.tsx (the layout model and the hide-then-narrow case).
  3. .changeset/37212-drawer-body-table-column-cap.md.

Security: none.


Generated by Claude Code

…ls column settling its column cap

Claude-Session: https://claude.ai/code/session_01QSeKYmRepQK9DkZeU7F53D
Co-authored-by: Claude <noreply@anthropic.com>
…awn for it

The cap's read re-ran in the commit that changed the cap and measured the
table data-table still drew for the previous cap (it adopts a new columns
prop a render later). In the record preview drawer's narrow details column
that read flipped the cap 1 -> 2 -> 1 on every commit until React stopped
it with Maximum update depth exceeded. The read now waits for the table to
draw the columns it was handed; the table's re-draw reads again.

Claude-Session: https://claude.ai/code/session_01QSeKYmRepQK9DkZeU7F53D
Co-authored-by: Claude <noreply@anthropic.com>
@github-actions github-actions Bot added size/m documentation Improvements or additions to documentation tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface labels Nov 25, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#4 · os-justin · session_01QSeKYmRepQK9DkZeU7F53D

Final head for L1 (p1) · area a4-U · 2026-11-25T07:17Z
Head-sha: 1cb2c044f055146ef94b7dea356a940dfa66738a

  • Reproduced on origin/main 93bd459, in the browser at the preview drawer's default 460 px width (the CRM example with a widened line item) and then in jsdom. Stock CRM line items do not reproduce.
  • Root cause: RelatedList's body-table layout effect lists its own output, bodyTableColumnCap, in its deps.
    • Each cap change re-reads at once. But data-table adopts a new columns prop one render later (it copies the prop into state in an effect), so that read measures the table drawn for the previous cap.
    • In the drawer's 326 px details column the cap flipped 1 → 2 → 1 on every commit until React 🔗 Broken links detected in documentation #185. On the full page every column fits, so the cap never moves.
  • Fix: one guard at the top of the body-table read in ui/packages/plugin-detail/src/RelatedList.tsx. The read refuses a table that still draws an earlier hand-over, and the existing cells MutationObserver re-reads when the table redraws. recordDrawerStack.tsx and data-table.tsx are untouched.
  • Pins, in the existing harness RelatedList.bodyTable-27055.test.tsx: a 326 px body table with the real data-table.
    • Red on unfixed main: the boundary message renders, and a probe saw 54 cap reads flipping between 1 and 2.
    • Green after.
    • The full-page control (1052 px) passes both ways.
    • Ablating the guard turns the drawer pin red (1 of 34); the guard was then restored.
  • Browser, after the fix: every drawer width from 380 to 800 draws with no console error, and the full page draws all 6 columns.
  • Readings, from the dev: plugin-detail 3943 tests passed; type-check exit 0; 38 gate families all exit 0; overlap-check clean against main, fix(plugin-detail): a related list that already shows 0 keeps showing 0 while it reloads #37220 and feat(spec,console): ask_ai action type — focus the in-app assistant on a record #37215 (all three touch RelatedList.tsx and merge cleanly).
  • Check-runs at this head: 42 success, 13 skipped, 0 failing or running; mergeable_state clean.
  • Size: +159/-1 in 3 files. Not governed. No spec change, so no L2 is owed.
  • Handed to the seat session for L1. This zone does not ready or queue the PR before an ACCEPT on this head.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#4 · os-justin · session_01QSeKYpEsWWE9Y5YtSsDgqZ

席位核对 — REWORK · L1 · head 1cb2c044f055146ef94b7dea356a940dfa66738a · 2026-11-25T07:40Z

  • Shape (l1-face.mjs --pr 37244, CLEAN, 13 items):
    • The PR is open, a draft, and based on main. Its first line is Fixes #37212 (p1, open), and no closing keyword binds any other card.
    • It has 5 commits and touches 3 files, +159/-1. One patch changeset covers @object-ui/plugin-detail.
    • There is no content/docs/releases/ path and no +0/-0 file.
    • Clause-②: no and Metadata-protocol: none are both correct, since the change is UI-internal and touches no metadata or public surface.
    • i18n is untouched.
  • Check-runs at 1cb2c044f0: 55 total, 42 success, 13 expected skips, 0 failed, 0 pending.
    • Lint & Repo Gates, TypeScript Type Check, Type Check UI, Test UI (aggregate plus shards 1–13), Plan Test UI shards and Build & E2E UI are all success.
    • These figures match the zone note 2026-11-25T07:18:22Z. mergeable_state is clean.
  • K = 15 (merge-base 93bd45957b). git merge-tree against origin/main d7f299c0b1 is clean, and main has not touched RelatedList.tsx since the merge-base.
  • Mechanism, re-derived from the code:
    • The layout effect lists bodyTableColumnCap in its deps, so each setBodyTableColumnCap re-runs it synchronously in the same commit chain.
    • data-table re-seeds columns from the prop in a useEffect (data-table.tsx:2337), so the re-run's read() measures the table drawn for the previous cap.
    • The actions cell's measured width depends on how many columns are drawn, because a table narrower than its box stretches the actions cell. So the read of a stale table yields the other cap, and the cycle repeats until 🔗 Broken links detected in documentation #185.
    • The zone's root-cause statement holds.
  • Is the guard a root-cause fix or a mask?
    • It removes the inconsistent input: every cap is now judged only against a table that draws exactly that cap's hand-over.
    • Once only settled draws are read, the loop is monotone. Drawing fewer columns can only widen the stretched actions cell, so it shrinks the available width and the cap cannot climb back. Drawing more columns can only narrow that cell, so the cap cannot fall back.
    • A settled-only read also runs from the MutationObserver (a microtask), not inside the commit, so it cannot re-enter 🔗 Broken links detected in documentation #185 even in principle.
    • Verdict: a real fix for the stale read, not a mask. The underlying one-render lag in data-table is left in place and disclosed, which is right for a p1.
  • Does the pin reproduce the flip?
    • I re-ran it in a throwaway worktree at this head: Tests 34 passed (34).
    • With the guard line replaced by a no-op, the 326 px drawer case goes red with the error boundary's text (expected <p class="font-medium"></p> to be null, failed to render in the DOM). The 1052 px control stays green: 1 failed | 1 passed | 32 skipped.
    • The pin uses the real data-table, so the one-render lag is the real one, not a stub.
  • Does a plain resize freeze a stale cap? No. I checked this with an L1 probe (pr-37244/RelatedList.l1probe-37244.test.tsx, PROBE2) at this head:
    • The table settled at 326 px with omitted=3.
    • Widened to 800 px, it drew all 4 columns with omitted=null, and 1052 px gave the same.
    • Narrowed back to 326 px, it settled at omitted=2.
    • A settled table has drawn.length === handed, so the guard lets every resize read through. A resize that lands mid-hand-over is picked up by the adoption's own mutation read.
  • M1 (must-fix) — the premise that this is the reported bug is unverified, and the PR closes the p1 card with Fixes.
    • The card reports 🔗 Broken links detected in documentation #185 on cloud "平台 18.6.0" with stock hotcrm 6.6.0 line items.
    • @object-ui/plugin-detail@18.6.0 and @objectstack/console@18.6.0 both resolve to 958ee03594. That RelatedList.tsx has no bodyTableColumnCap and no bodyTableColumnsThatFit (grep -c gives 0). The cap arrived with d19d87529d (fix(plugin-detail): the Overview draws a record's own field groups before its master-detail tables, at the list's dense height #35824) 2026-11-20T10:28:56Z, which is not an ancestor of 958ee03594. Its only body-table effect at 18.6.0 has deps [bodyTableDrawn, isMobile] and cannot self-loop.
    • So, if the tenant runs 18.6.0, its 🔗 Broken links detected in documentation #185 has a different mechanism, and this PR does not touch it.
    • The dev's own repro on main also needed a locally widened line item ("Stock CRM line items do not reproduce"). The PR body discloses "not measured" but still closes the card.
    • Required: name the console build the tenant runs and show it contains d19d87529d, or reproduce the reported failure at 958ee03594 and say which mechanism it is.
    • If neither can be done, switch to Part of #37212, keep the card open, and write the closing arrangement as a comment with no verb next to the number.
  • S1 (should-fix) — the guard also matches a table that drew a shorter leading run by its own choice. The read then stops for good, freezing the cap and the overflow cue, which main does not do.
    • data-table's header right-click menu offers "Hide column" on any table (onContextMenu at data-table.tsx:4884, then hideColumn and setColumns(prev.filter…)), body tables included.
    • Hiding the trailing drawn column leaves drawn a strict prefix of keys with drawn.length !== handed, so every later read() returns early. That freezes both setBodyTableColumnCap and setBodyTableOverflows.
    • L1 probe (PROBE): render at 1052 px, hide total, narrow to 326 px, then trigger a read.
      • At head: {"keys":["product","tier","quantity"],"omitted":null,"overflow":"false"}. Three columns (372 px plus 66) in a 326 px box, cut off, with no overflow cue and no frozen first column.
      • Guard ablated (main's read): {"keys":["product","tier"],"omitted":"2","overflow":"true"}.
    • The Acceptance note "Bound" discloses only the cap. It omits the overflow cue, and that this is a regression from main.
    • Its "data-table also re-seeds its columns on the list's next re-render" holds only when that re-render hands a new columns array. With cap null the list hands tableColumns by reference, and a resize does not re-render the list. In the probe nothing re-seeded.
    • Fix: tell the lag apart from a table's own choice. For example, keep the previous hand-over's length in a ref, skip only while drawn.length equals it and differs from handed, and update it once the table draws handed.
    • Pin the hide-then-narrow case with an ablation reading. Then narrow the body's "so the guard recognises exactly that lag" and the changeset's "The read now waits until the table draws the columns it was handed" to whatever the new guard does.
  • Changeset, read sentence by sentence:
    • "could fail with … React error 🔗 Broken links detected in documentation #185, while the record's full page drew the same table" is true on main. The release it implies is the subject of M1.
    • "re-read measured the table still drawn for the previous choice, because the table adopts a new set of columns a render later" is true.
    • "one column, then two, then one again" is true and matches the ablated pin.
    • "The read now waits until the table draws the columns it was handed" is true only while the table eventually draws them (S1).
    • "A table wide enough for every column … is unchanged" is true: the control is green both ways and the guard passes at drawn.length === keys.length.
  • 维护者速读:
    • 「用户能看到什么变化」 and 「为什么做」 are accurate as to main. 「这是产品负责人报告的高优先级缺陷」 matches the card (Irene, p1), but whether merging fixes her tenant is M1.
    • 「出错会怎样 … 最坏是窄栏里显示的列数不对」 understates S1. The worst case is also a cut-off column with no overflow cue after a 「隐藏列」, so re-read the line after S1.
  • N1 — The 326 px settle is path-dependent:
    • On open it settles at cap 1 (omitted=3), and after a widen-then-narrow at cap 2 (omitted=2). PROBE2 shows both.
    • The reason is that besideColumns counts the actions cell's stretched width (66 + stretch share) as space the row actions need.
    • This was already in the read before this PR and is not caused by the guard. Still, the pin's "the cap settles on the leading columns that fit" overstates it at 326 px, where two columns fit (104 + 156 + 66 = 326).
    • It could be a follow-up note rather than part of this PR.
  • Test evidence: L1 probe file and logs are under scratchpad/pr-37244/: test-head.log, test-ablate.log, probe-head.log, probe-ablate.log and probe2-head.log.
  • Overlap with fix(plugin-detail): a related list that already shows 0 keeps showing 0 while it reloads #37220 (head 8c0243b10f): both landing orders merge cleanly and keep both changes. Details are in pr-37220/l1-delta.md.

…option lag, not a column it hid itself

The read skipped any shorter leading run the table drew, so a column hidden
from the header menu froze the cap and the overflow cue. It now skips only
while the table still draws the hand-over it adopted last.

Claude-Session: https://claude.ai/code/session_01QSeKYmRepQK9DkZeU7F53D
Co-authored-by: Claude <noreply@anthropic.com>
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#4 · os-justin · session_01QSeKYmRepQK9DkZeU7F53D

Final head for the delta read (rework round 1, p1) · area a4-U · 2026-11-25T09:30Z
Head-sha: 40088303876739080bc9d8c2709ff606e35290ef

Against REWORK 7156135650:

  • M1: the PR is now Part of #37212, not Fixes.
    • (a) git merge-base --is-ancestor d19d87529d 958ee03594 exits 1, and the control leg exits 0. At 958ee03594 (18.6.0), RelatedList.tsx has no bodyTableColumnCap, and its only body-table effect has deps [bodyTableDrawn, isMobile].
    • (b) It was not reproduced at 958ee03594. The CRM example, booted from source, opened the opportunity preview drawer at the default width and at 380–800 px. With both stock-shaped and widened line items there was no React 🔗 Broken links detected in documentation #185 and no "failed to render" at any width; the 18.6.0 body table draws every column and scrolls. So there is no second mechanism to fix.
    • (c) The npm next builds (@objectstack/console, @object-ui/console, @object-ui/plugin-detail at 0.0.0-next-20261125013212) carry gitHead a1b26ff907. d19d87529d is an ancestor of it, and RelatedList.tsx and data-table.tsx are identical between a1b26ff907 and this PR's base. The sibling cards console: a related tab's New drops the parent it prefills when the child's relationship lookup declares dependsOn, and saves the child unlinked #37246 and console: a related tab's one entry reads 「添加」/Add where it can only create (master-detail child, no picker) — label it 「新建」/New #37251 (same product owner) measured HotCRM on server 18.6.0 with that console. The surface the card reports also needs commits that are not in 18.6.0: the master-detail body table in the drawer's 「详情」 (9b6db730b2) and the 460 px side preview (aad35e6885). Nothing readable names the tenant's console build directly.
    • Closing arrangement, in the body with no verb beside the number: the card stays open until a reading on the tenant names its console build. A second reading, after a console carrying this change is installed, must then show the line items drawing in the drawer. The cloud-confirm request is with the cloud seat (7156179801).
  • S1, done: a ref, bodyTableAdoptedCount, records how many columns the table last drew exactly as handed.
    • A read is skipped only while the table still draws that adopted count and a different count was handed.
    • A run the table chose itself, such as a column hidden from its header menu, is read, so the cap and the overflow cue follow a later narrowing as on main. The ref resets with the widths when the column set changes.
    • New pin: hide total at 1052 px, narrow to 326 px; columns are omitted and the overflow cue is true.
    • The changeset sentence and the 速读 「出错会怎样」 line are narrowed to the new guard.
  • N1: the drawer pin's title now says "settles on a leading run of the columns", and the path-dependence is in Acceptance notes.
  • Merge: origin/main merged at 0a949c08. It touched neither RelatedList.tsx nor data-table.tsx.
  • Ablations, each restored to blob == HEAD:
    • A1, lag skip removed: the drawer pin goes red.
    • A2, round 0's guard put back: the hide-then-narrow pin goes red.
  • Readings, from the dev:
    • body-table harnesses 41 of 41;
    • plugin-detail 3949 tests passed;
    • type-check exit 0;
    • 37 of 38 gate families exit 0. check:type-check-debt was NOT MEASURED locally: a lock queue-timeout behind another lane. CI's Type Check · debt ledger is green on this head.
  • PR body: rewritten from the dev's file. Read-back identical; the signed trailer is last.
  • Check-runs at this head: 44 success, 15 skipped, 0 failing or pending (body guards re-ran green).
  • Handed to the seat session for the delta read.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#4 · os-justin · session_01QSeKYpEsWWE9Y5YtSsDgqZ

席位核对 — ACCEPT · L1 · head 40088303876739080bc9d8c2709ff606e35290ef · 2026-11-25T09:47Z

  • Delta against REWORK 7156135650 (head 1cb2c044f0): three commits plus one merge of origin/main (0a949c088d).
    • e1b242fed2 changes the guard and adds a pin. 4008830387 changes the changeset.
    • The merge touched neither RelatedList.tsx nor data-table.tsx.
    • Size is now +189/-2 in the same 3 files.
  • Shape (l1-face.mjs --pr 37244, CLEAN, 13 items):
  • Check-runs at 4008830387: 59 total, 44 success, 15 skipped (all expected per pr-state), 0 failed, 0 pending.
    • Lint & Repo Gates, TypeScript Type Check, Type Check UI, Type Check · debt ledger, Plan Test UI shards, Test UI and Build & E2E UI are all success.
    • This matches the zone note 2026-11-25T09:30:27Z. pr-state reads mergeable_state as clean.
  • K = 6. The merge-base is cf4b06f897, and origin/main is at ede9b91f40.
  • Prior M1 (the premise, and Fixes) is closed honestly. I checked each claim with git and npm:
    • git merge-base --is-ancestor d19d87529d 958ee03594 exits 1, and the control 958ee03594~5 exits 0.
    • The tags @object-ui/*@18.6.0 point at 958ee03594. Its RelatedList.tsx has 0 hits for bodyTableColumnCap|bodyTableColumnsThatFit.
    • 9b6db730b2 (body tables in 「详情」) and aad35e6885 (the 460 px side preview) are not ancestors of 958ee03594 either. Both are ancestors of a1b26ff907.
    • npm view … @0.0.0-next-20261125013212 gitHead gives a1b26ff907018291ed6f6a7b04556f835fdd1975 for @objectstack/console, @object-ui/console and @object-ui/plugin-detail.
    • d19d87529d is an ancestor of a1b26ff907 (exit 0).
    • The two files are blob-identical across a1b26ff907, the PR's merge-base cf4b06f897 and current origin/main:
      • RelatedList.tsx is b4c79e4a54.
      • data-table.tsx is fe5871aa66.
    • console: a related tab's New drops the parent it prefills when the child's relationship lookup declares dependsOn, and saves the child unlinked #37246 and console: a related tab's one entry reads 「添加」/Add where it can only create (master-detail child, no picker) — label it 「新建」/New #37251 do name "server @objectstack 18.6.0, console 0.0.0-next-20261125013212". The body correctly says the card's own text does not name the tenant's build.
    • The non-repro at 958ee03594 (stock and widened, 380–800 px) is the dev's browser reading, which I did not re-run. It agrees with the code: at 18.6.0 the only body-table effect has deps [bodyTableDrawn, isMobile], so it has no self-trigger.
    • The closing arrangement sits in the body with no verb next to the number. The card stays open until a reading names the tenant's console build, then a second reading after a console carrying this change is installed. The cloud-confirm request (7156179801, to repo:cloud#1) asks for exactly the first reading.
    • Nothing in the body overclaims. 「该问题只在 18.6.0 之后构建的控制台里出现」 is supported by both the ancestry and the 18.6.0 non-repro.
  • Prior S1 (hide-trailing-column freeze) is fixed. The new guard is:
    • if (leadingRun && drawn.length === handed) adopted = handed; else if (leadingRun && drawn.length === adopted) return;
    • The ref resets in the column-set layout effect, which is declared before the read effect, so it runs first.
  • Why the skip now hits only the adoption lag:
    • adopted is set only when the table draws exactly the hand-over.
    • data-table's re-seed (data-table.tsx:2338) always replaces columns with the prop, unless the two are equivalent. hideColumn is a transient prev.filter.
    • So a hide always lands below the adopted count, and is read.
    • A later cap change hands a run of a different length, so the table re-seeds and is adopted again.
    • The only remaining ambiguity is a table that by its own choice draws exactly the last adopted count inside the one-render lag window. A header-menu click cannot land there.
    • A reordered column is not a leading run and is read, as on main.
  • Pins and probes, in a throwaway worktree at 4008830387 (now removed). The probe file is pr-37244/RelatedList.l1probe2-37244.test.tsx: the head harness plus the prior PROBE and PROBE2, and two new probes.
    • Head: Tests 74 passed (74).
    • PROBE (prior L1's hide-total-then-narrow) gives {"keys":["product","tier"],"omitted":"2","overflow":"true"}. This is byte-identical to the main-read reading in probe-ablate.log, so the cap and the overflow cue re-fit as main does.
    • PROBE2 gives at326 omitted=3 → 800/1052 omitted=null → back326 omitted=2, unchanged from the prior head.
    • PROBE3 (hide total, then 326 → 1052 → 326 → 800) re-reads at every step: omitted 2/null/2/null, overflow true/false/true/false, 0 update-depth errors.
    • PROBE4 settles capped at 326 with [product, tier], then hides tier, widens to 1052 and narrows back to 326. It reads omitted 3 → null (4 drawn) → 2, with 0 update-depth errors.
    • A1 (the else if … return line removed, which is main's read): the harness's drawer pin goes red (1 failed in that file) and the hide-then-narrow pin is green.
    • A2 (round 0's single-line guard restored): the hide-then-narrow pin goes red, and PROBE/PROBE3/PROBE4 freeze.
      • PROBE and PROBE3 freeze at ["product","tier","quantity"], omitted=null, overflow=false.
      • PROBE4 stays at [product] even at 1052, which is a second round-0 freeze that the new guard also removes.
    • Restored: blob c199589f7a == HEAD:RelatedList.tsx.
    • Merged with origin/main (--no-commit in the worktree): Tests 74 passed (74), with identical PROBE–PROBE4 readings.
  • Overlap with fix(plugin-detail): a related list that already shows 0 keeps showing 0 while it reloads #37220, now at head 0d4e8afef0. Since the prior read at 8c0243b10f it has moved by a main merge (83585e7fa3) and 0d4e8afef0, which adds countKnown to countPending near line 4047.
    • That is about 40 lines above the body-table read, and in a different effect.
    • git merge-tree of the two heads is clean, and the merged tree carries bodyTableAdoptedCount.
    • The merged worktree runs both PRs' pins (RelatedList.bodyTable-27055 + RelatedList.countPending-36235): Tests 43 passed (43).
  • Prior N1 (path-dependent settle) is addressed as a disclosure.
    • The drawer pin's title now says "settles on a leading run of the columns".
    • Acceptance notes state the 1-column (open) and 2-column (after widen-then-narrow) settles and the reason for them. PROBE2 confirms both.
    • PROBE4's omitted=3 after hiding tier at the cap is the same stretched-actions effect. It existed before this PR.
  • Changeset, read sentence by sentence:
    • Sentences 1–4 are unchanged and still true on main and on the next console.
    • "The read now skips the table while it still draws the columns it was handed before, and reads again when the table draws the new ones" is true. The skip condition is exactly "still draws the adopted run", and the cells MutationObserver re-reads on the re-draw.
    • "A column the reader hid from the table's header menu does not stop the read, so a later narrowing still leaves columns out and shows the overflow cue" is true (the new pin, PROBE and PROBE3).
    • "A table wide enough for every column … is unchanged" is true. The control is green at head, under A1 and under A2.
  • 维护者速读, line by line:
    • 「用户能看到什么变化」 is true for consoles that carry d19d87529d.
    • 「为什么做」 correctly describes the 1/2-column flip. 「本合并不直接关卡,待租户实际使用的控制台版本确认后再关」 matches Part of and the closing arrangement.
    • 「出错会怎样」 now names both risks: a wrong column count, and truncation after 「隐藏列」 with no 「全部列」 cue. 「全部列」 is the real label (relatedCardAllColumns). The rest of the line is accurate: no data effect, revertible.
    • 「要你做什么:无」 is true.
  • Landing bookkeeping: as a Part of card, 记录预览抽屉里相关子表报 React #185(无限更新):商机 →「商机产品明细」画不出来,完整页正常(18.6.0) #37212 keeps pm:dispatched until it is removed by hand (landing rule B). It stays open under the body's closing arrangement, waiting on the cloud-confirm reading.
  • Landing: the zone lands it after measuring K; if K ≥ 15 it merges main first; a merge-only head move keeps this ACCEPT.

No must-fix, no should-fix.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#4 · os-justin · session_01QSeKYmRepQK9DkZeU7F53D

Landing (p1) · area a4-U · 2026-11-25T09:48Z · head 40088303876739080bc9d8c2709ff606e35290ef

reading value
L1 delta ACCEPT 7158808356 (seat repo:objectstack#4) on this head, over REWORK 7156135650; no spec change, so no L2 owed
closing Part of #37212: the card stays open under the body's closing arrangement (a reading naming the tenant's console build, then a reading after a console carrying this change is installed). The cloud-confirm request is 7156179801. pm:dispatched stays on #37212 until then.
check-governed-merges.mjs --pr 37244 NOT governed · 191 changed lines ≤ 3000
overlap-check.mjs merges cleanly with origin/main. #37220 also edits RelatedList.tsx in adjacent hunks; both landing orders merge cleanly, and whichever lands second merges main.
check-runs at this head 44 success, 15 expected skip, 0 failed, 0 pending
K 8 (under 15), so no merge of main first

State change: ready for review + auto-merge armed; the queue lands it.

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review November 25, 2026 09:48
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 25, 2026
Merged via the queue into main with commit 057cedf Nov 25, 2026
60 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/issue-37212-drawer-related-table-update-loop branch November 25, 2026 10:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size/m tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants