feat(id): brand PermissionID, PtyID, QuestionID, and ToolID#17042
Merged
kitlangton merged 6 commits intodevfrom Mar 12, 2026
Merged
feat(id): brand PermissionID, PtyID, QuestionID, and ToolID#17042kitlangton merged 6 commits intodevfrom
kitlangton merged 6 commits intodevfrom
Conversation
6e18851 to
aba9bb0
Compare
05e0e5b to
42df6d3
Compare
aba9bb0 to
484a3c7
Compare
42df6d3 to
9b7a3f0
Compare
484a3c7 to
7476637
Compare
9b7a3f0 to
6d948bf
Compare
7476637 to
0cdc6f0
Compare
6d948bf to
753f330
Compare
… IDs The branded-remaining-ids PR changed these prefixes from their original values (per, que, tool) to shortened versions (prm, qst, tol). This would break validation of any existing IDs already persisted in the database, since the Zod .startsWith() validators would reject them.
The glob was changed from "tool_*" to "tol_*" alongside the prefix typo, causing cleanup to silently skip all truncated output files.
…refixes All branded ID schemas now derive their .startsWith() validation from Identifier.schema(key) instead of hardcoding prefix strings. This makes it impossible for schema validation to drift from the canonical prefix definitions in id.ts.
Schema.brand("SessionId") → Schema.brand("SessionID"), etc.
Brand tags now match their export names consistently.
19452df to
562689c
Compare
demostanis
pushed a commit
to demostanis/opencode
that referenced
this pull request
Mar 19, 2026
demostanis
pushed a commit
to demostanis/opencode
that referenced
this pull request
Mar 20, 2026
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.
Stacked on #16966 (PartID).
Summary
PermissionID,PtyID,QuestionID, andToolIDtypes with schema helpersIdentifier.schema()andIdentifier.ascending()usages with branded equivalentsTest plan
bun turbo typecheckpassesbun testpasses