Skip to content

Wait for HLS to index before hovering an identifier from base - #101

Merged
thomasjm merged 1 commit into
mainfrom
hover-wait-for-indexing
Aug 27, 2026
Merged

Wait for HLS to index before hovering an identifier from base#101
thomasjm merged 1 commit into
mainfrom
hover-wait-for-indexing

Conversation

@thomasjm

Copy link
Copy Markdown
Contributor

hovers putStrLn fails intermittently with No hover returned. — on main today, not just on
branches. hovers foo in the same file never fails: foo is a local binding, putStrLn is from
base and has no hover until HLS has indexed dependencies. The test hovers immediately after
openDoc, so it races that.

Wrapped in waitUntil, which retries until the assertions hold.

I looked at waiting on work-done progress ($/progress, which lsp-test already tracks via
getIncompleteProgressSessions) instead. It isn't sound: an empty progress set doesn't distinguish
"finished" from "between tasks", so the check can land in the gap before the server starts more
work. Retrying the assertion is the thing that actually converges.

Compiles; the flake itself only reproduces under CI load.

@thomasjm
thomasjm merged commit b5768ca into main Aug 27, 2026
26 of 60 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant