You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 265def6
Browse filesBrowse the repository at this point in the historyBrowse files
feat(gen)!: --baseline=adopt, and a refusal that fails the run on every port
The no-manifest refusal LED with "commit .metaobjects/.gen-state/.hashes.json",
which the population it names cannot do: nothing writes a manifest until a gen
succeeds, and a run where every file refuses writes none. So there was nothing to
commit and the next run refused identically. The only escape was --baseline=fresh,
correctly framed as the lossy one. Found by an adopter estate running the RC with
50 files refused and the leading instruction unfollowable.
--baseline=adopt separates the two things fresh does at once: record the files you
HAVE as the merge base, write nothing. The manifest then exists to commit, and the
regeneration arrives on the next run as its own reviewable diff. Placed at the
refusal rather than at the top of the decision, so adopting can ONLY convert a
refusal into a recorded baseline — unchanged and the pristine-file overwrite a
fresh clone depends on are untouched, and passing it cannot freeze a project's
regeneration.
What adopting DECLARES is stated everywhere it is offered, because the name invites
the other reading: that the files you have are generated output. It protects edits
made from then on; an edit already inside one becomes part of the base and the next
gen replaces it. A test pins that, rather than trusting the prose.
Shipped in TypeScript, Python and C# — the three ports with a hash manifest. A new
`adopted` write status carries it through the reporting layer instead of being
folded into `unchanged`: the run's whole product is the manifest, and a summary
that hid it would defeat the point. `fresh` stays TypeScript-only, and the other
two REFUSE that value naming what they do implement rather than accepting it and
refusing files anyway.
BREAKING: a refused file now FAILS gen on Python and C# (exit 1), as it always has
on TypeScript. Both printed the warning and exited 0, so an adopter who wired gen
into CI as a drift gate was green while codegen refused to write — the gate did not
gate, and nothing documented it. Found by probing the adopt work: no conformance
corpus covers CLI exit codes, and the divergence had no test on either side. A
build that starts failing was already unprotected, and the failure names its remedy.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NTcEKXTQMYt84fAjuw5A2M
Copy file name to clipboardExpand all lines: fixtures/agent-context-conformance/java-kotlin-react-tanstack/expected/.claude/skills/metaobjects-codegen/SKILL.md
+10Lines changed: 10 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -36,6 +36,16 @@ You run a `gen` step. The runner:
36
36
and the token, so an `@`-prefixed tag does not match it. Remove that token and
37
37
regeneration never touches the file again.
38
38
39
+
**A refusal FAILS the run — exit 1 on every port** (TypeScript always did; Python and
40
+
C# warned and exited 0 until 1.0, so a `gen` wired into CI was green while codegen
41
+
refused to write). The one-time fix for a project that predates the committed manifest
42
+
is **`gen --baseline=adopt`**: it records the files you have as the baseline and writes
43
+
nothing, so there is finally a `.hashes.json` to commit — then `gen` again, and the
44
+
regeneration lands as its own diff. Adopting DECLARES those files to be generated
45
+
output, so an edit already inside one is part of the baseline and that regeneration
46
+
replaces it; commit before you run it. (TypeScript additionally has
47
+
`--baseline=fresh`: write fresh output now and discard the edits.)
48
+
39
49
**The two rules protect a hand edit in opposite ways, so do not carry a habit across
40
50
ports.** On TypeScript, C# and Python, *editing the content* is what takes ownership —
41
51
that is what breaks the hash — and deleting the header changes nothing except your
0 commit comments