Skip to content

Fix Quick Chat workspace chrome - #787

Closed
coneilen wants to merge 11 commits into
scgopi:mainfrom
coneilen:coneilen-microsoft-wave1-d-quick-chat
Closed

coneilen wants to merge 11 commits into
scgopi:mainfrom
coneilen:coneilen-microsoft-wave1-d-quick-chat

Conversation

@coneilen

@coneilen coneilen commented Oct 14, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Fix the Windows Quick Chat workspace so dismissing a chat cannot restore its chat-scoped workspace or the previous loop's bar and panel when workspace toggles are used. Refs #774.

Changes

  • Show Quick Chat-specific workspace chrome and keep loop-only panels/actions out of chat workspaces while preserving the chat's agent pane.
  • Carry chat creation time through the model and create new chats with a date-stamped title and configured default backend.
  • Clear the chat workspace binding only after dismissal successfully resets to the current graph; prevent either workspace toggle from resurfacing a chat-bound workspace after a reset failure, and restore ordinary workspace behavior on project/node selection.
  • Match macOS Restart-session behavior: LoopWorkspaceLoopBar.swift:112-113 paints the button for unresolved nodes, while AppFeature+LoopSessions.swift:105-107 intentionally does nothing for Quick Chats. Windows paints and publishes the workspace-restart-session- UIA action; it is a visible no-op for chats, as documented by macOS: Quick Chat loop bar shows a Restart session button that does nothing #804.
  • Add workspace-binding, UIA/protocol, timestamp, and native Restart-session UIA regressions. The empty Quick Chats canvas/CTA remains deferred to lane B and is not claimed by this PR.
  • Restore the current-main GraphCanvas.loopDetailSparklineBounds and GraphCanvas.loopDetailFooterBounds accessibility geometry after the rebase regression.

Test plan

RED: zig.exe test src\App.zig --test-filter "opening a quick chat after a loop workspace selects the chat bar through its UIA item" on origin/main -> expected chat-1, found loop-a; 0 passed, 1 failed (behavioral).
GREEN: & $env:GRAPHCODE_ZIG0152 test src\App.zig src\AccessibilityProvider.cpp src\FilePicker.c src\FolderPicker.c C:\gcp\d2\winghostty\zig-out\lib\winghostty-win32-host.lib -DUNICODE -D_UNICODE -target x86_64-windows-msvc -lc -luser32 -lgdi32 -lgdiplus -lmsimg32 -lopengl32 -lkernel32 -limm32 -lole32 -loleaut32 -luiautomationcore -lshell32 -ladvapi32 -lwinhttp -IC:\gcp\d2\winghostty\include zig-out\lib\ghostty-vt-static.lib --cache-dir C:\gcs\d2\postpush-focused\cache --global-cache-dir C:\gcs\d2\postpush-focused\global-cache --test-filter "quick chat workspace" -> 2/2 passed on 29b4e3e.
REGRESSION: & $env:GRAPHCODE_ZIG0152 test src\App.zig src\AccessibilityProvider.cpp src\FilePicker.c src\FolderPicker.c C:\gcp\d2\winghostty\zig-out\lib\winghostty-win32-host.lib -DUNICODE -D_UNICODE -target x86_64-windows-msvc -lc -luser32 -lgdi32 -lgdiplus -lmsimg32 -lopengl32 -lkernel32 -limm32 -lole32 -loleaut32 -luiautomationcore -lshell32 -ladvapi32 -lwinhttp -IC:\gcp\d2\winghostty\include zig-out\lib\ghostty-vt-static.lib --cache-dir C:\gcs\d2\postpush-focused\cache --global-cache-dir C:\gcs\d2\postpush-focused\global-cache --test-filter "DPI UIA" -> 3/3 passed on 29b4e3e.

The same App test root and pinned dependencies passed with --test-filter "chat-bound workspace" (1/1) and --test-filter "loop detail UIA rectangles" (1/1), also on 29b4e3e. Logs: C:\gcs\d2\postpush-focused\quick-chat.log, chat-bound.log, loop-detail.log, and dpi-uia.log.

The native Restart-session contract test was run before and after the provider AutomationId mapping: RED was 208 checks with 2 expected failures (missing stable AutomationId and canvas-card-count invariant); GREEN was 208 checks, 0 failures. Exact-head shard-0 CI is pending after this push and will exercise the test wired by #802.

The last desktop full-unit run was on 624bff1: 1201/1201 tests and 55/55 sections completed, but the command exited 1 only because the #802 harness cleanup hit a Remove-Item race. #805 fixes that cleanup path; a current-head full -ShellPart unit run is still pending its desktop slot and is not claimed as passing.

Not verified

  • Exact-head CI for 29b4e3e is still queued; no current-head CI result is claimed yet.
  • The existing paired capture from 624bff1 remains applicable to the chat-bar pixels because this workspace-binding fix does not change Quick Chat painting, so no recapture is indicated for this commit. That capture's Agent-tab assertion failed and its pane remained at “Opening quick chat...”; it does not establish persisted daemon launch or agent attachment.
  • A current-head full -ShellPart unit run inside a desktop slot remains pending. The previous run's default-profile guard used a process-scoped scratch profile and the real-folder validation root C:\gc-d2.
  • The native contract test has local RED/GREEN evidence above; its current-head shard-0 CI result is pending.
  • The earlier local WorktreeGitProcess case=removals failure remains unattributed. A later run passed that case under the real C:\gc-d2 root, but that does not establish the earlier failure's cause.
  • make test and make check were not run; they are macOS validation commands and do not cover this Windows change.
  • Persisted daemon Quick Chat startup and agent attachment remain unverified; this PR does not claim either behavior.

Checklist

  • I have read the Contributing Guidelines
  • I have signed off my commits (git commit -s) per the DCO
  • Tests pass locally (make test)
  • Code follows the existing style (make check)
  • I added the test/contract before the implementation and observed the intended RED failure

@coneilen
coneilen force-pushed the coneilen-microsoft-wave1-d-quick-chat branch 5 times, most recently from 8874cd0 to a0ef04c Compare October 14, 2026 12:13
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 0f073d0e-2c12-43fc-bfed-4ab3c4867b37
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 0f073d0e-2c12-43fc-bfed-4ab3c4867b37
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 0f073d0e-2c12-43fc-bfed-4ab3c4867b37
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 0f073d0e-2c12-43fc-bfed-4ab3c4867b37
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 0f073d0e-2c12-43fc-bfed-4ab3c4867b37
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
Scope the Quick Chat workspace to its own bar and persist its creation timestamp.

Refs scgopi#774

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 3072b347-66bd-4d89-8c59-71a1f6f4a33d
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
Use the current-main loop detail bounds and load the Quick Chat row through the protocol fixture in the workspace regression.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 3072b347-66bd-4d89-8c59-71a1f6f4a33d
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 3072b347-66bd-4d89-8c59-71a1f6f4a33d
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
Limit Quick Chat panel suppression to the active chat workspace so returning to Graph can reopen the loop panel.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 3072b347-66bd-4d89-8c59-71a1f6f4a33d
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
Publish the chat bar and its actions independently of a project graph, with a regression covering the graph-less workspace path.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 3072b347-66bd-4d89-8c59-71a1f6f4a33d
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
Clear the chat-scoped workspace when returning to the graph and prevent toggles from restoring it until the user selects a project or loop.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 3072b347-66bd-4d89-8c59-71a1f6f4a33d
Signed-off-by: Colin Neilens <coneilen@microsoft.com>
@coneilen

Copy link
Copy Markdown
Collaborator Author

Closed unmerged by operator decision (2026-10-14). Wave 1 was stopped and is being restarted from current main under a revised process: exact-head CI as the regression gate, screenshots taken once at the end, and escalation only after 5 failed iterations. This PR's findings are recorded on the issue. Superseded by the wave-2 PR for the same issue.

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.

1 participant