Skip to content

fix(console): stop losing the manifest and name the SDL mistake - #16

Merged
chalabi2 merged 1 commit into
mainfrom
chalabi/console-manifest-guards
Jul 29, 2026
Merged

chalabi2 merged 1 commit into
mainfrom
chalabi/console-manifest-guards

Conversation

@chalabi2

@chalabi2 chalabi2 commented Jul 29, 2026 •

Copy link
Copy Markdown
Contributor

Two ways to end up with a lease that never gets a workload, both silent. Found while deploying a live multi-service workload to test console events.

1. deployment create without a context threw the manifest away

It printed manifest not cached (no active context); pass --manifest to lease create — but Console returns that manifest exactly once, at create, so there was nothing left to pass.

Real consequence, hit during testing: the deployment leased fine, then sat with an active lease and no workload, burning escrow, with console status answering 404.

Now the manifest is included in the result whenever it could not be cached, so the instruction is actually followable.

2. lease create --manifest posted whatever bytes it got

Passing the SDL is the obvious mistake — same file, same directory. Console replies:

422: invalid character '-' in numeric literal

That's its JSON parser hitting the leading --- of the YAML. Nothing in it names the cause. Now checked locally:

manifest file deploy.yaml is not JSON: --manifest takes the manifest Console
renders (reported by `akt console deployment create`, cached per context), not the SDL

Fails before the API call rather than after.

Verified

  • Reproduced the original 422 against the live API, then confirmed the new message replaces it
  • Unit tests: rendered manifest accepted, SDL rejected with a message naming the cause, missing file errors

Two ways to end up with a lease that never gets a workload, both quiet.

`deployment create` without an active context threw the manifest away
and said to pass --manifest to `lease create`. Console returns that
manifest exactly once, at create, so there was nothing left to pass: the
deployment could be leased and then sat there with no workload, burning
escrow, with `console status` answering 404. Emit the manifest in the
result whenever it could not be cached, so the instruction is followable.

`lease create --manifest` posted whatever bytes it was given. Passing the
SDL is the obvious mistake -- same file, same directory -- and Console
answers "invalid character '-' in numeric literal", its JSON parser
hitting the leading `---`. Nothing in that names the cause. Check the
file is JSON first and say what the flag actually wants.

Signed-off-by: Joseph Chalabi <chalabi.joseph@gmail.com>
@chalabi2
chalabi2 merged commit 23cc42c into main Jul 29, 2026
6 checks passed
@chalabi2
chalabi2 deleted the chalabi/console-manifest-guards branch July 29, 2026 16:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants