Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughBumped dependencies in two packages; requestHandler now catches URIError when creating H3Event and retries with a sanitized request path; getCookies() filters out undefined values; several e2e modules switched to add default exports and adjusted imports/exports. Changes
Sequence Diagram(s)mermaid Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
View your CI Pipeline Execution ↗ for commit 0bbe672
☁️ Nx Cloud last updated this comment at |
🚀 Changeset Version Preview2 package(s) bumped directly, 21 bumped as dependents. 🟩 Patch bumps
|
Bundle Size Benchmarks
Trend sparkline is historical gzip bytes ending with this PR measurement; lower is better. |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@packages/start-server-core/src/request-response.ts`:
- Around line 307-315: The cookie map uses a plain object (definedCookies) which
inherits Object.prototype and can expose prototype keys; change its creation to
a null-prototype object (e.g., use Object.create(null) for definedCookies) so
only actual cookie keys are present, keep the same filtering logic in the
for-loop over Object.entries(cookies), and ensure the variable's type remains
compatible with Record<string, string> (narrow or cast as needed) to satisfy
TypeScript strict mode.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 53cb6800-ed2a-4033-81fd-e93e793856cd
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (1)
packages/start-server-core/src/request-response.ts
There was a problem hiding this comment.
Important

Nx Cloud is proposing a fix for your failed CI:
We filter out undefined cookie values in the getAll() method of both supabase example utilities to satisfy the @supabase/ssr CookieMethodsServer contract, which requires { name: string; value: string; }[]. This fixes the TypeScript build errors introduced when the PR narrowed getCookies() return type to Record<string, string | undefined> to align with cookie-es v3.
Tip
✅ We verified this fix by re-running tanstack-start-example-supabase-basic:build, tanstack-solid-start-example-supabase-basic:build, tanstack-router-e2e-react-scroll-restoration-sandbox-vite:test:e2e and 1 more.
Suggested Fix changes
diff --git a/examples/react/start-supabase-basic/src/utils/supabase.ts b/examples/react/start-supabase-basic/src/utils/supabase.ts
index b06ffb81cd..9d3e6f079b 100644
--- a/examples/react/start-supabase-basic/src/utils/supabase.ts
+++ b/examples/react/start-supabase-basic/src/utils/supabase.ts
@@ -8,10 +8,14 @@ export function getSupabaseServerClient() {
{
cookies: {
getAll() {
- return Object.entries(getCookies()).map(([name, value]) => ({
- name,
- value,
- }))
+ return Object.entries(getCookies())
+ .filter(
+ (entry): entry is [string, string] => entry[1] !== undefined,
+ )
+ .map(([name, value]) => ({
+ name,
+ value,
+ }))
},
setAll(cookies) {
cookies.forEach((cookie) => {
diff --git a/examples/solid/start-supabase-basic/src/utils/supabase.ts b/examples/solid/start-supabase-basic/src/utils/supabase.ts
index 1c95bd001b..1d413dd467 100644
--- a/examples/solid/start-supabase-basic/src/utils/supabase.ts
+++ b/examples/solid/start-supabase-basic/src/utils/supabase.ts
@@ -8,10 +8,14 @@ export function getSupabaseServerClient() {
{
cookies: {
getAll() {
- return Object.entries(getCookies()).map(([name, value]) => ({
- name,
- value,
- }))
+ return Object.entries(getCookies())
+ .filter(
+ (entry): entry is [string, string] => entry[1] !== undefined,
+ )
+ .map(([name, value]) => ({
+ name,
+ value,
+ }))
},
setAll(cookies) {
cookies.forEach((cookie) => {
Or Apply changes locally with:
npx nx-cloud apply-locally cj6G-H0Ba
Apply fix locally with your editor ↗ View interactive diff ↗
🎓 Learn more about Self-Healing CI on nx.dev
closing h3js/h3#1362
closing h3js/h3#1361
Bumps
h3-v2to2.0.1-rc.20andcookie-esto v3.This needs a small
@tanstack/start-server-coreupdate because both bumps change behavior that Start currently relies on:requestHandlernow translates theURIErrorthrown bynew H3Event(request)on malformed percent-encoded request paths (e.g./%80,/%FF,/%E0%A4) into a 400 Bad Request response. Previously these inputs caused an uncaught error that surfaced as a 500.getCookies()return type narrows toRecord<string, string | undefined>matching the corrected h3 v2 rc.20 type. Runtime behavior is unchanged.Summary by CodeRabbit
Chores
Bug Fixes
Tests