config phase-set + full --json error chain (rc.13, TASK-390)#324
Merged
Shooksie merged 2 commits intoJul 14, 2026
Conversation
…hase-set`
Fix A: emit_cli_error now builds the --json error.message via anyhow's
alternate Display (`{:#}`) instead of `err.to_string()`, so the message
carries the full context chain (outer .context() + every underlying source)
matching the human path. Previously only the top-level context surfaced,
dropping the real cause (e.g. the "references unknown phase" detail behind
"the config to write is invalid...").
Fix B: add `animus workflow config phase-set --id <id> --input-json <json>`,
mirroring agent-set/workflow-set. It read-modify-writes the RAW config_source
base's `WorkflowConfig.phase_definitions` (NOT the agent-runtime overlay that
`workflow phases upsert` writes), so a subsequently-set workflow that
references the phase resolves at post-pack-merge validation instead of failing
"references unknown phase". Case-insensitive upsert to match phase-id
resolution elsewhere.
Tests: json_error_message chain assertion; phase-set JSON-error handler;
phase-authored-on-base lets a referencing workflow validate (+ control).
Docs: docs/reference/cli/index.md.
…ll --json error chain, TASK-390)
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two workflow-authoring tooling fixes (portal REQ). A:
--jsonerrors now carry the full anyhow chain ({err:#}) instead of only the top context — soworkflow config workflow-setsurfaces the real cause (e.g. 'references unknown phase X'). B: newanimus workflow config phase-set --id --input-jsonwrites WorkflowConfig.phase_definitions on the config_source base (not the agent-runtime overlayphases upsertuses), so a workflow referencing the phase validates — enables full custom-workflow authoring via MCP. Tests + codex self-vet clean; fmt/clippy/check green.