Skip to content
Source
Sign inSign up
TanStack/router

"Server function info not found" when calling a server function that's *only* called on the server #8731

Send to my agent
Openlynnntropy(GitHub profile, opens in a new tab) opened this issue 0 comments

Which project does this relate to?

Start

Describe the bug

If you call a server function inside another server function, and that function is only ever called on the server (and never on the client), the function call will throw a Server function info not found for [ID] error. This only happens in a production build, not in development.

Complete minimal reproducer

https://codeberg.org/lynnntropy/tanstack-start-nested-serverfn-repro

Steps to Reproduce the Bug

  1. Clone the reproduction repo
  2. pnpm i && pnpm build && pnpm start
  3. Visit http://localhost:3000
  4. See the error

Expected behavior

The function call shouldn't throw an error.

Screenshots or Videos

Image

Platform

  • Start Version: 1.169.2
  • OS: Linux
  • Browser: Chrome
  • Browser Version: 154.0.8037.92
  • Bundler: Vite
  • Bundler Version: 8.3.4

Additional context

This might be related to https://github.com/TanStack/router/issues/7943.

Sign in to join this conversation.