Repository navigation
Make SessionStart stop waiting on the network - #12
Merged
bguidolim merged 1 commit intoOct 30, 2026
Merged
Conversation
- Split SessionStart into a sync status check (local git only) and an async pull - Make hook entry points plain .mjs bootstraps that enable Node's compile cache - Fold the hooks' git probes into fewer spawns
bguidolim
force-pushed
the
bruno/faster-session-start
branch
from
October 29, 2026 14:04
50606b4 to
a2e2e7d
Compare
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.
Why
Every session waited ~1.75s at start, almost all of it the network pull, plus Node stripping TypeScript on each run. The pull now runs in the background, while a separate synchronous check still reports stuck state (rebase in progress, no upstream, lingering work) to Claude. The blocking part drops to roughly 60–100ms.
On Node 23+ the hooks also reuse Node's compile cache, which skips type stripping after the first run; Node 22 behaves as before. Teammates' memories now land a second or two after the session starts rather than before it.
Test plan
mcs syncin a project using the pack → expect three hooks registered: two SessionStart (one async), one Stop.claude/memorieswithin a few seconds.claude/.memories-repo, start a session → expect the/resolve-memoriesreminder