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
openspec new change prints Schema: spec-driven even when config.yaml selects a custom schema #2117
Cosmetic only, but it misleads agents (and humans) auditing which schema a change was created under; I hit exactly that during a custom-schema run. A version-pinned patch with this fix (verified end to end: JSON payload, persisted .openspec.yaml, and text output) lives at https://github.com/cabi/openspec-cdd (patches/ + smoke test S26).
I tried this on 1.14.3 and it looks narrower than described: only the spinner line is wrong. The Schema: line, --json, and .openspec.yaml all already show the custom schema.
Repro: openspec init --tools none, then openspec schema fork spec-driven my-flow, set schema: my-flow in openspec/config.yaml, and run openspec new change add-thing:
- Creating change 'add-thing' with schema 'spec-driven'...
Created change 'add-thing' at openspec/changes/add-thing/
Schema: my-flow
Next: openspec status --change add-thing
.openspec.yaml has schema: my-flow, and --json gives "schema": "my-flow".
That matches the code on main. createChange (src/utils/change-utils.ts around line 146) already resolves explicit option, then readProjectConfig(projectRoot)?.schema, then defaultSchema. It persists that value and returns it as result.schema, and printCreatedChangeHuman prints that. Passing schema: options.schema on line 152 is what lets the config fallback work. Only resolvedSchema on line 146, used just for the spinner text, skips the config.
So I think the minimal fix is to give the spinner the same resolution (or drop the schema from the spinner message). Changing what gets persisted, or root.defaultSchema, shouldn't be needed. One thing I didn't test is a --store-selected root, in case that's the path where you saw the wrong value persisted.
Activity
surlymochan commentedon Oct 19, 2026
I tried this on 1.14.3 and it looks narrower than described: only the spinner line is wrong. The
Schema:line,--json, and.openspec.yamlall already show the custom schema.Repro:
openspec init --tools none, thenopenspec schema fork spec-driven my-flow, setschema: my-flowinopenspec/config.yaml, and runopenspec new change add-thing:.openspec.yamlhasschema: my-flow, and--jsongives"schema": "my-flow".That matches the code on
main.createChange(src/utils/change-utils.tsaround line 146) already resolves explicit option, thenreadProjectConfig(projectRoot)?.schema, thendefaultSchema. It persists that value and returns it asresult.schema, andprintCreatedChangeHumanprints that. Passingschema: options.schemaon line 152 is what lets the config fallback work. OnlyresolvedSchemaon line 146, used just for the spinner text, skips the config.So I think the minimal fix is to give the spinner the same resolution (or drop the schema from the spinner message). Changing what gets persisted, or
root.defaultSchema, shouldn't be needed. One thing I didn't test is a--store-selected root, in case that's the path where you saw the wrong value persisted.fix(new-change): name the configured schema in the progress line (Fis…