Skip to content

Commit a4838e1

Browse files
committedJan 2, 2017
[processing] Don't abort heatmap if adding single feature fails
1 parent ef0131d commit a4838e1

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed
 

‎python/plugins/processing/algs/qgis/Heatmap.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@
3232
from qgis.core import QgsFeatureRequest
3333
from qgis.analysis import QgsKernelDensityEstimation
3434

35+
from processing.core.ProcessingLog import ProcessingLog
3536
from processing.core.GeoAlgorithm import GeoAlgorithm
3637
from processing.core.GeoAlgorithmExecutionException import GeoAlgorithmExecutionException
3738
from processing.core.parameters import ParameterVector
@@ -166,8 +167,8 @@ def processAlgorithm(self, progress):
166167
total = 100.0 / len(features)
167168
for current, f in enumerate(features):
168169
if kde.addFeature(f) != QgsKernelDensityEstimation.Success:
169-
raise GeoAlgorithmExecutionException(
170-
self.tr('Error adding feature to heatmap'))
170+
ProcessingLog.addToLog(ProcessingLog.LOG_ERROR,
171+
self.tr('Error adding feature with ID {} to heatmap').format(f.id()))
171172

172173
progress.setPercentage(int(current * total))
173174

0 commit comments

Comments
 (0)
Please sign in to comment.