False positive for the "Server Actions must be async functions." diagnostic when using builder pattern with arrow function #77864
Labels
linear: turbopack
Confirmed issue that is tracked by the Turbopack team.
Server Actions
Related to Server Actions.
Turbopack
Related to Turbopack with Next.js.
Link to the code that reproduces this issue
https://github.com/ChristianIvicevic/debug/tree/turbopack-async-arrow-function
To Reproduce
pnpm install
pnpm dev
Current vs. Expected behavior
Current behavior
Extracting that inlined schema into a separate object does work and won't trigger the false positive.
Expected behavior
Being able to inline the
schema
here which is the cause of the false positive:Provide environment information
Operating System: Platform: darwin Arch: arm64 Version: Darwin Kernel Version 24.3.0: Thu Jan 2 20:24:23 PST 2025; root:xnu-11215.81.4~3/RELEASE_ARM64_T6031 Available memory (MB): 49152 Available CPU cores: 16 Binaries: Node: 22.14.0 npm: 10.9.2 Yarn: N/A pnpm: 10.7.1 Relevant Packages: next: 15.2.4 // Latest available version is detected (15.2.4). eslint-config-next: N/A react: 19.1.0 react-dom: 19.1.0 typescript: 5.8.3 Next.js Config: output: N/A
Which area(s) are affected? (Select all that apply)
Turbopack, Server Actions
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
No response
The text was updated successfully, but these errors were encountered: