[PyQt] PyQtDeployed app can't find standard modules

David Beck dbeck at ualberta.ca
Mon Oct 31 14:42:13 GMT 2016


Hello,

I have suddenly begun to get errors like the following when I try to run a PyQtDeployed application:

Traceback (most recent call last):
File "eFieldBook.py", line 2, in <module>
File "bootstrap.py", line 969, in _find_and_load
File "bootstrap.py", line 958, in _find_and_load_unlocked
File "bootstrap.py", line 664, in _load_unlocked
File "bootstrap.py", line 634, in _load_backward_compatible
File ":/ELFB/ui/fieldbook.py", line 11, in <module>
File "bootstrap.py", line 1016, in _handle_fromlist
File "bootstrap.py", line 222, in _call_with_frames_removed
File "bootstrap.py", line 969, in _find_and_load
File "bootstrap.py", line 958, in _find_and_load_unlocked
File "bootstrap.py", line 664, in _load_unlocked
File "bootstrap.py", line 634, in _load_backward_compatible
File ":/ELFB/menus.py", line 2, in <module>
File "bootstrap.py", line 1016, in _handle_fromlist
File "bootstrap.py", line 222, in _call_with_frames_removed
File "bootstrap.py", line 969, in _find_and_load
File "bootstrap.py", line 958, in _find_and_load_unlocked
File "bootstrap.py", line 664, in _load_unlocked
File "bootstrap.py", line 634, in _load_backward_compatible
File ":/ELFB/metaDataTableFillers.py", line 2, in <module>
File "bootstrap.py", line 1016, in _handle_fromlist
File "bootstrap.py", line 222, in _call_with_frames_removed
File "bootstrap.py", line 969, in _find_and_load
File "bootstrap.py", line 958, in _find_and_load_unlocked
File "bootstrap.py", line 664, in _load_unlocked
File "bootstrap.py", line 634, in _load_backward_compatible
File ":/ELFB/metaDataBtns.py", line 3, in <module>
File "bootstrap.py", line 969, in _find_and_load
File "bootstrap.py", line 958, in _find_and_load_unlocked
File "bootstrap.py", line 664, in _load_unlocked
File "bootstrap.py", line 634, in _load_backward_compatible
File ":/random.py", line 41, in <module>
File "bootstrap.py", line 969, in _find_and_load
File "bootstrap.py", line 956, in _find_and_load_unlocked
ImportError: No module named ‘math'

I’ve played around with the code and changed the import calls and have gotten ImportErrors for other modules like time (called from datetime.py) and syspath as well. This is quite new and I hadn’t done anything except a system upgrade. When this started to happen, I reinstalled and upgraded all the packages to the newest versions, so now I’m running OSX 10.12.1, Qt 5.7, Python 3.5.2, PyQt 5.7, and the latest version of pyqtdeploy installed via pip. I also built the deployment project using build-sysroot.py (thank you so much for writing that script!). That didn’t change anything. If anyone has any suggestions as to what might be happening here, I would really appreciate it.

cheers,

David





More information about the PyQt mailing list