Skip to content

Commit

Permalink
[processing] fixed handling output html files in grass 7
Browse files Browse the repository at this point in the history
  • Loading branch information
volaya committed Oct 14, 2015
1 parent 68ebd4b commit 2f9db5a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 1 addition & 3 deletions python/plugins/processing/algs/grass/grass.txt
Expand Up @@ -105,6 +105,4 @@ In some cases, it might be interesting to take the console output from GRASS and
extract a part of it for saving or formatting.

To do this, just add an output of type OutputHTML. Processing will take care of
turning that into 2 output, one of type OutputHTML and another one of type OutputFile.
The second one will contain the raw output of the algorithm, while the first one
will have some HTML formatting
sending the console output to that output file
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/grass7/Grass7Algorithm.py
Expand Up @@ -139,6 +139,9 @@ def defineCharacteristicsFromFile(self):
hasRasterOutput = True
elif isinstance(output, OutputVector):
vectorOutputs += 1
if isinstance(output, OutputHTML):
self.addOutput(OutputFile("rawoutput", output.description +
" (raw output)", "txt"))
line = lines.readline().strip('\n').strip()
except Exception as e:
ProcessingLog.addToLog(
Expand Down

0 comments on commit 2f9db5a

Please sign in to comment.