Skip to content

Responsive UI updates handling of slow status updates in large mono repos #162417

@digitarald

Description

@digitarald

This is a pain point from various teams that work on large monorepos, funneled through their infrastructure team. They also offered to dogfood any solutions that we could come up with. Many of the devs use other code editors but depend on VS Code's git UI as their preferred git GUI.

The example flow that where the effect is the most frustrating is staging files. Clicking the + causes the UI to think for seconds while the user waits; and only later the file appears.

Main cause of this is of course slow Git CLI, especially on macOS.

I am proposing that VS Code could try to handle slow Git environments more gracefully. To start with experimental settings help users that are blocked by this. It should warn user are aware of the risk that updates in git outside are potentially not captured in the UI state.

Optimistic UI updates for quick operations

Experimental setting that tries to make optimistic UI updates for the most common UI actions.

As a first testing area Stage and Discard (aka git add and remove) are prime examples. They are frequent interactions that should feel snappy, and are most affected by slow git status updates. They run a quick command but then batch a statue update to get a refreshed UI state (as all SCM state right now depends on git status as single source of truth).

Low risk, as git status will still run. High impact on VS Code feeling snappier.

Improve progress

Improved progress on long-running actions. Avoid repeated clicks and confusion when actions don't give enough feedback on slow-running operations.

Related: #62751

Backlog

Scope status update to sub-folder

Experimental setting to scope git status to a folder. In local test that improved performance 10x, but milage will vary.

  • Setting: Alternatively the setting could ask for a workspace folder to limit git to.
  • Current workspace: Limited status checks to files inside the current workspace folder.
  • From task context: For staging files it could scope to just the file or the folder.

High risk and complexity.


Anything else, ideas, tweaks, experiments to try?

Metadata

Metadata

Labels

feature-requestRequest for new features or functionalitygitGIT issuesperfscmGeneral SCM compound issues

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions