Skip to content

✍️ Reframe strict structured concurrency around lifetime correctness#1140

Closed
taras wants to merge 4 commits intostrict-structured-concurrency-blogfrom
tm/reframe-strict-concurrency-lifetime-correctness
Closed

✍️ Reframe strict structured concurrency around lifetime correctness#1140
taras wants to merge 4 commits intostrict-structured-concurrency-blogfrom
tm/reframe-strict-concurrency-lifetime-correctness

Conversation

@taras
Copy link
Copy Markdown
Member

@taras taras commented Mar 16, 2026

Motivation

The strict structured concurrency post already introduced foreground and background work, but it still read primarily as a convenience refinement. This follow-up makes the stronger claim explicit: when incidental background work can keep a scope alive after the meaningful computation is complete, the lifetime model is semantically wrong and every framework built on top of it inherits an incorrectness tax.

Approach

Rewrite the article to lead with the correctness argument, introduce foreground vs background earlier, and recast the spinner/timeout example as a semantic and operational failure mode rather than cleanup boilerplate. Preserve the existing points about aggressive teardown, classic structured concurrency, and orderly cleanup while tightening the argument around lifetime correctness, hung scopes, and the operational cost of letting support work outlive the computation it was supposed to support.

@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new bot commented Mar 16, 2026

Open in StackBlitz

npm i https://pkg.pr.new/effection@1140

commit: 82c603c

Replace the static foreground/background split diagram with an animated
timeline that shows bars growing over time, the scope boundary appearing
when foreground completes, and background overshoot being reclaimed.

Supports CSS animations with prefers-reduced-motion fallback to static
end-state. Light/dark mode via prefers-color-scheme media query.

Session-ID: ses_306f2b523ffeWNTN1w2kiCQ3Lj
Replace per-row FG/BG abbreviations with FOREGROUND and BACKGROUND
section headings. Collapse title to one line at 52px. Move caption
down 8px for breathing room.

Session-ID: ses_306f2b523ffeWNTN1w2kiCQ3Lj
@cowboyd cowboyd force-pushed the strict-structured-concurrency-blog branch 16 times, most recently from 3947b58 to a10f632 Compare April 3, 2026 17:50
@cowboyd
Copy link
Copy Markdown
Member

cowboyd commented Apr 3, 2026

This feedback has been integrated.

@cowboyd cowboyd closed this Apr 3, 2026
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