Bug 1654637

Summary: keyboard grab failed connecting to XQuartz
Product: [Fedora] Fedora Reporter: Christophe de Dinechin <dinechin>
Component: spice-gtkAssignee: Marc-Andre Lureau <marcandre.lureau>
Status: CLOSED EOL QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 28CC: alon, berrange, cfergeau, fidencio, hdegoede, marcandre.lureau, sandmann, victortoso
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-05-28 23:49:49 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Christophe de Dinechin 2018-11-29 10:12:53 UTC
Description of problem:

When running virt-viewer over ssh -Y from a macOS system running XQuartz, the
following message often happens when returning to the virt-viewer after
losing focus (switching to another application)

(virt-viewer:4900): GSpice-WARNING **: 11:00:54.712: keyboard grab failed 4

After that message shows up, it's impossible to type anything in the VM, and
it is necessary to restart another virt-viewer.

Version-Release number of selected component (if applicable):

virt-viewer.x86_64                      6.0-4.fc28                      @updates
spice-glib.x86_64                        0.35-1.fc28                    @updates
spice-gtk3.x86_64                        0.35-1.fc28                    @updates
spice-protocol.noarch                    0.12.14-2.fc28                 @updates
spice-server.x86_64                      0.14.0-4.fc28                  @fedora 
spice-vdagent.x86_64                     0.17.0-6.fc28                  @fedora 

How reproducible: Always (it may take a few iterations of focus change)


Steps to Reproduce:
1. From macOS, connect to a Fedora 28 system with `ssh -Y hostname`
2. In the resulting shell, use something like `virt-viewer vmname` or `virt-install` or `virt-manager`
3. Check that you can correctly interact with the VM
4. Do something else (read mail, watch a web page) so that XQuartz loses focus
5. Return to the VM. Try typing something.
6. If step 5 works, go back to step 4 and repeat a few times.
7. If step 5 fails, you probably have a message like the above on the terminal

Actual results:

Keyboard focus is lost and keyboard interaction with the VM is no longer possible

Expected results:

Interaction with the VM using the keyboard should remain possible.

Additional info:

I've only observed that with XQuartz so far. I will attempt to reproduce from a Wayland or Xorg session, and update this BZ with my findings.

Comment 1 Daniel Berrangé 2019-03-21 13:52:40 UTC
Re-assigning to spice-gtk since that's responsible for the error message, though ultimately it probably just delegates to gtk for the actual grab, so might eventually need a further reassign

Comment 2 Marc-Andre Lureau 2019-03-21 14:13:51 UTC
it's likely an upstream bug, moved there.
https://gitlab.freedesktop.org/spice/spice-gtk/issues/90

Comment 3 Daniel Berrangé 2019-03-21 14:44:20 UTC
Even if there's an upstream bug, I'd expect this to be kept open as any fix is still appropriate for applying to Fedora

Comment 4 Marc-Andre Lureau 2019-03-21 14:59:46 UTC
ok

Comment 5 Ben Cotton 2019-05-02 19:45:40 UTC
This message is a reminder that Fedora 28 is nearing its end of life.
On 2019-May-28 Fedora will stop maintaining and issuing updates for
Fedora 28. It is Fedora's policy to close all bug reports from releases
that are no longer maintained. At that time this bug will be closed as
EOL if it remains open with a Fedora 'version' of '28'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 28 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 6 Ben Cotton 2019-05-28 23:49:49 UTC
Fedora 28 changed to end-of-life (EOL) status on 2019-05-28. Fedora 28 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.