Repository navigation
lint: effecttsgo/schema-number to zero, at error - #618
Merged
Merged
Conversation
Schema.Number becomes Schema.Finite (or Schema.Int for counts and statuses) across src, examples, tests and docs. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Y5G6PMempKsgjiV1NDcCJY
Takes the tree of the branch rebased onto 928131a (#543). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Y5G6PMempKsgjiV1NDcCJY
🦋 Changeset detectedLatest commit: 24ee596 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Y5G6PMempKsgjiV1NDcCJY # Conflicts: # src/Resource.filter.test.ts
This was referenced Nov 12, 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.
Summary
Part of #536.
effecttsgo/schema-numbergoes from 101 sites to 0 and is set to"error"invite.config.ts, next to the other raised effecttsgo rules.Schema.NumberacceptsNaNand±Infinity, so each site now uses the most precise number schema that fits:Schema.Finitefor page leaves and general numbers:FlatQuery.tsandQuery.ts(including thefromString: falsepage leaves), the northwind example, the tests and type-level tests, and the doc examples and README snippets.Schema.Intfor counts, statuses and indices:statusofServerErrors.Redirect/HttpError/JsonapiErrorand ofClient.ErrorResponseServerErrors.ValidationFailureApiError.UnsupportedIncludeDepth.maxDepthConformance.ContractViolation.remainingQuery parsing over the wire is unchanged: it already decoded through
FiniteFromString. Error codes and messages are unchanged, and the conformance tests pass unchanged.One test changed for a different reason.
Resource.filter.test.tshas a "refuses to encode a non-finite number" test, and it needs a schema that admits NaN to reach the encoder's guard. It now builds one explicitly withSchema.make<typeof Schema.Finite>(SchemaAST.number), and a comment says why.No inline disables and no overrides. Lint went from 3682 to 3581 warnings before the toolchain bump; the only per-rule change was
schema-number(101 → 0).Verification
Run on the tree rebased onto 928131a (#543). The pushed head is a merge whose tree is identical to that one, because the force-push was refused.
pnpm install --frozen-lockfile: passvp run build: passvp check: pass (0 errors)vp run check: passvp run -r test:unit: passvp run docgen: passvp run test:coverage, thenvp exec fallow audit --base origin/trunk: pass (verdictpass)Changeset
.changeset/schema-number-finite.md: minor, Breaking. It lists every published schema whose accepted values narrowed and includes a migration note: pass finite values, and integers for theSchema.Intfields, and annotate asSchema.Finitewhere code namedSchema.Number.Notes
The emitted
.d.tsnow namesSchema.Finite/Schema.Intwhere it namedSchema.Number.Generated by Claude Code