Skip to content

Commit

Permalink
Merge pull request taskcluster#215 from djmitche/error-message-newline
Browse files Browse the repository at this point in the history
Always precede [taskcluster:error] with newline
  • Loading branch information
gregarndt authored and imbstack committed May 7, 2020
1 parent a9826c5 commit da7af99
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion workers/docker-worker/lib/log.js
Expand Up @@ -23,5 +23,7 @@ export function fmtLog() {

export function fmtErrorLog() {
let args = Array.prototype.slice.call(arguments);
return '[taskcluster:error] ' + util.format.apply(this, args) + '\r\n';
// always include a newline before this string, so that it is at the beginning of the line
// where treeherder expects it, even if the last output was not newline-terminated
return '\r\n[taskcluster:error] ' + util.format.apply(this, args) + '\r\n';
}

0 comments on commit da7af99

Please sign in to comment.