shared_preference 中的问题:^2.0.3(最新到现在 10-03-2021)

Issue in shared_preference: ^2.0.3 (latest till now 10-03-2021)

更新 flutter 后,我的一个项目出现问题。错误日志如下。主要问题是无法在设备上完美保存。一些首选项已保存,一些已保留。我从 fluttersharedprefs.xml

查到的
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at java.util.concurrent.ThreadPoolExecutor$AbortPolicy.rejectedExecution(ThreadPoolExecutor.java:2086)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at java.util.concurrent.ThreadPoolExecutor.reject(ThreadPoolExecutor.java:848)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at java.util.concurrent.ThreadPoolExecutor.execute(ThreadPoolExecutor.java:1394)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at io.flutter.plugins.sharedpreferences.MethodCallHandlerImpl.commitAsync(MethodCallHandlerImpl.java:137)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at io.flutter.plugins.sharedpreferences.MethodCallHandlerImpl.onMethodCall(MethodCallHandlerImpl.java:96)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler.onMessage(MethodChannel.java:233)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at io.flutter.embedding.engine.dart.DartMessenger.handleMessageFromDart(DartMessenger.java:85)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at io.flutter.embedding.engine.FlutterJNI.handlePlatformMessage(FlutterJNI.java:818)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at android.os.MessageQueue.nativePollOnce(Native Method)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at android.os.MessageQueue.next(MessageQueue.java:340)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at android.os.Looper.loop(Looper.java:183)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at android.app.ActivityThread.main(ActivityThread.java:7853)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at java.lang.reflect.Method.invoke(Native Method)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:526)
E/MethodChannel#plugins.flutter.io/shared_preferences( 9295):   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1034)
E/flutter ( 9295): [ERROR:flutter/lib/ui/ui_dart_state.cc(186)] Unhandled Exception: PlatformException(error, Task io.flutter.plugins.sharedpreferences.MethodCallHandlerImpl@d8dbf46 rejected from java.util.concurrent.ThreadPoolExecutor@6e10313[Running, pool size = 1, active threads = 1, queued tasks = 0, completed tasks = 14], null, java.util.concurrent.RejectedExecutionException: Task io.flutter.plugins.sharedpreferences.MethodCallHandlerImpl@d8dbf46 rejected from java.util.concurrent.ThreadPoolExecutor@6e10313[Running, pool size = 1, active threads = 1, queued tasks = 0, completed tasks = 14]

日志很多但是由于spaceWhosebug的问题我写不出来....

我建议您按照此处的说明在官方 Flutter 存储库中向 Flutter 团队提交错误报告:https://github.com/flutter/plugins#issues