Skip to content

Fixes a race condition in index refreshing that could spawn hundreds of external "git" processes#527

Merged
hannesa2 merged 1 commit intogitx:masterfrom
SMA-HP:fix/race-condition-refresh-index
Mar 3, 2026
Merged

Fixes a race condition in index refreshing that could spawn hundreds of external "git" processes#527
hannesa2 merged 1 commit intogitx:masterfrom
SMA-HP:fix/race-condition-refresh-index

Conversation

@SMA-HP
Copy link
Copy Markdown
Collaborator

@SMA-HP SMA-HP commented Mar 3, 2026

This PR fixes a bug where hundreds of external git commands were executed during a git diff when changes had been made in the git project repository.

The issue was caused by a couple of race conditions in PBGitIndex, specifically in the refresh method.
This PR should resolve the unintended behavior.

…s of external "git" processes and slows down host machine
@SMA-HP SMA-HP changed the title [FIX] fixes a race condition while refreshing index which may spawns hundreds of "git" processes [FIX] Fixes a race condition in index refreshing that could spawn hundreds of external "git" processes Mar 3, 2026
@hannesa2 hannesa2 added the bugfix label Mar 3, 2026
@hannesa2 hannesa2 changed the title [FIX] Fixes a race condition in index refreshing that could spawn hundreds of external "git" processes Fixes a race condition in index refreshing that could spawn hundreds of external "git" processes Mar 3, 2026
@hannesa2
Copy link
Copy Markdown
Contributor

hannesa2 commented Mar 3, 2026

close #485

@hannesa2
Copy link
Copy Markdown
Contributor

hannesa2 commented Mar 3, 2026

Thanks a lot. Keep finger crossed 🤞 that it solves the issue

@hannesa2
Copy link
Copy Markdown
Contributor

hannesa2 commented Mar 3, 2026

/Users/runner/work/gitx/gitx/External/objective-git/ObjectiveGitFramework.xcodeproj:1:1: error: Unable to open base configuration reference file '/Users/runner/work/gitx/gitx/External/objective-git/Carthage/Checkouts/xcconfigs/Mac OS X/Mac-StaticLibrary.xcconfig'. (in target 'libgit2' from project 'ObjectiveGitFramework')

I'll make same pull request on upstream, if this error raise there as well

@hannesa2 hannesa2 merged commit 6b020c4 into gitx:master Mar 3, 2026
5 of 6 checks passed
@hannesa2
Copy link
Copy Markdown
Contributor

hannesa2 commented Mar 3, 2026

I wait a few days for a possible solution here #470 (comment) before I create a new release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants