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

Ensure there's always an opened GDK display present #57

Merged
merged 1 commit into from
Dec 17, 2024

Conversation

jikortus
Copy link
Contributor

@jikortus jikortus commented Dec 17, 2024

Sometimes it happens that there's no GDK display present and this leads to a traceback when a keyCombo() is sent. It's not entirely sure if this is a bug in dogtail or if we should open the display explicitly ourselves. We can remove this piece of code in the future if we find out that this should rather get fixed in dogtail.

I have discussed this problem with Michal Odehnal and it's not clear if dogtail should explicitly take care of the display opening or not. We agreed on opening the display explicitly in Anabot at least for now, with further discussions/investigation in the new year.

I have tested this change locally in a VM on both RHEL-9 and 10 (I added Gdk.Display.get_default().close() so that the code within the condition got executed).

@jikortus jikortus force-pushed the gdk-display-workaround branch from a638960 to 030ce4f Compare December 17, 2024 12:36
Sometimes it happens that there's no GDK display present and this
leads to a traceback when a keyCombo() is sent. It's not entirely
sure if this is a bug in dogtail or if we should open the display
explicitly ourselves. We can remove this piece of code in the future
if we find out that this should rather get fixed in dogtail.
@jikortus jikortus force-pushed the gdk-display-workaround branch from 030ce4f to f10a506 Compare December 17, 2024 12:40
@jikortus jikortus self-assigned this Dec 17, 2024
@jikortus jikortus requested a review from jstodola December 17, 2024 12:42
Copy link
Collaborator

@jstodola jstodola left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, it looks good.

@jstodola jstodola merged commit 6cb2883 into main Dec 17, 2024
3 checks passed
@jstodola jstodola deleted the gdk-display-workaround branch December 17, 2024 14:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants