Repository navigation
fix(plugin-email): a host's own mail transport reads as in use on GET /api/settings/mail - #34731
Conversation
… /api/settings/mail
A transport the host hands to plugin-email that no `provider` option names
(a plain IEmailTransport, such as a hosted platform's mail channel) left
`live.provider` unstated, so the first-run checklist could not read mail as
set up while it was delivered. It is now stated as
`{ value: null, source: 'environment' }`.
- spec: `SettingsNamespacePayloadSchema.live` documents that `value` is null
under 'none' or 'environment' (in use, named by no option); in-use is read
from `source`. Shape unchanged.
- service-settings: the live-value judge serves environment + null; settings
+ null and keys with no option table stay dropped.
- plugin-email: describeLiveMailTransport states environment + null for an
environment-origin transport no option names.
Claude-Session: https://claude.ai/code/session_01ADHkmTBjYWuaUonx8DhAbB
Co-authored-by: Claude <noreply@anthropic.com>
… reading Claude-Session: https://claude.ai/code/session_01ADHkmTBjYWuaUonx8DhAbB Co-authored-by: Claude <noreply@anthropic.com>
📓 Docs Drift CheckThis PR changes 3 package(s): 4 hand-written doc(s) NAME something this change touched and may need an implementation-accuracy re-verification:
What this run could not see
Coarse fallback — 176 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 410a590091463afe0c17a80e13fe0b682eda6f0c && git checkout 410a590091463afe0c17a80e13fe0b682eda6f0c
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin dc66d3308271f3055308c5c982ebc8d53195065f 9e70d11b5a453c4a787655c649a0284c4f29f896 && git checkout -B drift-repro dc66d3308271f3055308c5c982ebc8d53195065f && git merge --no-ff 9e70d11b5a453c4a787655c649a0284c4f29f896
node scripts/docs-audit/affected-docs.mjs --json dc66d3308271f3055308c5c982ebc8d53195065f
|
|
repo:objectstack#2 · os-steve · session_01ADHkmRfW5u1LRmhWwaYHRp Final head for review: |
|
l2-review#4 · os-steve · session_01ADHkmP44onN8RMzsPMqjRq Contract-review-claim: session_01ADHkmP44onN8RMzsPMqjRq · head 9e70d11 · 2026-11-17T09:38Z |
|
repo:objectstack#2 · os-steve · session_01ADHkmTPcB6fZEwhd2hNQwC 席位核对L1 verdict: ACCEPT · PR #34731 · card #32799 (Fixes) · first review · L1-c2 of seat repo:objectstack#2 · read 2026-11-17T09:41Z Head-sha: Read from GitHub and the diff at this head (merge base Shape and ruling
Code
Pins. The changed existing test is split exactly as the body says.
Prose. I checked the changeset sentence by sentence against the diff. " Consumer read (not a REWORK item; the ruling assigns it). Two in-repo readers still hold the old meaning:
On the managed profile the mail row stays hidden while not delivering, so nothing new shows there. On a self-hosted deployment with a host transport class, the row reads "not set up" until the ui card lands. Before this PR, such a deployment fell back to Gates: 76 check-runs on this head, all L2 owed: yes. It touches Landing tier: NOT governed, +110/−25 = 135 lines. It touches |
|
l2-review#4 · os-steve · session_01ADHkmP44onN8RMzsPMqjRq Contract reviewServed-tier: Inputs read: card #32799 body and all 14 comments (ruling 6942903820 = C, seat analysis 6931556929, cloud confirm 6918167282, dev report 6944198803); PR #34731 body and its 9-file net diff against merge base ① Derived judgments
② Semver levelClause-②: yes (widening) — correct, and the same line stands on the PR body and in the changeset body. The schema's accept set does not move; what widens is the set the settings route serves (one more ③ Boundary flags
④ Design judgment
Consumers of No must-fix, no should-fix.
Implemented-by: VERDICT: PASS |
|
repo:objectstack#2 · os-steve · session_01ADHkmQ2SN4K183oqAvUajA Seat record · 2026-11-17T09:45Z · Head-sha: 9e70d11 维护者速读
席位意见:同意合并。改动严格落在裁决 C 的一种组合上,放宽而不收窄;控制台半边已立 #34749,复审的两个 nit 已补进该卡。 席位核对
|
⛔ merge queue 构建失败 — 先分诊,再决定要不要重排队列构建 44064296349 红了。队列跑的是全量套件(PR 侧 CI 只跑 affected 子集), 分类: 失败的 job(日志抽取,best effort):
跨 PR 相同签名(24h,按失败测试文件聚合):
历史信号:
分诊清单:
Generated by Claude Code · merge-queue-triage workflow (#4859) |
Requested by Steve · project thread
Fixes #32799
Clause-②: yes (widening) — the served
liveentry ofGET /api/settings/:namespacenow also admits{ value: null, source: 'environment' }; every entry served before is served unchangedMetadata-protocol: none
维护者速读
GET /api/settings/mail上报为live.provider = { value: null, source: 'environment' },即「在用、来自运行环境、选项表叫不出名」。spec 只改live的说明文字(形状不变),service-settings 判定放行environment + null这一种组合。settings + null、无选项表的键照旧丢弃;内置 smtp/resend/postmark 读数不变。回滚即 revert 本 PR。控制台isMailDelivering目前把environment + null读成未完成,要等 ui 跟进卡 console: isMailDelivering reads source 'environment' with a null value as not delivering, so the hosted setup checklist still does not tick after #32799 #34749 才会打勾。packages/services/service-settings/src/settings-service.ts(judgeLiveValue新增一行)、packages/plugins/plugin-email/src/live-transport-status.ts(新增一个分支)、packages/spec/src/system/settings-manifest.zod.ts(live说明)。pnpm --filter @objectstack/plugin-email exec vitest run src/live-transport-status.pin.test.ts,预期 21 个通过,其中「environment: the host's own transport …」一条读到{ value: null, source: 'environment' }。What changes
@objectstack/spec—SettingsNamespacePayloadSchema.live: the docblock and thevalue/sourcedescribes now say a non-nullvalueis one of the key's options, andvalueisnullunder'none'(nothing in use) or'environment'(in use, supplied by the boot environment or host, named by no option). In-use is read fromsource, never fromvalue === null;'settings'always names an option. Shape unchanged. Generatedcontent/docs/references/system/settings-manifest.mdxregenerated.@objectstack/service-settings—judgeLiveValueserves{ value: null, source: 'environment' }.settings+nulland any entry on a key with no option table stay dropped.SettingsLiveValue/SettingsLiveStatus.valuesdocs follow.@objectstack/plugin-email—describeLiveMailTransportstates{ value: null, source: 'environment' }for anenvironment-origin transport noprovideroption names (a plainIEmailTransportthe host hands over). Stock transports read as before; a transport swapped in throughsetTransportis still not stated; asettingsorigin with no option is still not stated..changeset/32799-host-mail-transport-live-environment.md(patch × 3).Tests
packages/plugins/plugin-email/src/live-transport-status.pin.test.ts— changed existing test: "states nothing for a transport no option names, or one this plugin did not install" split in two. The host's-own-transport half now asserts{ value: null, source: 'environment' }through the served door (realSettingsService+ mail manifest, body parsed bySettingsNamespacePayloadSchema), as ruling C requires. The swapped-transport half keeps "not stated", plus a host-own transport swapped throughsetTransport. New unit pin: a no-option transport is stated only underenvironment(notsettings, not without an origin).packages/services/service-settings/src/settings-routes.live-status.pin.test.ts— new:environment+nullserved on the mail page with no warn; new drop row: a key with no option table asenvironment+null. The existingsettings+nulldrop row is relabelled ("no value under source "settings"").packages/spec/src/system/settings-manifest.test.ts— the payload parsesenvironment+null.Acceptance notes
domain:ui, not in this claim, ruling C's "另立 ui 卡"):ui/apps/console/src/pages/settings/firstRunChecklistLogic.tsisMailDeliveringtreatsenvironmentas done only with a non-empty stringvalue, so{ value: null, source: 'environment' }reads not done (before this PR the absent statement fell back toisMailConfigured(values)).ui/apps/console/src/pages/settings/types.tsstill documents "nullexactly whensourceis'none'". Filed console: isMailDelivering reads source 'environment' with a null value as not delivering, so the hosted setup checklist still does not tick after #32799 #34749.Verification
At head
9e70d11b5a453c4a787655c649a0284c4f29f896(merge base origin/maindc66d330); full report: card comment 6944198803.os-verify-lock:@objectstack/service-settings76 files / 1516 passed;@objectstack/plugin-email54 / 1025 passed;@objectstack/specsrc/system73 / 2577 passed.dispatch-gates --commandsderives 117;--ran: 117 run, 0 NOT-MEASURED, 0 UNRUN.Ablations (scripts/ablation-replace.mjs; each restored blob == HEAD, git diff HEAD empty)
if (source === 'environment' && value === null) …removed: service-settings pin 1 failed / 23 passed. The plugin-email pins resolve the service-settings dist built before the mutation, so no dist leg was taken there.else if (!option && origin === 'environment') …removed: plugin-email pin 2 failed / 19 passed (the unit pin and the served-door pin).Gate re-runs
The first pass ran beside a locked build on a shared box. Four commands were non-zero and each passed when re-run:
check-plugin-teardown-shape --self-testexited 3 until the pinned commit was fetched; speccheck:generatedand spectypecheckhit a tsc out-of-memory and passed alone;check:skill-examplesandcheck:dual-build-cjs-loadsexited 3 (no built dist) and passed after a turbo build of./packages/**.CI at this head: 68 check-runs, 58 success, 10 skipped, 0 failed.