[QGIS-Developer] Adding WMS and WFS from Metasearch fails in Q3

Alessandro Pasotti apasotti at gmail.com
Wed Jul 19 06:10:40 PDT 2017


Tom,

I've recently done quite a bit of refactoring in the provider dialogs, and
all the signals are now available in the abstract base class
QgsAbstractDataSourceWidget that all provider dialogs inherit from.

addWfsLayer (as well as all other add*Layer clones scattered through the
various providers) has been retired in favour of the more generic
addVectorLayer.

See the available signals at:
https://github.com/qgis/QGIS/blob/73b66fa1f5003aae7e9bca96c703eadf88f838d0/src/gui/qgsabstractdatasourcewidget.h#L76

Cheers


On Wed, Jul 19, 2017 at 1:38 PM, Tom Kralidis <tomkralidis at gmail.com> wrote:

> Hi Paolo: thanks for the info.  I'm able to reproduce in master.
>
> Digging deeper, this may be rooted in [1].  Any idea how one interacts with
> the WFS provider now via Python?
>
> Cheers
>
> ..Tom
>
>
> [1] https://github.com/qgis/QGIS/commit/73b66fa1f5003aae7e9bca96
> c703eadf88f838d0
>
> On Sun, 16 Jul 2017, Paolo Cavallini wrote:
>
> Date: Sun, 16 Jul 2017 17:38:59 +0300
>> From: Paolo Cavallini <cavallini at faunalia.it>
>> To: qgis-developer <qgis-developer at lists.osgeo.org>
>> Subject: [QGIS-Developer] Adding WMS and WFS from Metasearch fails in Q3
>>
>>
>> For WFS:
>>
>> AttributeError: 'QMainWindow' object has no attribute 'addWfsLayer'
>> Traceback (most recent call last):
>>  File
>> "/usr/local/src/qgis/QGIS/build_qgis3/output/python/plugins/
>> MetaSearch/dialogs/maindialog.py",
>> line 781, in add_to_ows
>>    ows_provider.addWfsLayer.connect(self.iface.mainWindow().addWfsLayer)
>> AttributeError: 'QMainWindow' object has no attribute 'addWfsLayer'
>>
>> For WMS, the WMS dialog is opened, but a new recod is not added to the
>> list.
>>
>> All the best.
>> --
>> Paolo Cavallini - www.faunalia.eu
>> QGIS & PostGIS courses: http://www.faunalia.eu/training.html
>> https://www.google.com/trends/explore?date=all&geo=IT&q=qgis,arcgis
>> _______________________________________________
>> QGIS-Developer mailing list
>> QGIS-Developer at lists.osgeo.org
>> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
>> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
>>
> _______________________________________________
> QGIS-Developer mailing list
> QGIS-Developer at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
>



-- 
Alessandro Pasotti
w3:   www.itopen.it
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20170719/1f5079b5/attachment.html>


More information about the QGIS-Developer mailing list