Skip to content

Allow skipping over non-required progress messages#4896

Merged
crtschin merged 1 commit intohaskell:masterfrom
crtschin:crtschin/optional-progress-expectations
Apr 15, 2026
Merged

Allow skipping over non-required progress messages#4896
crtschin merged 1 commit intohaskell:masterfrom
crtschin:crtschin/optional-progress-expectations

Conversation

@crtschin
Copy link
Copy Markdown
Collaborator

Related #4714.

I think there may be more of these progress-related assertions, I haven't gone through it with a finetooth comb. These were the ones that were most prominent to me.

What happens at each of these is that some messages don't occur at all in the message stream, the main ones being Indexing and Processing. I presume that we're just too fast, where ghcide finishes indexing by the time it gets a token to communicate progress.

Instead of failing the test when we don't see these messages that may not occur, modify the assertion so it better matches what we expect for progress flows.

  • If we see a begin, we must see an end.
  • If we see a begin, it must contain a token from a preceding create.
  • If we see a create, its token may be used by subsequent progressions.

Additoinally, I made the error a bit more informative so it shows which messages it hung on. After this I repeated the tests in this file, and couldn't reproduce the failures anymore.

@crtschin crtschin force-pushed the crtschin/optional-progress-expectations branch from b45ae8c to b1eb311 Compare April 14, 2026 20:11
@crtschin crtschin marked this pull request as ready for review April 14, 2026 20:54
@crtschin crtschin requested a review from fendor as a code owner April 14, 2026 20:54
Copy link
Copy Markdown
Collaborator

@fendor fendor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you very much, please merge when you are ready.

@crtschin crtschin merged commit fdfe3f4 into haskell:master Apr 15, 2026
41 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.

2 participants