[Qgis-developer] Point sampling tool fails on identify

G. Allegri giohappy at gmail.com
Fri Oct 19 04:04:18 PDT 2012


I notice that the identify type is not required.
Simply changing:

ident = rastLayer.identify(point)[1]

to

ident = rastLayer.dataProvider().identify(point)[1]

should work...




2012/10/19 G. Allegri <giohappy at gmail.com>

> AFAICS the identify method has moved to QgsRasterDataProvider, and has
> changed the signature (now you pass the type of identify).
> The pointsamplingtool should be upgraded.
>
> giovanni
>
> 2012/10/19 Paolo Cavallini <cavallini at faunalia.it>
>
>>  Hi all.
>> With current osgeo4w, PST fails with:
>>
>>   File
>> "/home/paolo/.qgis//python/plugins/pointsamplingtool/doPointSamplingTool.py",
>> line 273, in accept
>>     self.sampling(outPath)
>>   File
>> "/home/paolo/.qgis//python/plugins/pointsamplingtool/doPointSamplingTool.py",
>> line 345, in sampling
>>     ident = rastLayer.identify(point)[1]
>> AttributeError: 'QgsRasterLayer' object has no attribute 'identify'
>>
>> Is this related to:
>>
>> https://github.com/qgis/Quantum-GIS/commit/b5412cbf950d489c824ff322e0ae9a312f4a06da
>> and fixed with it?
>> Thanks.
>>
>> --
>> Paolo Cavallini - Faunaliawww.faunalia.eu
>> Full contact details at www.faunalia.eu/pc
>> Nuovi corsi QGIS e PostGIS: http://www.faunalia.it/calendario
>>
>>
>> _______________________________________________
>> Qgis-developer mailing list
>> Qgis-developer at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/qgis-developer
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20121019/3c7c15b2/attachment.html>


More information about the Qgis-developer mailing list