Commit 64baa68
fix(spec): dist-freshness refusal derives package label and build remedy from pkgDir (#11471)
inspectDistFreshness() / inspectBundleFreshness() hardcoded packages/spec in
their refusal cause strings and the pnpm --filter @objectstack/spec build
remedy line, regardless of pkgDir. Every real caller passed SPEC_DIR until
#10969 gave check:skill-examples a second surface (packages/client-react /
packages/client) -- confirmed live: a stale-dist refusal on that surface
misnamed the stale package and printed a non-actionable remedy.
Both cause strings now interpolate a packages/<name> label derived from
pkgDir's own path, and the build-remedy line reads pkgDir/package.json#name
-- both falling back sensibly when the shape doesn't match / the file is
unreadable. dist-freshness.test.ts's pinned literals are updated to match,
and two new cases prove the derivation is genuine: a non-spec-shaped pkgDir
(packages/widgets, package.json name @acme/widgets), and the package.json-
missing fallback.
Fixes #11250
Claude-Session: https://claude.ai/code/session_01T9cDbY2NBiVJWYx3BpWfH2
Co-authored-by: Claude <noreply@anthropic.com>1 parent 466b389 commit 64baa68
3 files changed
Lines changed: 138 additions & 10 deletions
File tree
- .changeset
- packages/spec/scripts
- lib
Lines changed: 19 additions & 0 deletions
| 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 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
34 | | - | |
| 34 | + | |
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
| |||
84 | 84 | | |
85 | 85 | | |
86 | 86 | | |
87 | | - | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
88 | 93 | | |
89 | 94 | | |
90 | 95 | | |
| |||
107 | 112 | | |
108 | 113 | | |
109 | 114 | | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
110 | 121 | | |
111 | 122 | | |
112 | 123 | | |
| |||
118 | 129 | | |
119 | 130 | | |
120 | 131 | | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
121 | 171 | | |
122 | 172 | | |
123 | 173 | | |
| |||
130 | 180 | | |
131 | 181 | | |
132 | 182 | | |
133 | | - | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
134 | 187 | | |
135 | 188 | | |
136 | 189 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
94 | 94 | | |
95 | 95 | | |
96 | 96 | | |
97 | | - | |
| 97 | + | |
98 | 98 | | |
99 | 99 | | |
100 | 100 | | |
101 | 101 | | |
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
105 | 159 | | |
106 | 160 | | |
107 | 161 | | |
| |||
164 | 218 | | |
165 | 219 | | |
166 | 220 | | |
| 221 | + | |
167 | 222 | | |
168 | 223 | | |
169 | | - | |
| 224 | + | |
170 | 225 | | |
171 | | - | |
| 226 | + | |
172 | 227 | | |
173 | 228 | | |
174 | 229 | | |
| |||
178 | 233 | | |
179 | 234 | | |
180 | 235 | | |
181 | | - | |
| 236 | + | |
182 | 237 | | |
183 | 238 | | |
184 | 239 | | |
| |||
239 | 294 | | |
240 | 295 | | |
241 | 296 | | |
| 297 | + | |
242 | 298 | | |
243 | 299 | | |
244 | | - | |
| 300 | + | |
245 | 301 | | |
246 | | - | |
| 302 | + | |
247 | 303 | | |
248 | 304 | | |
249 | 305 | | |
| |||
254 | 310 | | |
255 | 311 | | |
256 | 312 | | |
257 | | - | |
| 313 | + | |
258 | 314 | | |
259 | 315 | | |
260 | 316 | | |
| |||
0 commit comments