Repository navigation
feat(app-shell): the publish sheet speaks the console's language, and a load error the server answered shows its code and sentence - #29780
Conversation
…nguage and lists no key list for a new item Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QsR2jVQc3uTU5ZhjP31Sh8
…nce, on the list page and the record page alike Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QsR2jVQc3uTU5ZhjP31Sh8
… a new item with no key list and the object extension group Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QsR2jVQc3uTU5ZhjP31Sh8
… the list, record and app pages; no answer keeps the network sentence Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QsR2jVQc3uTU5ZhjP31Sh8
…load errors Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QsR2jVQc3uTU5ZhjP31Sh8
|
Contract-review-claim: session_01QsR2jV5sBSzCYNEDgpYLJw · head eae9d62 · 2026-11-03T04:28Z Generated by Claude Code |
|
director#1 · zhuangjianguo · session_01QsR2jV5sBSzCYNEDgpYLJw Contract reviewServed-tier: Read-only; nothing built or run. Card #29704 (publish sheet in plain words; load errors carry the server's reason). ① Derived judgments
② Semver level
③ Boundary flags
④ Design judgment
No must-fix. No should-fix. Implemented-by: VERDICT: PASS Generated by Claude Code |
|
domain:ui#5 · zhuangjianguo · session_01QsR2jQjvWkZ7is6GXbC6DB 席位核对 — ACCEPT ·
|
Requested by Steedos · project thread
Fixes #29704
Clause-②: yes (widening)
Metadata-protocol: none
维护者速读
overrides声明。新增项不再列出属性清单和「平台生成」分组,对象扩展分组显示中文名「对象扩展」。列表页、记录页、应用页和相关列表在加载失败时,如果服务器有回复,就显示它给出的原因和错误码(如 404OBJECT_NOT_FOUND)。只有请求完全没有得到回复时,才提示「请检查网络连接后重试」。+ overrides、+ isDefault这类内部键名,看不懂。Studio in zh-CN: a new object publishes "successfully" and never reaches the data plane, because its echoed queue column carries a translated label #29673 中对象注册失败时,服务器已经明确回复了原因,页面却让人去查网络,排查方向完全错误。ui/packages/app-shell/src/preview/DraftChangesPanel.tsx的EntryDetail,以及ui/packages/react/src/utils/error-message.ts新增的answeredLoadFailure(四个页面共用的唯一判断规则)。OBJECT_NOT_FOUND,应看到服务器的原句和错误码,而不是网络提示。下方 Verification 附有前后截图。What changes
Publish sheet (
DraftChangesPanel)localizeMetadataForm, thentranslateSchemaFieldLabel. The machine-name chip is still judged on the spec's source label (objectui#8231). To keep the studio namespace off the console's eager graph,isZhLocaleand the schema-field label tables moved verbatim into a new import-free leaf,views/metadata-admin/schema-field-label.ts, andi18n.tsre-exports them.Object.keys(OverrideDeclarationFields), i.e.overrides) is dropped where the protection envelope is dropped, so a customized item no longer lists+ overrides.preview.changes.detailNewItem). It lists no key rows and no 平台生成 group. Updates keep both.object_extensionhas a count family in all ten packs (preview.changes.typeCount.object_extension), so its group reads 「对象扩展 N」 / "N object extensions".Load errors
answeredLoadFailure(err)in@object-ui/react, besideclassifyLoadError, exported with its type. It returns the server's{ code, message }when a server answered, andnullotherwise. A server answered when the error has a numerichttpStatus,statusorstatusCode, orHTTPplus three digits in its message. The sentence comes fromextractWriteErrorMessage, or from a wrapped{ error: { code, message } }body parked underdetails. RelatedList's localserverSentencerule is lifted into it.networkwith an answer shows the server's sentence and alist-error-codechip. The network sentence stays for no answer. Refused, unauthorized, rejected and api-disabled kinds keep their own fixed copy.failedand PageView's record scopefailedfollow the same rule (record-load-failed-code,page-record-load-failed-code). RelatedList now reads the shared helper and shows the code too.console/AppContent.tsx(RouteObjectReadFailed, withMetadataProviderandappObjectScope) is filed as console: a route whose object read was answered (5xx, or a 404 with an unknown code) says "check your connection" instead of the server's reason #29728.Tests
DraftChangesPanel.namedChanges-27835:~ 列数and~ 显示名称, with nooverridesand no English label;computeChangeDetaildrops the declaration;draft-entry-newand no key rows, with noviewKind,isDefaultor "Includes:".DraftChangesPanel.groupHeading-13221: anobject_extensiongroup reads 「对象扩展 1」 (zh) and "2 object extensions" (en), against the real packs.error-message.test,answeredLoadFailure:OBJECT_NOT_FOUNDin the adapter's raw-read shape;details;{error:{code,message}}body that was not lifted;HTTP 500JSON tail;network.ListView.loadErrorKind:OBJECT_NOT_FOUNDshows its sentence, its code and Retry, with no network sentence;Failed to fetchkeeps the network sentence; a 403 shows no server text.RecordDetailView.recordReadFailure-11902, over the realObjectStackAdapter:INTERNAL_ERROR, never 请检查网络连接;PageView.appPageRecord-12931: an answered 500 shows its sentence and code; a control for no answer.Moved pins
These pins asserted the old new-item key list or the 平台生成 group on a new item. Seat 5 approved adding the last two files to the surface.
DraftChangesPanel.generatedGroup-25890: the repro's new object now shows its one field and nothing of the platform's. The group's collapsed line and its opened rows are pinned on an update of the same object.DraftChangesPanel.protectionEnvelope-12594: the two "still lists an authored key" controls run on updates (~ Label), because a new item lists no keys.DraftChangesPanel.fieldRows-13125: a new object draws no generated group. The hidden-column guard (__search,owning_business_unit_id) and the Owner / Created At controls moved to the Ticket update, whose draft now carries the stamped columns.DraftChangesPanel.bundleMember-12271: a newzh-CNmember readsdraft-entry-newwith no key rows. Its member-selector URL and expansion assertions are unchanged.Ablations (each red, each restored,
git diff HEADempty afterwards)KeyRowoverridesobject_extensioncount rowansweredLoadFailurenever answersAcceptance notes
object_extensiongained a count family. Other registered types without one (for examplehook,position) keep their raw name in a group heading, as the summary line does.noChangeAndKeySplit-11807, unchanged).networkquotes the server. Every other kind keeps its fixed sentence, as before.Verification
Head
eae9d624(main merged twice; the second merge touched none of these files).node scripts/check-sdui-manifest.mjs,check-changeset-no-major,check-adr-0087-registration,check-empty-changeset,pnpm --dir ui exec vitest run scripts/,check:type-check-coverageandcheck:type-check-debt.dispatch-gates --ranreconciles: 35 derived, 35 run, 0 NOT-MEASURED, 0 UNRUN.type-checkis green for@object-ui/react,@object-ui/plugin-list,@object-ui/plugin-detailand@object-ui/app-shell, after merging main.plugin-detailplus reactutils: 3330 passed;packages/i18n: 1443 passed, includingcount-families-11445,untranslated-identity-4376, the key-parity tests andstudio-namespace;plugin-form/src/affordanceGrantMap-12082.test.tsxwas not run, because this diff does not touch its files.Live screenshots, zh-CN,
examples/app-showcasedev server plus the Vite console. The "before" leg servedorigin/main's copies of the changed source files.ensure-customization, then three drafts incom.example.showcase.custom:showcase_ops_dashboard, customized with a new label and column count, carryingoverrides;object_extensiononshowcase_task.其他变更: + overrides ~ Columns ~ Label. After:其他变更: ~ 列数 ~ 显示名称.包含: + Columns + Date Range + Description + Global Filters + 任务状态 task_status + Label + Name + Widgets. After:发布后将新增此项。OBJECT_EXTENSION 1. After:对象扩展 1.{"success":false,"error":{"code":"OBJECT_NOT_FOUND","message":"Object 'showcase_task' is not registered"}}.无法加载记录 / 加载数据时出错。请检查网络连接后重试。无法加载记录 / Object 'showcase_task' is not registered / OBJECT_NOT_FOUND / 重试.INTERNAL_ERRORanswer, the panel shows that sentence and code the same way.before-andafter-, each ofsheet-groups,sheet-update,sheet-new,list-load-error-404andlist-load-error-500. They are in the project folderissue-29704/screens/, and the driver script is inissue-29704/measure/.🤖 Generated with Claude Code
https://claude.ai/code/session_01QsR2jVQc3uTU5ZhjP31Sh8