docs(plugin-list): the sort remedy names a stored denormalised field — not the formula type the server refuses (#4335) - #4560
Merged
Conversation
… not a formula (#4335) The README's sorting section prescribed the one field type the server hard- refuses to order by: 'denormalize it onto this object with a formula field and sort that column like any other text column'. A formula value is computed on read, no driver materializes a column for it, and since objectstack#6994 the protocol answers such a sort with a 400 INVALID_SORT (UNMATERIALIZED_SORT_TYPES). objectui#4243 also withholds formula fields from the sort picker, so the 'like any other text column' clause described a column the picker never offers. Rewrite the remedy in the vocabulary the refusal door and the #4294-landed sort panel hint now share -- a stored field, written when the source changes -- name the refusal explicitly, and repair the trailing clause. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017Qqyix2QcnpUC9XeYVDzx3
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
✅ Console Performance Budget
📦 Bundle Size Report
Size Limits
|
Collaborator
Author
|
PM step-7 复核 — ACCEPT (session_017Qqyix2QcnpUC9XeYVDzx3)
Auto-merge armed (squash) — landing verified per the merge-queue discipline. Generated by Claude Code Generated by Claude Code |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #4335
packages/plugin-list/README.md, section "Sorting (and why relational columns are not offered)", prescribed the one field type the server hard-refuses to order by — and the sentence after it described a column the picker no longer offers. Docs-only: one file, no runtime change, no strings, no tests.Before
After
Every factual claim, verified at its source
Read-only, at objectui
origin/main@a90888230and objectstackorigin/main@5d24f4b94."denormalize ... as a stored field, written when the source changes" is the shared vocabulary. Measured first, per the ruling. The landed [i18n] The list sort panel's relational hint recommends a formula field, which the server refuses to sort by (400) #4294 hint —
packages/i18n/src/locales/en.tslist.sortRelationalHint, byte-identical to the provider-less fallback inpackages/plugin-list/src/ListView.tsx— reads: "To sort by that name, denormalize it onto this object as a stored field, written when the source changes, and sort by that. Not a formula field: it is virtual, so no column is stored for it and the server refuses to sort by one." The server's refusal hint (objectstackpackages/metadata-protocol/src/protocol.ts) says the same thing in the same words: "Denormalise the value onto '${object}' (a stored field, written when the source changes) and sort by that. A formula field is virtual: with no column behind it the ORDER BY reaches the driver, finds nothing, and is dropped." The README now uses that vocabulary too, so the three surfaces read as one voice."a hard
400 INVALID_SORT". objectstackprotocol.ts:UNMATERIALIZED_SORT_TYPESisnew Set(['formula']); the sort gate filters the requested names through it and, on a hit, throws viainvalidSortError, which setserr.status = 400anderr.code = 'INVALID_SORT'. Cited by behavior, not line number — the card's:1593and the triage comment's:1903disagree, and the constant is what is stable."since
objectstack#6994" — the refusal branch is introduced by a comment naming that issue as "the third verdict on this axis"."before that it degraded silently: ... arbitrary order under a
200,ascanddescidentical". The same comment carries the measurement that motivated the refusal: a formulaorderByreturned five rows under a 200 in an order matching neither direction, withascanddescbyte-identical."The picker withholds formula fields for the same reason (
objectui#4243)".ListView.tsx:UNSORTABLE_FIELD_TYPES = new Set(['formula']), and thesortFieldsmemo pushes a field only when it is neither relational nor in that set — so the old "sort that column like any other text column" named a column the picker does not list. That is what the repaired clause now says."stays listed under both rules ... a sort the server would refuse can still be edited away". Same memo: the
inUseexception applies to both the relational and the unsortable branch, and only relational entries get the(by ID)suffix (list.sortByIdSuffix). The README previously described this exception as relational-only.Verification
Plus a self-scan of the edited file for raw control bytes beyond the gate's surface —
grep -naPover thex00-x08 / x0b / x0c / x0e-x1f / x7frange: no matches.eslint/tsc/vitestare not implicated by a.md-only change and were not run.Changeset: none — the presence gate's own verdict, quoted above.
README.mdis not under a package'ssrc/.Surface
packages/plugin-list/README.mdonly (16 insertions, 4 deletions, one file). No locale packs, nosrc, nocontent/docs/releases/.Out of scope, filed not fixed
#4559 —
ListView.tsx's own comment above thesortFieldsmemo still calls a formula field "the supported alternative ... which sorts like any text column", describing a hint that has said the opposite since #4294 and code that filters it out. Observation-class (a comment; nothing renders it), sofinding, unassigned, nopm:queue.Generated by Claude Code