You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Review: fix(frontend): submit Vercel drain grace period
Small, focused fix — the Vercel connect flow now submits drainGracePeriod/requestLifespan from validated schema constants instead of a hardcoded 0, and centralizes the Vercel-specific values (VERCEL_REQUEST_LIFESPAN, VERCEL_DRAIN_GRACE_PERIOD) in connect-vercel-form.tsx. Good use of a single source of truth shared between the "quick" and full Vercel connect frames.
Bug: the new drainGracePeriod < requestLifespan bound only applies to Vercel
connect-vercel-form.tsx builds a Vercel-specific configurationSchema that caps drainGracePeriod at VERCEL_REQUEST_LIFESPAN - 1:
drainGracePeriod: z.coerce.number().min(0).max(VERCEL_REQUEST_LIFESPAN-1,`Must be less than ${VERCEL_REQUEST_LIFESPAN}`)...
but the base configurationSchema in connect-manual-serverless-form.tsx (used directly by the generic/custom serverless flow in connect-manual-serverless-frame.tsx) still only has:
with no upper bound relative to requestLifespan. Since both flows share the same DrainGracePeriod input component (no max attribute either), a user configuring a generic/custom serverless runner can still submit requestLifespan=10 with drainGracePeriod=1000 — the exact invariant this PR just added protection for on Vercel is left unenforced everywhere else. If this invariant matters generally (as the PR title/description implies), consider moving the drainGracePeriod <= requestLifespan check (e.g. via .refine() comparing both fields) into the base configurationSchema so all providers inherit it, rather than duplicating a Vercel-only ceiling.
Minor
connect-manual-serverless-frame.tsx now passes drainGracePeriod: values.drainGracePeriod straight through to buildServerlessConfig without a fallback (unlike the ?? 1 / ?? 0 defaults on the neighboring fields). Since the base schema already .default(0)s the field via the RHF/zod resolver, this is likely fine, but worth double-checking that values.drainGracePeriod is never undefined at submit time for the generic flow — a stray undefined would previously have been silently coerced but now flows straight into the request payload.
Other
No test coverage added, but this is a UI form-wiring fix with no complex logic, so that's reasonable to skip given the scope of the change.
No security or performance concerns.
Overall a solid fix for the Vercel flow; the main follow-up worth considering is whether the new upper-bound validation should be generalized rather than Vercel-only.
abcxff
changed the base branch from
main
to
stack/fix-rivetkit-napi-remove-stale-httprequestbodystream-test-after-envoy-v6-revert-rlmrkmtkAugust 25, 2026 19:27
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
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.
No description provided.