Skip to content
Browse files
[processing][grass] Don't try to create skipped optional outputs
(cherry-picked from f03baa8)
  • Loading branch information
nyalldawson committed Apr 10, 2018
1 parent 1614638 commit f98a785270207c99794b65eca68e36bbb68faf61
Showing 1 changed file with 9 additions and 2 deletions.
@@ -637,6 +637,10 @@ def processOutputs(self, parameters, context, feedback):

for out in self.destinationParameterDefinitions():
outName =
if not outName in parameters:
# skipped output

if isinstance(out, QgsProcessingParameterRasterDestination):
self.exportRasterLayerFromParameter(outName, parameters, context)
elif isinstance(out, QgsProcessingParameterVectorDestination):
@@ -688,8 +692,11 @@ def exportRasterLayerFromParameter(self, name, parameters, context, colorTable=T
:param context: Algorithm context.
:param colorTable: preserve color Table.
fileName = os.path.normpath(
self.parameterAsOutputLayer(parameters, name, context))
fileName = self.parameterAsOutputLayer(parameters, name, context)
if not fileName:

fileName = os.path.normpath(fileName)
grassName = '{}{}'.format(name, self.uniqueSuffix)
outFormat = Grass7Utils.getRasterFormatFromFilename(fileName)
createOpt = self.parameterAsString(parameters, self.GRASS_RASTER_FORMAT_OPT, context)

0 comments on commit f98a785

Please sign in to comment.