-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Description
Steps to reproduce
Edit: this is reproducable on the stable channel as well
3.38.1, so quite a large regression in the Stable Flutter release
Be on Flutter beta channel (I believe this happens on Stable channel as well, we saw crashes at hungrimind.com/learn/flutter when we upgraded to 3.38 but during my testing I was on beta just to see if there was something that might already have been fixed and coming in a CP or similar).
This might be relevant to #174791 because it seems similar just more "random". I.e somtimes the page doesn't "connect" with the web-server and when doing hot restart after that it seems to crash.
- run
flutter run -d web-server --web-port=8080 - open localhost:8080
- close the tab
- do hot restart (so you see the error/warning of no clients connected
- open localhost:8080 again
- repeat step 3,4,5 until you see the below result.
Result: See white screen and if you do hot restart in this white screen you will get a crash on the web-server because of timeout.
In general the url should always connect and display the page (not just stay on white, but this is at least the visual trigger where I know that if I do a restart now it will crash) so feels like there are 2 issues at play, the white screen of not connecting and the timeout when doing hot restart when that is present.
~/projects/hungrimind/test/testing_preview flutter run -d web-server --web-port=8080
Launching lib/main.dart on Web Server in debug mode...
Waiting for connection from debug service on Web Server... 6.4s
lib/main.dart is being served at http://localhost:8080
The web-server device requires the Dart Debug Chrome extension for debugging. Consider using the Chrome or Edge devices for an improved development workflow.
Flutter run key commands.
r Hot reload. 🔥🔥🔥
R Hot restart.
h List all available interactive commands.
d Detach (terminate "flutter run" but leave application running).
c Clear the screen
q Quit (terminate the application on the device).
Debug service listening on ws://127.0.0.1:44456/hH9Xw2A1nX0=
A Dart VM Service on Web Server is available at: http://127.0.0.1:44456/hH9Xw2A1nX0=
WebSocketProxyService: No clients available.
Performing hot restart... 33ms
Recompile complete. No client connected.
33ms
WebSocketProxyService: No clients available.
Performing hot restart... 21ms
Recompile complete. No client connected.
21ms
WebSocketProxyService: No clients available.
Performing hot restart... 26ms
Recompile complete. No client connected.
26ms
WebSocketProxyService: No clients available.
Performing hot restart... 24ms
Recompile complete. No client connected.
24ms
WebSocketProxyService: No clients available.
Performing hot restart... 27ms
Recompile complete. No client connected.
27ms
WebSocketProxyService: No clients available.
Performing hot restart... 25ms
Recompile complete. No client connected.
25ms
WebSocketProxyService: Hot restart failed: TimeoutException after 0:00:15.000000: Hot restart timed out - received 0/1 responses
Performing hot restart... 15.0s
hotRestart: (-32603) Hot restart failed: TimeoutException after 0:00:15.000000: Hot restart timed out - received 0/1 responses
Expected results
No crash and the browser should connect, not stay as a white screen.
Actual results
Opening the url results in a white screen and a crash if you try to trigger a hot restart
Code sample
not applicable, just any newly created Flutter app.
Screenshots or Video
not applicable, it will just be white and the web-server command will crash.
Logs
Logs
Flutter Doctor output
Doctor output
[✓] Flutter (Channel beta, 3.39.0-0.1.pre, on macOS 15.5 24F74 darwin-arm64, locale en-US) [161ms]
• Flutter version 3.39.0-0.1.pre on channel beta at /Users/robertbrunhage/tools/flutter
• Upstream repository [email protected]:flutter/flutter.git
• Framework revision cbb46938ee (4 days ago), 2025-11-10 17:13:11 -0600
• Engine revision b9afb03275
• Dart version 3.11.0 (build 3.11.0-93.1.beta)
• DevTools version 2.52.0
• Feature flags: enable-web, enable-linux-desktop, enable-macos-desktop, enable-windows-desktop, enable-android, enable-ios, cli-animations, enable-native-assets, omit-legacy-version-file,
enable-lldb-debugging
[✓] Android toolchain - develop for Android devices (Android SDK version 36.1.0) [797ms]
• Android SDK at /Users/robertbrunhage/Library/Android/Sdk
• Emulator version 36.2.12.0 (build_id 14214601) (CL:N/A)
• Platform android-36, build-tools 36.1.0
• ANDROID_HOME = /Users/robertbrunhage/Library/Android/Sdk
• ANDROID_SDK_ROOT = /Users/robertbrunhage/Library/Android/Sdk
• Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
This is the JDK bundled with the latest Android Studio installation on this machine.
To manually set the JDK path, use: `flutter config --jdk-dir="path/to/jdk"`.
• Java version OpenJDK Runtime Environment (build 21.0.8+-14018985-b1038.68)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 16.4) [428ms]
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 16F6
• CocoaPods version 1.16.2
[✓] Chrome - develop for the web [4ms]
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Connected device (2 available) [5.7s]
• macOS (desktop) • macos • darwin-arm64 • macOS 15.5 24F74 darwin-arm64
• Chrome (web) • chrome • web-javascript • Google Chrome 142.0.7444.162
[✓] Network resources [496ms]
• All expected network resources are available.
• No issues found!