explorer: a restored snapshot loses to a folder's running animation
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 35/100
Direzione di ricerca
Start with core/widgets/TreeWidget.zig (the branch's expanded and the _expanded data around lines 468 and 890) and plugins/workbench/src/files.zig (carryBack and the expander near line 1150), then find where setExplorerBranchOpen is called. Replay #293's property test with seed 0x6 to reproduce the failure. Done when the tree draws open or closed from the caller's value each frame, the expander reports toggles instead of writing back, and both the seed test and a new test that sets open state mid-close-animation pass.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Found by #293 (#280 step B1), whose property test replays a demo and seeks to random moments. With seed 0x6 it fails in the tour's explorer, on seeks to 46937, 13890 and 17830 ms: after a snapshot restore, the explorer's open folders aren't the ones the snapshot holds. The checked-in seed and nine others pass, so this shows up only when a seek lands during a folder's open or close animation.
Cause: open state lives in two places that copy each other
core.widgets.TreeWidget's branch keeps its ownexpanded, stored per widget as_expandedin dvui's data (core/widgets/TreeWidget.zig:468,:890). It eases toward the caller's value through an animation.- The workbench keeps the explorer's open folders on the host (
setExplorerBranchOpen, the per-branch open state the snapshot captures and restores). Each frame it writes the branch'sexpandedback into that state (plugins/workbench/src/files.zig,carryBackand the expander around:1150).
So a restore that sets the host's open state while a branch's own animation is still running loses: the next frame copies the widget's in-flight value back over the restored one. Nothing is wrong with the snapshot or the player. The model has two writers.
Fix
Give the open state one owner. The tree should draw open or closed from the caller's value each frame, keeping only the animation's progress as its own state, and never write it back. Clicking the expander reports a toggle to the caller, which changes its state. Then a restore, or anything else that sets the open folders (a reveal-in-explorer, a demo keyframe), takes effect on the next frame with no race.
Test: #293's property test with seed 0x6 must pass, plus a focused integration test: start a folder's close animation, set the open state from outside, run frames, and check the branch ends open.
Part of #280.
🤖 Generated with Claude Code
- Lingua principale
- Zig
- Stelle
- 1.5k
- Fork
- 40
- Merge medio
- 5h 5m
- PR unite (30g)
- 278
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di fizzyedit/fizzy
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
fizzyedit/fizzy#306 · 3 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 8/100
fizzyedit/fizzy#336 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
I maintainer di solito rispondono entro 1 giorno
-
Example repos that move with fizzy, and a dvui app on fizzy's backendForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 12/100
I maintainer di solito rispondono entro 1 giorno
-
enhancement
Difficoltà 5/5 Più di una settimana Idoneità per principianti 12/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di fizzyedit/fizzy
Issue simili
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 92/100
I maintainer di solito rispondono entro 2 giorni
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
jhomlala/betterplayer#1609 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
NousResearch/hermes-agent#140957 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
-
[Feature]: Windows 语音输入默认关闭Apertaenhancement source/qq
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
metasequoiaime/msime-windows#1054 ·
I maintainer di solito rispondono entro 1 giorno