You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Flutter调试器运行数秒后无响应,无法重载/重启及打开DevTools

Flutter应用启动后无法重载/重启、DevTools无法打开的问题

我在M2 MacBook的VS Code中运行并调试Flutter应用,现在遇到问题:启动应用数秒后无法重载或重启,DevTools也无法打开。Windows平台也存在相同问题,因此排除平台因素。

以下是verbose日志信息:

[+1987 ms] Skipping target: gen_localizations
[   +1 ms] Skipping target: gen_dart_plugin_registrant
[        ] Skipping target: _composite
[        ] complete
[   +2 ms] Performing hot restart...
[  +26 ms] Scanned through 1879 files in 22ms
[        ] Syncing files to device Gokul’s iPhone...
[   +2 ms] <- reset
[        ] Compiling dart to kernel with 0 updated files
[        ] Processing bundle.
[        ] <- recompile package:sample_app/main.dart 593be64a-7c40-4c54-84d1-f94eac8c8808
[        ] <- 593be64a-7c40-4c54-84d1-f94eac8c8808
[        ] Bundle processing done.
[  +67 ms] Updating files.
[+8701 ms] DevFS: Sync finished
[        ] Syncing files to device Gokul’s iPhone... (completed in 8.8s)
[        ] Synced 93.4MB.
[        ] <- accept
[+4097 ms] Ignoring terminal input: "r" because we are busy.

我使用的依赖包如下:

dependencies:
flutter:
sdk: flutter
cupertino_icons: ^1.0.6
hooks_riverpod: ^2.5.1
flutter_hooks: ^0.20.5
riverpod_annotation: ^2.3.5
fluro: ^2.0.5
logging: 1.1.0
logger: ^2.3.0
freezed: ^2.5.2
freezed_annotation: ^2.4.1
json_annotation: ^4.9.0
http: ^1.2.1
material_design_icons_flutter: ^7.0.7296
form_validator: ^2.1.1
fpdart: ^1.1.0
dotted_line: ^3.2.2
flutter_svg: ^2.0.10+1
slang: ^3.31.1
slang_flutter: ^3.31.0
intl: ^0.19.0
uuid: ^4.4.0
carousel_slider: ^5.0.0
flutter_card_swiper: ^7.0.1
lottie: ^3.1.2
jiffy: ^6.3.1
url_launcher: ^6.3.0
device_info_plus: ^10.1.2
connectivity_plus: ^6.0.5
shared_preferences: ^2.1.1
cunning_document_scanner: ^1.2.3

flutter_html: ^3.0.0-beta.2
firebase_core: ^3.4.1
firebase_messaging: ^15.1.1
flutter_secure_storage: ^9.2.2
isar: ^4.0.0-dev.14
isar_flutter_libs: ^4.0.0-dev.14
path_provider: ^2.1.4
permission_handler: ^11.3.1
envied: ^0.5.4+1

dev_dependencies:
flutter_test:
sdk: flutter
flutter_lints: ^3.0.0
riverpod_generator: ^2.4.0
build_runner: ^2.4.10
custom_lint: ^0.6.4
riverpod_lint: ^2.3.10
json_serializable: ^6.8.0
flutter_native_splash: ^2.4.1
flutter_launcher_icons: ^0.14.1
change_app_package_name: ^1.4.0
envied_generator: ^0.5.4+1

请问有人遇到过类似问题吗?

内容的提问来源于stack exchange,提问作者Gokul S Pillai

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.17 09:20:18