Skip to content

Complete the deterministic loop core#1

Merged
dhruvl merged 8 commits into
mainfrom
loop-hardening
Jul 12, 2026
Merged

Complete the deterministic loop core#1
dhruvl merged 8 commits into
mainfrom
loop-hardening

Conversation

@dhruvl

@dhruvl dhruvl commented Jul 12, 2026

Copy link
Copy Markdown
Owner

Rounds out the loop core so real asyncio code runs on it with a full contract:

  • unsupported asyncio APIs now raise a named SimulationFenceError instead of a bare NotImplementedError
  • cancelled callbacks and timers are recorded in the scheduling trace, so replay hashes account for every RNG draw
  • set_exception_handler / get_exception_handler and task factories, matching stdlib semantics on 3.12 and 3.13
  • seeded sim.random / sim.uuid4 / sim.time shims: seed-derived inside a run, stdlib fallback outside
  • replay stability proven across 100 reruns per seed and across processes under varying PYTHONHASHSEED
  • scheduling overhead benchmark (stdlib only, no timing assertions)
  • first docs page: the supported asyncio subset, stated honestly

45 tests green on 3.12 and 3.13, zero warnings, mypy strict clean.

@dhruvl
dhruvl merged commit 958179f into main Jul 12, 2026
4 checks passed
@dhruvl
dhruvl deleted the loop-hardening branch July 18, 2026 18:30
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