Tuesday, 6 October 2020

Qt QApplication constructor taking very long time on Raspberry Pie python3 PyQt5

I am investigating extremely slow start of a python3 script running on Raspberry Pie and nailed it down to Qt QApplication constructor. To confirm, I have created TestQt.py:

from sys import argv
from PyQt5.QtWidgets import QApplication

app = QApplication(argv)

It takes 45-49 seconds to execute, e.g.

pi@raspberrypi:~/test-dir $ time python3 TestQt.py

real    0m48.973s
user    0m0.394s
sys     0m0.106s

While it starts, top shows very low CPU consumption. I have no idea what can be the cause. Any ideas, please?

Edit: as suggested in a comment by three_pineapples:
Raspbian GNU/Linux 10 (buster)
Python 3.7.3
PyQt version: 5.11.3
Qt version: 5.11.3



from Qt QApplication constructor taking very long time on Raspberry Pie python3 PyQt5

No comments:

Post a Comment