Repository navigation
feat(engine): aggregate delete failures during destroy instead of aborting - #973
Merged
Merged
Conversation
…rting A single failed provider.delete used to abort the whole destroy phase, stranding every not-yet-deleted resource — even ones whose deletes would have succeeded (observed live: a Lambda delete failure left a CloudMap namespace, its services, and a Route53 zone undeleted). collectGarbage now attempts every delete in dependency order, catches each failure without interrupting siblings, skips resources whose dependent failed to delete (recorded as "blocked by", not a spurious second error), keeps the replaced-row drain loop from re-spinning on failed rows, and raises one typed DestroyError aggregate at the end so the destroy still fails overall. Co-Authored-By: Claude Fable 5 <[email protected]>
…araya-83b931 # Conflicts: # packages/alchemy/src/Apply.ts
Contributor
|
Install the packages built from this commit: alchemy bun add alchemy@https://pkg.ing/alchemy/4cf9f19@alchemy.run/better-auth bun add @alchemy.run/better-auth@https://pkg.ing/@alchemy.run/better-auth/4cf9f19@alchemy.run/pr-package bun add @alchemy.run/pr-package@https://pkg.ing/@alchemy.run/pr-package/4cf9f19 |
DavidJFelix
added a commit
to DavidJFelix/alchemy-effect
that referenced
this pull request
Aug 7, 2026
Resolves conflicts between the dashboard work (deployment journal in apply, --ui deploy flow, delete-node pending reporting) and main's Plan.destroy + aggregated destroy failures (alchemy-run#973), destroy stack-state cleanup (alchemy-run#965), and local/live provider modes (alchemy-run#963): - apply: keep the journal exit-mapping; run state.deleteStack after the deployment journal closes on a successful destroy - collectGarbage: adopt main's outcome-based blocked/failed delete aggregation, keep the pending status report for queued deletions - deploy/destroy/test harness: Plan.destroy + apply command option - Cloudflare Workers ui: domains attr became singular domain
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.
Builds on the aggregated-GC-failure work from #899: destroy already attempts every delete and aggregates failures; this PR makes the result a structured, typed aggregate and distinguishes blocked deletes from failed ones.
DependentDeletionFailedmarker + raw combinedCausewith outcome-typed delete effects (deleted | failed | blocked) and oneDestroyErrorraised at the end (added toapply's declared error union).skippedwith a "blocked by <fqn>" session note and a structuredblockedentry — instead of afailstatus that conflates it with the real failure.Keeps #899's zombie-row provider guard and
stripUnresolved(bindings)commit hygiene; itsdestroy-robustness.test.tspasses unchanged.New engine tests (
describe("error-aggregating destroy")intest/apply.test.ts): sibling survival + aggregate contents + recovery on re-destroy; a 3-deep chain where only the failing leaf is a failure and its upstream dependencies are blocked (delete never invoked); disjoint subtrees draining fully despite a failure elsewhere; replaced-row drain failure terminating withDestroyErrorinstead of hanging.🤖 Generated with Claude Code