You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
The restart of a file's highlighting doesn't wait for the end of indexing, as it means to: inSmartMode's result is dropped #2363
LSPFileSupport.restartDaemonCodeAnalyzerWithDebounce means the restart of a file's highlighting to wait for the end of indexing, when the project is in dumb mode, but it doesn't (LSPFileSupport.java:531-534 on main, 0612fe5):
if (executeInSmartMode) {
action.inSmartMode(project);
}
action.submit(AppExecutorUtil.getAppExecutorService());
Each method of NonBlockingReadAction returns a new action, and leaves the one it's called on as it is. So the result of inSmartMode is dropped, and the action submitted is the one without it: in dumb mode, the restart runs at once, as in smart mode. It's like that since 0ebc3a9, in 0.13.0. It's the only call of its kind in src/main/java.
Effect
Small. During indexing, the daemon runs only the passes that are dumb-aware, and when indexing ends, it restarts the highlighting of every file anyway. So the highlighting ends up the same; the restart during indexing is work for nothing.
Fix
action = action.inSmartMode(project);. #2357 (for #2356) rewrites the same lines, so the fix can go with it or after it.
Activity
fix: a restart of a file's highlighting that comes while the project …
fix: a restart of a file's highlighting that comes while the project …