Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

QuLogic
Copy link
Member

@QuLogic QuLogic commented Sep 9, 2025

PR summary

This adds requirements for all of Gdk/GdkPixbuf/Gio/GLib/GObject before using them, as we do for Gtk.

Note, Gdk is bunded with Gtk, so it's the only one that changes versions depending on backend.

Fixes #30525

PR checklist

@QuLogic QuLogic added this to the v3.10.7 milestone Sep 9, 2025
@QuLogic
Copy link
Member Author

QuLogic commented Sep 9, 2025

Note, this doesn't explicitly do GioUnix, but as that comes with Gio (but is platform-specific), I'm hoping that's enough to fix it.

@LangQi99
Copy link
Contributor

LangQi99 commented Sep 9, 2025

What about

    try:
        gi.require_version("GioUnix", "2.0")
    except ValueError:
        # GioUnix is not available on this platform, which is fine
        pass

I tried it in #30535

This adds requirements for all of Gdk/GdkPixbuf/Gio/GLib/GObject before
using them, as we do for Gtk.

Fixes matplotlib#30525
This test has been an expected failure since it was created, and in that
time, `gtk_test_widget_send_key` was never made to work, nor was a
replacement found. In GTK4, that API doesn't exist either.
For example, GTK3 and GTK4 conflict, and which one is tested depends on
which one loads first. Running in a subprocess ensures that both work,
but we only do that for backends as adding ~100 more subprocesses is
overkill.
@QuLogic QuLogic force-pushed the gtk-require-version branch from 8a720cb to 93a5b91 Compare September 9, 2025 06:38
@tacaswell
Copy link
Member

Sorry I was going down the issue list in order and merged #30535 before I got to this one.

@QuLogic
Copy link
Member Author

QuLogic commented Sep 11, 2025

That is okay; this has turned into more of a cleanup on the tests a bit than fully fixing the original issue.

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

Successfully merging this pull request may close these issues.

[Bug]: Pipeline fails with "GioUnix was imported without specifying a version first"
3 participants