Skip to content

fix: release standalone resources when the caller is killed - #5

Merged
lupodevelop merged 1 commit into
mainfrom
fix/standalone-crash-cleanup
Oct 17, 2026
Merged

lupodevelop merged 1 commit into
mainfrom
fix/standalone-crash-cleanup

Conversation

@lupodevelop

Copy link
Copy Markdown
Owner

Improvements to the lifecycle management of standalone formula resources in the testcontainer library. The main enhancement is that both acquisition and release of standalone resources now occur in a dedicated guard process, ensuring that resources are reliably released even if the caller process is killed during acquisition or release. This change improves robustness, prevents resource leaks, and clarifies process boundaries.

Resource Lifecycle Management Improvements

  • Standalone formula acquisition and release now run in a dedicated guard process, ensuring that resources are released even if the caller is killed during acquisition or release. The body continues to run in the caller's process, and acquisition/release callbacks must not depend on the caller's process-local state.
  • The with_standalone function replaces with_cleanup, coordinating acquisition, body execution, and release across processes for improved reliability.

@lupodevelop
lupodevelop merged commit c7d6730 into main Oct 17, 2026
2 checks passed
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