Closed EricConnect closed 3 years ago
Hi @EricConnect
I have a similar issue - how did you fix this?
Best, Daniel
Hi Daniel,
I remember my problem is lost one line in main.dart.
void main() {
WidgetsFlutterBinding.ensureInitialized(); // I lost this line, so always failed when init.
...
Best, Eric
Hello. When I use your example. An issue was occur as the title.
Could you please update the example to provide a better way use redux_persist? I debugged some details. I believe this bug is not belongs to you. Actually, when I use the io file store. It has the same issue. If you can update the example and find a new way to initialized the redux state it will give me a big help. Thank you very much.
============================================== E/flutter ( 7218): [ERROR:flutter/lib/ui/ui_dart_state.cc(199)] Unhandled Exception: Null check operator used on a null value E/flutter ( 7218): #0 MethodChannel.binaryMessenger (package:flutter/src/services/platform_channel.dart:142:86) E/flutter ( 7218): #1 MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:148:36) E/flutter ( 7218): #2 MethodChannel.invokeMethod (package:flutter/src/services/platform_channel.dart:331:12) E/flutter ( 7218): #3 MethodChannelPathProvider.getTemporaryPath (package:path_provider_platform_interface/src/method_channel_path_provider.dart:34:26) E/flutter ( 7218): #4 getTemporaryDirectory (package:path_provider/path_provider.dart:78:40) E/flutter ( 7218): #5 doSearch (package:bug_test/main.dart:12:29). (dart:ui/hooks.dart:142:25)
E/flutter ( 7218): #8 _rootRun (dart:async/zone.dart:1354:13) (dart:ui/hooks.dart:138:5)
E/flutter ( 7218): #13 _delayEntrypointInvocation. (dart:isolate-patch/isolate_patch.dart:283:19)
E/flutter ( 7218): #14 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)
E/flutter ( 7218):
E/flutter ( 7218): #6 main (package:bug_test/main.dart:7:3)
E/flutter ( 7218): #7 _runMainZoned.
E/flutter ( 7218): #9 _CustomZone.run (dart:async/zone.dart:1258:19) E/flutter ( 7218): #10 _runZoned (dart:async/zone.dart:1789:10)
E/flutter ( 7218): #11 runZonedGuarded (dart:async/zone.dart:1777:12) E/flutter ( 7218): #12 _runMainZoned.
Syncing files to device sdk gphone x86 arm... 93ms
============================================== flutter doctor -v
[✓] Flutter (Channel stable, 2.2.2, on macOS 11.4 20F71 darwin-x64, locale en-CA) • Flutter version 2.2.2 at /Users/jbc/Development/flutter • Framework revision d79295af24 (3 weeks ago), 2021-06-11 08:56:01 -0700 • Engine revision 91c9fc8fe0 • Dart version 2.13.3
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3) • Android SDK at /Users/jbc/Library/Android/sdk • Platform android-30, build-tools 30.0.3 • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264) • All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS • Xcode at /Applications/Xcode.app/Contents/Developer • Xcode 12.5.1, Build version 12E507 • CocoaPods version 1.10.1
[✓] Chrome - develop for the web • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 4.2) • Android Studio at /Applications/Android Studio.app/Contents • Flutter plugin can be installed from: 🔨 https://plugins.jetbrains.com/plugin/9212-flutter • Dart plugin can be installed from: 🔨 https://plugins.jetbrains.com/plugin/6351-dart • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
[✓] Connected device (2 available) • sdk gphone x86 arm (mobile) • emulator-5554 • android-x86 • Android 11 (API 30) (emulator) • Chrome (web) • chrome • web-javascript • Google Chrome 91.0.4472.114
• No issues found!