Repository navigation
Conversation
schloerke
added this pull request to stack #2550
October 15, 2026 02:54
…e/2508-memory-bank
…e/2508-memory-bank
…e/2508-memory-bank
…e/2508-memory-bank
…ironment docstring
…e/2508-memory-bank
…e/2508-memory-bank
schloerke
force-pushed
the
schloerke/2508-memory-bank
branch
from
October 15, 2026 15:35
c0859ae to
9db5645
Compare
25 of 33 tasks
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.
Stacked on #2559. Updates the memory bank so contributor docs describe the async concurrency stack (#2549, #2545, #2546, #2520, #2547, #2548, #2525, #2552, #2559) instead of the global
reactive.lock()model it replaces.Changes
reactiveInternals.md: the flush loop and lock sections are replaced. New sections cover rounds (request_round()viacall_soonin a fresh context, non-waiting starts, rerun instead of nesting), cycles and the busy count,run_once_when_idle(),reactive.flush()/run_until_idle()semantics, async calcs and effects interleaving, destroy-time cancellation, and the deprecated no-opreactive.lock(). Pitfalls are rewritten.sessionMessaging.md: the message loop holds no lock.updatemessages go throughrun_once_when_idle(), and dispatch messages run as their own tasks. "The flush cycle" becomes "Cycles and the output flush": one message per cycle, sent even when empty; queues reset before the send is awaited; the "recalculating" yield (fix(session): Send each output's progress message before it renders #2525); and the per-task output-nameContextVar(fix(session): Track the rendering output per task forclientdata.output_*()#2559). The session-end section and pitfalls are updated.otel.md:reactive_updateis a per-session cycle span. It starts when the busy count goes 0→1, and it ends at idle or at session end. The doc covers its parents and children, thestart_otel_span()/use_otel_span()helpers, and howtest_otel_reactive_update.pytests it.bookmarking.md: a new "Restore gate" section (fix(bookmark): Run async on_restore callbacks before the session's effects #2548), and the callback timing now refers to cycles instead of flushes.ciAndTooling.md: theplaywright-windowsjob and PR-checks gate,PLAYWRIGHT_INSTALL_ARGS, thepytest.initimeout and--strict-markerssettings, and why-p no:rerunfailuressilently drops tests.playwrightTesting.md: the Windows-specific tests, how the busy-indicator timing test works, and theasync/and express-session-start test changes.concurrencyTesting.md: how to write tests in the style oftest_concurrency.py. It covers theClientdrivers,wait_untilwith its 10 s limit,asyncio.Events instead of sleep durations for ordering, state waits plussettle()for negative assertions, duck-typed session mocks,MockTime, and releasing tasks stranded on dead event loops.architecture.mdlinks to it.Review notes
Writing these docs turned up a few code leftovers. This PR doesn't change any of them:
invalidate_later()still says the round'sreactive_updatespan has no parent. That span now belongs to the session's cycle.detached_otel_context()(shiny/otel/_core.py), so it could be removed.uploadEndsets its input in the middle of a cycle instead of throughrun_once_when_idle(), unlikeupdatemessages. This matches R. The docs list it as a pitfall.Verification
file.md#anchorlink inmemory-bank/resolves.