Repository navigation
Rebuild a theme graph that failed to build - #1349
Merged
clauderic merged 1 commit intoOct 20, 2026
Merged
Conversation
ThemeGraphManager caches each graph as a promise. On a file change, processQueue awaited the cached promise before replacing it. When the build had failed, that await threw, so the graph was never rebuilt and every request got the same error until the language server restarted. It now still waits for a build in progress, but rebuilds whether that build succeeded or failed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 20, 2026
clauderic
added this pull request to stack #1353
October 20, 2026 13:15
charlespwd
approved these changes
Oct 20, 2026
EvilGenius13
approved these changes
Oct 20, 2026
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.
Stacked on #1348. Review that one first; this PR's base moves to
mainonce it merges.What are you adding in this PR?
When a theme graph fails to build, the language server keeps that failure until it restarts.
ThemeGraphManagercaches each graph as a promise.processQueueawaited the cached promise before replacing it. When the build had failed, that await threw, so the graph was never rebuilt.It now still waits for a build in progress, so builds don't overlap, but rebuilds whether that build succeeded or failed.
What's next? Any followup issues?
None.
Tophatting
npx vitest run packages/theme-language-server-common/src/server/ThemeGraphManager.spec.ts. The test makes the first build fail on areadDirectoryerror, then expects a file change to rebuild the graph. Without the fix, the second request rejects with the first build's error.Before you deploy
changeset🤖 Generated with Claude Code