Skip to content

fix: reject deletion of already-released leases#401

Open
raballew wants to merge 1 commit intojumpstarter-dev:mainfrom
raballew:032-fix-lease-validation
Open

fix: reject deletion of already-released leases#401
raballew wants to merge 1 commit intojumpstarter-dev:mainfrom
raballew:032-fix-lease-validation

Conversation

@raballew
Copy link
Copy Markdown
Contributor

Summary

  • DeleteLease was silently setting Release=true again on leases that were already released, which is a no-op but misleading. Now it returns a FailedPrecondition error if the lease was already released, so callers get clear feedback.
  • Added tests covering both the rejection case and the happy path.

Fixes #250

Test plan

  • New unit tests for already-released lease rejection and active lease acceptance
  • Existing controller tests pass

🤖 Generated with Claude Code

DeleteLease now returns a FailedPrecondition error when attempting to
delete a lease that has already been released, instead of silently
re-patching it.

Closes jumpstarter-dev#250

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@netlify
Copy link
Copy Markdown

netlify bot commented Mar 31, 2026

Deploy Preview for jumpstarter-docs failed. Why did it fail? →

Name Link
🔨 Latest commit 8b9ae3e
🔍 Latest deploy log https://app.netlify.com/projects/jumpstarter-docs/deploys/69cbe3967d640a00086cdf4d

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.

jmp create allows an attepmpt of creating an invalid lease, jmp delete allows deleting an already deleted lease

1 participant