Repository navigation
fix(plugin-dashboard): a record opened from a drill counts and steps through the whole drill - #36658
Conversation
… whole drill ListViewBlock no longer shadows a host's onTotalChange with the tab count; ListView reports the query behind its rows (onFindParamsChange); the drill reads its whole result's ids with that query for the record page's stepper. Claude-Session: https://claude.ai/code/session_01JQwxbZkNEjKLHtTo4edMVH Co-authored-by: Claude <noreply@anthropic.com>
…e drill Claude-Session: https://claude.ai/code/session_01JQwxbZkNEjKLHtTo4edMVH Co-authored-by: Claude <noreply@anthropic.com>
…e the whole drill Claude-Session: https://claude.ai/code/session_01JQwxbZkNEjKLHtTo4edMVH Co-authored-by: Claude <noreply@anthropic.com>
|
repo:objectstack#1 · os-warren · session_01JQwxbZeHNsF3RWcWpj7rGj Contract reviewServed-tier: ① Derived judgmentsThe published surface is exactly the one additive prop. No index file is in the diff. The prop is truly optional. It is declared The declarations are true. Nothing in the diff is under ② Semver levelCorrect. The changeset grades
③ Boundary flagsmust-fix — the deferred open has no live guard, so a cancelled drill still navigates. should-fix — the windowed replay has no unique tiebreak and no dedupe. note — the filter, sort and search are carried exactly. The replay copies note — row-level permissions are unchanged, no widened grant. The ids come from the same adapter, the same object and the same filter the list already ran, with note — the cap and the fallbacks. Over 1,000 matches the walk stops at the first 1,000; a record past the cap, a read that throws, or a result that moved under the list all return the drawn rows with the full total. The user then sees 「第 N 条,共 M 条」 with ↑ ↓ stopping before M. That is the platform's established shape, not a new one: note — cost, and a degradation nothing records. Up to ten parallel note — the click has no pending affordance. The row click now does nothing visible until the read settles, and a second click on another row in that window is dropped by Double
No test weakened. Both touched test files are additions only — a new top-level Server write authority and data authority are unchanged. No server, REST, driver, permission or spec code is in the diff. The only new behaviour on the wire is an id-only read of a query the viewer had already run. ④ Design judgmentAgainst card #36554 and item 6 of #36256 the fix lands. Item 1 is done where the card said the defect was, in Item 2 asked for the drill's total and its condition to reach the record page, "paging as needed". The PR does not do that: it pre-reads the ids in the drill and hands a flat sibling list, leaving One cross-surface effect is worth keeping in view: the drill's record page now steps further than the console object list page's does, which still walks only the rows it loaded. The PR notes it and does not file it. That is the right disposition for now. The shape of the work is good — narrow, additive, reversible, read-only, documented in the README and in the prop's own comment, with a red leg measured. What keeps it from passing is the async seam it introduces: an open that can fire after the user cancelled, and a windowed replay that is not ordered well enough to be the authoritative record sequence it is handed off as. Implemented-by: VERDICT: FAIL |
…oses; read its step set in a stable order Review round 2 on the drill's whole-result step set: - The deferred open checks that the drill is still open and mounted and that no later click started another open; otherwise it is dropped, so Esc or an outside click while the ids are read navigates nowhere. - The id read appends `id` as the last tiebreaker to the list's sort (`id` alone when there is none) and deduplicates the ids, so parallel windows over a sort with ties neither repeat nor skip a record. - A failed read is warned once. Claude-Session: https://claude.ai/code/session_01JQwxbZkNEjKLHtTo4edMVH Co-authored-by: Claude <noreply@anthropic.com>
|
repo:objectstack#1 · os-warren · session_01JQwxbZeHNsF3RWcWpj7rGj Contract reviewServed-tier: ① Derived judgmentsUnchanged from round 1, and still true. The delta touches only plugin-dashboard source and two test files. It adds ② Semver levelUnchanged. The changeset is byte-identical to round 1: both entries ③ Boundary flagsRound 1 must-fix (open after cancel): closed. Every path that navigates or calls Round 1 should-fix (unstable windows): closed. Descending id sort: handled. The check is on the last key's Id field named differently: no new exposure. The tiebreak always names Changed exact-param assertions: only this PR's own. The one edited expectation, note — within a tie, the step set's order can differ from the screen's. The list draws its page with no tiebreak, and the read-back sorts ties by note — the failure warning. Round 1's bare note — the page-size and row-budget limits. The module comment and the Round 2 acceptance notes now say what round 1 noted: note — the changeset body. It still says the read-back uses "the same filter, sort and search", without naming the appended Everything round 1 confirmed still holds at the new head. Filter, sort and search are carried; the read is the same query, ids only, so no grant widens; there is no render loop; and no server write or data authority changes. The PR body's Round 2 section matches the code. ④ Design judgmentRound 1's judgment stands. The fix meets #36554's "Done when" and #36256 item 6 by pre-reading ids, a declared, bounded divergence from the card's "paging as needed". The rework is narrow and correct. It replaces the drop-the-second-click guard with "the last click wins, and nothing opens once the drill is closed or gone", which is the better rule. It gives the windowed read a total order and an exact-once guarantee. And it says the failure once. No new surface, no new state shared beyond the component. Implemented-by: VERDICT: PASS |
|
repo:objectstack#1 · os-warren · session_01JQwxbZeHNsF3RWcWpj7rGj 维护者速读从仪表盘下钻的明细里点开一条记录,记录页上的「第几条 / 共几条」和上一条、下一条现在按整个下钻结果来算,不再只算第一页。 席位核对 — ACCEPT (L1) · repo:objectstack#1 · head
|
Requested by Warren · project thread
Fixes #36554
Clause-②: yes (widening) — one additive member,
ListViewProps.onFindParamsChange(@object-ui/plugin-list); nothing is removed or renamedMetadata-protocol: none
The remainder of the drill-dialog card #36256 (after PR #36461): the one open defect against its item 6, and the 「上季度」 acceptance line re-read on data that has last-quarter values. Card #36256 stays open on this merge; whether it ends once this lands is the seat's call (the re-check below reads as passed).
维护者速读
What changes
list-viewpage block handed the list its own tab-badge reporter asonTotalChangeafter spreading the host's props, so a host'sonTotalChange(the drill's) was never called. The block now calls both: the host's and the tab badge's.ListViewgains a host prop,onFindParamsChange(findParams), called with the params of the read that drew the rowsonRowsChangereports, each time that query settles with a different answer, keyed on its content. It answers whereonRowsChangeanswers with rows (a paged grid that draws the rows it fetched) and answersnullfor any other kind.DrillRecordListkeeps that query and, when a record name is clicked and the count exceeds the rows drawn (or the rows drawn are a later page), re-issues it for ids alone (drillRecordOrigin, newdrillRecordSteps.ts): the same filter, sort and search,$select: ['id'], window by window at the list's own window or 100, whichever is wider, up to 1,000 ids. The record page gets those ids as its step set and the drill's count, so 「N of M」 says where the record sits in the whole drill and ↑ ↓ walk all of it. No record page, history-state shape orDrillRecordOriginchange.$orderbyis the list's sort withidappended as the last tiebreaker (idalone when the list sends no sort; a sort already ending onidis kept), and the ids are deduplicated in order. The deferred open checks that the drill is still open and mounted and that no later click has started another open; otherwise it is dropped, so Esc or an outside click while the ids are read navigates nowhere and does not close a drill opened since. A failed read is logged once (console.warn) and keeps the rows drawn.ui/packages/plugin-list/README.md(the block's two count listeners, the new host prop). Changeset:.changeset/36554-drill-record-steps-whole-result.md(patch,@object-ui/plugin-dashboardand@object-ui/plugin-list).Tests
Base
3cf6a44b, head named in the hand-off; all runs underos-verify-lock, fromui/withvitest run --maxWorkers=2.drillDialogStandardList-36256.test.tsx(the reallist-viewin the real drill dialog), new describe for A record opened from a drill counts only the drawn rows: 「共 N 条」 and previous / next ignore the drill's total #36554: a drill whose read matches 40 and draws 2 opens a record with all 40 ids, in order, andtotal: 40; every id read carries the drill's condition and no write is made. Control: a drill whose 3 rows are its whole result hands{ siblings: [d1, d2, d3], total: 3 }and makes no id read.ListView.harness.test.tsx, new describeListView.onFindParamsChange-36554: a paged grid reports exactly the params of the read that drew its rows; a calendar reportsnull.drillRecordSteps-36554.test.ts: the query kept and stripped, a later page read from the start, the 1,000 cap walked in windows, the list's wider window, no read (and no promise) when all is drawn, and the drawn rows kept on no query, no count, a failed read or a moved result.git restore --source=3cf6a44b, tests committed), the two harness describes readTests 4 failed | 133 skipped (137)(expected undefined to be 40; the controlexpected { siblings: [ 'd1', 'd2', 'd3' ] }withouttotal;onFindParamsChangenever called). Restored withgit checkout HEAD --;git diff HEADempty.packages/plugin-dashboard/ packages/plugin-list/ packages/plugin-report/plus app-shelldrill*,pageBlockDrill*,useOpenRecordList*,DashboardView*,ReportView*andpage-tabs-list-count-26613:Test Files 1 failed | 468 passed (469)on the first head. The failure wasDrillDownDialog-36256"the record's name opens its page with the shown rows", which assertsopenRecordsynchronously; the drill now opens at once when no read is owed (no assertion edited), and the file plus the four drill suites readTest Files 5 passed (5), Tests 24 passed (24).type-check(tsc --noEmitandtsconfig.test.json):@object-ui/plugin-list,@object-ui/plugin-dashboard,@object-ui/app-shell, each exit 0, after the@object-ui/app-shell^...closure build.Round 2 (contract review 7097462049)
dc1c6c89(the three source files restored from it, new tests kept:Tests 8 failed | 9 passed (17)), green at the new head (17 passed (17)):drillDialogStandardList-36256.test.tsx: with the id reads held, closing the drill (open→ false) and then answering the reads opens no record and closes nothing; the same after the drill unmounts; two clicks while the read is held open only the second record, with the whole step set.drillRecordSteps-36554.test.ts: 150 rows tied on the list's sort across two 100-row windows, from a source that answers ties in a different order per window unlessidsettles them: every window carries[amount desc, id asc]and the step set is each id once, in order;idalone when there is no sort, anidsort kept as written; a boundary row two windows both answer is counted once; a failure is warned once over two failed reads. The first test's exact-params expectation now names the appended tiebreaker.packages/plugin-dashboard/ packages/plugin-list/ packages/plugin-report/plus the app-shellDashboardView*,ReportView*,drill*,pageBlockDrill*,useOpenRecordList*tests:Test Files 468 passed (468),Tests 4742 passed | 13 skipped (4755).Gates
dispatch-gates --commandsderived 38 families; all run, each:: exit 0;--ran: "38 derived famil(ies) accounted for — 38 run, 0 NOT-MEASURED (a DERIVED zero — all 38 recorded an exit code and none of them is 3)".vitest run scripts/:Test Files 172 passed | 2 skipped (174).check:new-line-citations: 0 new.check:nul-bytes: OK.overlap-check:VERDICT clean exit 0againstorigin/main3cf6a44, no open PR head shares a file.Verification
Browser, the showcase app (
objectstack dev --freshon a random port, the Console vite server on another, both stopped after), 1440×900. Screenshots are in the project thread's files (issue-36554/), not inline: this branch is the only ref the session may push.4 records, and the read isfilter=["and",["issued_on",">=","2026-07-01"],["issued_on","<=","2026-09-30"]]. No non-GET request was sent from opening the drill. The record name opens the invoice page, which reads 「1 of 4 · Revenue Pulse」; Next gives 「2 of 4」.60 records. Opening the 50th drawn row: the page reads 「50 of 60」, one id read went out (top=100&select=id), and Next steps to a record the drill never drew, 「51 of 60」. On main the drill never hears the count and hands only the drawn rows, which the red leg above measures in the harness; main itself was not walked in the browser.Two-minute check: run the
drillDialogStandardList-36256file; the #36554 describe expects 40 ids andtotal: 40from a drill that draws 2.Acceptance notes
max(list window, 100)rows per request, and its last window reaches$skip900 for a 1,000-id read. Neither limit is set by default (packages/types/src/query-read-limits.ts:OS_DATA_MAX_PAGE_SIZE"no maximum",OS_DATA_QUERY_ROW_BUDGET"no budget"); a deployment that sets the page size below 100 or the row budget below the walk refuses the read, and the record page then keeps the rows drawn (as before) with one console warning, not an error.Human Minimum
packages/specholds no runtime logic. (No spec change.)pnpm lintpasses (changed files: 0 errors).main, one pull request.packages/spectouched: n/a.content/docs/references/,packages/*/CHANGELOG.mdorcontent/docs/releases/.🤖 Generated with Claude Code
https://claude.ai/code/session_01JQwxbZkNEjKLHtTo4edMVH
Generated by Claude Code