"A global key was used multiple times inside one widget's child list." Navigation Red Screen of Death

Troubleshooting

Hello, I am working on a simple flutterflow app and every time some sort of navigation action is activated, I am greeted with the following error:

══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════

The following assertion was thrown building InheritedGoRouter(goRouter: Instance of 'GoRouter'):

setState() called after dispose(): _HomePageWidgetState#b9eca(lifecycle state: defunct, not mounted) This error happens if you call setState() on a State object for a widget that no longer appears in the widget tree (e.g., whose parent widget no longer includes the widget in its build). This error can occur when code calls setState() from a timer or an animation callback. The preferred solution is to cancel the timer or stop listening to the animation in the dispose() callback. Another solution is to check the "mounted" property of this object before calling setState() to ensure the object is still in the tree. This error might indicate a memory leak if setState() is being called because another object is retaining a reference to this State object after it has been removed from the tree. To avoid memory leaks, consider breaking the reference to this object during dispose().

The relevant error-causing widget was:

InheritedGoRouter

InheritedGoRouter:file:///opt/.pub-cache/hosted/pub.dev/go_router-12.1.3/lib/src/router.dart:248:11

When the exception was thrown, this was the stack:

dart_sdk.js:37972 dart:sdk_internal 11994:11 throw_

dart_sdk.js:37972 packages/flutter/src/widgets/widget_state.dart.js 49540:23 <fn>
ETC.

What have you tried so far?

I have tried duplicating the project, reverting to previous versions, and only keeping one navigation button in the app. Nothing is working....

Did you check FlutterFlow's Documentation for this topic?
Yes
7
3 replies