• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Rotorsoft / act-root / 32851693390
100%

Build:
DEFAULT BRANCH: master
Ran 25 Aug 2026 01:12PM UTC
Jobs 1
Files 114
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

25 Aug 2026 01:09PM UTC coverage: 100.0%. Remained the same
32851693390

push

github

web-flow
fix(act): stop treating work that outlived a handler as a reaction (#1568)

* fix(act): stop treating work that outlived a handler as a reaction

#1541 made the triggering event ambient so a handler's dispatches thread the
causation chain whichever IAct reference makes them. AsyncLocalStorage keeps
that frame alive for anything the handler starts, so a debounce timer or an
un-awaited settle() still read as "inside a reaction" indefinitely.

That is not cosmetic. `reactingTo` also decides whether the inferred
optimistic-concurrency guard applies, so detached work committed unguarded:
a read-modify-write dispatched from a batching flush silently lost an update.
Two withdrawals of 10 from 100 left 90. #1543 asserted the leftover leak was
"metadata only, no guard is skipped" — that claim was wrong and untested.

The rule is now one sentence: the reaction context applies while the handler
runs, and not after. run_reacting carries a mutable liveness token and flips
it in a finally; Act.do only inherits the event while it is live. Detached
work therefore neither carries that causation nor skips the guard.

Dropping the causation for detached work is the other half of the fix, not a
casualty: attributing a decade-old timer's flush to whichever event happened
to arm it was the over-attribution #1543 already documented as a wart.

internal/ is byte-identical to master — the whole change is scoped.ts (which
owns ambient context) and one resolve at the Act boundary.

Closes #1562

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01K5eB6CMELZJfayCYpQta8N

* test(act): reduce the #1562 regression test to its essentials

The first version carried scaffolding that was mine, not the defect's: two
states, a mutated label threaded through three scopes, a separate capture for
the in-handler case, and an arbitrary sleep(20).

Measuring the boundary showed what is actually load-bearing. A bare
un-awaited disp... (continued)

4237 of 4237 branches covered (100.0%)

Branch coverage included in aggregate %.

7 of 7 new or added lines in 1 file covered. (100.0%)

9199 of 9199 relevant lines covered (100.0%)

1337.9 hits per line

Jobs
ID Job ID Ran Files Coverage
1 32851693390.1 25 Aug 2026 01:12PM UTC 114
100.0
GitHub Action Run
Source Files on build 32851693390
  • Tree
  • List 114
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #32851693390
  • bff17a23 on github
  • Prev Build on master (#32648709197)
  • Next Build on master (#32881014490)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc