Repository navigation
perf(boot): cached login PATH, async recapture; no sync git in projects:list / listBranches (#1475) - #1479
Merged
Conversation
… paint (#1475) The $SHELL -lic PATH capture ran via execFileSync at main.js top level, blocking window creation ~0.7 s on every launch. primeProcessPath now applies the last captured PATH from userData/login-path.json; the capture re-runs with async execFile once the window has painted (startMemory), and startRun/startWorkflowRun await it before the first provider spawn, so a first run or a changed rc file still gets the shell's PATH. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…1475) projects:list ran execFileSync git rev-parse per project for the icon cache key (138 ms at boot, again on every 60 s TTL lapse). Read .git / gitdir / commondir directly instead. Key the cache on the project root too, so two checkouts of one repo no longer share an icon entry. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…er (#1475) listBranchesAsync runs the default-branch probe and for-each-ref in parallel off the event loop. The first git:listBranches key in ipc-git.js was shadowed by the second and never ran; removed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ly (#1475) Without a cached PATH, the which-probe could report a CLI missing before the async capture lands. Cached boots do not wait. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
2 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #1475: main-process findings 3 and 4 in
docs/perf/2026-10-05-main-process.md.PATH capture no longer blocks boot
primeProcessPathapplies the last launch's login-shell PATH (cached inuserData/login-path.json) synchronously, with no shell.$SHELL -liccapture now runs async after first paint and refreshes the cache.runner.startRunandstartWorkflowRunawaitwhenPathReady()before any spawn.providers:listwaits for the capture before runningwhich.whenPathReadystarts the capture itself if nothing has yet, so callers can't hang. The capture keeps its shell timeout and resolves to null on failure.No sync git on the hot IPC paths
projects:list: the icon cache key reads the git common dir from disk (.git→gitdir:→commondir) instead of spawninggit rev-parseper project.git:listBranches: uses the async default-branch helper. The dead duplicate handler is dropped.Measured independently (real
$SHELLand HOME, read-only):$SHELL -lic, median of 3; PM1 measured 0.71 s on an idle machine)Tests
pathenv.test.js(cached apply, async refresh, first run, spawn waits),project-icon.test.js, and thebase-branchadditions.provider-usage.test.js, which passes 22/22 on its own.npm run typecheckclean;npm run test:smokeA–E.🤖 Generated with Claude Code