Repository navigation
fix(studio): a sealed undo of a GSAP-animated layer's style shows in place - #8320
Conversation
…place, without a reload
…of replaying the older state
terencecho
left a comment
There was a problem hiding this comment.
Two preview-ordering issues remain at 4df4f85c.
- P2 · An undo can overwrite an edit made while it waits.
gsapUndoRestore.ts:413–435advances the counter only for history restores. A normal GSAP edit can update the same frame throughuseGsapScriptCommits.ts:229–236without advancing it. In a delayed-reply test, Studio sent the new script, then the older undo's refusal triggered a second soft reload with the old script and styles. The saved file has the newer edit, but the preview shows the older one. Invalidate the fallback on intervening preview writes as well as on later history restores. Preserve the current playhead when issuing a delayed retry, since the captured time can also predate a scrub. - P2 · A lost reply can retry into a different preview load.
gsapUndoRestore.ts:451–454treatsnulllike an explicit refusal.previewChannel.ts:26–38,87–96also returnsnullwhen the old frame's editing client is disposed, and the follow-up request can acquire a new client for the same iframe element. The element-keyed counter still matches. Keep the retry tied to the original editing client and require an explicit refusal. A timeout on the current preview can use the existing full reload.
The PR body names the regression required by the review rule. The build and 165 targeted tests passed, including 11 in Chrome. The named regression failed with the implementation reverted. Two additional request-ordering probes confirmed the stale script and the retry after a missing reply.
— tai (automated review)
Edit accuracy: accurate 271 (base branch 271), smooth 69 of thoseThe gate passes. Quarantined, measured but not gated (0) Unstable (1)
|
…uest, so no write races it
|
Both points are fixed by removing the second request, at 23fa4fa. The re-run no longer goes out after the reply. Studio puts it in the
Also:
Checked on Linux at 23fa4fa:
Remeasured at this head, sealed preview, one undo of a crop at a time: no preview document loads, and the layer is back in place after 54 to 65 ms. On main it reloads (2 documents) and takes 441 to 1291 ms. The crop bench is in the body: sealed undo 15 and redo 1 off on main, 0 and 0 here; unsealed 0 and 0 on both. |
terencecho
left a comment
There was a problem hiding this comment.
The restore now sends one request, and the delayed-reply and navigation checks passed in sealed Chrome. Two P2s remain.
- P2 ·
packages/core/src/runtime/editing/softReload.ts:511— When the re-run waits for MotionPath, completion still seeks to the original undo time. I scrubbed from 1.5 s to 4 s while the plugin was pending. Completing the load moved the playhead back to 1.5 s. Preserve a newer seek during the wait, or use the reload fallback for a restore that needs to wait for the plugin. - P2 ·
packages/core/src/runtime/editing/softReload.ts:634— An optional re-run can block a static restore that never needs it. In sealed Chrome, a static style undo stayed in place until I added an unrelated inline SVG style above the 16 KiB re-run field limit. The restore then requested a full reload. The base sender kept the same fixture in place. Preserve the valid static restore and use the reload fallback only if the frame needs a re-run it cannot accept.
The build, 152 targeted unit tests, and 11 existing Chrome tests passed. The named red-first tests failed with the old behavior. The full suites and edit-accuracy benchmark were outside this pass.
— tai (automated review)
…un keeps the plain restore
|
Both fixed at 5822316, red-first.
The player time the fix compares is the Studio preview's own clock time ( Checked on Linux at 5822316:
The probe and bench numbers in the body stand: the change only affects a re-run that waits for the plugin, and a re-run the frame drops. |
terencecho
left a comment
There was a problem hiding this comment.
The oversized unrelated style now leaves the plain restore available, and a single scrub to a different position survives a pending MotionPath load. Two overlaps still fail in sealed Chromium.
- P2 — Scrubbing away and back can rewind playback (
packages/core/src/runtime/editing/softReload.ts:466). The comparison uses the initial and final playhead values. If the restore carries Studio's 2s position, the frame starts at 4s, and the user scrubs to 5s and back to 4s before the plugin loads, the comparison sees equal values and finalizes at 2s. Track seek ordering across the wait so the latest scrub wins even when the time returns to its initial value. - P2 — A pending undo can replace a newer animation edit (
packages/core/src/runtime/editing/softReload.ts:521). The plugin callback still runs the old script after a newer soft reload has succeeded. In sealed Chromium, the newer edit installed a tween ending at 120px. Releasing the pending plugin load restored the old 60px tween. Check whether playback has received a newer reload for the same timeline before executing the deferred script.
— tai (automated review)
…sealed preloads MotionPath
…ition's own script
|
Both fixed at 3948815, red-first, in
A sealed preview now also loads the MotionPath plugin ahead of time, as a same-origin preview does ( Tests, in real Chrome with the real runtime, a sandboxed preview frame and the plugin request held (
Plus core unit cases for each race in With core as at 5822316, all three Chrome tests fail: the scrubbed re-run ends at 2 s instead of 4 s, the newer edit falls back to a full reload, and the sealed preview never loads the plugin. The three core cases fail there too. Checked on Linux at 3948815:
|
terencecho
left a comment
There was a problem hiding this comment.
Two P2s remain in packages/core/src/runtime/editing/softReload.ts.
- Line 529 — A waiting re-run can lose an independent timeline. The supersession counter is frame-wide, but a re-run replaces only its own timeline keys. In sealed Chrome, I held the plugin load for
main, applied an edit toother, then released the plugin. Both requests reported success and onlyotherremained in the registry. A newer reload should supersede the waiting work only for the timelines it replaces. - Line 546 — A superseded request can still force a full reload. The plugin error callback skips the supersession check. In sealed Chrome, a newer edit to the same timeline completed in place, then failing the older plugin request still triggered Studio’s reload fallback. Apply the supersession decision on failure as well as success.
The prior scrub and same-timeline overwrite cases now pass. The workspace build and 159 targeted tests passed offline, including the new MotionPath cases. The six named prior-head regressions failed as expected when run against the previous implementation. Both findings above reproduced in sealed Chrome.
— tai (automated review)
|
Both fixed at cdabe44, by making the soft-reload wait one state machine in
What a run writes from the file (its restore plan and timing) still lands when it starts, in arrival order, so a later attribute restore or edit is never written over by an older waiting run. While a run waits, the old timeline keeps playing over those restored attributes, as it did before this change. The real-Chrome tests also showed that a run joining a plugin load already in flight (the connect preload, or Studio's same-origin preload) polled for it every 50 ms. Core now has one loader: every waiting run queues on the single request in flight, and its load or error settles them all at once, in arrival order. Studio's same-origin preload calls it instead of keeping its own copy. A failed load is not remembered; the next run requests it again. Tests: a table of every ordering of plugin ok or failing with a scrub, a newer run on the same timeline, a newer run on another timeline, an attribute restore and an edit, in core ( Against main, an edit to a property the timeline does not animate is kept in both. An inline transform written on the animated layer during the wait differs: main's new tween starts from it, this change starts from the authored value, as a fresh load shows.
Checked on Linux at cdabe44:
|
…in-place # Conflicts: # packages/studio/src/utils/gsapUndoRestore.sealed.test.ts
terencecho
left a comment
There was a problem hiding this comment.
Changes requested at a665227e. The prior disjoint-timeline cancellation and prompt stale-plugin-error cases pass. Four failures remain in Chrome.
- P2 ·
packages/core/src/runtime/editing/softReload.ts:517–542. An older waiting script can overwrite a newer value-only edit. In sealed Chrome, the editing port'spatch-tweensrequest returnedpatched: trueand the element moved to x=300. Releasing the older MotionPath wait replaced that tween and moved it back to x=60. A successful patch skips a fresh rerun in Studio, so no generation changes before the older swap. Account for the in-place tween patch in the same ordering as a rerun. - P2 ·
packages/studio/src/utils/gsapSoftReload.ts:213–221. An old sealed request can still reload the preview after a newer run has already landed. Hold the MotionPath response, request a run on one timeline, and apply a newer run on that same timeline. A prompt plugin failure correctly leaves the preview alone. Holding the response past the editing-port deadline calls the old request's reload callback while the newer timeline is visible. The host treats the timed-out request as a fresh refusal before the frame can report supersession. Apply the ownership check to timeout and cancellation outcomes as well as normal replies. - P2 ·
packages/core/src/runtime/editing/softReload.ts:480–488. Two different timelines waiting for the same plugin can land at the older run's requested time. I queued waits at 2 s and 3 s, with no user seek after either request. Both scripts ran, but both preview modes settled at 2 s. The first swap's own seek increments the same counter used to detect a newer user seek, so the second swap treats 2 s as the newer time. Separate the swap's bookkeeping from user playback position changes. - P2 ·
packages/core/src/runtime/editing/softReload.ts:487–488. Playback can continue during a wait without changing the seek count. In both preview modes I queued a run at 1 s, started playback, and let it advance past 1.5 s before releasing MotionPath. The swap resumed playback near 1 s. Use the live playhead when playback advanced while a run was pending.
I ran all 34 sealed and unsealed Chrome cases alongside 230 focused core tests and 133 targeted Studio tests. The previous implementation failed the same-timeline stale failure and different-timeline wait controls.
— tai (automated review)
…er the file size cap
…ore it reads them
terencecho
left a comment
There was a problem hiding this comment.
Changes requested at c12ab108.
P2 · packages/studio/src/utils/gsapLiveRetime.ts:195 and packages/studio/src/utils/gsapSoftReload.ts:233. A successful older timing sync can overwrite an unrelated clip's newer saved timing. The ledger versions the snapshots it uses for recovery, but the initial frame request still sends every clip's timing from the older snapshot. I delivered a newer undo at the preview-sync boundary first, then delivered the older retime and let the frame apply it. The older sync left the unrelated clip at data-start="0" while a fresh load of the saved file showed "1". Both the live-retime and rerun paths reproduced it in sealed Chromium. Their in-order controls passed. A temporary revision check that reloaded the saved file before sending the older timing passed both reversed cases. Preserve the newer state before applying an older sync, and keep a test where that older request gets a successful frame reply.
The earlier timing-coverage case now completes with zero reloads. It produces one reload with the previous ledger. The pinned reversed-response refusal case also passes and is red with the previous ledger. 175 Chromium cases and 285 scoped Studio tests passed. I checked this ordering at the production preview-sync boundary, with the save completion order controlled by the fixture. All required hosted checks passed. The body has named fails-without evidence and could also name this round's two new cases.
— tai (automated review)
…a newer data-start undo
terencecho
left a comment
There was a problem hiding this comment.
P2 · A fresh preview load can still accept older saved timing (packages/studio/src/utils/sealedPreviewLedger.ts:72, :125).
The new send gate fixes both reversed-save cases on the same load. The gate starts at version zero on a new load, though, even when that frame already loaded a newer saved file. In sealed Chromium I held the older retime completion, applied the newer undo of another clip's data-start, then loaded a frame from the newer saved bytes before delivering the older completion. Both the live-retime and the soft-reload paths sent the old timing to the loaded frame, changing the untouched clip's data-start from 1 back to 0. The same-load controls passed. I reproduced it both on a new load of the same iframe and when the sync selected the replacement iframe.
Give admission a version floor for the file state the frame loaded, or keep delayed sync work tied to its original load and converge from the saved file when the load changed. Add the reload-between-completions case for both timing paths.
Validation included 177 Chromium cases and 294 scoped Studio tests. Disabling the admission check turns both same-load reversed timing cases red. The additional reload cases fail on this head.
— tai (automated review)
|
Fixed at 0847d49. Your finding. A new preview load now starts its send floor at the file revision Studio's shadow reload recorded when that load began, and checked before showing it. The reload hands that revision to the ledger as it promotes the load, so the one record of which file a load shows also sets the floor. Studio's preview reloads all go through it ( One consequence: a save whose request went out before a reload began but finished after it is below that floor too. Its sync reloads once more. It is never lost. Tests. Your two cases are fixed rows: the round-11 pair with the frame loading the newer saved file between the newer and the older sync, for the live retime and the retime re-run. The harness's reload records the revision when it starts and hands it over once the load shows, as Studio's does. The generator's reversed step sometimes loads the newer file between the two syncs. A ledger row sends an older live retime to a new load that shows a newer file: nothing is posted, and the preview reloads. Red without the fix. With the floor taken out ( Checked on Linux:
|
terencecho
left a comment
There was a problem hiding this comment.
The shadow promotion now seeds the send floor from the revision it recorded at load time. A stale live retime or timing rerun is refused on that replacement load and recovers by reloading the saved file. The existing recovery check still requires timing coverage for every affected timeline.
124 scoped Studio tests and 179 Chromium cases passed, including 100 generated sequences. Both named replacement-load cases failed when revision seeding was disabled. I also checked the production promotion hook with a write during loading. GitHub's required checks are clear. The separate Flake gate was still running when I checked.
— tai (automated review)
terencecho
left a comment
There was a problem hiding this comment.
The merge tree matches a clean merge of the reviewed head and main, and the PR patch ID is identical. All required checks passed. The fresh CodeQL analysis also passed. Its warning refers to alert 1243, which is already open on main at the unchanged compiler line.
I verified the merge and hosted checks for this head. No local tests were rerun for the merge-only update. Some optional checks were still running.
— tai (automated review)
What
In a sealed preview (Studio cannot script the frame), undoing or redoing a change to the style of a layer GSAP animates now shows in place. Before, it reloaded the whole preview. A crop is the common case: undoing a crop of a tweened or
gsap.setlayer blanked and rebuilt the preview, and the layer showed the crop until the reload finished. An unsealed preview already restored it in place.The sealed preview is off by default until the sealed-by-default change (#7846) lands, so nothing changes for anyone before then.
Why
A crop saves only the layer's
style; the GSAP script does not change. So a sealed undo sendsrestore-attributes. The frame refuses it for any element GSAP has parsed when the page has a script: by its own rule, such an element needs a re-run instead. Studio never sent the re-run; it reloaded the preview. A same-origin preview re-runs the script in place for the same undo.How
The re-run travels in the same
restore-attributesrequest, and the frame decides, since only the frame knows which elements GSAP has parsed. Nothing is sent after the reply, so no later edit, undo, scrub or new preview load can be overwritten by it. The frame runs the re-run synchronously in its request's turn, in the order requests arrive; the one exception is a script that first loads the MotionPath plugin, which finishes later. That wait is one state machine insoftReloadFrame, for every soft reload in both modes:superseded, which Studio treats as done (no reload). A plugin failure is answered the same way:cannot-soft-reload(Studio reloads) only for a run still current.patch-tweensanswerspatched: false,live-retimeanswersunchanged, Studio's same-origin patch returnsfalse), so Studio re-runs the saved script and the newest script supersedes the waiting run. The drag-timegsap-setpreview is left alone; its commit goes through those refused paths.utils/sealedPreviewLedger.ts): every write it sends takes a ticket with its timelines, its send order and the file version its save produced. A late answer (a refusal, a timeout, a failure, a refused patch's fallback) is dropped only when a later re-run of all its timelines, read at that file version or newer, was sent; that re-run carries the change and owns its own recovery. Tween patches and retimes never cover anything. An uncovered change recovers with the newest saved script for its timelines, never the script its request captured. An answer from a replaced preview load does nothing.restore-attributesnow answersreran), counted from the restore's send order.SAVED_STATE_DEADLINE_MS(30 s, insealedPreviewLedger.ts) for the frame's answer, not the port's usual 5 s; still unanswered then, it recovers with a full reload. A late success inside that window resolves cleanly. Before this round, a script-only re-run could cover such a write once it timed out at 5 s, so its refusal after the deadline was dropped and the old title ordata-startstayed.sendPreviewWrite. Once the frame can take it, a write whose saved file version is older than one already sent to that preview load is not sent: an older timing sync whose sync goes out after a newer save's would otherwise put its file's clip timing over the newer file's. It recovers the way that sender's refusal does: nothing when an already-sent re-run of a newer file carried its change, else a re-run of the newest saved file in place, else a full reload (a newer undo of attributes alone leaves no script snapshot to re-run). A re-run's coverage is recorded at that send, and only when it is sent, ranked by file version first.useShadowPreviewReload.ts): it is handed to the ledger as the load is promoted, so the one record of which file a load shows sets the floor. A write older than that is not sent to the new load and recovers by a reload, so a timing completion held across a reload cannot put an older file's clip timing on the newer load. A save whose request went out before a reload began but finished after it is below that floor too: its sync reloads once more rather than being lost.useGsapScriptCommits.ts:455), so their responses cannot reverse; the timing sync (timelineTimingSync.ts:353) and undo (useEditHistoryActions.ts:101) send theirs after the lock, so a newer save's sync can go out first, and before this the older one then looked newest.newestPreviewWrite, which every late failure uses to pick what to re-run): an earlier save's timing may never have reached the frame, and the newest file holds it. The timing sent is the saved file's own values, so it changes nothing when they are already on screen.previewAnswerinpreviewChannel.ts;previewRequestkeeps answering null for both, for its other callers). Every error code excepttimeoutanddisposedcounts as an explicit refusal,failedincluded: the frame may have applied part of the request before failing, which is safe only because a refusal of saved state is never covered and recovers with a full reload, the saved file.previewMotionPathUrl), so the first motion-path re-run after a load does not wait in either mode.State: a sealed preview after late answers in any order; orderings tested: generated sequences of script re-runs, tween patches, retimes, restore-safe and unsafe attribute undos and script-plus-attribute undos, live retimes through Studio's
moveLiveTweens, each reaching the frame, refused, or rejected by the port before the frame applies anything, replies answered in random orders, scrubs, frame reloads; oracle: equals a fresh load of the saved file, the playhead where Studio last put it, full reload only after a refusal nothing recovers in place. State: late answers from a sealed preview (soft re-run, tween patch, retime, restore); orderings tested: an older refusal after a newer re-run, a refused patch held while a newer patch lands, an older refusal after an unrelated successful patch, an older run timing out after an attribute-only undo, a re-run sent while a patch's write was in flight, a restore answered after the preview reloaded; in Studio unit tests and in real Chromium with the frame's replies held. State: the soft-reload wait; orderings tested: plugin ok or failing; before or after a scrub, playback, a newer run on the same timeline (also held past the editing port's deadline), a newer run on another timeline (also two waiting at once), an in-place tween patch, a drag preview, an attribute restore, and an edit to a property the timeline does or does not animate; in core, and in real Chrome sealed and unsealed; not tested: alive-retimeduring the wait in Chrome (its refusal is the same check aspatch-tweens).Core:
restore-attributestakes an optionalrerun: the script, standalone sets, authored styles and timing asoft-reloadtakes. The request's owntimeandscopescomplete it. Arerunthe frame cannot take (an unknown or over-limit field, an empty script) is dropped and the restore kept: a restore that needs no re-run still applies in place, and one that needs it is refused, so Studio reloads.softReloadwith them. It plans the attributes with the sameplanRestore, so every rule there applies, fix(core): a redo in a sealed preview puts Studio's edit marks back in place #8264's included. Otherwise it sets the attributes as before, and the script does not run.Studio:
applySealedRestoreattaches thererunonly when the file keeps a GSAP script. It builds it withsealedRerun, the buildersoft-reloadnow uses as well. A refusal, or no reply while the run is still the newest, reloads the preview.patch-tweensrefusal, during a wait or not, used to reload the whole preview. It now re-runs the saved script in place, the path a same-origin preview takes when a patch misses (applyPreviewSyncowns that one fallback for both). A full reload comes only when the re-run answerscannot-soft-reload.The editing agent serves only a page marked for Studio, connected from its parent window (
editingAgent.ts:285,:289). A render's page is its own top window, so no render reachesrestore-attributesor the re-run.Test plan
Core,
softReload.test.ts, "restore-attributes with a re-run":soft-reloaddoes not take, an authored style over its limit, or no object, and keeps the restore;ok,scrub,ok,ok,scrub,same,ok,same,fail,ok,same,fail,same,other,ok,other,fail,ok,other,attr,ok,ok,attr,edit,ok,ok,edit,play,ok,two,ok,patch,ok), checking the answer, which script ran for each timeline, the restored attribute, the edit and the playhead; and "starts a fresh plugin load for the next re-run after one failed".Studio, real Chrome with the real runtime and the plugin request held,
gsapSoftReloadWait.browser.test.ts, sealed (a sandboxed frame) and unsealed (readsHF_PARITY_MODE):move,okandok,move(an inline transform on the animated layer),same,late,ok(the plugin held 5.5 s, past the editing port's 5 s) anddrag,ok,drag(a drag preview frame on each side of the swap), through Studio's ownapplySoftReloadand, sealed, itsrestore-attributesrequest;Against main for the edit rows, in real Chrome: an edit to a property the timeline does not animate (
color) is kept in both. An inline transform written on the animated layer during the wait differs: main's new tween starts from it (x 180 at 2 s), this change starts it from the authored value, as a fresh load shows (x 30). Written after the swap, both keep it (x 300).Studio,
gsapUndoRestore.sealed.test.ts:Studio,
useGsapScriptCommits.sealed.test.ts: "re-runs the saved script in place when the frame refuses a patch of a soft-reloadable edit".Studio,
sealedPreviewLedger.test.ts, every reply held and answered in any order: "re-runs a refused patch's recovery with the timing of a live retime saved after it" (the reviewer's retime sequence, through Studio'smoveLiveTweens); "drops an older explicit refusal once a newer re-run of its timeline was sent"; "re-runs the newest saved script when a patch refusal held while a newer patch lands arrives"; "still recovers an older script run that times out after an attribute-only undo of its timeline"; "ignores a restore answered after the next load"; and two guards, "still recovers an older script run after an unrelated successful patch of its timeline" and "does not let a re-run sent while a patch's write was in flight cover the patch".Studio, real Chromium, sealed, two files sharing one fixture (
studio/tests/sealedOrderingFixture.ts; harness instudio/tests/sealedPreviewHarness.ts, sequence runner instudio/tests/sealedPreviewSequence.ts):sealedPreviewOrdering.browser.test.tsholds 30 fixed sequences (the round-9 and round-10 pinned seeds as literal steps);sealedPreviewOrderingGenerated.browser.test.tsholds generated sequences, seeds 1 to 40 by default, the same in every CI run, so a red seed there can be rerun by number.HF_ORDERING_SEEDS,HF_ORDERING_SEED_BASEandHF_ORDERING_SEED_LISTchange them only for local runs such as the five-run bar. The split keeps each file well under the flake gate's 120 s per file under contention.data-startundo whose responses come back newest first, the older one's sync answered by the frame, sometimes with a load of the newer file between them; an answer to one pending reply or refusal, picked at random; or a save, each sent the way Studio sends it after writing the file: a script re-run, a tween patch, a retime ofdata-startthrough the soft re-run with timing, a live retime (data-startand a tween duration) throughmoveLiveTweenswith Studio's timing-sync fallback, an undo of a restore-safe attribute (data-label), of an unsafe one (title, refused by the frame), of the script and thetitletogether, or of thedata-startof a clip no script animates. Each save reaches the frame (reply held), is refused (answered later with the frame's refusal), is rejected by the port before the frame applies anything (answered later withok: false, codeinvalid-params), or is never answered (only its deadline settles it). Odd seeds play a file with two GSAP scripts.data-start,data-label,title, the tween at 2 s) equals a fresh load of the saved file, the preview's playhead is within a frame of Studio's, and a full reload happens only after a refusal or missed deadline that leaves nothing to recover in place (or in a two-script file, where a recovery may only reload). A new load is shown at Studio's playhead, as the real preview's reload shows it. Each save marks Studio's file revision, as Studio's write does.data-startand gets a successful frame reply; the clip keeps the undo's timing.reversedstep: both saves marked in order, the newer's preview sync sent first), and generated seeds 52 and 148, which found that class.data-start, then the patch's refusal; an undo of a script and atitlethe frame refuses and a newer run, both answered after the undo's deadline.Studio, real Chromium, sealed, the frame's real replies held in transit (
gsapSoftReloadWait.browser.test.ts, "late answers held in transit, sealed"): an older explicit refusal after a newer run painted; a patch refusal held across the swap while a newer patch lands; an older run timing out (held past the port's 5 s) after an attribute-only undo; a restore its old load never answered across a preview reload; and a guard, an older script refusal after an unrelated successful patch.fails without the fix:
previewLoadShowsa no-op, as at 0b0e114), the reviewer's two round-12 sequences fail (the unrelated clip back atdata-start0 where the saved file has 1), and so does the ledger row that sends an older live retime to a new load showing a newer file; with 0b0e114's code, generated seeds 178, 210 and 316 fail too (a tween's x).data-start0 where the saved file has 1), and eight generated seeds found by themselves (52, 118, 231, 307 and 366 a clip'sdata-start, 54 and 178 a tween's x, 395 an older script). The two new ledger rows (sealedPreviewLedger.test.ts: an older live retime sent after a newer re-run, and after a newer undo of another clip) fail there too.gsapSoftReload.ts,gsapUndoRestore.ts,useGsapScriptCommits.ts,gsapLiveRetime.ts,previewChannel.tsandsealedPreviewLedger.tsas at 961b71b (round 8) and the round-9 harness, 7 of 419 ordering sequences fail: both of the reviewer's round-9 sequences, and the five pinned round-9 seeds (312 and 320: a write of saved state never answered and then covered by a script-only run,data-startandtitlelost; 2101, 3037 and 3657: a two-script file's newerdata-startundo overwritten). The round-8 rows, the reload guard and 400 generated seeds pass there. In those 400 seeds the generator found 312 and 320 by itself; the two-script class needs its shape (a refused patch or live retime, then an applieddata-startundo before any reload), and a scan of odd seeds to 4000 for that shape gave 52 candidates, of which 2101, 3037 and 3657 fail.softReload.tsand Studio'sgsapSoftReload.ts,gsapUndoRestore.ts,useGsapScriptCommits.ts,gsapLiveRetime.ts,previewChannel.tsandsealedPreviewLedger.tsas at b8a3637 (round 6), 4 of the 43 ordering sequences fail: the title undo and seed 29 (title not on screen), the static undo (an unneeded full reload) and seed 28 (data-startlost, a refused retime covered by a script-only run); the guard sequence passes there too; and "re-runs a refused patch's recovery with the timing of a live retime saved after it" fails (the re-run carries no timing).softReload.tsand Studio'sgsapSoftReload.ts,gsapUndoRestore.ts,useGsapScriptCommits.ts,gsapLiveRetime.tsandpreviewChannel.tsas at d9b8cae (round 5), the four corerestore-attributescases (now checkingreran), four of the sixsealedPreviewLedger.test.tsrows and four of the five held-answer Chromium rows fail; the three guard rows pass there too.gsapUndoRestore.tsas on main, "carries the script re-run in the restore request when the file keeps a script" fails.gsapUndoRestore.tsas at 4df4f85 (the re-run sent after the reply), "carries the script re-run in the restore request when the file keeps a script", "leaves an edit sent while the restore waits, and the playhead it was sent at" and "sends nothing more after a reply a new preview load lost" fail.rerun, "re-runs the script in the same request when GSAP has parsed a restored element" fails.softReload.tsas at 23fa4fa, the four "drops a re-run with …" cases fail.softReload.ts,patchTween.ts,liveRetime.tsandinit.tsand Studio'sgsapSoftReload.ts,gsapUndoRestore.ts,gsapRuntimePatch.ts,useGsapScriptCommits.tsandsealedTweenPatch.tsas at a665227 (round 4), the core table failsok,scrub,ok,play,okandtwo,ok; the timed-out case with a newer run sent fails; the refused-patch re-run fails; and the Chrome table fails 15 of its 44 rows across both modes (among themplay,ok,two,ok,patch,okandsame,late,ok).softReload.tsandrestoreAttributes.tsand Studio'sgsapSoftReload.tsas at 3948815 (the runtime rebuilt for the Chrome test), the core table failssame,ok,same,failandother,ok, and the Chrome table fails 15 of its 34 rows across both modes (among themscrub,ok,same,fail,other,ok,other,fail,edit,okandmove,ok).Run on Linux at 848d02c (0847d49 moves the runner's reversed step into its own function): the fixed file (30 sequences) 30/30, and the generated file five times with fresh seeds (seed bases 0, 1000, 2000, 3000, 4000; 100 each) 100/100 every run: 530 sequences, no problems. Four copies of the wait table and the fixed file run at once pass every time. Studio's wide run (9157 tests) passes, the shadow reload's tests included; the ledger rows pass three runs in a row. At 0847d49: Studio
tscno errors, both ordering files (70) pass,fallow auditno issues in 44 changed files. Round 10's two red checks are fixed: the sealed restore's send moved tosealedRestoreSend.ts(the 600-line cap), and two wait-table rows now settle before reading (the second waiting run, the paused frame). At c4fd71a (the same code before the split): Studio's wide run (9145 tests) and the touched Studio tests (339) pass. At 961b71b, Studio's wide run (9137 tests) passes. Earlier, at adaab5a (core unchanged since): coresoftReload,patchTween,liveRetime,restoreAttributes,editingAgentandeditingPorttests (254) and Studio's touched tests (343, the wait and ordering tables included) pass three runs in a row; core'sruntimetests (3512) and Studio'sutils,hooks,components/editor,webmcpandplayertests (7731) pass; core and Studiotscno errors. Format and lint clean.Proof
Sealed preview, three crop cases (a tweened layer, a
gsap.setlayer, a tweened layer placed byxPercentand turned 30°), cropped, then undone. Counted from the undo key, one case at a time:xPercent, r30, root, 50% zoomOn main, the documents are the frames the reload navigates; with this change no frame navigates.
Bench
Edit-accuracy bench, every crop case (120 per run), at main and at this change:
The 15 sealed undo misses on main are the root
holdandtweenlayers: the bench measured them before the reload finished, so the layer still showed the crop (40 px, the cropped edge). Run alone with a 3 s settle, the same cases pass on main. This branch's base is before #8310, so its sealed runs still show #8310's turned crop frame misses (46 and 48, on turned layers only, in different cases from run to run); this change does not touch the crop frame.Before
Sealed preview on main, a tweened layer cropped, then undone: the preview reloads (2 documents) and the layer is back after 441 ms.
After
The same undo at this change: no document loaded, and the layer is back after 54 ms.