flutter_load_widget icon indicating copy to clipboard operation
flutter_load_widget copied to clipboard

Duplicate GlobalKey detected in widget tree. - please help

Open Hendaru opened this issue 5 years ago • 13 comments

`

[38;5;248m════════ Exception caught by widgets library ═══════════════════════════════════[39;49m [38;5;244mThe following assertion was thrown while finalizing the widget tree:[39;49m Duplicate GlobalKey detected in widget tree.

[38;5;244mThe following GlobalKey was specified multiple times in the widget tree. This will lead to parts of the widget tree being truncated unexpectedly, because the second time a key is seen, the previous instance is moved to the new location. The key was:

  • [LabeledGlobalKey<LoadingWidgetState>#0b60e] This was determined by noticing that after the widget with the above global key was moved out of its previous parent, that previous parent never updated during this frame, meaning that it either did not update at all or updated before the widget was moved, in either case implying that it still thinks that it should have a child with that global key. The specific parent that did not update after having one or more children forcibly removed due to GlobalKey reparenting is:
  • LoadingTheme A GlobalKey can only be specified on one widget at a time in the widget tree. [39;49m[38;5;244mWhen the exception was thrown, this was the stack[39;49m [38;5;244m#0 BuildOwner.finalizeTree.[39;49m [38;5;244m#1 BuildOwner.finalizeTree[39;49m [38;5;244m#2 WidgetsBinding.drawFrame[39;49m [38;5;244m#3 RendererBinding._handlePersistentFrameCallback[39;49m [38;5;244m#4 SchedulerBinding._invokeFrameCallback[39;49m [38;5;244m...[39;49m [38;5;248m════════════════════════════════════════════════════════════════════════════════[39;49m

`

Hendaru avatar Dec 17 '19 00:12 Hendaru

I have same error

marshall9213 avatar Feb 07 '20 17:02 marshall9213

@CaiJingLong Any news on this?

luis-cruzt avatar Mar 25 '20 22:03 luis-cruzt

I have the same error. Please, help us!

pabloroxo avatar Mar 26 '20 21:03 pabloroxo

I think this plugin is dead.

luis-cruzt avatar Apr 26 '20 20:04 luis-cruzt

Provide an example code to reproduce it?

CaiJingLong avatar May 07 '20 05:05 CaiJingLong

I have same error. Any updates on this?

image

vytautas-pranskunas- avatar Jul 28 '20 20:07 vytautas-pranskunas-

@CaiJingLong You can try open a page and call Loading, after that I click notification to open that page, it'll show Multiple widgets used the same GlobalKey.. I've tried hide loading but it's not working.

mrtungdev avatar Sep 09 '20 07:09 mrtungdev

same issue please fix

tegarkurniawan avatar Sep 23 '20 09:09 tegarkurniawan

same issue

p02diada avatar Oct 02 '20 06:10 p02diada

You must be sure that not show loading multiple times at the same time without hide loading first. I solved this problem by fixing all of these cases. I hope it helps you

linhle1412 avatar Oct 10 '20 03:10 linhle1412

Still the same issue in 2022. Can someone provide a fix for this.

gvsakhil avatar Mar 22 '22 05:03 gvsakhil

me too

sayglon-work avatar Aug 02 '22 15:08 sayglon-work

I am also facing the same issue

Abhishek01039 avatar Aug 22 '22 07:08 Abhishek01039