You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Steps to Reproduce
The App hangs during app splash page but when I close the app and clear the data from the app info screen. The app will then open with no issues and work for several cycles (over multiple days) before hanging once again.
Please let me know if you need anything further and thanks for any help you can give. Cheers.
---- Getting the following error upon Hive.init() command
E/flutter (29354): [ERROR:flutter/lib/ui/ui_dart_state.cc(209)] Unhandled Exception: HiveError: This should not happen. Please open an issue on GitHub.
E/flutter (29354): #0 BinaryReaderImpl.readFrame (package:hive/src/binary/binary_reader_impl.dart:250)
E/flutter (29354): #1 FrameHelper.framesFromBytes (package:hive/src/binary/frame_helper.dart:21)
E/flutter (29354): #2 FrameIoHelper.framesFromFile (package:hive/src/io/frame_io_helper.dart:42)
E/flutter (29354):
E/flutter (29354): #3 StorageBackendVm.initialize (package:hive/src/backend/vm/storage_backend_vm.dart:86)
E/flutter (29354):
E/flutter (29354): #4 HiveImpl._openBox (package:hive/src/hive_impl.dart:116)
E/flutter (29354):
E/flutter (29354): #5 HiveImpl.openBox (package:hive/src/hive_impl.dart:145)
E/flutter (29354):
E/flutter (29354): #6 main (package:us_congress_vote_tracker/main.dart:54)
E/flutter (29354):
E/flutter (29354):
E/flutter (29354): [ERROR:flutter/lib/ui/ui_dart_state.cc(209)] Unhandled Exception: HiveError: This should not happen. Please open an issue on GitHub.
E/flutter (29354): #0 BinaryReaderImpl.readFrame (package:hive/src/binary/binary_reader_impl.dart:250)
E/flutter (29354): #1 FrameHelper.framesFromBytes (package:hive/src/binary/frame_helper.dart:21)
E/flutter (29354): #2 FrameIoHelper.framesFromFile (package:hive/src/io/frame_io_helper.dart:42)
E/flutter (29354):
E/flutter (29354): #3 StorageBackendVm.initialize (package:hive/src/backend/vm/storage_backend_vm.dart:86)
E/flutter (29354):
E/flutter (29354): #4 HiveImpl._openBox (package:hive/src/hive_impl.dart:116)
E/flutter (29354):
E/flutter (29354): #5 HiveImpl.openBox (package:hive/src/hive_impl.dart:145)
E/flutter (29354):
E/flutter (29354): #6 main (package:us_congress_vote_tracker/main.dart:54)
E/flutter (29354):
E/flutter (29354):
Code sample
Code is called in main() as shown below:
void main() async {
WidgetsFlutterBinding.ensureInitialized();
Directory directory = await getApplicationDocumentsDirectory();
Hive.init(directory.path); // <= ** Error seems to occur here **
await Hive.openBox(appDatabase);
await Functions.initializeBox(appDatabase);
if (!kIsWeb) await MobileAds.instance.initialize();
runApp(MyApp());
// Register to receive BackgroundFetch events after app is terminated.
// Requires {stopOnTerminate: false, enableHeadless: true}
if (!kIsWeb)
BackgroundFetch.registerHeadlessTask(backgroundFetchHeadlessTask);
}
Version
Platform: Android ** Web version seems to work fine so far **
After reading some of the other similar issues, I changed the command to 'await Hive.initFlutter()' but had no luck. Still having the issue. It seems to be having trouble creating the initial database but after the install and 'clear app data' it seems to work.
Steps to Reproduce
The App hangs during app splash page but when I close the app and clear the data from the app info screen. The app will then open with no issues and work for several cycles (over multiple days) before hanging once again.
Please let me know if you need anything further and thanks for any help you can give. Cheers.
---- Getting the following error upon Hive.init() command
E/flutter (29354): [ERROR:flutter/lib/ui/ui_dart_state.cc(209)] Unhandled Exception: HiveError: This should not happen. Please open an issue on GitHub.
E/flutter (29354): #0 BinaryReaderImpl.readFrame (package:hive/src/binary/binary_reader_impl.dart:250)
E/flutter (29354): #1 FrameHelper.framesFromBytes (package:hive/src/binary/frame_helper.dart:21)
E/flutter (29354): #2 FrameIoHelper.framesFromFile (package:hive/src/io/frame_io_helper.dart:42)
E/flutter (29354):
E/flutter (29354): #3 StorageBackendVm.initialize (package:hive/src/backend/vm/storage_backend_vm.dart:86)
E/flutter (29354):
E/flutter (29354): #4 HiveImpl._openBox (package:hive/src/hive_impl.dart:116)
E/flutter (29354):
E/flutter (29354): #5 HiveImpl.openBox (package:hive/src/hive_impl.dart:145)
E/flutter (29354):
E/flutter (29354): #6 main (package:us_congress_vote_tracker/main.dart:54)
E/flutter (29354):
E/flutter (29354):
E/flutter (29354): [ERROR:flutter/lib/ui/ui_dart_state.cc(209)] Unhandled Exception: HiveError: This should not happen. Please open an issue on GitHub.
E/flutter (29354): #0 BinaryReaderImpl.readFrame (package:hive/src/binary/binary_reader_impl.dart:250)
E/flutter (29354): #1 FrameHelper.framesFromBytes (package:hive/src/binary/frame_helper.dart:21)
E/flutter (29354): #2 FrameIoHelper.framesFromFile (package:hive/src/io/frame_io_helper.dart:42)
E/flutter (29354):
E/flutter (29354): #3 StorageBackendVm.initialize (package:hive/src/backend/vm/storage_backend_vm.dart:86)
E/flutter (29354):
E/flutter (29354): #4 HiveImpl._openBox (package:hive/src/hive_impl.dart:116)
E/flutter (29354):
E/flutter (29354): #5 HiveImpl.openBox (package:hive/src/hive_impl.dart:145)
E/flutter (29354):
E/flutter (29354): #6 main (package:us_congress_vote_tracker/main.dart:54)
E/flutter (29354):
E/flutter (29354):
Code sample
Code is called in main() as shown below:
void main() async {
WidgetsFlutterBinding.ensureInitialized();
Directory directory = await getApplicationDocumentsDirectory();
Hive.init(directory.path); // <= ** Error seems to occur here **
await Hive.openBox(appDatabase);
await Functions.initializeBox(appDatabase);
if (!kIsWeb) await MobileAds.instance.initialize();
runApp(MyApp());
// Register to receive BackgroundFetch events after app is terminated.
// Requires {stopOnTerminate: false, enableHeadless: true}
if (!kIsWeb)
BackgroundFetch.registerHeadlessTask(backgroundFetchHeadlessTask);
}
Version
Framework • revision 3595343e20 (13 days ago) • 2021-09-30 12:58:18 -0700
Engine • revision 6ac856380f
Tools • Dart 2.14.3
The text was updated successfully, but these errors were encountered: