Skip to content

fix(cache): avoid unpack limit on buffers with >8000 diagnostics - #187

Merged
rachartier merged 1 commit into
rachartier:mainfrom
miniex:fix/cache-unpack-limit
Oct 8, 2026
Merged

rachartier merged 1 commit into
rachartier:mainfrom
miniex:fix/cache-unpack-limit

Conversation

@miniex

@miniex miniex commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

cache.update copies the list with { unpack(diagnostics) } (since c05cc05). LuaJIT limits unpack to ~8000 values, so a buffer with more diagnostics errors with cache.lua:81: too many results to unpack on every DiagnosticChanged.

Build the copy in the existing bucketing loop instead. Added a regression test with 20000 diagnostics (fails before, passes after).

@rachartier

Copy link
Copy Markdown
Owner

Thanks!

@rachartier
rachartier merged commit f3cab9a into rachartier:main Oct 8, 2026
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