-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
QMS plugin crashes in master #60286
Comments
That should be reported to the authors of the plugin at https://github.com/nextgis/quickmapservices so they investigate if that's a misuse of the QGIS API from their side or really a QGIS issue |
The crash occurs on Windows 10 running the latest QGIS 3.41.0-Master 9e25ade (Jan 25, 2025) and f33604b (Jan 23, 2025) from OSGeo4W (using Python 3.12.8 and python3-sip 6.9.1) with the latest plugin version 0.19.37 and also with previous ones (0.19.36, 0.19.35, 0.19.34). The crash doesn't occur on the same system running QGIS 3.41.0-Master f999386 (Jan 12, 2025) from OSGeo4W (using Python 3.12.8 and python3-sip 6.8.3) either with the latest plugin version or with the previous ones. @rouault, the following simple -supposedly legit- Python code executed in the Python console makes QGIS 3.41.0-Master 9e25ade crash: layer = QgsVectorLayer("Point?field=fldtxt:string&field=fldint:integer", "testlayer", "memory")
layer.setAttribution("test") There is a test in place QGIS/tests/src/python/test_qgsvectorlayer.py Line 3779 in 6ca5140
Maybe it's a Windows \ OSGeo4W specific issue. |
It looks like an OSGeo4W specific issue: the crash doesn't occur on the same system running a MingW64 build (using Python 3.11.10, sip 6.7.10) at the same commit. Ping @jef-n. |
May be because It would be interesting to see if other deprecated methods cause crashes on that build. |
@nyalldawson, it looks like the crash occurs with deprecated methods of QgsMapLayer involving QGIS Server (abstract, setAbstract, attribution, setAttribution, ...) while it doesn't occur with deprecated methods like hasAutoRefreshEnabled and setAutoRefreshEnabled. |
ok, let's see if @troopa81 has any insights... |
Ouch... I'm gonna build a Windows dev env and try to reproduce ... |
174 if hasattr(layer, 'serverProperties'):
175 layer.serverProperties().setAttribution(ds.copyright_text)
176 layer.serverProperties().setAttributionUrl(ds.copyright_link)
177 else:
178 layer.setAttribution(ds.copyright_text)
179 layer.setAttributionUrl(ds.copyright_link) |
@jef-n, indeed the crash occurs with various methods of QgsMapLayer e.g. abstract, setAbstract, attribution, setAttribution, shortName, setShortName ... but not with e.g. hasAutoRefreshEnabled and setAutoRefreshEnabled, and also occurs e.g. with QgsProject().fileInfo(). |
also happens on debian
|
The crash doesn't occur on Ubuntu 22.04.1 running QGIS 3.41.0-Master 6f4df5d (Jan 2, 2025, from https://ubuntu.qgis.org/ubuntu-nightly/). |
@agiudiceandrea @jef-n Thank you for the report. I'm suspecting that pyqt-sip module is not build against the same sip build than the qgis package. Because in the @jef-n stacktrace we see that it crashes when calling sip_api_precated_12_16, and I presume the symbol is missing. I'm rebuilding to test a little bit more thoroughly, but I think I'm gonna disable the deprecated support until I figured out what the issue reaaly is |
What is the bug or the crash?
in the master update now, starting the QMS plugin, QGIS crashes
Steps to reproduce the issue
Versions
Supported QGIS version
New profile
Additional context
No response
The text was updated successfully, but these errors were encountered: