Skip to content

fix(flow-chat): route permission requests to a single owner - #2595

Merged
bobleer merged 1 commit into
GCWing:mainfrom
guantw:codex/fix-review-permission-panel-routing
Aug 28, 2026
Merged

fix(flow-chat): route permission requests to a single owner#2595
bobleer merged 1 commit into
GCWing:mainfrom
guantw:codex/fix-review-permission-panel-routing

Conversation

@guantw

@guantw guantw commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Render the shared permission mailbox in BTW/review side panels so direct child-session requests can be answered.
  • Separate broad transcript/task-card routing from actionable permission ownership, keeping each request on exactly one UI surface.
  • Add regression coverage for direct and delegated requests and owner-only active batches.

Ported from GitCode PR #75.

Type and Areas

Type: regression fix

Areas: Web UI, FlowChat permission routing, BTW/review sessions

Motivation / Impact

BTW and review sessions render outside ModernFlowChatContainer. A direct permission request from one of these child sessions could therefore block its runtime without exposing a way to answer it in the side panel. Delegated requests also need one actionable owner to avoid duplicate permission panels.

This change lets direct review-child requests stay actionable on the child surface while delegated subagent requests remain owned by the parent Task surface.

Verification

  • pnpm --dir src/web-ui run test:run src/flow_chat/components/modern/permissionRequestRouting.test.ts src/flow_chat/components/modern/usePermissionRequests.test.tsx — 2 files, 17 tests passed.
  • pnpm --dir src/web-ui run lint — passed.
  • pnpm run type-check:web — passed.
  • git diff --check — passed.
  • Manual UI interaction checks were not run, per the local FlowChat verification guide.

Remote scenarios: no live remote scenario was exercised. The owner-selection behavior is covered at unit/hook level; Remote Control and Peer Device Mode remain pending manual integration checks. Remote Workspace and Detached Dispatch are not directly affected by this UI-only change.

Reviewer Notes

  • git range-diff confirms this is patch-equivalent to GitCode PR Third-party API incompatibility #75 on top of the current GitHub main.
  • AI-assisted change; automated verification above passed, manual UI verification pending.
  • No persisted shapes, protocol contracts, user-visible strings, or locale resources changed.

Checklist

  • This PR is focused and does not include secrets, temporary prompts, generated scratch files, or unrelated artifacts.
  • Relevant verification is recorded above, or skipped checks are explained.
  • User-facing strings, docs, and locales are updated where applicable.

BTW and review sessions render outside the main flow-chat container, so a direct permission request could block the child runtime without exposing any way to answer it in the side panel.

Render the shared permission mailbox in BtwSessionPanel and separate broad transcript routing from actionable ownership. Delegated subagent requests remain owned by the parent Task surface, while direct review-child requests stay with the child surface. This avoids duplicate permission panels without inheriting the parent's permission mode.

Add routing and hook regression coverage for direct and delegated requests, including the one-owner active batch behavior.
@bobleer
bobleer merged commit 32f2427 into GCWing:main Aug 28, 2026
8 checks passed
guantw added a commit to guantw/BitFun that referenced this pull request Aug 28, 2026
Adapt GCWing#2595 to the Explore composer architecture. The primary composer handles only requests owned by the primary session, while embedded BTW and review panels expose direct child-session requests through the shared approval band. Delegated requests remain actionable only from the parent surface.
guantw added a commit to guantw/BitFun that referenced this pull request Aug 28, 2026
Adapt GCWing#2595 to the Explore composer architecture. The primary composer handles only requests owned by the primary session, while embedded BTW and review panels expose direct child-session requests through the shared approval band. Delegated requests remain actionable only from the parent surface.

Repair stale design-system test mocks inherited from the latest Explore base so the full frontend suite can exercise the migrated SSH and Appearance dialogs.
guantw added a commit to guantw/BitFun that referenced this pull request Aug 28, 2026
Adapt GCWing#2595 to the Explore composer architecture. The primary composer handles only requests owned by the primary session, while embedded BTW and review panels expose direct child-session requests through the shared approval band. Delegated requests remain actionable only from the parent surface.

Repair stale design-system test mocks and normalize a cross-platform stylesheet fixture inherited from the latest Explore base so the full frontend suite passes on Linux and Windows checkouts.
1688mengdie pushed a commit to BitFun-SIG/taiji-plugin-library that referenced this pull request Aug 29, 2026
上游 2 提交(PR GCWing#2595 权限请求单 owner 路由):
- 4177686 fix(flow-chat): route permission requests to a single owner
- 32f2427 Merge pull request GCWing#2595

交集 3 文件 auto-merge 干净,逐文件归因(无文本冲突):
- BtwSessionPanel.tsx: 原则③双方并存(上游权限信箱投影嵌入 BTW 面板 / 本地历史自动加载放宽+chat-full-width+失败重试),锚点互不重叠
- ModernFlowChatContainer.tsx: 原则④上游 ownedRequests/ownedActiveBatch 收窄口径采上游 + 本地 headerLeftActionsContent(R-GC-24)并存
- usePermissionRequests.test.tsx: 原则③双方并存(上游 owned 语义断言×2 + 本地 getAvailableModes mock)
验证门: cargo check -p bitfun-core --lib / --features agent-runtime / --features product-full / -p bitfun-transport --jobs 4 + cargo metadata --locked 探针(记录见 sync-record-20260829-四区.md)
Cargo.lock 工作树遗留为所有者未裁决产物,现状保留未动
bobleer added a commit that referenced this pull request Aug 29, 2026
…n-fixes-explore

fix(explore): backport #2565 and adapt #2595
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants