Repository navigation
Refresh dependent notebook diagnostics after text changes - #1917
Open
Maxim Gagiev (maximilliangrand) wants to merge 1 commit into
Open
Maxim Gagiev (maximilliangrand) wants to merge 1 commit into
Maxim Gagiev (maximilliangrand) wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
🟢 Approval recommended
The narrowly scoped change reuses the existing guarded refresh path, and the regression directly covers the reported delay with no unresolved findings.
No open issues 🎉
What changed in this PR
Addresses #1837 by refreshing dependent notebook cells together after a text change, avoiding the background scheduler’s per-cell delay.
Changes:
- Extends the existing notebook-wide refresh path to text edits while preserving capability guards, cell filtering, and deduplication.
- Adds a regression test that blocks background timers and verifies exactly one pull per Python cell, excluding an unrelated JavaScript cell.
| File | Description |
|---|---|
client/src/common/diagnostic.ts |
Triggers notebook-wide dependent-cell refreshes on text changes. |
client-node-tests/src/integration.test.ts |
Tests prompt dependent-cell pulls, filtering, and deduplication. |
Review effort: Balanced
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.
Fixes #1837.
After a notebook cell edit, unchanged cells with inter-file dependencies wait in the background scheduler, which delays each pull by 500 ms. Reuse the existing notebook-wide refresh path for text changes so matching cells are pulled together after the change notification is sent. Keep the capability and on-change guards, language/visibility filtering, and per-event deduplication.
The integration regression edits one of three Python cells and checks that all three are pulled exactly once while an unrelated JavaScript cell is excluded. It holds background timers to prevent a delayed pull from hiding the regression.
Validation on macOS arm64 with Node 22.17.0 and VS Code Insiders:
npm run compilepassed.npm --prefix client-node-tests test: 225 passed.Browser and other package test suites were not run. Implemented and independently reviewed with Codex assistance.