Files
olivv-cs-ComfyUI-FunPack/app
digital-garbageandClaude Sonnet 5 ecbdc42785 fix: tour -- restart mock was reloading the real page, plus a stray player fetch
Round 9's module-definition sweep came back clean (the four standalone
modules found in rounds 5/7/8 are all still correctly covered, and no
fifth exists) -- but it caught two real bugs my own round-8 live
verification missed by not waiting long enough:

- Both restartComfy() implementations call FunPackRestart.waitForReload()
  after API.restart() resolves. That function polls API.health() starting
  3.5s later and calls location.reload() once it reports ok -- and
  API.health is ALREADY mocked to ok:true for the Settings About panel's
  own unrelated reasons, so the very first poll after a restart click
  reloads the real page mid-tour, silently resetting all tour progress.
  Nothing actually restarted, so there's nothing to wait for -- fixed by
  short-circuiting waitForReload() in tour mode instead of polling toward
  a reload.
- demoProject() pointed a fake scene_renders entry at a real-shaped
  ComfyUI /view URL for a file that doesn't exist. Since bootstrap()
  notifies immediately on tour start, player.js's render() (a plain Store
  subscriber, never blocked or mocked) picks it up and issues a real GET,
  then a real HEAD retry, against the live backend -- zero clicks, always
  404s, but still a genuine unmocked reach into the real install. Fixed at
  the source instead of patching player.js's internals: an always-
  unrendered demo scene is an honest trade-off the tour's own FAQ text
  already accounts for.

Verified live: clicked both restartComfy implementations, waited the full
5s past the 3.5s poll delay this time (my round-8 verification hadn't
waited long enough to catch this) -- confirmed no reload, still on
?mode=tour; confirmed zero /view?filename= requests; full tour sequence
still completes cleanly.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-16 00:48:40 +03:00
..