5

I upgraded Ubuntu from 16.04 to 16.10, and python3 code that was previously working, does not work anymore, i.e.:

$ python3
Python 3.5.2+ (default, Sep 22 2016, 12:18:14) 
[GCC 6.2.0 20160927] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from PyQt4.QtWebKit import QWebView
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: No module named 'PyQt4.QtWebKit'
>>> 

Package python3-pyqt4 is installed.

Why is this, and what other packages are needed for this to work?

  • sudo apt-get install python3-pyside.qtwebkit – Raphael Oct 22 '16 at 4:41
  • hm... but I want applications that use PyQt4.QtWebKit to work. Why is this changed in 16.10? – vedar Oct 22 '16 at 4:49
  • python3-pyside.qtwebkit - Qt 4 WebKit module - Python3 bindings is what you wanted right? Did the above package solved your issue? – Raphael Oct 22 '16 at 4:53
  • No. I don't want to use PySide and re-factor all code. I want my Python3 applications that use PyQt4 WebKit, to work as expected. – vedar Oct 22 '16 at 4:59
3

It looks like the PyQt4.QtWebKit package got removed in Ubuntu 16.10, probably because both PyQt4 and QtWebKit are long unmaintained.

  • PyQt5.QtWebKit is available, PyQt4.QtWebKit is not – vedar Oct 24 '16 at 6:38
  • Whoops, indeed - thanks, edited! Though at some future Ubuntu release, I'd expect PyQt5.QtWebKit to be removed as well. – The Compiler Oct 24 '16 at 14:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.