Dash-to-dock: Super+number shorcuts stop working if screensaver has been activated

Created on 14 Nov 2017  Â·  13Comments  Â·  Source: micheleg/dash-to-dock

Hi,
After turning on the Super+(0-9) shortcuts to activate apps, they work very well (and I've come to absolutely love and rely on them). Unfortunately, since updating to Ubuntu 17.10, I'm experiencing a bug. Whenever the screensaver activates (and then the computer is woken back up), those shortcuts no longer work. I can consistently make them work again by turning them off and on again in the dash-to-dock UI. Note the relevant log messages at the bottom of this bug report.

Reproduction:
With shortcuts activated through the d-t-d UI, call
gnome-screensaver-command -a
Move the mouse to turn the screensaver off.
Shortcuts no longer work.

Any help, including workarounds, would be enormously appreciated -- now that I've gotten used to those shortcuts, it's hard to live without them.
Thanks for the awesomeness that is dash-to-dock!

Repro info:

  • Extension version
    61
  • Gnome Shell version
    3.26.1

  • Linux distribution and version
    Ubuntu 17.10

  • Whether you have a multi-monitor configuration
    No

  • Your settings: include the output of the command dconf dump /org/gnome/shell/extensions/dash-to-dock/.

  [/]
  preferred-monitor=0
  shortcut-text=''
  dock-fixed=false
  force-straight-corner=false
  intellihide=true
  intellihide-mode='ALL_WINDOWS'
  show-show-apps-button=false
  hot-keys=true
  require-pressure-to-show=false
  apply-custom-theme=false
  custom-theme-running-dots=true
  unity-backlit-items=false
  dock-position='BOTTOM'
  custom-theme-shrink=false
  background-opacity=0.90000000000000002
  height-fraction=0.76000000000000001
  dash-max-icon-size=36
  hotkeys-show-dock=true
  shortcut=@as []
  opaque-background=false
  • Other info:

    • The bug does persist after disabling all other extensions.

    • I don't have Looking Glass -- google suggests that's a Cinnamon thing?

    • journalctl -f /usr/bin/gnome-shell | grep -v AppIndicatorSupport-WARN

    • Note: I'm omitting the AppIndicator logs because there's a constant stream of them on my system

    • Nothing is logged when I use the Super+Number hotkeys to (successfully) change applications.

    • Once I've screensaver-ed the system and reawoken it, the hotkeys don't work. The following has appeared in the log:



      • (duplication omitted, but these were duplicated for each individual number)



      Nov 12 21:54:00 egg-p51 gnome-shell[2062]: WARNING: addSignalMethods is replacing existing [0x55c1cf40a7d0 Gjs_ShowAppsIcon.dash-item-container] connect method
      Nov 12 21:54:00 egg-p51 gnome-shell[2062]: WARNING: addSignalMethods is replacing existing [0x55c1cf40a7d0 Gjs_ShowAppsIcon.dash-item-container] disconnect method
      Nov 12 21:54:00 egg-p51 gnome-shell[2062]: WARNING: addSignalMethods is replacing existing [0x55c1cf40a7d0 Gjs_ShowAppsIcon.dash-item-container] emit method
      Nov 12 21:54:07 egg-p51 org.gnome.Shell.desktop[2062]: Window manager warning: Trying to re-add keybinding "app-hotkey-1".
      Nov 12 21:54:07 egg-p51 org.gnome.Shell.desktop[2062]: Window manager warning: Trying to re-add keybinding "app-shift-hotkey-1".
      Nov 12 21:54:07 egg-p51 org.gnome.Shell.desktop[2062]: Window manager warning: Trying to re-add keybinding "app-ctrl-hotkey-1".
      Nov 12 21:54:07 egg-p51 org.gnome.Shell.desktop[2062]: Window manager warning: Trying to re-add keybinding "shortcut".
ubuntu-dock

All 13 comments

I should add that I haven't been able to find any relevant issues filed against gnome-screensaver.

I tried on my system (albeit I'm on 3.22) and I can't reproduce the issue. Does it also happen when the lock screen is triggered automatically or with super-L?

org.gnome.Shell.desktop[2062]: Window manager warning: Trying to re-add keybinding "app-hotkey-1".

@didrocks Perhaps you can carry an extra (permanent) patch on the ubuntu-dock branch that renames the keybindings? I've seen this problem pop up in other places (can't remember now, probably Launchpad). This is not so much a problem with dash-to-dock (any change name done on it will be eventually be picked up by ubuntu-dock when rebasing).

When an Ubuntu user first installs dash-to-dock, the app-keys don't work, as the specified keybindings are already defined.

Edit: Added the quote. I was specifically referring to the warnings!

@micheleg Yes, it happens whether the lock screen is triggered automatically or manually. I just tried turning screen locking off, and then letting "blank screen" kick in and then waking it back up, and that's sufficient to break the shortcuts. So I think it's actually not specific to the lock screen, but to the screen-blanking.

@franglais125 I know you're addressing someone else there, but just to be clear, what you're saying is a bit over my head. I think you're saying that Super+number is already bound, though -- do you know what it's bound to / what process is binding it? Is that ubuntu-dock? If I can find a way to eliminate those other bindings, that might be a sufficient workaround for my needs (although seems worth an actual fix).

Thanks!

I've got Ubuntu Dock turned off in tweaks/extensions, in case that makes any difference.

@franglais125: I think the issue is maybe more than the keybindings aren't properly unregistered on extension teardown (which ubuntu-dock calls when dash to dock is enabled)?

It think that would be more the way to go than renaming (especialy seeing the number of shortcuts), and either fix the bug in dash-to-dock unregistration or even maybe the Shell not doing the proper thing, wdyt?

Actually, there is maybe a race between having dash-to-dock up and ubuntu-dock tear down. I doubt the Shell will anyway let (even if renaming) setting the same key combinations (super + num for instance) retaken by another extension. We need to give it some thoughts it seems…

For anyone else who encounters this problem, I've finally found a workaround for ubuntu-dock breaking the dash-to-dock keyboard shortcuts: just uninstall ubuntu-dock and then reinstall dash-to-dock. Fortunately, existing dash-to-dock settings will remain in place, so you won't need to reconfigure it.

I don't know whether this fix will persist across updates, but perhaps the ubuntu-dock bug will be fixed by then.

@micheleg thanks again for all your awesome work on d-t-d!

sudo apt remove gnome-shell-extension-ubuntu-dock
sudo apt install gnome-shell-extension-dashtodock

I can confirm both the bug and that it goes away if you ditch ubuntu-dock and install dashtodock.

Either confirm. Workaround also works with exceptions:

  1. I didn't remove ubuntu-dock,
  2. I removed d-t-d, but shortcuts start work normally.
    Seems like ubuntu dock gets settings of d-t-d and applies them in correct way...

Guys, you should uninstall gnome-shell-extension-ubuntu-dock from system, after that - no bugs

I'm seeing some fighting between Super+Number shortcuts and GNOME's own "switch to workspace" shortcuts, too, even if the former are disabled in Dash to Dock's settings. It's as if Dash to Dock still binds them to switch to dock apps, but then unbinds them once it reads its configuration... This on Arch Linux, so no Ubuntu extensions are involve.d

For anyone else who encounters this problem, I've finally found a workaround for ubuntu-dock breaking the dash-to-dock keyboard shortcuts: just uninstall ubuntu-dock and then reinstall dash-to-dock. Fortunately, existing dash-to-dock settings will remain in place, so you won't need to reconfigure it.

I don't know whether this fix will persist across updates, but perhaps the ubuntu-dock bug will be fixed by then.

@micheleg thanks again for all your awesome work on d-t-d!

sudo apt remove gnome-shell-extension-ubuntu-dock
sudo apt install gnome-shell-extension-dashtodock

I was seeing the exact same issue, and this solution worked for me. Note that a restart was required afterwards.

Was this page helpful?
0 / 5 - 0 ratings