aunetx / blur-my-shell

Extension that adds a blur look to different parts of the GNOME Shell, including the top panel, dash and overview
https://extensions.gnome.org/extension/3193/blur-my-shell/
GNU General Public License v3.0
1.58k stars 88 forks source link

Use `Background.BackgroundManager` instead of `Meta.BackgroundActor` #439

Closed aunetx closed 8 months ago

aunetx commented 1 year ago

From GdH on matrix:

Hi, is there any reason you're using directly Meta.BackgroundActor with insane updating instead of Background.BackgroundManager which can handle updates by its own in Blur My Shell?

mattia-b89 commented 1 year ago

Is this the reason why we get these error right after extension enabling?

Nov 04 08:09:47 arch-xps gnome-shell[49940]: The meta of type 'ColorEffect' with name '<unknown>' is already attached to actor 'MetaBackgroundActor'
Nov 04 08:09:47 arch-xps gnome-shell[49940]: The meta of type 'NoiseEffect' with name '<unknown>' is already attached to actor 'MetaBackgroundActor'
Nov 04 08:09:47 arch-xps gnome-shell[49940]: Object Meta.BackgroundActor (0x56180f545d20), has been already disposed — impossible to access it. This might be caused by the object having been destroyed from C code using something such as destroy(), dispose(), or remove() vfuncs.
                                             == Stack trace for context 0x561809f8f850 ==
                                             #0   7ffee8d1e0a0 b   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/components/screenshot.js:151 (29babe1cdb50 @ 36)
                                             #1   7ffee8d1e710 I   self-hosted:203 (1aae89395880 @ 245)
                                             #2   7ffee8d1ee00 b   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/components/screenshot.js:149 (29babe1cdb00 @ 38)
                                             #3   56180a056dd0 i   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/components/screenshot.js:47 (29babe1cd740 @ 17)
                                             #4   56180a056d38 i   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/components/screenshot.js:42 (29babe1cd650 @ 132)
                                             #5   56180a056ca8 i   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/extension.js:222 (29babe1ad880 @ 522)
                                             #6   56180a056be0 i   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/extension.js:88 (29babe1ad600 @ 1498)
                                             #7   56180a056b38 i   resource:///org/gnome/shell/ui/extensionSystem.js:252 (2bdda8e1bab0 @ 438)
                                             #8   7ffee8d1f8f0 b   resource:///org/gnome/shell/ui/extensionSystem.js:606 (2bdda8e232e0 @ 163)
                                             #9   56180a056ab8 i   resource:///org/gnome/shell/ui/extensionSystem.js:705 (2bdda8e23650 @ 12)
                                             #10   7ffee8d21aa0 b   resource:///org/gnome/gjs/modules/core/overrides/Gio.js:730 (1aae89391a60 @ 169)
                                             #11   56180a056a10 i   resource:///org/gnome/shell/ui/extensionSystem.js:276 (2bdda8e1bb00 @ 301)
                                             #12   56180a056988 i   resource:///org/gnome/shell/ui/shellDBus.js:447 (2707f5b5c470 @ 25)
                                             #13   56180a0568a8 i   resource:///org/gnome/gjs/modules/core/overrides/Gio.js:329 (1aae8938ace0 @ 185)
                                             #14   56180a0567f8 i   resource:///org/gnome/gjs/modules/core/overrides/Gio.js:408 (1aae8938ae20 @ 34)
                                             #15   56180a056768 i   resource:///org/gnome/shell/ui/init.js:21 (1aae89370ba0 @ 48)
Nov 04 08:09:47 arch-xps gnome-shell[49940]: clutter_actor_remove_child: assertion 'child->priv->parent != NULL' failed
Nov 04 08:09:47 arch-xps gnome-shell[49940]: Object Meta.BackgroundActor (0x56180f545d20), has been already disposed — impossible to access it. This might be caused by the object having been destroyed from C code using something such as destroy(), dispose(), or remove() vfuncs.
                                             == Stack trace for context 0x561809f8f850 ==
                                             #0   7ffee8d1e0a0 b   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/components/screenshot.js:152 (29babe1cdb50 @ 55)
                                             #1   7ffee8d1e710 I   self-hosted:203 (1aae89395880 @ 245)
                                             #2   7ffee8d1ee00 b   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/components/screenshot.js:149 (29babe1cdb00 @ 38)
                                             #3   56180a056dd0 i   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/components/screenshot.js:47 (29babe1cd740 @ 17)
                                             #4   56180a056d38 i   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/components/screenshot.js:42 (29babe1cd650 @ 132)
                                             #5   56180a056ca8 i   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/extension.js:222 (29babe1ad880 @ 522)
                                             #6   56180a056be0 i   file:///home/mattia/.local/share/gnome-shell/extensions/blur-my-shell@aunetx/extension.js:88 (29babe1ad600 @ 1498)
                                             #7   56180a056b38 i   resource:///org/gnome/shell/ui/extensionSystem.js:252 (2bdda8e1bab0 @ 438)
                                             #8   7ffee8d1f8f0 b   resource:///org/gnome/shell/ui/extensionSystem.js:606 (2bdda8e232e0 @ 163)
                                             #9   56180a056ab8 i   resource:///org/gnome/shell/ui/extensionSystem.js:705 (2bdda8e23650 @ 12)
                                             #10   7ffee8d21aa0 b   resource:///org/gnome/gjs/modules/core/overrides/Gio.js:730 (1aae89391a60 @ 169)
                                             #11   56180a056a10 i   resource:///org/gnome/shell/ui/extensionSystem.js:276 (2bdda8e1bb00 @ 301)
                                             #12   56180a056988 i   resource:///org/gnome/shell/ui/shellDBus.js:447 (2707f5b5c470 @ 25)
                                             #13   56180a0568a8 i   resource:///org/gnome/gjs/modules/core/overrides/Gio.js:329 (1aae8938ace0 @ 185)
                                             #14   56180a0567f8 i   resource:///org/gnome/gjs/modules/core/overrides/Gio.js:408 (1aae8938ae20 @ 34)
                                             #15   56180a056768 i   resource:///org/gnome/shell/ui/init.js:21 (1aae89370ba0 @ 48)
aunetx commented 1 year ago

@mattia-b89 no it isn't, the reason is unclear -- I think there is a race condition leading to this, but I can't simply remove these lines because that would cause other more serious bugs... I think I will need to simply check if an actor has already been disposed of, but I don't know how :)

At least this is only a log and does not cause any more damages, but I agree that it's uncool to spam the logs with it

aunetx commented 8 months ago

The issue described should not happen anymore with #546, closing this (for some reason I can't link it to be closed automatically)