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

[BUG] Error in syslog: TypeError: menuInstance is null #243

Open
gsmetal opened this issue May 12, 2022 · 3 comments
Open

[BUG] Error in syslog: TypeError: menuInstance is null #243

gsmetal opened this issue May 12, 2022 · 3 comments
Assignees
Labels

Comments

@gsmetal
Copy link

gsmetal commented May 12, 2022

Describe the bug
As I see everything works, but found this error in syslog:

JS ERROR: TypeError: menuInstance is null#012_updateMenuVisibility@/home/gsmetal/.local/share/gnome-shell/extensions/[email protected]/extension.js:210:51#012enable/<@/home/gsmetal/.local/share/gnome-shell/extensions/[email protected]/extension.js:180:45#012_updateVisibility@resource:///org/gnome/shell/ui/status/volume.js:109:9#012_maybeShowInput@resource:///org/gnome/shell/ui/status/volume.js:304:14#012destroy@/home/gsmetal/.local/share/gnome-shell/extensions/[email protected]/extension.js:125:21#012disable@/home/gsmetal/.local/share/gnome-shell/extensions/[email protected]/extension.js:278:38#012_callExtensionDisable@resource:///org/gnome/shell/ui/extensionSystem.js:123:32#012_onEnabledExtensionsChanged/<@resource:///org/gnome/shell/ui/extensionSystem.js:519:45#012_onEnabledExtensionsChanged@resource:///org/gnome/shell/ui/extensionSystem.js:519:24#012_sessionUpdated@resource:///org/gnome/shell/ui/extensionSystem.js:645:14#012_emit@resource:///org/gnome/gjs/modules/core/_signals.js:114:47#012_sync@resource:///org/gnome/shell/ui/sessionMode.js:203:14#012pushMode@resource:///org/gnome/shell/ui/sessionMode.js:164:14#012activate@resource:///org/gnome/shell/ui/screenShield.js:652:34#012lock@resource:///org/gnome/shell/ui/screenShield.js:698:14#012_prepareForSleep@resource:///org/gnome/shell/ui/screenShield.js:284:22#012_emit@resource:///org/gnome/gjs/modules/core/_signals.js:114:47#012_prepareForSleep@resource:///org/gnome/shell/misc/loginManager.js:202:14#012_emit@resource:///org/gnome/gjs/modules/core/_signals.js:114:47#012_convertToNativeSignal@resource:///org/gnome/gjs/modules/core/overrides/Gio.js:152:19

Extension Information

  • Shell Version: 42
  • Extension Version (Leave blank, if not sure)
  • Install method: extension.gnome.org
  • OS: ubuntu 22.04, gnome session with x.server
@gsmetal gsmetal added the bug label May 12, 2022
@gsmetal gsmetal changed the title [BUG] Error in dmesg: TypeError: menuInstance is null [BUG] Error in syslog: TypeError: menuInstance is null May 12, 2022
@normanr
Copy link

normanr commented Sep 23, 2022

Unwrapping the original error to make it more readable:

JS ERROR: TypeError: menuInstance is null
_updateMenuVisibility@/home/gsmetal/.local/share/gnome-shell/extensions/[email protected]/extension.js:210:51
enable/<@/home/gsmetal/.local/share/gnome-shell/extensions/[email protected]/extension.js:180:45
_updateVisibility@resource:///org/gnome/shell/ui/status/volume.js:109:9
_maybeShowInput@resource:///org/gnome/shell/ui/status/volume.js:304:14
destroy@/home/gsmetal/.local/share/gnome-shell/extensions/[email protected]/extension.js:125:21
disable@/home/gsmetal/.local/share/gnome-shell/extensions/[email protected]/extension.js:278:38
_callExtensionDisable@resource:///org/gnome/shell/ui/extensionSystem.js:123:32
_onEnabledExtensionsChanged/<@resource:///org/gnome/shell/ui/extensionSystem.js:519:45
_onEnabledExtensionsChanged@resource:///org/gnome/shell/ui/extensionSystem.js:519:24
_sessionUpdated@resource:///org/gnome/shell/ui/extensionSystem.js:645:14
_emit@resource:///org/gnome/gjs/modules/core/_signals.js:114:47
_sync@resource:///org/gnome/shell/ui/sessionMode.js:203:14
pushMode@resource:///org/gnome/shell/ui/sessionMode.js:164:14
activate@resource:///org/gnome/shell/ui/screenShield.js:652:34
lock@resource:///org/gnome/shell/ui/screenShield.js:698:14
_prepareForSleep@resource:///org/gnome/shell/ui/screenShield.js:284:22
_emit@resource:///org/gnome/gjs/modules/core/_signals.js:114:47
_prepareForSleep@resource:///org/gnome/shell/misc/loginManager.js:202:14
_emit@resource:///org/gnome/gjs/modules/core/_signals.js:114:47
_convertToNativeSignal@resource:///org/gnome/gjs/modules/core/overrides/Gio.js:152:19

(note that _updateVisibility has been renamed to _sync in https://gitlab.gnome.org/GNOME/gnome-shell/-/commit/762b4c20664880af30149e7f6a097f68c27adf83 -- which from reading the related bug looks like it could make this extension obsolete \o/)

@normanr
Copy link

normanr commented Sep 23, 2022

_signalManager should probably be cleaned up first in SDCInstance.disable() (like VolumeMenuInstance.destroy()), otherwise it will notify _updateMenuVisibility after the menus are destroyed (and the values are already set to null).

@Anthony-Fiddes
Copy link

Just commenting that I also experienced this issue:

Nov 26 13:29:09 fiddes-thinkpad gnome-shell[25503]: JS ERROR: TypeError: menuInstance is null
                                                    _updateMenuVisibility@/home/anthonyfiddes/.local/share/gnome-shell/extensions/sound-output-dev>
                                                    enable/<@/home/anthonyfiddes/.local/share/gnome-shell/extensions/sound-output-device-chooser@k>
                                                    _updateVisibility@resource:///org/gnome/shell/ui/status/volume.js:110:9
                                                    _maybeShowInput@resource:///org/gnome/shell/ui/status/volume.js:305:14
                                                    destroy@/home/anthonyfiddes/.local/share/gnome-shell/extensions/sound-output-device-chooser@kg>
                                                    disable@/home/anthonyfiddes/.local/share/gnome-shell/extensions/sound-output-device-chooser@kg>
                                                    _callExtensionDisable@resource:///org/gnome/shell/ui/extensionSystem.js:124:32
                                                    _onEnabledExtensionsChanged/<@resource:///org/gnome/shell/ui/extensionSystem.js:539:45
                                                    _onEnabledExtensionsChanged@resource:///org/gnome/shell/ui/extensionSystem.js:539:24
                                                    _sessionUpdated@resource:///org/gnome/shell/ui/extensionSystem.js:665:14
                                                    _emit@resource:///org/gnome/gjs/modules/core/_signals.js:114:47
                                                    _sync@resource:///org/gnome/shell/ui/sessionMode.js:206:14
                                                    pushMode@resource:///org/gnome/shell/ui/sessionMode.js:165:14
                                                    activate@resource:///org/gnome/shell/ui/screenShield.js:654:34
                                                    lock@resource:///org/gnome/shell/ui/screenShield.js:700:14
                                                    lockIfWasLocked/<@resource:///org/gnome/shell/ui/screenShield.js:716:18

On pop_os 22.04, Gnome 42.9

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

No branches or pull requests

4 participants