Skip to content

Fix desktop visible error states / 修复桌面可见错误状态#5119

Merged
SivanCola merged 2 commits into
esengine:main-v2from
GTC2080:GTC/fix-desktop-visible-errors
Jun 25, 2026
Merged

Fix desktop visible error states / 修复桌面可见错误状态#5119
SivanCola merged 2 commits into
esengine:main-v2from
GTC2080:GTC/fix-desktop-visible-errors

Conversation

@GTC2080

@GTC2080 GTC2080 commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Split Settings initial loading from failures so rejected startup settings reads show a safe error message and retry path instead of an endless loading state.
  • Preserve Workspace Changes git metadata in frontend state and show a non-blocking warning when git status is unavailable or failed, while still rendering session files.
  • Surface non-image paste/drop attachment failures through the existing toast path without clearing composer content or exposing local paths in user-visible text.

Verification

  • git diff --check
  • (cd desktop/frontend && corepack pnpm test)
  • (cd desktop/frontend && corepack pnpm build)
  • (cd desktop && go test ./...)
  • go test ./...

Cache impact

Cache-impact: none - desktop frontend visible error/empty-state handling only; no provider-visible prompt, tool schema, request serialization, memory prefix, or cache-sensitive behavior changed.
Cache-guard: (cd desktop/frontend && corepack pnpm test) covers the new Settings, Workspace Changes, and Composer regressions.
System-prompt-review: N/A

@github-actions github-actions Bot added v2 Go rewrite (1.x) — main-v2 branch, active development desktop Wails desktop app (desktop/**) labels Jun 23, 2026
@GTC2080 GTC2080 force-pushed the GTC/fix-desktop-visible-errors branch from a175859 to 87f7a4a Compare June 23, 2026 05:59
@GTC2080 GTC2080 force-pushed the GTC/fix-desktop-visible-errors branch from 87f7a4a to 1466e44 Compare June 23, 2026 06:30

@SivanCola SivanCola left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, I reviewed this against the latest main-v2 and the implementation looks directionally right: the Settings panel now exits the endless loading state on startup read failure, Workspace Changes keeps rendering session files while surfacing git-status failures, and pasted/dropped non-image attachment failures now use the existing toast path without exposing exception text.

I cannot approve it in the current state because the PR head is now conflicting with main-v2. Please rebase onto the latest main-v2 and resolve these conflicts before merge:

  • desktop/frontend/package.json
  • desktop/frontend/src/__tests__/composer-goal-toggle.test.tsx
  • desktop/frontend/src/components/WorkspacePanel.tsx

When resolving WorkspacePanel.tsx, please preserve the newer code-preview/body class handling from main-v2 and then reapply the WorkspaceChangesView state shape plus git-unavailable warning. When resolving composer-goal-toggle.test.tsx, please keep the newer composer draft/session coverage from main-v2 and add this PR's attachment-failure assertions on top.

Related PR scan: this overlaps with Workspace Changes work in #4843, #4987, and #5245. I think this PR can still merge independently after rebase because it is narrowly about visible error states, but the final rebase should re-check the combined Workspace Changes UI.

Security/cache review: pass. I did not see new dependencies, network calls, command execution, privilege expansion, provider-visible prompt changes, tool-schema changes, provider request serialization changes, compaction changes, or reasoning upload changes.

Verified on the PR head:

  • git diff --check origin/main-v2...HEAD passed
  • corepack pnpm --dir desktop/frontend exec tsx src/__tests__/workspace-changes-errors.test.tsx passed
  • corepack pnpm --dir desktop/frontend exec tsx src/__tests__/settings-refresh-snapshot.test.tsx passed
  • corepack pnpm --dir desktop/frontend exec tsx src/__tests__/composer-goal-toggle.test.tsx passed
  • GitHub checks are currently green on the old head, including desktop, platform tests, CodeQL, and cache-impact

Once the conflicts are resolved and CI stays green on the rebased head, I will consider merging it into main-v2.

@SivanCola

Copy link
Copy Markdown
Collaborator

Pushed e3a7ad9a7 to resolve the main-v2 conflicts on this PR.

What changed:

  • Merged the latest main-v2 into the PR head.
  • Kept the newer WorkspacePanel split/code-preview behavior from main-v2 and reapplied the Workspace Changes git-unavailable warning path.
  • Kept the newer composer drop-navigation regression and retained this PR's pasted/dropped attachment failure coverage.
  • Included workspace-changes-errors.test.tsx in the updated frontend test script list.

Verified after the merge:

  • git diff --check passed
  • corepack pnpm --dir desktop/frontend exec tsc --noEmit passed
  • corepack pnpm --dir desktop/frontend check:css passed
  • corepack pnpm --dir desktop/frontend exec tsx src/__tests__/workspace-changes-errors.test.tsx passed
  • corepack pnpm --dir desktop/frontend exec tsx src/__tests__/settings-refresh-snapshot.test.tsx passed
  • corepack pnpm --dir desktop/frontend exec tsx src/__tests__/composer-goal-toggle.test.tsx passed

Note: corepack pnpm --dir desktop/frontend exec tsc --noEmit -p tsconfig.test.json still reports pre-existing test typing issues in unrelated test files (composer-profile.test.ts and use-controller-meta.test.ts).

GitHub now reports the PR as mergeable; required checks are still running on the new head.

@SivanCola SivanCola merged commit ba8ccc0 into esengine:main-v2 Jun 25, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

desktop Wails desktop app (desktop/**) v2 Go rewrite (1.x) — main-v2 branch, active development

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants