feat: park PUT candidate layout while preserving the live runtime

This commit is contained in:
2026-10-23 10:52:23 +08:00
parent 799fe9f3c7
commit d521568d73
3 changed files with 131 additions and 43 deletions
+3
View File
@@ -194,3 +194,6 @@ The API worker now owns a pending HTTP request plus its scalar result while REPL
Complete-source candidates now separate one-time compilation/source execution from initial layout. load_incremental owns the isolated VM while its first layout is pending; the current live VM stays separate. Cancellation uses the same Mount checkpoint/continuation cleanup as later refresh. Synchronous load helpers remain for host regression coverage. This does not yet slice parsing, compilation, source execution, structural preparation or paint.
The API keeps the old runtime alongside a pending PUT candidate. Newer submissions cancel only the obsolete candidate; failures restore the published runtime's submission owner. Background epoch checks distinguish accepted replacements from DELETE revocation, so queued/superseded candidates do not destroy the previous live heap. Candidate resumption reads only the primary shell viewport, avoiding reuse of an old secondary window's dimensions for a new VM's resource with the same numeric ID. Success publishes the complete candidate document and commands together, then replaces the old runtime.