<div dir="ltr"><div>Hi,</div><div><br></div><div>I am trying to build QGIS with QT6 on Ubuntu (tried 24.10 and 25.04), </div><div>it builds without errors but when I run it, the following error appears:</div><div><br></div><div>

<p style="margin:0px;text-indent:0px;white-space:pre-wrap"><span style="color:rgb(255,0,0)">Couldn't load PyQGIS.<br>Python support will be disabled.</span><br></p>
<pre style="margin:12px 0px;text-indent:0px"><span style="font-family:"Hack""><br>Traceback (most recent call last):<br>  File "", line 1, in <br>  File "/home/ale/dev/QGIS/build/Desktop_QT6-Debug/output/python/qgis/gui/__init__.py", line 25, in <br>    from qgis._gui import *<br>RuntimeError: qgis._gui cannot import type '���A� ' from PyQt6.QtCore<br><br></span></pre>
<p style="margin:0px;text-indent:0px;white-space:pre-wrap">Python version:<br>3.13.3 (main, Jun 16 2025, 18:15:32) [GCC 14.2.0]<br><br>QGIS version:<br>3.99.0-Master 'Master', e717e3cd2b9<br><br>Python path:<br>['/home/ale/dev/QGIS/build/Desktop_QT6-Debug/output/python', '/home/ale/.local/share/QGIS/QGIS3/profiles/default/python', '/home/ale/.local/share/QGIS/QGIS3/profiles/default/python/plugins', '/home/ale/dev/QGIS/build/Desktop_QT6-Debug/output/python/plugins', '/home/ale/dev/gdal/desktop-install/local/lib/python3.13/dist-packages', '/home/ale/dev/gdal/autotest/pymod', '/usr/lib/python313.zip', '/usr/lib/python3.13', '/usr/lib/python3.13/lib-dynload', '/usr/local/lib/python3.13/dist-packages', '/usr/lib/python3/dist-packages']</p><br></div><div><br></div><div>I checked the QGIS/build/Desktop_QT6-Debug/output/python/qgis content and it looks legit.</div><div><br></div><div>PyQt6 installation also looks ok, importing core works ok, only gui does not work.</div><div><br></div><div>Any idea about what's going wrong?</div><div><br></div><div><br></div><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>Alessandro Pasotti</div><div>QCooperative:  <a href="https://www.qcooperative.net" target="_blank">www.qcooperative.net</a><br></div>ItOpen:   <a href="http://www.itopen.it" target="_blank">www.itopen.it</a></div></div></div>