Skip to content

Commit

Permalink
[BUGFIX][Processing][Rscript] Write to R_OUTPUT_VALUES file if saveOu…
Browse files Browse the repository at this point in the history
…tputValues

Fixes #16618 Processing rscripts: cannot concatenate 'str' and 'NoneType' objects
  • Loading branch information
rldhont committed Jun 6, 2017
1 parent 5fdde8a commit 3d9af5b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/r/RAlgorithm.py
Expand Up @@ -400,7 +400,7 @@ def getExportCommands(self):
value = out.value value = out.value
value = value.replace('\\', '/') value = value.replace('\\', '/')
commands.append('write.csv(' + out.name + ',"' + value + '")') commands.append('write.csv(' + out.name + ',"' + value + '")')
elif out.name != RAlgorithm.R_OUTPUT_VALUES: elif out.name != RAlgorithm.R_OUTPUT_VALUES and self.saveOutputValues:
commands.append('cat("##' + out.name + '",file="' + outputDataFile + '",sep="\n",append=TRUE)') commands.append('cat("##' + out.name + '",file="' + outputDataFile + '",sep="\n",append=TRUE)')
commands.append('cat(' + out.name + ',file="' + outputDataFile + '",sep="\n",append=TRUE)') commands.append('cat(' + out.name + ',file="' + outputDataFile + '",sep="\n",append=TRUE)')


Expand Down

0 comments on commit 3d9af5b

Please sign in to comment.