Comfy-Org / Comfy-Org/ComfyUI_frontend
CRDT follower cannot restore persisted binding through AgentPanelRoot
- Dominant language
- TypeScript
- Stars
- 2k
- Forks
- 699
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 490
Description
The FE-1902 remount recovery path in `useAgentCrdtFollower` is unreachable through the production composition when the in-memory binding is absent. At `origin/main` SHA `5882b01388fd2d5ef72e00f92e7761ef5f91f3d8`, `AgentPanelRoot.vue:374-381` computes `isBoundWorkflowActive=false` whenever `boundWorkflowId=null`. The immediate watcher in `useAgentCrdtFollower.ts:375-390` therefore returns from its `!active` branch before the persisted-ID restoration at `:392-403`. The composable test at `useAgentCrdtFollower.test.ts:233-240` supplies `workflowId=null` with the helper default `initiallyActive=true` from `:112-130`, a state the real root cannot produce, so it does not cover this integration condition.
```text
[sessionStorage: wf-persisted]
|
v
[AgentPanelRoot: boundWorkflowId = null]
|
v
[isBoundWorkflowActive = false]
|
v
[follower returns from !active]
X
[readPersistedDocId() -> subscribe]
```
This is masked for ordinary same-runtime panel remounts by the module-level in-memory binding in `useAgentSession.ts:61-77`, but it breaks the documented fallback when that memory is absent while session storage survives. A production-composition regression test should cover that state and the activity/binding contract should allow restoration without permitting background projection.
Freshness checked against `origin/main` `5882b01388fd2d5ef72e00f92e7761ef5f91f3d8` and open heads [#16373](https://github.com/Comfy-Org/ComfyUI_frontend/pull/16373) `86eaf8d0990bbda78d5f7f22b193666ce946604d`, [#16375](https://github.com/Comfy-Org/ComfyUI_frontend/pull/16375) `f3f861693675ee4c60d3a466a226e5a67df6a7e8`, [#16396](https://github.com/Comfy-Org/ComfyUI_frontend/pull/16396) `93bffc1bdacdaa4203b19319ff6503bac52112a7`, and [#16432](https://github.com/Comfy-Org/ComfyUI_frontend/pull/16432) `b522fe5bf8ae7a64dec18af029bd348b3efee9ea`; none fixes the contradiction. Independently verified in OPP-44.
Contributor guide
Assessment
This issue has not been assessed yet.