Skip to content

fix: asobi delete says what the control plane actually does - #52

Merged
Taure merged 1 commit into
mainfrom
fix/delete-retire-wording
Aug 17, 2026
Merged

Taure merged 1 commit into
mainfrom
fix/delete-retire-wording

Conversation

@Taure

@Taure Taure commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

Client half of widgrensit/asobi_saas#291. Merge that one first.

Why

That PR routes CLI destruction through the FSM, so a durable environment now retires — compute down, database kept 30 days, name reusable immediately — instead of being torn down and DROP DATABASE'd inline. Ephemeral environments still drop. The response is the queued destroying rather than a completed deleted.

Environment X deleted promised something the control plane deliberately does not do, and would have kept promising it. Now: Environment X is being destroyed.

Two refusals worth naming

asobi_saas#291 adds a role gate and starts honouring the protected flag, so this route can now refuse for reasons a generic message obscures:

  • 403 is a role refusal, not an expired session. delete failed (403) sends somebody off to re-run asobi login to fix a permission they do not have.
  • 409 means deletion protection is set — something they can act on, rather than retry.

Both get their own message and a test.

Checks

gofmt -l clean, go vet clean, go build ./..., go test ./... pass (2 new). Usage text and README updated to describe retirement rather than deletion.

widgrensit/asobi_saas#291 routes CLI destruction through the FSM, so a
durable environment now retires - compute down, database kept 30 days, name
reusable immediately - instead of being dropped inline, and the response is
the queued "destroying" rather than a completed "deleted".

"Environment X deleted" promised something the control plane deliberately
does not do, and would have kept promising it.

Two refusals also get their own message. A 403 is a role refusal, not an
expired session, and the generic "delete failed (403)" sends somebody to
re-run `asobi login` to fix a permission they do not have. A 409 means
deletion protection is set, which is a thing they can act on rather than
retry.
@Taure
Taure merged commit f542f52 into main Aug 17, 2026
1 check passed
@Taure
Taure deleted the fix/delete-retire-wording branch August 17, 2026 08:38
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.

1 participant