docs(spec): state what the object-* blocks declare on record_picker filter docblock - #17657
docs(spec): state what the object-* blocks declare on record_picker filter docblock#17657os-bill wants to merge 1 commit into
Conversation
… filter docblock The `filter` docblock on `ElementRecordPickerPropsSchema` (anchor: `Filter rules narrowing which records the picker offers`) claimed that "the four `object-*` blocks declare `filter` as `z.unknown()`, no orthography at all". Measured on `packages/spec/src/ui/component.zod.ts`: zero occurrences of a `filter` key declared `z.unknown()`, against 61 occurrences of `z.unknown()` in the same file on the same instrument. All eight Zod `filter` declarations in the file are `z.array(ViewFilterRuleSchema).optional()`. The `object-*` family in `ComponentPropsMap` has six entries, not four. Four of them carry a `filter` door -- `object-grid`, `object-metric`, `object-kanban`, `object-calendar` -- and each declares `z.array(ViewFilterRuleSchema)`. The other two, `object-form` and `object-master-detail-form`, declare no `filter` key at all. The corrected parenthetical states both numbers, names all six and keeps the existing provenance citation unchanged. Prose only: no declaration moves and no accept set changes. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MkQhmuuJAVDjmeWNixwDDH
|
Supersedes #17652, which is now closed. ⛔ Its branch is deliberately left in place. #17652 carried the identical correction; its commit message also carried Generated by Claude Code |
📓 Docs Drift Check1 anchor(s) derived from 1 changed package(s); no hand-written page names any of them, so this run has nothing to list — not a clean bill of health. This check sees only pages that NAME a derived anchor: one that documents this change in prose, or enumerates it in an authoring dialect, names none and stays invisible to it on every run. What this run could not see
Coarse fallback — 135 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): Which tree this was computed onThis run read A worktree cut from an older # while this PR is open — GitHub drops the merge commit once it closes
git fetch origin bdeb98399615fc745574eb38336f7c23a08f05b4 && git checkout bdeb98399615fc745574eb38336f7c23a08f05b4
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin d07fc178b9ae778e3dca988c641d18065d8f392b c65d38699c3f2a31999c77f6485b4433cc667b2f && git checkout -B drift-repro d07fc178b9ae778e3dca988c641d18065d8f392b && git merge --no-ff c65d38699c3f2a31999c77f6485b4433cc667b2f
node scripts/docs-audit/affected-docs.mjs --json d07fc178b9ae778e3dca988c641d18065d8f392b |
Part of #17475
Correcting one parenthetical in the
filterdocblock onElementRecordPickerPropsSchema. Prose only: no declaration moves, no accept set changes, no schema is touched.Supersedes PR #17652
#17652 carried the identical correction but its commit message also carried
Part of #17475. The card relation is declared once, in the PR body; a commit carries no card trailer, socheck:partof-closing-keywordwas red there. On an already-pushed branch nothing clears that without a history rewrite, and amend / rebase / force-push are forbidden here — so this is a fresh branch off currentorigin/main, not a rewrite. ⛔ Nothing published was rewritten and the old branch is left in place.Content identity proven, not assumed —
git hash-objecton this branch againstgit rev-parse 567cb419f8:PATH:packages/spec/src/ui/component.zod.tsd81a58da6cd81a58da6c.changeset/17475-record-picker-filter-docblock.mdbc9a24292cbc9a24292cLit control on the same instrument:
AGENTS.md, a path deliberately not copied, readsd756b7c087here against94cac72c99there — so the comparison could have come back the other way.git log 567cb419f8..origin/mainover both paths is empty, so nothing onmainwas reverted by taking them.Commit message, checked before the push (occurrences via
grep -o | wc -l, nevergrep -c):Part of,Part-of,Refs,Fix/Fixes/Fixed,Close/Closes/Closed,Resolve/Resolves/Resolvedand#[0-9]+each read 0; lit controls on the same text readCo-Authored-By1,Claude-Session1,object-*3,filter10.Gate run on two legs, because a green whose instrument cannot fail is not a reading:
scripts/check-partof-closing-keyword.mjsexits 0 on this commit and 1 on6f2d6d9ac, naming that commit'sPart of #17475.Generators re-run on the newer base:
pnpm --filter @objectstack/spec buildthengen:docs(222 files) leave the tree carrying only the two paths above. ⛔ No generated artefact was hand-edited.The falsified sentence
The docblock (anchored by content:
Filter rules narrowing which records the picker offers, never by line — the block moves) claimed:Re-measured on
origin/main, not inherited from the cardThe card's census is from
fd62a66b7c; this branch was cut from76c9fab30cand then mergedorigin/mainatbc2bf01c8a. Every number below was taken again on that tree.1. Census — occurrences, not lines (
grep -o | wc -l, ongit show origin/main:packages/spec/src/ui/component.zod.tsso no builtdist/is in the population):filter: z.unknown()— darkz.unknown()— lit control, same file, same instrumentViewFilterRuleSchema— lit controlThe lit controls come back non-zero on the same instrument and the same file, so the dark zero is a reading and not a matcher that finds nothing.
Eight Zod
filterdeclarations exist in the file and all eight arez.array(ViewFilterRuleSchema).optional()(lines 1122, 1158, 1853, 2229, 2490, 2704, 2772, 2882 onorigin/main). A ninthfilter:line, at 1460, is aKeySetGuidanceprose string — not a declaration. The card'sgrep -n '^ filter:'reading of 7 is the two-space-indent subset of the same set.2. The
object-*block count — measured, not copied. The docblock says four. The family is six:ComponentPropsMapkeyfilterdoorobject-gridObjectGridPropsSchemaz.array(ViewFilterRuleSchema).optional()object-metricObjectMetricPropsSchemaz.array(ViewFilterRuleSchema).optional()object-kanbanObjectKanbanPropsSchemaz.array(ViewFilterRuleSchema).optional()object-calendarObjectCalendarPropsSchemaz.array(ViewFilterRuleSchema).optional()object-formObjectFormPropsSchemaobject-master-detail-formObjectMasterDetailFormPropsSchemaSo "four" is right as a count of
filterdoors and wrong as a count of the family — and the sentence gave no way to tell which it meant. The file's own header says so independently:#7751 then GREW the map by the object-* block family -- six entries. The corrected prose states both numbers and names all six blocks.3. #17166 / PR #17473 landed and did fence this key out.
7aae0050bb docs(spec): name all five exportOptions members on object-grid, not two (#17473)is an ancestor oforigin/main(git merge-base --is-ancestorexit 0 — positive ancestry, which is self-certifying even on this shallow checkout). Its diff tocomponent.zod.tstouches zero lines containingfilterorobject-*. Unpaid work, not a duplicate.4. Wrap-across-line-break handled. Under a naive whitespace flatten the target sentence reads 0 in the source — because a JSDoc block carries a leading
*on every line. Stripping the comment prefix before collapsing gives 1. That zero was a mistyped anchor, not an absence, and the edit was anchored on the contiguous two-line span with a uniqueness assertion (hits !== 1aborts).The correction
The parenthetical now folds the four
filterdoors into the enumeration of array-declared doors it belongs in, keeps the#15449citation as provenance for when they moved, and names the two blocks that carry nofilterkey at all.Generated pages: verified on this tree, with a live control
pnpm --filter @objectstack/spec gen:docsregenerates 222 files and leaves the tree clean — a comment docblock is not a.describe(), socontent/docs/references/**does not move.That clean reading is admissible because the instrument was shown to swing the other way. Positive control,
trap-restored: a marker was appended to a neighbouring.describe()string on the same schema, proven on disk (grep -c0 → 1; blob hashd81a58da6c→e341d20797), thengen:schema+gen:docswere re-run —content/docs/references/ui/component.mdxwent modified. Restored withgit checkout HEAD -- ..., hash back tod81a58da6c,gen:schema+gen:docsre-run from the restored source,git status --porcelainempty.A first attempt at that control is reported rather than hidden: it exited 1 on a prerequisite refusal (
packages/spec/json-schema is older than packages/spec/src), which measured nothing and was discarded, not retried in silence.Why a changeset, measured rather than assumed
@objectstack/specfiles[]shipsdistandsrc/**/*.zod.ts. After a build, the corrected sentence is present in 2 published dist files (dist/ui/index.js,dist/ui/index.mjs) and the old falsified fragment in 0; the lit control (the sibling.describe()prose) hits the same 2 files. The docblock ships.patchon@objectstack/spec.Verification
Run at
567cb419f8on the superseded branch; the content of this branch is byte-identical (proof below), rebuilt and re-generated on the newer based07fc178b9.pnpm --filter @objectstack/spec build—VERDICT command-exit 0.pnpm --filter '@objectstack/spec^...' build— empty run:No projects matched the filters.packages/spechas no workspace dependencies, so the closure leg measured nothing and is reported as such.pnpm --filter @objectstack/spec typecheck—VERDICT command-exit 0;check:test-typecheck: OK — 54 file(s) / 259 error(s) / 144 pinned signature(s) held.pnpm --filter @objectstack/spec test—VERDICT command-exit 0;Test Files 473 passed (473),Tests 13429 passed (13429).pnpm lint(eslint . --no-inline-config, the repo-wide population) — exit 0. Run whole, at this HEAD, so no narrowing is claimed and none needs defending.node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack(change set taken by the script from the merge base, not hand-listed): 76 derived, 75 run green, 1 NOT MEASURED, 0 unrun, reconciled with--rancarrying a recorded exit code per family.Two families were re-run rather than reported from a misinvocation:
check:doc-formula-expressionsfirst exited 3 —PREREQUISITE NOT MET, unbuilt@objectstack/formula/@objectstack/lint. Nothing was measured. After building both: exit 0.check:react-declaration-parityfirst exited 1 withMANIFEST is not set — this gate did NOT run. Re-run as CI runs it (MANIFEST="$PWD/sdui.manifest.json" ... --baseline react-declaration-parity.baseline.json --strict): exit 0,no new DECLARATION divergence vs accepted baseline.check:lean-entry-closurefirst exited 3 on an unbuilt@objectstack/objectql. After building it: exit 0.NOT MEASURED, declared:
pnpm check:dual-build-cjs-loadsexits 3 —PREREQUISITE NOT MET, 48 packages have nodist/; clearing it is a repo-widepnpm build, which is CI's run and not this round's. Recorded as exit 3, never as a pass.🤖 Generated with Claude Code
https://claude.ai/code/session_01MkQhmuuJAVDjmeWNixwDDH
Generated by Claude Code