解决ImportError: cannot import name ‘QtWebKitWidgets’错误

首先安装 1)
    pip install PyQtWebEngine
2)
    pip install PyQt5==5.11.3

使用QtWebEngineWidgets替换QtWebKitWidgets

2 In PyQt5 “QtWebKitWidgets” is Deprecated. I just replace this line
from PyQt5.*QtWebKitWidgets* import *QWebView*, *QWebPage*
from PyQt5.*QtWebKit* import *QWebSettings*
With this code:
from PyQt5.QtWebEngineWidgets import QWebEngineView as QWebView,QWebEnginePage as QWebPage
from PyQt5.QtWebEngineWidgets import QWebEngineSettings as QWebSettings
QtWebKitWidgets.QWebView()
替换为
QtWebEngineWidgets.QWebEngineView()