问题
Flutter log prints thousands of verbose/spam logs.
I am trying to debug a complex app but flutter printing so much verbose that it is difficult for me to find things which i am printing myself.
Is there any way to disable Verbose?
Something like:
Logger.level.disable('verbose')
My platform:
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, v1.12.13+hotfix.8, on Microsoft Windows [Version 10.0.18362.657], locale en-US)
[√] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[√] VS Code, 64-bit edition (version 1.42.1)
[√] Connected USB device (1 available)
回答1:
This was a bug in flutter engine which is now fixed in beta channel and soon will be released in next stable release.
You should just ignore these errors if possible otherwise change your flutter channel by:
flutter channel beta
Edit:
If you are using Android Studio then you can filter log. Deselecting any other option other than "Info" will remove unwanted log.
来源:https://stackoverflow.com/questions/60360240/setting-flutter-log-levels-flutter-printing-thousands-of-verbose-lines