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

assert g_type != TYPE_NONE #21

Closed
totaam opened this issue Aug 1, 2021 · 3 comments
Closed

assert g_type != TYPE_NONE #21

totaam opened this issue Aug 1, 2021 · 3 comments
Labels
bug Something isn't working

Comments

@totaam
Copy link
Collaborator

totaam commented Aug 1, 2021

Just like #20 (comment) and #7 (comment).

py2app step:
./setup.py py2app  --without-server --without-shadow --without-proxy
 (see /Users/macos/xpra/py2app.log for details - this may take a minute or two)
ERROR: py2app failed

  File "/Users/macos/gtk/inst/lib/python3.9/site-packages/gi/importer.py", line 144, in load_module
    importlib.import_module('gi.repository.' + dep.split("-")[0])
  File "/Users/macos/gtk/inst/lib/python3.9/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
  File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 664, in _load_unlocked
  File "<frozen importlib._bootstrap>", line 627, in _load_backward_compatible
  File "/Users/macos/gtk/inst/lib/python3.9/site-packages/gi/importer.py", line 145, in load_module
    dynamic_module = load_overrides(introspection_module)
  File "/Users/macos/gtk/inst/lib/python3.9/site-packages/gi/overrides/__init__.py", line 118, in load_overrides
    override_mod = importlib.import_module(override_package_name)
  File "/Users/macos/gtk/inst/lib/python3.9/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "/Users/macos/gtk/inst/lib/python3.9/site-packages/gi/overrides/Pango.py", line 41, in <module>
    FontDescription = override(FontDescription)
  File "/Users/macos/gtk/inst/lib/python3.9/site-packages/gi/overrides/__init__.py", line 195, in override
    assert g_type != TYPE_NONE
AssertionError

Really not sure what causes this or how to fix it.
IIRC, last time I saw this was caused by a DLL path issue, perhaps caused by #19?

@totaam totaam added the bug Something isn't working label Aug 9, 2021
@totaam
Copy link
Collaborator Author

totaam commented Aug 9, 2021

Only a problem for CLIENT_ONLY=1 builds.

@totaam
Copy link
Collaborator Author

totaam commented Feb 23, 2023

I am no longer seeing this problem when packaging, only when trying to run code from a jhbuild shell.

For some strange reason, we now have to set LD_LIBRARY_PATH to run test commands, ie:

LD_LIBRARY_PATH=$JHBUILD_PREFIX/lib python3 xpra/platform/path.py

@totaam
Copy link
Collaborator Author

totaam commented Nov 12, 2023

Re-appeared when building the v5.x branch, and not for master!
Ran the offending import from a shell:

$ python3 -c "from gi.repository import GLib, GdkPixbuf, Pango, GObject, Gtk, Gdk"
** (process:13827): WARNING **: 12:32:48.766: Failed to load shared library 'libgdk_pixbuf-2.0.0.dylib' \
    referenced by the typelib: dlopen(libgdk_pixbuf-2.0.0.dylib, 0x0009): tried: \
    'libgdk_pixbuf-2.0.0.dylib' (no such file), \
    '/System/Volumes/Preboot/Cryptexes/OSlibgdk_pixbuf-2.0.0.dylib' (no such file), \
    '/usr/lib/libgdk_pixbuf-2.0.0.dylib' (no such file, not in dyld cache), \
    'libgdk_pixbuf-2.0.0.dylib' (no such file), \
    '/usr/local/lib/libgdk_pixbuf-2.0.0.dylib' (no such file), \
    '/usr/lib/libgdk_pixbuf-2.0.0.dylib' (no such file, not in dyld cache)
(..)
    assert g_type != TYPE_NONE

Workaround in Xpra-org/xpra@262cffc

Why doesn't setting DYLD_LIBRARY_PATH help?
Why is it failing for gdk pixbuf? Could this be jpeg related? (#19)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant