Skip to content

[Fixed] Repository list scrolling gets stuck over tall groups - #22438

Merged
sergiou87 merged 2 commits into
desktop:developmentfrom
peteski22:fix-repository-list-scroll-capture
Jun 30, 2026
Merged

sergiou87 merged 2 commits into
desktop:developmentfrom
peteski22:fix-repository-list-scroll-capture

Conversation

@peteski22

Copy link
Copy Markdown
Contributor

Closes #22387

Description

In the repository list, mouse-wheel/trackpad scrolling gets stuck and jerks up/down a few pixels when the pointer is over the rows of a group that is taller than the visible foldout (e.g. a large organization). Over a group header, a short group, or empty space it scrolls normally. It can occasionally "break out" and then gets stuck again after selecting a different repository.

Root cause

SectionList renders each group as its own nested react-virtualized Grid inside the outer (root) grid that owns the real scrollbar. The per-section grids are meant to be passive windows whose scroll position is driven entirely by the parent via the scrollTop prop.

However, when a section is taller than its allotted height, react-virtualized gives that inner grid overflow-y: auto, making it independently scrollable. The mouse wheel then scrolls the inner grid instead of the root container. Because the inner grid's scrollTop is controlled by the parent, it moves a few pixels and immediately snaps back — producing the stuck/jerky behaviour. Selecting a repository changes selectedRows, which forces every section grid to re-render and re-applies the controlled scrollTop, which is why scrolling appears to "work for a bit" after a click.

Sections that fit within the viewport are not scrollable, which is why scrolling works when the pointer is over short groups or group headers.

This was observed live (macOS Tahoe 26.5.1, Apple Silicon) by inspecting the rendered grids: the tall section's grid reports overflow-y: auto with only a few pixels of internal scroll range, while every other section reports overflow-y: hidden.

Fix

Force the per-section grids to overflow: hidden so they act as the passive windows they were always intended to be, leaving the root grid as the sole scroll surface. react-virtualized still positions each section correctly via the controlled scrollTop, and the wheel now always reaches the root scroll container.

Tests

Added app/test/unit/ui/section-list-scroll-test.tsx, which renders a SectionList with one section taller than the viewport and asserts that no per-section grid is independently scrollable. It fails on development (overflow-y: auto) and passes with this change.

Screenshots

This is a scroll-interaction fix with no visual change; behaviour is covered by the added unit test and was verified manually in a dev build.

Release notes

Notes: [Fixed] Scrolling no longer gets stuck when the pointer is over a tall group in the repository list - #22387

Copilot AI review requested due to automatic review settings June 29, 2026 15:44
@peteski22
peteski22 requested a review from a team as a code owner June 29, 2026 15:44
@peteski22
peteski22 requested a review from niik June 29, 2026 15:44
@github-actions github-actions Bot added external Pull request originating outside of the Desktop core team needs-triage unmet-requirements and removed needs-triage labels Jun 29, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for your pull request! Unfortunately, it doesn't meet the requirements for review:

  • None of the referenced issues have the help wanted label

Please update your PR to address the above. This PR will be automatically closed in 7 days if these requirements are not met.

Full contribution requirements
  1. Include a detailed description of what this PR does
  2. Link to an issue with the help wanted label (use Fixes #123 or Closes #123)

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes a scroll interaction bug in the repository list where wheel/trackpad scrolling can get “stuck” when the pointer is over a section (group) whose inner react-virtualized Grid becomes independently scrollable.

Changes:

  • Force per-section react-virtualized grids to use overflowX/overflowY: hidden so only the outer grid remains scrollable.
  • Add a unit test that renders a tall section and asserts per-section grids are not independently scrollable.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
app/src/ui/lib/list/section-list.tsx Prevents inner section grids from becoming scrollable by forcing overflow to hidden.
app/test/unit/ui/section-list-scroll-test.tsx Adds regression coverage to ensure per-section grids never end up with overflow-y: auto for tall sections.

@peteski22

Copy link
Copy Markdown
Contributor Author

@sergiou87 no rush at all — but whenever you get a chance to take a look, if the approach here seems reasonable, would you be able to add the help wanted label to #22387 (or handle it however you'd prefer)? That'll clear the contribution check so this can be picked up for review.

There's a quick repro recipe and some DOM evidence over in #22387 — the short version is that a group taller than the foldout makes its inner react-virtualized grid independently scrollable, so the wheel scrolls that inner grid (whose scrollTop is parent-controlled) and snaps back instead of scrolling the list. Happy to adjust anything or record a video if useful.

(Paired through the investigation and fix with Claude Code; the words are mine.)

@leftCoast

Copy link
Copy Markdown

Well, the bug seems to be here on macOS x64. Can someone kick this thing and pull this fix? I'm completely stuck with this version.

@sergiou87

sergiou87 commented Jun 30, 2026 •

Copy link
Copy Markdown
Member

@peteski22 thank you for this!! With your instructions I was able to reproduce the problem and now, with this patch, I can see it fixed.

Could you update this branch with the latest development to fix CI checks, please? 🙏

The grouped repository list renders each group as its own nested
react-virtualized grid inside the outer scroll container. When a group is
taller than the visible area react-virtualized gives that inner grid an
overflow-y of 'auto', making it independently scrollable. The mouse wheel
then scrolls the inner grid - whose scroll position is controlled by the
parent - so it nudges a few pixels and snaps back instead of scrolling the
list. Selecting a repository forces the inner grids to re-render and
re-applies the controlled position, which is why scrolling resumes briefly
after a click.

Force the per-section grids to overflow: hidden so they act as passive
windows driven solely by the parent's scrollTop, leaving the outer
container as the only scroll surface.

Closes desktop#22387
Track whether ResizeObserver was present on globalThis/window before the
test overrode it and delete the property on cleanup when it wasn't, rather
than leaving a lingering undefined value that could leak into other tests
that check for its presence.
@peteski22
peteski22 force-pushed the fix-repository-list-scroll-capture branch from 5296af0 to e64598b Compare June 30, 2026 18:31
@peteski22

Copy link
Copy Markdown
Contributor Author

Thanks @sergiou87, glad it reproduced! Rebased onto the latest development — CI should be happy now. Let me know if you'd like any changes.

@sergiou87 sergiou87 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thank you for this!! 💖

@sergiou87
sergiou87 merged commit 82ad6c1 into desktop:development Jun 30, 2026
9 checks passed
pull Bot pushed a commit to ConnectionMaster/desktop-1 that referenced this pull request Jul 1, 2026
…croll-capture

[Fixed] Repository list scrolling gets stuck over tall groups

@dmitrijsingur26-prog dmitrijsingur26-prog left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

app/src/ui/lib/list/section-list.tsx

@ketong999

Copy link
Copy Markdown

TTEZWW2Fz8VCR7s2kcn3bea764p6Y8dmjh

@EYEHACK-M

This comment has been minimized.

@peteski22
peteski22 deleted the fix-repository-list-scroll-capture branch July 28, 2026 10:35
Kosikowski added a commit to Kosikowski/GitHub-Desktop-Plus that referenced this pull request Aug 17, 2026
* Draft release 3.5.13-beta1

* Apply suggestion from @tidy-dev

* Apply suggestion from @tidy-dev

* Apply suggestion from @tidy-dev

* Apply suggestion from @tidy-dev

* Update changelog.json

* Fix linting issues

* Fix variable-height SectionList row offsets

* Handle incomplete Copilot token pricing

* Add popup ARIA to popover dropdowns

* Add aria-describedby to cost details button

Add conditional aria-describedby/aria-controls handling for the Copilot cost details button and disable tooltip-managed aria-describedby. Update tests to use test timers, assert aria attributes before/after opening the popover, and simulate hover to verify tooltip behavior. Ensures correct accessibility attributes and prevents tooltip from overwriting aria-describedby.

* Add aria-label to popover button for model picker

Expose buttonAriaLabel prop on PopoverDropdown and set it in CopilotModelPicker to provide a descriptive aria-label (e.g. "Commit message generation: GPT-5 mini"). Improves accessibility by labeling the dropdown button. Update unit test to assert the new aria-label.

* Simplify code

* Use type-only Copilot RPC imports

* Fix Copilot model comment grammar

* Scope Copilot preferences ResizeObserver test override

* Use type-only Copilot model imports in tests

* Restore ResizeObserver test globals precisely

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Honor number preferences for model credit costs

* Select cheapest Copilot model without sorting

Co-Authored-By: Markus Olsson <[email protected]>

* Use shared formatCompactNumber and update tests

Replace local formatCompactNumber implementation with shared formatter from lib/format-number and simplify formatTokenBatchSize to delegate to it. Update unit tests to reflect new batchSize/contextMax values and localized compact formatting: add helpers (assertElementTextContent, getCostDetailsValue) and adjust expectations for token/unit labels and values.

Co-Authored-By: Markus Olsson <[email protected]>

* Add copilotLicenseType to user/copy APIs and model

Expose user's Copilot license type across API and account model. Added copilotLicenseType to Viewer response types and fetchUserCopilotInfo, returned in fetchUser and mapped into the Account constructor. Updated Account to store and carry copilotLicenseType through withToken. Enables code to surface user's Copilot license type alongside endpoint and desktop-enabled flag.

* Refactor Copilot preferences access UI

Replace boolean copilotAvailable with dotComAccount and explicit Copilot access states (signed-out, checking, no-license, desktop-disabled, enabled). Show contextual call-to-action UI for sign-in, view plans, or open Copilot feature settings when access is not enabled. Add CallToAction usage, new handlers in Preferences to open browser links, and styling for the CTA. Update tests to cover new access states and behaviors, and adjust App/Preferences props accordingly. Improves clarity of Copilot settings UX and centralizes access logic.

* Support multiple accounts in Copilot prefs

Replace single dotComAccount with accounts array in Copilot preferences. Compute Copilot access by scanning all accounts (enabled / checking / no-license / desktop-disabled) and introduce CopilotLicenseTypeNoAccess constant. Update Preferences consumer to pass accounts and simplify copilot SDK checks with Array.some. Adjust tests and account factory (makeAccount) to match new shape and add coverage for multi-account scenarios (enabled and checking states).

* Clarify Copilot access messaging

Update copy in preferences UI to clarify licensing and feature setting state. Replace vague "require access to GitHub Copilot" with explicit "require a GitHub Copilot license", and change desktop-disabled message to state that a license exists but "Copilot in GitHub Desktop" is disabled in Copilot feature settings. Helps users better understand required license vs feature toggle. (app/src/ui/preferences/copilot.tsx)

* Rename Copilot sign-in handler and update messaging

Rename prop onDotComSignIn to onSignIn and wire Preferences to select Accounts tab when Copilot sign-in is requested. Update Copilot preferences UI text and button label to be account-agnostic ('Sign in to an account', 'Sign In') and reword Copilot/license messages. Update unit tests to match the new prop name and copy changes.

* Fix Copilot access state for unloaded metadata

Require Copilot license metadata before showing the model picker and ignore GHES accounts when deriving settings access state. Add regression coverage for unloaded license metadata, GHES accounts, and GHE account access.

* Update copilot-preferences-test.tsx

* Use account endpoint when creating a client with Copilot SDK

* (WIP) Use Copilot SDK with GHE accounts

* Use GHE host (strip api.) for Copilot CLI

Import isGHE and update getCopilotGHHost to return the correct GitHub Enterprise host. For GHE endpoints, strip a leading "api." prefix (e.g. "api.example.com" -> "example.com"); preserve existing behavior for dotcom and non-GHE endpoints. This ensures Copilot CLI host override matches Enterprise host naming expected by tooling.

* Add GITHUB_COPILOT_INTEGRATION_ID env var

Set GITHUB_COPILOT_INTEGRATION_ID in CopilotStore environment to `copilot-desktop` and append `-dev` when __DEV__ is true. This exposes integration identifier to the Copilot process for host/integration awareness.

* Respect Copilot Desktop enabled flag when selecting account

When searching for an account eligible for Copilot SDK commit message generation, add a check for account.isCopilotDesktopEnabled. Prevents selecting accounts that have Copilot SDK enabled but where Copilot Desktop is disabled. Change in app/src/lib/stores/app-store.ts.

* Remove unnecessary app state field

* Clear stale Copilot models on account changes

Avoid keeping the previous account's Copilot model list when the selected Copilot account has no cached models yet. Re-sync from the active account cache when model fetching returns no list so Settings shows loading instead of stale data.

* Warm Copilot models after account updates

Kick off a non-blocking model fetch when an account update selects an eligible Copilot account with no cached model list. Share the fetch path with the Settings dispatcher action so the Copilot tab can leave its loading state after sign-in while already open.

* Update app-store.ts

* Add 'Always use Copilot for conflict resolution' setting and nudge

- Add toggle in Settings → Copilot to always start Copilot when
  merge conflicts are detected
- Add settings button to Copilot conflicts result dialog header
- Show a one-shot nudge dialog at 5 clicks suggesting the setting
- Consolidate the old button-clicked boolean and use-count into a
  single numeric click counter (migrates old localStorage values)
- Dismiss/Esc on nudge dialog continues resolution (same as No)

Co-authored-by: Copilot <[email protected]>

* Update app/src/lib/shells/win32.ts

* Update octicons and bump @primer/octicons

Regenerate octicons (app/src/ui/octicons/octicons.generated.ts) with many new/updated icon variants and sizes. Bump @primer/octicons dependency from ^19.0.0 to ^19.28.1 and update yarn.lock accordingly. Keeps icon set in sync with upstream release 19.28.1.

* Show spinner icon while generating commit message

Replace the 'x' icon with 'squareCircle' when a commit message is being generated. Keeps the Copilot icon for normal state; swaps to squareCircle during generation to better indicate in-progress status.

* Refactor active session/client names and cancel

Rename activeSession/activeClient to generationActiveSession/generationActiveClient for clarity. Update commit message generation flow to use the new fields, ensure both are cleared in finally, and improve cancelCommitMessageGeneration to handle cases where only a client exists by calling client.stop(). Preserve abort() when a session exists and log errors on failures.

* Add TabBar with Summary/Changes tabs to Copilot conflicts dialog

Introduce a tab bar to the Copilot conflict resolution dialog with two
tabs: Summary (existing content) and Changes (skeleton placeholder).

- Add CopilotConflictsChanges placeholder component that accepts
  conflictedFiles and copilotResolutions props for future diff support
- Track selected tab in component state
- Apply copilot-conflicts-changes-active className to widen dialog to
  800px when Changes tab is active
- Style tab bar to span full dialog width with negative margins

Co-authored-by: Copilot <[email protected]>

* Gate Changes tab behind enableCopilotConflictResolutionChangesTab feature flag

Add a development-only feature flag so the Changes tab is hidden in
production builds. When the flag is off, the dialog renders the existing
summary + file list without any tab bar.

Co-authored-by: Copilot <[email protected]>

* Fix prettier: remove extra blank line in findWarp()

Co-authored-by: Copilot <[email protected]>

* Add split-pane layout for Changes tab with FileList and Diff

Replace the placeholder with a layout mirroring PullRequestFilesChanged:
- Uses the existing FileList component (via CommittedFileChange adapter)
- Uses the real Diff component with mock ITextDiff data (2 sample files
  showing conflict marker removal)
- DiffOptions gear icon for toggling side-by-side view
- Minimal SCSS following the pull-request-files-changed pattern

The mock data demonstrates the layout with realistic conflict resolution
hunks. Real diff computation will be wired in a follow-up PR.

Co-authored-by: Copilot <[email protected]>

* Add cancellable Copilot commit generation check

Add logic to CommitMessage to determine when in-flight Copilot commit message generation can be cancelled based on account + Copilot SDK feature flag. Adjust UI to show/cancel button state and icon only when cancellation is allowed. Wire in getAccountForCommitMessageGeneration and feature flag enableCopilotSdkCommitMessageGeneration. Add unit tests covering both disabled and enabled Copilot SDK cases for the copilot button behavior.

* Update Copilot button ariaLabel and disabled logic

Refine Copilot generate button accessibility and behavior while a commit message is being generated. Replace previous ternary logic with explicit branches to surface three states: prompt to generate, canceling generation, and "Generating commit details…". Also adjust disabled condition to check cancelability directly. Update unit test to expect the new "Generating commit details…" aria label.

* Replace mock diff with real resolution diff computation

Use git diff --no-index with temp files to compute actual diffs between
the on-disk conflicted file and Copilot's resolved content. This follows
the same pattern used by getWorkingDirectoryDiff for new/untracked files.

Changes:
- Add getResolutionDiff() in app/src/lib/git/diff.ts that writes original
  and resolved content to temp files, runs git diff --no-index, and parses
  the output through DiffParser
- Refactor CopilotConflictsChanges to load diffs asynchronously with
  request-token guards against stale setState from rapid file switching
- Support hideWhitespaceInDiff toggle by passing -w flag
- Add loading state and error handling with graceful fallback
- Include large diff and buffer size safety checks
- Remove createMockDiff() entirely

Co-authored-by: Copilot <[email protected]>

* Use merge base (stage 1) instead of on-disk conflicted file for diff

Diff the common ancestor (:1:path) against Copilot's resolution rather
than the file with conflict markers. This produces a cleaner diff that
shows what changed relative to the last clean version — no conflict
markers appear as deletions.

Falls back to on-disk content if stage 1 is unavailable (e.g. not in
an active merge).

Co-authored-by: Copilot <[email protected]>

* Use assertNever in renderTabContent for exhaustiveness checking

Refactor renderTabContent to a switch statement with assertNever in the
default case so the compiler catches missing cases if new tabs are added.

Co-authored-by: Copilot <[email protected]>

* Refine commit message generation UI logic

Improve commit message generation UI logic by extracting local booleans (canCancelGenerateCommitMessage, showCancelGenerateCommitMessage) and tightening conditions. Ensure aria-label informs user when no files selected, correctly show "Cancel generating" state only when generation can be cancelled, and use local var for disabled calculation. Simplifies conditional checks and clarifies accessible labels during generation.

* Tighten commit-message test runtime checks

Refactor commit-message test helpers: decouple test instance type from CommitMessage and add explicit runtime guards when reading Copilot button (throwing clear errors on null/undefined). Replaces assert.notEqual checks with direct checks to produce clearer failures and stricter typing in tests.

* Show modified icon instead of conflict warning in changes file list

The Changes tab previews what a resolution will produce, so showing the
conflict warning emblem is misleading. Override file status to Modified
when constructing the file list items.

Co-authored-by: Copilot <[email protected]>

* Fix Prettier formatting

Co-authored-by: Copilot <[email protected]>

* Address review feedback: race condition, diff type handling, tests, enum typing

- Fix race condition: increment diffRequestId before early return for
  files without a resolution, preventing stale in-flight requests from
  overwriting state
- Render all diff types (Text, LargeText, Unrenderable) instead of only
  Text — the Diff component handles all IDiff variants
- Type onTabSelected with CopilotConflictsTab enum for proper narrowing
  with assertNever
- Add 2 unit tests for getResolutionDiff covering merge-base diffing and
  fallback behavior

Co-authored-by: Copilot <[email protected]>

* Add getStageDiff() for computing diffs against merge stages

Add a new getStageDiff() function that computes a diff from the merge
base (:1:) to a specific conflict stage (:2: for ours, :3: for theirs)
using the same temp-file + git diff --no-index pattern as
getResolutionDiff().

Returns a StageDiffResult discriminated union:
- { kind: 'diff', diff } on success
- { kind: 'missing-stage', stage } when the blob doesn't exist
- { kind: 'error' } on unexpected failures

This provides the foundation for previewing ours/theirs diffs in the
Copilot conflicts Changes tab (UI changes in a follow-up PR).

Includes unit tests covering:
- Computing ours (:2) and theirs (:3) diffs during active conflicts
- Returning missing-stage when a file only exists in one branch
- Respecting the hideWhitespaceInDiff flag

Co-authored-by: Copilot <[email protected]>

* Add abortable commit message generation

Make commit message generation cancellable via AbortController/AbortSignal. Add commitMessageGenerationAbortController to repository state and wire AppStore.withIsGeneratingCommitMessage to create/manage the controller and pass its signal to generation calls. Refactor CopilotStore to accept AbortSignal: add createCancellableSession, make sendAndWait abort-aware, and propagate cancellation to session/client cleanup. Remove previous generationActiveSession/client cancellation fields and replace with signal-driven logic. Update repository-state-cache initial state. Add unit tests covering cancellation at several stages (model resolution, pre-session, during session creation, during generation).

* Add getStageDiff() for computing diffs against merge stages

Add a new getStageDiff() function that computes a diff from the merge
base (:1:) to a specific conflict stage (:2: for ours, :3: for theirs)
using the same temp-file + git diff --no-index pattern as
getResolutionDiff().

Returns IDiff directly (matching getResolutionDiff's signature) rather
than a custom discriminated union. Handles edge cases the same way the
regular changes view does:
- File deleted in stage: diffs base → empty (all-deletion diff)
- File added in stage only (no base): diffs empty → stage (all-addition)
- Neither base nor stage exists: returns DiffType.Unrenderable

This provides the foundation for previewing ours/theirs diffs in the
Copilot conflicts Changes tab (UI changes in a follow-up PR).

Co-authored-by: Copilot <[email protected]>

* Add getStageDiff() for computing diffs against merge stages

Add a new getStageDiff() function that computes a diff from the merge
base (:1:) to a specific conflict stage (:2: for ours, :3: for theirs)
using the same temp-file + git diff --no-index pattern as
getResolutionDiff().

Returns IDiff directly (matching getResolutionDiff's signature) rather
than a custom discriminated union. Handles edge cases the same way the
regular changes view does:
- File deleted in stage: diffs base → empty (all-deletion diff)
- File added in stage only (no base): diffs empty → stage (all-addition)
- Neither base nor stage exists: returns DiffType.Unrenderable

This provides the foundation for previewing ours/theirs diffs in the
Copilot conflicts Changes tab (UI changes in a follow-up PR).

Co-authored-by: Copilot <[email protected]>

* Bump form-data from 4.0.4 to 4.0.6

Bumps [form-data](https://github.com/form-data/form-data) from 4.0.4 to 4.0.6.
- [Release notes](https://github.com/form-data/form-data/releases)
- [Changelog](https://github.com/form-data/form-data/blob/master/CHANGELOG.md)
- [Commits](https://github.com/form-data/form-data/compare/v4.0.4...v4.0.6)

---
updated-dependencies:
- dependency-name: form-data
  dependency-version: 4.0.6
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>

* Remove unused @babel/core and @babel/plugin-transform-modules-commonjs

These dependencies are no longer used anywhere in the codebase:
- No babel config files exist (.babelrc, babel.config.*)
- No source files import or require these packages
- Webpack does not use babel-loader
- Tests use tsx for TypeScript transpilation

They appear to be leftover from when the project used babel-jest
and babel-minify, both of which have since been removed.

Co-authored-by: Copilot <[email protected]>

* Add resolution choice dropdown UI to Copilot conflicts Changes tab

Implement a per-file diff header in the Changes tab with a resolution
choice dropdown that lets users switch between viewing Copilot's merged
resolution, current branch (ours), or incoming branch (theirs) diffs.

Key changes:
- Add resolution dropdown with context menu (same pattern as Summary tab)
- Use SeamlessDiffSwitcher for smooth diff loading transitions
- Add expandable subheader showing resolution reasoning or branch info
- Extract shared resolution helpers to copilot-resolution-helpers.ts
- Remove enableCopilotConflictResolutionChangesTab dev feature flag
- Both tabs read from the same manualResolutions state for bidirectional sync

Co-authored-by: Copilot <[email protected]>

* Address review feedback: fix overflow toggle, no-resolution state, docs

- Fix #1: Re-measure subheader overflow after collapsing via
  requestAnimationFrame so the toggle button persists correctly
- Fix #2: Add noResolution state to avoid rendering SeamlessDiffSwitcher
  (perpetual spinner) when no Copilot resolution exists for a file
- Fix #3: Remove duplicated doc line in getResolutionDiff JSDoc
- Fix #4: Show 'No Copilot resolution available' in subheader when
  no resolution exists instead of misleading default text

Co-authored-by: Copilot <[email protected]>

* Add getStageDiff() for computing diffs against merge stages

Add a new getStageDiff() function that computes a diff from the merge
base (:1:) to a specific conflict stage (:2: for ours, :3: for theirs)
using the same temp-file + git diff --no-index pattern as
getResolutionDiff().

Returns IDiff directly (matching getResolutionDiff's signature) rather
than a custom discriminated union. Handles edge cases the same way the
regular changes view does:
- File deleted in stage: diffs base → empty (all-deletion diff)
- File added in stage only (no base): diffs empty → stage (all-addition)
- Neither base nor stage exists: returns DiffType.Unrenderable

This provides the foundation for previewing ours/theirs diffs in the
Copilot conflicts Changes tab (UI changes in a follow-up PR).

Co-authored-by: Copilot <[email protected]>

* Draft release 3.5.13-beta2

* Make error-reporting endpoints configurable

Adds CI workflow inputs and env vars to supply error-reporting endpoints, exposes them to the renderer via build-time replacements and globals, and switches exception reporting to use those configurable endpoints. Also guards against undefined endpoints (no-op when not provided) and preserves existing fatal-error send guard.

* Update changelog.json

* Inline error-reporting endpoint vars

Remove top-level ErrorEndpoint and NonFatalErrorEndpoint constants and use the build-time macros inline when selecting the reporting URL. Keeps same undefined-guard behavior and avoids module-level bindings so endpoint macros can be evaluated at call time.

* Extract copilot copy into helper and always run

Move Copilot package copying and cleanup logic into new copyCopilotDependency() helper and replace the previous inline block with a call to it. Previously the copy/cleanup ran only for non-production releases; this change unconditionally runs the copying step. Keeps prebuilds and mxc binary pruning logic intact.

Note: behavior change — copilot files are now copied for all builds (was gated by isNonProductionRelease). Co-authored-by: Copilot <[email protected]>

* Respect feature flag for Copilot SDK commit messages

Allow Copilot SDK commit message generation for beta/dev users or when account has 'desktop_enable_copilot_sdk_commit_message_generation'. Replaces previous always-true beta-only return with a combined check and restores production feature-flag gating. Cleans up commented-out code and clarifies intent in comments.

* Remove unused constant

* Use removeAndCopy for copilot package copy

Replace cpSync recursive copy with removeAndCopy when copying copilot package into build output. Ensures destination is removed before copying to avoid stale files left behind and produce a clean, deterministic build output.

* Fix Copilot conflict resolution data loss with per-hunk reassembly

The model was asked to return the complete file content but only received
isolated conflict hunks with 3 lines of context. For non-trivial files,
the model could not reconstruct the surrounding code — causing all
non-conflicted lines to be lost when writeFile overwrote the file.

Redesigns the resolution contract so the model returns resolved content
per conflict hunk (keyed by order, matching 'Conflict 1 of N' in the
prompt), and the app deterministically reassembles the full file by
splicing each resolution into the original file's conflict marker blocks.

This eliminates data loss because:
- Non-conflicted code is preserved exactly (never passes through the model)
- Model output is small (only resolved sections, not entire files)
- No truncation risk regardless of file size
- The reassembly is deterministic — no LLM involved

Changes:
- New per-hunk model response format: resolutions[].hunks[] instead of
  resolutions[].resolvedContent
- New reassembleResolvedFile() function that splices per-hunk resolutions
  into the original file by finding and replacing conflict marker blocks
- New reassembleResolutions() bridge that produces IFileResolution[] from
  raw model output + original file contexts (UI/write path unchanged)
- Store rawContent on IFileConflictContext for reassembly (not in prompt)
- Updated system prompt for per-hunk contract
- validateResolutionPaths now also validates hunk counts per file
- Safety check in _applyCopilotConflictResolutions rejects suspiciously
  small resolutions (<20% of original size) as a belt-and-suspenders guard

Co-authored-by: Copilot <[email protected]>

* Remove obsolete file-size safety check

With per-hunk reassembly, resolvedContent is built deterministically by
splicing model output into the original file. The old safety check that
rejected files <20% of original size was a stopgap from the initial
approach where the model was responsible for returning the complete file.

Co-authored-by: Copilot <[email protected]>

* Recover conflict dialog when conflicts are resolved externally

When a user resolves merge/rebase/cherry-pick conflicts outside of
GitHub Desktop (e.g. in an external editor), a background status
refresh clears changesState.conflictState to null. If the user then
interacts with the still-open conflicts dialog, onContinueAfterConflicts
previously treated null conflictState as an invalid state and threw via
endFlowInvalidState. Because the throw occurred inside an async handler,
it became an unhandled promise rejection — isCommitting was never reset,
leaving the dialog permanently frozen with a loading spinner.

Fix by separating null conflictState (conflicts resolved externally)
from actual logic errors:

- null conflictState: call onFlowEnded() to close the dialog gracefully
  since the conflict flow has ended naturally.
- Other invalid states: continue to throw via endFlowInvalidState() to
  surface real bugs.

Additionally, wrap ConflictsDialog onSubmit/onAbort in error handling so
that any future unhandled throw resets the loading/aborting UI state
instead of freezing the dialog.

Co-authored-by: Copilot <[email protected]>

* Diff all resolution options against conflict-marker file

Previously the diff preview compared resolutions against the merge base
(stage 1), which showed auto-merged changes alongside the actual conflict
resolutions — confusing because it mixed Git's work with the user's choice.

Now all three resolution options (Copilot, current, incoming) diff against
the working-tree file (which still has conflict markers). This gives a
consistent baseline so the user sees exactly what each option changes
relative to the file's current state.

Co-authored-by: Copilot <[email protected]>

* Draft release 3.5.13-beta3

* Bump dompurify from 3.4.0 to 3.4.11 in /app

Bumps [dompurify](https://github.com/cure53/DOMPurify) from 3.4.0 to 3.4.11.
- [Release notes](https://github.com/cure53/DOMPurify/releases)
- [Commits](https://github.com/cure53/DOMPurify/compare/3.4.0...3.4.11)

---
updated-dependencies:
- dependency-name: dompurify
  dependency-version: 3.4.11
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>

* Render dialog error as a child of dialog

* Keep worktree list in sync when renaming or deleting worktrees

Fixes #22335. Renaming a worktree now goes through the dispatcher and
AppStore so that _refreshWorktrees runs afterwards, and when the
currently selected worktree is renamed we switch to its new path before
refreshing. Likewise, deleting the currently selected worktree now uses
the repository returned from switching to the main worktree so the
subsequent git call targets a path that still exists.

Co-authored-by: Pol Rivero <[email protected]>
Co-authored-by: Copilot <[email protected]>

* Don't reserve toolbar space for the worktree foldout when hidden

Fixes #22356. The worktree dropdown is only shown when there are linked
worktrees, but updateResizableConstraints always reserved horizontal
space for it, preventing the branch foldout and push/pull button from
filling the available width. The width allocation now accounts for
whether the worktree dropdown is actually visible, and is recalculated
whenever the set of worktrees changes.

Co-authored-by: Pol Rivero <[email protected]>
Co-authored-by: Copilot <[email protected]>

* Allocate foldout widths in layout order (worktree, branch, push/pull)

Fixes #22357. The toolbar foldouts are laid out as worktree -> branch ->
push/pull, but the resize width constraints were still allocated
branch-first. This made resizing unintuitive once the foldouts were
reordered. The allocation now follows the same order as the layout,
giving the worktree dropdown priority, then the branch dropdown, then
the push/pull button.

Co-authored-by: Pol Rivero <[email protected]>
Co-authored-by: Copilot <[email protected]>

* Widen the add worktree dialog to 500px

Co-authored-by: Copilot <[email protected]>

* Keep rename worktree dialog open when the rename fails

Addresses review feedback on #22335. dispatcher.moveWorktree now returns
a boolean indicating success (reporting any error via postError), and the
rename dialog only dismisses on success so the user can correct the name
and retry after a failure (e.g. name collision or locked worktree).

Co-authored-by: Copilot <[email protected]>

* Reserve toolbar space when the worktree foldout is open with no worktrees

Addresses review feedback on #22356. The worktree dropdown is also
rendered when its foldout is open (even with no linked worktrees) so the
user can create their first worktree from the toolbar.
isWorktreeDropdownVisible now mirrors that render condition, and the
toolbar width constraints are recalculated when the worktree foldout is
opened or closed so the dropdown no longer overflows the toolbar.

Co-authored-by: Copilot <[email protected]>

* Preserve repository state when renaming the selected worktree

Addresses review feedback on #22335. A repository's hash (the key used by
the state cache) is derived from its path, so renaming the currently
selected worktree changed the hash and caused _selectRepository to hit a
cache miss, resetting in-memory UI state such as a typed commit message.
RepositoryStateCache.transferState now moves the cached state to the new
identity before re-selecting, since the renamed worktree is still the
same working directory.

Co-authored-by: Copilot <[email protected]>

* Don't record a worktree deletion when removal fails

Addresses review feedback (pre-existing issue surfaced while fixing
#22335). The catch block in _deleteWorktree showed the failure popup but
fell through to refresh the worktrees and increment the deleted count,
recording a deletion that never happened and double-counting when the
user retried with force. It now returns early on failure so the success
path only runs when the worktree is actually removed.

Co-authored-by: Copilot <[email protected]>

* Apply prettier formatting

Co-authored-by: Copilot <[email protected]>

* Draft release 3.5.13-beta4

* Update changelog with fixes for worktree issues

* Ensure GIT_EXEC_PATH is set for hook proxy

When running hooks the bundled git may set an incorrect GIT_EXEC_PATH. This change ensures GIT_EXEC_PATH is populated from the system git's --exec-path when missing in the shell environment. Added util wrappers (promisify execFile), memoized lookup, and which usage to locate system git, plus logging and fallbacks. createHooksProxy now uses ensureGitExecPathEnv to adjust the shell env before invoking the internal git. This avoids broken //libexec/git-core paths and makes hook execution more reliable across user environments.

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Draft release 3.5.13

* Update to 3.6.0 and enable Copilot/worktree flags

Bump app version to 3.6.0 and flip feature-flag defaults: Copilot conflict resolution and worktree support are now enabled by default (changed to always-true functions). Update changelog to list 3.6.0 release notes and reorder entries accordingly.

* Fix copilot preferences tests for always-on conflict resolution

The enableCopilotConflictResolution feature flag was changed to always
return true, which means the conflict resolution model picker is now
always rendered alongside the commit message generation picker. This
caused several test failures due to ambiguous element queries.

Changes:
- Use getAllByRole/getAllByText where both pickers match the same query
- Scope model selection click to within the popover dropdown to avoid
  matching the second picker's button text
- Remove the withConflictResolutionEnabled test helper since the flag
  is no longer toggleable
- Replace 'is hidden when flag is disabled' test with 'renders both
  pickers' since conflict resolution is always on
- Simplify remaining conflict resolution tests by removing unnecessary
  env var wrappers

Co-authored-by: Copilot <[email protected]>

* Add thank you

* Bump all the things

* Update production electron version

* fix(license-overrides.ts): add missing linuxmusl copilot platform

* Hard code copilot picker popover heights for now

* Remove awaits when stopping Copilot client

Replace awaited calls to this.stopClient(client) with direct calls in several code paths. The stopClient call appears synchronous (or no longer returns a Promise), so remove unnecessary await to avoid awaiting non-Promise values and keep control flow consistent. Affects three locations in copilot-store.ts where the client is stopped in finally/cleanup logic.

* Make stopClient non-async and handle errors via .catch

Remove async/await from stopClient and call client.stop() without awaiting, attaching a .catch() to log errors. Keeps shutdown from blocking on stop and centralizes error logging.

* fix: default Copilot model to 'auto' for broader plan compatibility

The hardcoded default 'gpt-5-mini' model is no longer available for
Copilot Free and Student plan users, causing 400 errors during commit
message generation and conflict resolution. The 'auto' model uses
server-side routing and works across all plan tiers.

Closes #22380

Hide multiplier label for the Auto model in model picker

The Auto model routes requests to different underlying models with varying
credit multipliers, so displaying a single '(1x)' label is misleading.
Skip the billing label for the default model (now 'auto') and show it
simply as 'Auto (default)'.

Also updates DefaultCopilotModel from 'gpt-5-mini' to 'auto' and the
fallback display name to 'Auto' to match the upstream SDK change.

Co-Authored-By: Copilot <[email protected]>

* Update @github/copilot-sdk to ^1.0.3

Update the copilot-sdk dependency to 1.0.3 and simplify the build
script's copyCopilotDependency function. The @github/copilot package
now ships platform-specific optional dependencies (e.g.
@github/copilot-darwin-arm64) that already contain only the binaries
for the target platform, making the cross-platform pruning logic and
mxc-bin cleanup unnecessary.

Update build.ts

Co-Authored-By: Copilot <[email protected]>

* Fix default Copilot model and clean up type annotations

- Set Auto as the default Copilot model for conflict resolution
- Remove unnecessary parentheses around type annotations and nullish coalescing expressions for TypeScript compliance
- Add cross-compilation support to CI environment setup
- Fix trailing newline in test file

Update build.ts

Co-Authored-By: Copilot <[email protected]>

* Draft release 3.6.1-beta1

* Update api.ts

* Draft release 3.6.1-beta2

Add beta2 changelog entry for Max plan fix

Update `3.6.1-beta2` release notes to include a fix ensuring Copilot Max plan users are recognized correctly (#22400).

* Draft release 3.6.1

* Fix memoize-one comparator crashing hook proxy

The custom equality function was written for memoize-one's v5+ full
argument-array signature, but the repo uses [email protected] which
invokes the comparator once per argument as (newArg, lastArg). This
caused a TypeError on the second and every subsequent hook invocation,
spuriously failing hooks after the first one in a session.

Rewrite the comparator to use the correct per-argument signature.

Co-authored-by: Copilot <[email protected]>

* Disable session store for Copilot requests

Set `enableSessionStore: false` in CopilotStore requests used for commit message generation and conflict resolution. This keeps these one-off prompts stateless and avoids persisting session context where it isn’t needed.

* Look up PATH case-insensitively in hook proxy

shellEnv.env is a plain, case-sensitive object and PATH isn't guaranteed
to be uppercase on Windows (cmd/PowerShell may store it as Path), so
reading shellEnv.env.PATH directly could miss it and skip setting
GIT_EXEC_PATH entirely. Resolve PATH case-insensitively before gating on
it.

Co-authored-by: Copilot <[email protected]>

* Remove misleading debug log in hook proxy

The else branch logged "Failed to find system git" even though the
system git had already been resolved successfully; reaching it only
means git --exec-path returned nothing, which is already logged in
memoizedGetExecPathFromGit's catch handler. Drop the redundant,
misleading log.

Co-authored-by: Copilot <[email protected]>

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Fix commit message @-autocomplete matching users without a name

When a mentionable user hasn't configured a profile name their `name`
is `null`. The search haystack was built with `${user.login} ${user.name}`,
which stringifies `null` to the literal text "null". As a result, typing
`@null` (or even a lone `@n`, `@u`, or `@l`) in the commit message would
match every user that hadn't set a name, polluting and re-ordering the
autocompletion suggestions.

Coalesce the name to an empty string before building the haystack (the
existing `.trim()` removes the now-trailing space), and lift the matching
and ranking logic into an exported pure function, `matchMentionableUsers`,
so it can be unit tested without a backing database.

Co-authored-by: Copilot <[email protected]>

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Close watchers on error to avoid leaking

* Open existing worktree instead of prompting to add it

When invoking Desktop from the CLI (e.g. `github .`) inside a linked
worktree whose sibling worktree is already tracked, switch to that
worktree instead of showing the Add repository popup.

listWorktrees now accepts a path so it can be called before a
Repository exists, and matchExistingRepository is generalized to match
any path-bearing object (reusing its Windows-aware path normalization).

Co-authored-by: Copilot <[email protected]>

* Add test dialog to dispatch CLI actions

Add a development-only "Dispatch CLI action" Test menu item that opens a
tabbed dialog for dispatching each CLIAction (Open repository / Clone
URL), with text inputs matching the union members' properties.

Co-authored-by: Copilot <[email protected]>

* Ignore non-left gutter mousedown in diff row

Fix line-number gutter mousedown handling to only start selection on primary-button clicks. The previous `evt.buttons === 2` check only filtered right-click and still allowed middle-click to trigger selection. Added a unit test to confirm middle-button mousedown on a gutter line number is ignored.

* Expand SideBySideDiffRow interaction tests

Refactors the unit test to use shared row/render helpers and adds broad event coverage for line and hunk interactions. New cases verify primary vs non-primary mousedown behavior, selection/deselection dispatch, modified-row column inference, line-number checkbox and context menu callbacks, hunk checkbox/context menu callbacks, and hunk expansion click dispatch with the correct expansion type.

* Update pull_request_template.md

* Draft release 3.6.2-beta1

* Add Electron upgrade to v42 to release notes

* Update changelog.json

* Clarify line endings warning and add link to docs

* Handle Copilot optional license overrides

Build Copilot CLI license overrides from `@github/copilot` package metadata instead of hardcoded platform/version combos. This adds entries for optional platform packages and also accounts for installed package versions when they differ, keeping generated license data in sync with the bundled Copilot packages.

* Add in-memory session FS for Copilot sessions

Introduce a `SessionFsProvider` in `copilot-store` backed by in-memory files/directories, including read/write, stat, readdir, rm, and rename behavior. Wire it into Copilot chat session options and set `sessionFs` metadata (`initialCwd`, `sessionStatePath`, conventions) so session-state file workflows work without touching disk.

* Extract Copilot session FS provider

Move in-memory Copilot session FS logic into a shared helper and reuse its config in CopilotStore. This deduplicates the session filesystem setup and keeps commit-message and conflict-resolution flows on the same provider implementation.

* Use POSIX paths in in-memory session FS

Switches the in-memory Copilot SessionFs provider to always use POSIX path conventions, since the runtime only uses conventions when building virtual paths. Replaces manual slash normalization and parent path logic with `path.posix.normalize` and `path.posix.dirname` for simpler, consistent behavior across platforms.

* Fix in-memory FS trailing slash normalization

Normalize POSIX paths by trimming trailing slashes except root (`/`), so equivalent paths resolve same key. Add new unit test file covering config defaults, isolated provider state, read/write/append, path normalization, stat and directory typing, rm semantics, rename behavior, and ENOENT errors.

* Pass recursive=false to mkdir in copilot test

Add explicit recursive parameter to mkdir call in copilot in-memory session provider test. The parent directory 'state' is created beforehand, so non-recursive mkdir is appropriate here.

* Fix root path handling in in-memory session FS

Update `createCopilotInMemorySessionFsProvider` to treat `/` as root sentinel, same as `.`. This prevents recursive parent creation on absolute POSIX paths and fixes child/prefix logic for `readdir` and directory deletion checks at root. Added unit test covering `/state/events.jsonl` read/write and root directory listing to lock behavior.

* Derive type locally for SDK independence

Replace import of SessionFsReaddirWithTypesEntry from SDK internal module with a locally-derived type based on SessionFsProvider['readdirWithTypes']. This decouples the implementation from SDK internal details.

Also simplify path joining using posix.join and add test coverage for root-level directory listing with readdirWithTypes.

* Stabilize in-memory session directory metadata

* Honor recursive mkdir semantics in session FS

* Prevent session FS file-directory collisions

* Include bundle SHA-256 hashes in error reports

Compute SHA-256 hashes of main.js and renderer.js at runtime using the
existing getFileHash utility and include them in crash reports sent to
Central. This enables Central to validate that error reports come from
unmodified official bundles by comparing the reported hashes against
known-good values stored during the deployment publish step.

Hashes are computed lazily on the first error report and cached for the
lifetime of the process to avoid startup performance impact.

Co-authored-by: Copilot <[email protected]>

* [Fixed] Repository list scrolling gets stuck over tall groups

The grouped repository list renders each group as its own nested
react-virtualized grid inside the outer scroll container. When a group is
taller than the visible area react-virtualized gives that inner grid an
overflow-y of 'auto', making it independently scrollable. The mouse wheel
then scrolls the inner grid - whose scroll position is controlled by the
parent - so it nudges a few pixels and snaps back instead of scrolling the
list. Selecting a repository forces the inner grids to re-render and
re-applies the controlled position, which is why scrolling resumes briefly
after a click.

Force the per-section grids to overflow: hidden so they act as passive
windows driven solely by the parent's scrollTop, leaving the outer
container as the only scroll surface.

Closes #22387

* Restore ResizeObserver only when it originally existed in test

Track whether ResizeObserver was present on globalThis/window before the
test overrode it and delete the property on cleanup when it wasn't, rather
than leaving a lingering undefined value that could leak into other tests
that check for its presence.

* Fix formatting in get-file-hash test

Co-authored-by: Copilot <[email protected]>

* Simplify to a single combined bundleHash field

Instead of sending separate mainBundleHash and rendererBundleHash fields,
compute a single combined SHA-256 hash of both bundle hashes. This means
one field to send, one value to store on the server, and one string
comparison to validate. Scales naturally if we add more files later.

Co-authored-by: Copilot <[email protected]>

* Clarify line endings warning and add link to docs

* Guard session FS rename destinations

* Cover session FS rename invariants

* Extract shared computeBundleHash utility and hash all bundle files

- Create app/src/lib/compute-bundle-hash.ts with Merkle-style hash of all 7
  shipped bundle files (main, renderer, crash, highlighter, cli, index.html,
  crash.html)
- Update exception-reporting.ts to use the shared utility and cache failures
- Add getBundleHash() to script/dist-info.ts for build-time use
- Write bundle-hash.json in script/package.ts alongside bundle-size.json

The shared module ensures identical hash computation between runtime error
reports and CI deployment publishing.

Co-authored-by: Copilot <[email protected]>

* Address review feedback and fix lint

- Cache hash failures (attempted at most once per session)
- Note caching only benefits non-fatal errors
- Document which files are/aren't included in the hash and why
- Fix prettier formatting

Co-authored-by: Copilot <[email protected]>

* Upload bundle-hash.json as CI artifact

Co-authored-by: Copilot <[email protected]>

* Reject session FS subtree renames

* Normalize session FS cwd paths

* Expect normalized session FS cwd fallback

* Merge pull request #22416 from desktop/niik/open-worktree-from-cli

Open existing worktree when invoking from the CLI

* Merge pull request #22438 from peteski22/fix-repository-list-scroll-capture

[Fixed] Repository list scrolling gets stuck over tall groups

* Draft release 3.6.2

* Merge pull request #22444 from desktop/fix-license-overrides

Handle Copilot optional license overrides

* Fix async race: make getBundleHash synchronous in build scripts

The fire-and-forget .then() could allow the process to exit before
bundle-hash.json was written. Use synchronous readFileSync + createHash
to match the existing getBundleSizes pattern.

Co-authored-by: Copilot <[email protected]>

* Share bundleFiles list from compute-bundle-hash module

Export bundleFiles from app/src/lib/compute-bundle-hash.ts and import it
in script/dist-info.ts to eliminate duplication and drift risk.

Co-authored-by: Copilot <[email protected]>

* Consolidate hash logic into compute-bundle-hash module

Move the sync implementation into computeBundleHashSync in the shared
module. dist-info.ts now just calls it -- no duplicated algorithm.

Co-authored-by: Copilot <[email protected]>

* Remove getBundleHash wrapper from dist-info.ts

package.ts now imports computeBundleHashSync directly from the shared
module -- no unnecessary indirection through dist-info.

Co-authored-by: Copilot <[email protected]>

* Draft release 3.6.3-beta1

* Prevent PathText truncation update loop

Harden truncation length search in `PathText` to avoid repeated state updates that can hit React max update depth. Clamp min/max character bounds safely and, after the first non-fitting result, switch to midpoint narrowing instead of ratio-only stepping. Adds a regression test that mocks span width to keep content non-fitting and asserts rendering does not throw.

* Stop sending non-fatal trampoline parse errors

Remove `sendNonFatalException` from `TrampolineCommandParser.logCommandCreationError`. Command creation failures are still logged with `log.error`, but no longer reported as non-fatal exceptions to reduce noisy/duplicate error reporting.

* Ignore stdio EPIPE in console transport

Add a shared stdio error handler that swallows broken-pipe (`EPIPE`) errors on `process.stdout` and `process.stderr`, while rethrowing all other stream errors. Export the installer for unit testing, and add tests covering both ignored `EPIPE` and thrown non-`EPIPE` errors. Also fix a typo in the transport comment.

* Fix missing worktree fallback

Fall back to the main worktree when the selected linked worktree path has been removed but its git metadata is still available.

* Surface git errors during commit message generation

Previously, if getFilesDiffText threw (e.g., due to an index.lock file),
the error propagated uncaught and the UI would just blink without showing
anything to the user. Move the try/catch to wrap the entire callback body
inside withIsGeneratingCommitMessage so that any git error (not just
Copilot API errors) is surfaced via emitError.

Co-authored-by: Copilot <[email protected]>

* Fix disappearing files in Changes view after backgrounding

When the app returns from background with new file changes, the
SectionList's per-section Grid components may not re-render their
cells despite the rowCount changing. This happens because
react-virtualized's PureComponent optimization can skip updates
when the root Grid's re-render cascade doesn't properly propagate
to section grids (especially when render scheduling is throttled
while backgrounded).

Fix by explicitly calling recomputeGridSize() and forceUpdate() on
all section grids whenever rowCount changes, ensuring stale internal
caches are cleared and cells are re-rendered.

Fixes #20566

Co-authored-by: Copilot <[email protected]>

* Draft release 3.6.3-beta2

* Apply suggestion from @tidy-dev

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Fix prettier formatting of hits array type annotation

* Support Windows paths in Copilot session filesystem

Enable the in-memory session filesystem provider to use Windows filesystem conventions on Windows platforms instead of always using POSIX conventions. This allows the Copilot SDK to work correctly with Windows paths when running on Windows. The provider now detects the platform at runtime and normalizes paths accordingly, while still supporting POSIX conventions on non-Windows platforms.

* Pass conventions as parameter, don't check platform directly

* Bump @github/copilot-sdk to 1.0.5

Updates the app dependency from `@github/copilot-sdk` 1.0.3 to 1.0.5 to pick up the latest Copilot SDK fixes and behavior. This also pulls in newer `@github/copilot` runtime packages (1.0.69) for all supported platforms.

* Draft release 3.6.3-beta3

* Draft release 3.6.3

* Draft release 3.6.4

* Bump version and add changelog

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 36e766ea-4259-41cb-b605-4268bda66429

* Update 3.6.4 changelog

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 36e766ea-4259-41cb-b605-4268bda66429

* Migrate to @electron/packager

Replace deprecated electron-packager with @electron/packager and update notarization options and dependency lockfile.

* Preserve legacy macOS icons with Packager 18

Electron Packager 18 probes for an Icon Composer .icon project when the configured macOS icon has an extensionless basename. Because our logo directories contain both icon-logo.icon and icon-logo.icns, packaging on the macOS 14 CI runners attempts to compile the .icon project and fails: actool support for that format requires a macOS 26 build host and Xcode 26.

Rename the generated ICNS artifacts to icon-logo-legacy.icns and pass that explicit, unique basename to Packager. Its sibling .icon probe now finds no matching project, so older build hosts skip Icon Composer compilation and copy the ICNS fallback normally.

Keep the precompiled Assets.car resource and CFBundleIconName=icon-logo unchanged. Packaged applications therefore retain both formats: older supported macOS versions use electron.icns through CFBundleIconFile, while macOS 26 can use the checked-in Icon Composer asset catalog.

Update build-icon-assets.sh to clean and emit the new legacy filename whenever icon assets are regenerated. Add comments at both naming sites documenting why the distinct basename is required.

Validated with yarn compile:script, bash -n script/build-icon-assets.sh, yarn build:dev on macOS 14, packaged plist/resource inspection, yarn lint:fix, and the full 1,558-test unit suite (1 skipped).

* Pin cross-compiled Copilot packages to the lockfile

The CI setup action installs a platform-specific Copilot package when the runner architecture differs from the build target. That package was previously added without a version, so Yarn resolved the latest registry release instead of the version selected by app/yarn.lock.

On the macOS arm64 runner building x64, the application dependency graph was locked to Copilot 1.0.69 but the helper installed @github/copilot-darwin-x64 1.0.78. That newer package introduced MediaRemoteAdapter.framework into the packaged application. Apple rejected its nested binary during notarization with an invalid-signature error, making deploy output depend on whichever Copilot release happened to be latest at build time.

Read the exact target package version from the installed, lockfile-resolved @github/copilot package's optionalDependencies map. Install the cross-compilation package as PKG@VERSION, preserving the existing platform and architecture selection while ensuring all platform packages come from the same Copilot release.

Quote the complete package spec and include the selected version in CI logging so future failures show precisely which artifact entered the build.

Validated version resolution for Darwin, Linux, and Windows on x64 and arm64; ran Prettier, YAML diagnostics, actionlint, git diff --check, and the full 1,558-test unit suite with 1,557 passing and 1 skipped. Signing and notarization remain CI-only checks because they require release credentials.

* Restore platform-specific packaging icons

Use the uniquely named legacy ICNS only for Darwin builds. Keep the extensionless icon-logo basename on Windows and Linux so Electron Packager can resolve each platform's expected icon format.

Passing icon-logo-legacy.icns for every platform caused Windows normalization to look for icon-logo-legacy.ico, which does not exist, leaving packaged Windows builds with the default Electron icon.

Validated Packager resolution for production and development assets: macOS skips Icon Composer compilation and resolves icon-logo-legacy.icns, while Windows resolves icon-logo.ico. Also ran yarn compile:script, yarn lint:fix, and the full 1,558-test unit suite with 1 skipped.

* Fix Windows access-key collision in View menu

Upstream 3.6.4's 'Toggle &full screen' claims the same access key as
the fork's 'Show &Favorites Sidebar'. Move the favourites item to
F&avorites, caught by upstream's new duplicate-access-key menu test.

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: tidy-dev <[email protected]>
Co-authored-by: Markus Olsson <[email protected]>
Co-authored-by: Cocodrulo <[email protected]>
Co-authored-by: Sergio Padrino <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
Co-authored-by: Markus Olsson <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Pol Rivero <[email protected]>
Co-authored-by: Tom Oostveen <[email protected]>
Co-authored-by: Sukanth Gunda <[email protected]>
Co-authored-by: Alex Ruddick <[email protected]>
Co-authored-by: Whitebrim <[email protected]>
Co-authored-by: Peter Wilson <[email protected]>
Co-authored-by: Mateusz Kosikowski, PhD <[email protected]>
Copilot-Session: 36e766ea-4259-41cb-b605-4268bda66429
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

external Pull request originating outside of the Desktop core team unmet-requirements

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Version 3.6.0 (x64): Repository list - After updating to 3.6.0 the "scrolling" occasionally gets stuck

7 participants