Commit 9f601e8
* feat(spec)!: EnvironmentArtifact 信封收敛为单一声明 —— C10 双源清账,./system 持活 wire 形,./cloud re-export (#4740)
`EnvironmentArtifact(Input|Schema)` 曾由 `./cloud` 与 `./system` 各自导出一个
声明:cloud 侧是活的 wire 形(checksum 为 64 位 hex 字符串、metadata =
ObjectStackDefinitionSchema),全仓唯一 runtime Zod parse
(packages/metadata/src/plugin.ts `_parseAndRegisterArtifact`)与 cloud 仓
3 处 type import 都用它;system 侧是文档化「v0」(checksum 对象、分类袋
metadata、内联 functions[]、必填 manifest、payloadRef 保留位),三仓
(objectstack / cloud / objectui)import 级实测零代码消费者、从未有 producer
产出过。两侧互相解析不过。按维护者裁决(#4740,路线 A′)收敛:
- system/environment-artifact.zod.ts 重写为活 wire 形(唯一声明);
Sha256Digest(Schema) 随声明搬入 ./system(./cloud 仍导出)
- cloud/environment-artifact.zod.ts 改为纯 re-export(同一符号,两个入口)
- 从未实现的 functions / manifest / payloadRef 走 retiredKey() tombstone
退役(ADR-0049):tsc 处 never、parse 处 prescription;无 ADR-0087
conversion —— 信封是传输形状,不落 sys_metadata、不在 conversion walker
的 stack 树上,存量行不可能携带(#4734 先例逐条评估,论证见 PR)
- v0 家族 16 个导出名(8 const + 8 type)自 ./system 移除;9 个
system/EnvironmentArtifact* def 停止发布(json-schema.manifest.json
#2978 蓄意删键;authorable-surface 46 行经 #4650 门禁 7 组「def no
longer emitted」自证删除)
- 符号身份 pin(compiler API,exports-map 枚举 16 入口 + 防空转守卫):
三名字全入口唯一解析到 src/system/environment-artifact.zod.ts;S1
(重加被删名)/ S2(cloud 侧新声明的禁止路线)sabotage 均红
- #4666 盲区:checksum 对象→字符串是 key 级门禁不可见的类型变更,parse
pin 钉住(旧对象形 → 拒;64 位 hex 字符串 → 过),changeset 显式警示
- packages/metadata runtime parse 一字未动(收敛目标即其已解析形状),
14 文件 290 测试全绿
- north-star.mdx §6.3 锚点同步(单一声明 + re-export;字段清单改为 wire 形)
- 基线 6 → 3(dual-source-exports.baseline.json 删 3 行)
- changeset:@objectstack/spec major(移除 16 个已发布导出名,TS2305),
零元数据迁移;strictness-ledger 实跑零变化
Fixes #4740
Claude-Session: https://claude.ai/code/session_0176qgxgCXTJCUv4YFLtusP9
Co-authored-by: Claude <noreply@anthropic.com>
* fix(docs): 头注措辞避开行首 `import` —— 生成器按行成段,MDX 把该行当 ESM 解析(Build Docs 红)
build-docs.ts 把 docblock 按行拆成独立段落,`system/environment-artifact.zod.ts`
头注中断行后有一行以 `import ` 开头,MDX/acorn 将其解析为 ESM import 语句,
`content/docs/references/system/environment-artifact.mdx` SyntaxError。改写措辞
(「so the chosen entry point can never change the shape a consumer gets」),
重生成后两个 environment-artifact.mdx 均无行首 `import `/`export `(代码围栏内
的 TypeScript Usage 示例不受影响),`pnpm --filter @objectstack/docs build`
exit 0,`check:docs` 248 文件同步。
生成器坑本体(docblock 行成段 + 行首 import 炸 MDX,#4696 家族)记入 PR 顺带
发现,不在本 PR 修生成器。
Claude-Session: https://claude.ai/code/session_0176qgxgCXTJCUv4YFLtusP9
Co-authored-by: Claude <noreply@anthropic.com>
* chore(spec): rebase 到含 #4764 的 main 后全量重生成 —— 蓄意删键重放 + 生成物从新基重算(#4535 §7)
os-regen merge driver 对 json-schema.manifest.json / authorable-surface.json /
api-surface.json 不做文本合并,rebase 回退了蓄意手删;本 commit 重放:manifest
删 system/EnvironmentArtifact* 9 键 + system/Sha256Digest 在列,authorable-surface
删 46 行(#4650 门禁以新 merge-base 695cfbd 重新自证,7 组「def no longer
emitted」),api-surface / spec-changes / upgrade-guide / docs 全量重生成。
复验:check:generated 8/8、check:dual-source-exports(基线 6 → 3)、
strictness-ledger / variant-docs / liveness / empty-state 全绿;spec 测试
292 文件 / 7348 全过;全仓 typecheck 122/122;docs 产物无行首 import/export
(Build Docs 措辞修复在 rebase 后仍生效)。
Claude-Session: https://claude.ai/code/session_0176qgxgCXTJCUv4YFLtusP9
Co-authored-by: Claude <noreply@anthropic.com>
---------
Co-authored-by: Claude <noreply@anthropic.com>
1 parent 695cfbd commit 9f601e8
12 files changed
Lines changed: 655 additions & 809 deletions
File tree
- .changeset
- content/docs
- concepts
- references
- cloud
- system
- packages/spec
- src
- cloud
- system
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
66 | | - | |
| 66 | + | |
| 67 | + | |
67 | 68 | | |
68 | 69 | | |
69 | 70 | | |
70 | 71 | | |
71 | 72 | | |
72 | 73 | | |
73 | | - | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | | - | |
| 12 | + | |
13 | 13 | | |
14 | | - | |
| 14 | + | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
17 | 17 | | |
18 | | - | |
| 18 | + | |
19 | 19 | | |
20 | | - | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
21 | 27 | | |
22 | 28 | | |
23 | 29 | | |
| |||
Lines changed: 44 additions & 164 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | | - | |
| 12 | + | |
13 | 13 | | |
14 | | - | |
| 14 | + | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
17 | 17 | | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
| 18 | + | |
29 | 19 | | |
30 | | - | |
| 20 | + | |
31 | 21 | | |
32 | | - | |
| 22 | + | |
33 | 23 | | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
| 24 | + | |
47 | 25 | | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
| 26 | + | |
81 | 27 | | |
82 | | - | |
| 28 | + | |
83 | 29 | | |
84 | | - | |
| 30 | + | |
85 | 31 | | |
86 | | - | |
| 32 | + | |
87 | 33 | | |
88 | | - | |
89 | | - | |
90 | | - | |
91 | | - | |
| 34 | + | |
92 | 35 | | |
| 36 | + | |
93 | 37 | | |
94 | | - | |
95 | | - | |
96 | | - | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
| 38 | + | |
121 | 39 | | |
| 40 | + | |
122 | 41 | | |
123 | | - | |
| 42 | + | |
124 | 43 | | |
125 | | - | |
| 44 | + | |
126 | 45 | | |
127 | | - | |
| 46 | + | |
128 | 47 | | |
129 | | - | |
| 48 | + | |
130 | 49 | | |
131 | | - | |
132 | | - | |
133 | | - | |
| 50 | + | |
134 | 51 | | |
| 52 | + | |
135 | 53 | | |
136 | | - | |
| 54 | + | |
137 | 55 | | |
138 | | - | |
| 56 | + | |
139 | 57 | | |
140 | | - | |
| 58 | + | |
141 | 59 | | |
142 | | - | |
| 60 | + | |
143 | 61 | | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
| 62 | + | |
149 | 63 | | |
| 64 | + | |
150 | 65 | | |
151 | | - | |
| 66 | + | |
152 | 67 | | |
153 | | - | |
154 | | - | |
155 | | - | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | | - | |
160 | | - | |
161 | | - | |
162 | | - | |
163 | | - | |
164 | | - | |
165 | | - | |
166 | | - | |
167 | | - | |
168 | | - | |
169 | | - | |
170 | | - | |
171 | | - | |
172 | | - | |
173 | | - | |
174 | | - | |
175 | | - | |
176 | | - | |
177 | | - | |
178 | | - | |
179 | | - | |
180 | | - | |
181 | | - | |
| 68 | + | |
182 | 69 | | |
| 70 | + | |
183 | 71 | | |
184 | | - | |
| 72 | + | |
185 | 73 | | |
186 | | - | |
| 74 | + | |
187 | 75 | | |
188 | | - | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
189 | 79 | | |
190 | | - | |
| 80 | + | |
191 | 81 | | |
192 | | - | |
193 | | - | |
194 | | - | |
195 | | - | |
196 | | - | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
197 | 85 | | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
198 | 89 | | |
199 | 90 | | |
200 | 91 | | |
201 | | - | |
202 | | - | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | | - | |
207 | | - | |
208 | | - | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | 92 | | |
213 | 93 | | |
214 | 94 | | |
0 commit comments