Load a local html file into a QWebView in Python
<p>Here's my problem: I want to load a local html file into a <code>QWebView</code> in Python. 
EDIT: I use PySide as a Qt package.</p>

<p>My code:</p>

<pre><code>class myWindow(QWidget):
    def __init__(self, parent=None):
        self.view = QWebView(self)
        filepath = "file://" + os.path.join(os.path.dirname(__file__), 'googlemap.html')
        self.view.load(QUrl(filepath))
</code></pre>

<p>This is just showing me a blank widget.
If I change </p>

<pre><code>self.view.load(QUrl(filepath)
</code></pre>

<p>by</p>

<pre><code>self.view.load(QUrl("http://www.google.com/"))
</code></pre>

<p>It works fine.</p>

<p>However, the file is clearly in the good directory and I can open the same file directly with my browser.</p>

<p>EDIT 2:
The problem appears after an update on my Raspberry Pi 2 (which runs the code above)</p>