Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App crashing on load #1

Open
mikibudhiraja opened this issue May 26, 2020 · 0 comments
Open

App crashing on load #1

mikibudhiraja opened this issue May 26, 2020 · 0 comments

Comments

@mikibudhiraja
Copy link

I have been trying to use the code, but getting an error of Modular.navigatorKey.
Screenshot_1590533285

The following is the output of debug console.

Launching lib/main.dart on Android SDK built for x86 in debug mode...
✓ Built build/app/outputs/flutter-apk/app-debug.apk.
D/EGL_emulation(21191): eglMakeCurrent: 0xdff53200: ver 3 0 (tinfo 0xdff3a490)
I/Choreographer(21191): Skipped 33 frames! The application may be doing too much work on its main thread.
D/EGL_emulation(21191): eglMakeCurrent: 0xd7e1baa0: ver 3 0 (tinfo 0xd7ef6290)
I/flutter (21191): -- AppModule INITIALIZED
I/flutter (21191): -- LoginModule INITIALIZED
I/flutter (21191): ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════
I/flutter (21191): The following assertion was thrown building IconTheme(color: Color(0xdd000000)):
I/flutter (21191): Add Modular.navigatorKey in your MaterialApp;
I/flutter (21191):
I/flutter (21191): return MaterialApp(
I/flutter (21191): navigatorKey: Modular.navigatorKey,
I/flutter (21191): ...
I/flutter (21191):
I/flutter (21191): .
I/flutter (21191): 'package:flutter_modular/src/modular_base.dart':
I/flutter (21191): Failed assertion: line 35 pos 9: '_navigatorKey != null'
I/flutter (21191):
I/flutter (21191): The relevant error-causing widget was:
�[38;5;248mI/flutter (21191): MaterialApp�[39;49m
I/flutter (21191):
I/flutter (21191): When the exception was thrown, this was the stack:
�[38;5;248mI/flutter (21191): #2 Modular.link�[39;49m
�[38;5;248mI/flutter (21191): #3 Modular.generateRoute�[39;49m
�[38;5;244mI/flutter (21191): #4 _WidgetsAppState._onGenerateRoute�[39;49m
�[38;5;244mI/flutter (21191): #5 NavigatorState._routeNamed�[39;49m
�[38;5;244mI/flutter (21191): #6 Navigator.defaultGenerateInitialRoutes�[39;49m
�[38;5;244mI/flutter (21191): #7 NavigatorState.initState�[39;49m
�[38;5;244mI/flutter (21191): #8 StatefulElement._firstBuild�[39;49m
�[38;5;244mI/flutter (21191): #9 ComponentElement.mount�[39;49m
I/flutter (21191): ... Normal element mounting (93 frames)
�[38;5;244mI/flutter (21191): #102 Element.inflateWidget�[39;49m
�[38;5;244mI/flutter (21191): #103 Element.updateChild�[39;49m
�[38;5;244mI/flutter (21191): #104 ComponentElement.performRebuild�[39;49m
�[38;5;244mI/flutter (21191): #105 StatefulElement.performRebuild�[39;49m
�[38;5;244mI/flutter (21191): #106 Element.rebuild�[39;49m
�[38;5;244mI/flutter (21191): #107 BuildOwner.buildScope�[39;49m
�[38;5;244mI/flutter (21191): #108 WidgetsBinding.drawFrame�[39;49m
�[38;5;244mI/flutter (21191): #109 RendererBinding._handlePersistentFrameCallback�[39;49m
�[38;5;244mI/flutter (21191): #110 SchedulerBinding._invokeFrameCallback�[39;49m
�[38;5;244mI/flutter (21191): #111 SchedulerBinding.handleDrawFrame�[39;49m
�[38;5;244mI/flutter (21191): #112 SchedulerBinding.scheduleWarmUpFrame.�[39;49m
I/flutter (21191): (elided 13 frames from class _AssertionError, class _RawReceivePortImpl, class _Timer, dart:async, and dart:async-patch)
I/flutter (21191):
I/flutter (21191): ════════════════════════════════════════════════════════════════════════════════════════════════════

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant