py2app
py2app copied to clipboard
PySide2 5.15.2 app does not draw window content
Same issue of #271, but with PySide2. I am opening a new issue as I assume the original one was somehow fixed, probably on the PyQt side.
Symptoms: app does not show any dialog when opened and actually requires Force Quit to terminate.
I tested this on Python 3.7 and 3.9 with PySide2 5.13.1 and 5.15.2. The apps built with both Python versions on 5.13 were functional and those built with 5.15 were not. The only way to create functional apps on 5.15 was to rebuild the py2app stubs, as suggested in https://github.com/ronaldoussoren/py2app/issues/271#issuecomment-609078700. I performed the whole investigation on py2app 0.24 (more on that in the end of the issue).
To facilitate reproduction and debugging on your side, I created a GitHub repository, with Actions, with code and artifacts already ready to be downloaded and inspected. I add here the links to the corresponding Actions builds. You can also easily inspect the generating code for each branch.
Python | 5.13.1 | 5.15.2 | 5.15.2 + rebuilt stubs |
---|---|---|---|
3.7 | cp37-pyside513-py2app024 ✅ | cp37-pyside515-py2app024 ❌ | cp37-pyside515-py2app024-rb ✅ |
3.9 | cp39-pyside513-py2app024 ✅ | cp39-pyside515-py2app024 ❌ | cp39-pyside515-py2app024-rb ✅ |
Answers to your questions from the previous issue:
Which version of Python?
This affects both 3.7 and 3.9.
How is Python installed (Python.org installer, home-brew, anaconda, ...)?
I reproduced this locally on homebrew Python and also on GitHub Action on Python.org installer
Which version of macOS?
Builds were primarily done on 10.15, tests on both 10.15 and 11.
Which CPU architecture(s) (x86_64, arm64, ...)?
The whole test was done on x86_64.
Which version of PyQt/PySide/....?
PySide2 5.13.1 pass, 5.15.2 fail.
How was that library installed?
All the libraries were installed via pip
. An extra manual step was performed as showed in https://github.com/albertosottile/py2app_pyside2/blob/master/ci/pyside2_linker.py to add symlinks in the Frameworks installed from the wheels, as wheels still do not support symlinks. An extra cleaning step is also performed to delete the PySide2/Qt/
tree from the zip library, but this should be irrelevant as the .so are not loaded from the zip file.
Note on py2app 0.24: I had to limit myself to this version as 0.26.1 introduces a new bug that compromises the build heavily (#384)