Repository navigation
fix(registry): guard the cluster page against the D1 parameter cap - #50
Merged
Merged
Conversation
The regression guard for SKILLD-X measured the shared membership SQL fragment. /api/clusters/<slug> wraps that fragment twice and binds each pinned skill four times, so the guard read 30 parameters where D1 counts 60 against its cap of 100. The route now asks cluster-membership for both statements, so the thing under the cap is the thing that gets sent.
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.
❓ Type of change
📚 Description
Sentry check-in of the
skilldproject, 2026-08-20. Eight of the nine open issues are already closed by deployed commits. This is the gap the ninth left behind.SKILLD-Xwas 173 events of:ba8ede4chunked those reads and the errors stopped. The guard that came with it measuresclusterMembersSql, which is a fragment rather than a statement./api/clusters/<slug>wraps that fragment twice and binds each pinned skill four times across the count and the list, so the guard reads 30 parameters forcontext-engineeringwhere D1 counts 60 against its cap of 100. Eleven more pins on that track breaches the cap while the old guard stays green.The route now asks
cluster-membershipfor both statements instead of assembling the ORDER BY itself, so the thing being measured is the thing being sent.Loose end I did not take: nothing enforces this at runtime, so a breach that lands without CI still surfaces as a D1 error in production. I could not think of a runtime check better than failing the build.