PyQt5 not working on DEY 2.6-r1


I installed PyQt5 on my ConnectCore6 using bitbake by adding this to the local.config:

IMAGE_INSTALL_append_pn-dey-image-qt " qtbase qttools python3-pyqt5"

Originally, th command import PyQt5 would fail. I solved this by adding a directory to the python path: export PYTHONPATH=/usr/share/sip:$PYTHONPATH

Now i can import PyQt5 core but when I try to make a simple GUI from:
I cannot complete the import statement: from PyQt5.QtWidgets import QApplication

I get the error: ImportError: cannot import name ‘QApplication’

I have checked and the libraries are available under /usr/share/sip and QApplication appears to be there under QtWidgets. Can anyone help with using PyQt5 on the Connect Core Digi-embeded-yocto?

I got it working. I ran:
$ python3
And found the path from inside the python shell

>>> import sys
>>> sys.path

I poked around in the listed paths and found that PyQt5 was in /usr/lib/python3.5m/site-packages

The site-packages/ directory was not in the python path, so I added it to the path:

$ export PYTHONPATH=/usr/lib/python3.5m/site-packages:$PYTHONPATH