t3-oss / create-t3-turbo

Clean and simple starter repo using the T3 Stack along with Expo React Native
https://turbo.t3.gg
MIT License
4.73k stars 408 forks source link

bug: nextjs crashes after file changes when running pnpm run dev #1240

Open tconroy opened 2 weeks ago

tconroy commented 2 weeks ago

Provide environment information

System: OS: macOS 15.0.1 CPU: (10) arm64 Apple M1 Max Memory: 4.28 GB / 64.00 GB Shell: 5.9 - /opt/homebrew/bin/zsh Binaries: Node: 20.16.0 - ~/.local/state/fnm_multishells/56907_1730686687697/bin/node Yarn: 1.22.22 - /opt/homebrew/bin/yarn npm: 10.8.1 - ~/.local/state/fnm_multishells/56907_1730686687697/bin/npm pnpm: 9.12.3 - ~/.local/state/fnm_multishells/56907_1730686687697/bin/pnpm bun: 1.1.34 - /opt/homebrew/bin/bun Watchman: 2024.10.28.00 - /opt/homebrew/bin/watchman

Describe the bug

live reload for nextjs is not working, and appears to be silently crashing the nextjs server on code changes.

Link to reproduction

NA

To reproduce

after running pnpm run dev from the repo root, nextjs boots and I can view the app. However, as soon as I make an edit to a file (such as changing some text or adding a new route), the page does not update. If I refresh the page manually, I get ERR_CONNECTION_REFUSED in the browser.

Additional information

There is no error output in the terminal.

Interestingly, if I cd into apps/next and pnpm run dev the app directly, it works correctly.

This specifically seems to be a turbo-related issue.

OopsOverflow commented 2 weeks ago

I had the same bug. I rolledback this change #1227 locally and it stopped happening on my machine, others on windows still experience the same issue. Which Next.js version are you using btw?

juliusmarminge commented 2 weeks ago

Do you have this set in the nextjs turbo config? https://github.com/t3-oss/create-t3-turbo/blob/main/apps/nextjs/turbo.json#L10

OopsOverflow commented 2 weeks ago

Do you have this set in the nextjs turbo config? https://github.com/t3-oss/create-t3-turbo/blob/main/apps/nextjs/turbo.json#L10

Yes I can confirm that the problem persists even with this (project default) config.

OopsOverflow commented 1 week ago

Looks like the same behaviour as this. Upgrading to 2.2.4-canary.9 fixes the issue for the moment. Waiting for the stable release 🤞🏻