Merge pull request #3909 from jakemcdermott/fix-3578-comment

Improve code comment regarding handling of omitted events
This commit is contained in:
Jake McDermott 2019-10-28 11:52:11 -04:00 committed by GitHub
commit ad383cdb44
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -213,8 +213,8 @@ function JobRenderService ($q, $compile, $sce, $window) {
const record = this.createRecord(event, lines);
if (lines.length === 1 && lines[0] === '') {
// Some events, mainly runner_on_start events, have an actual line count of 1
// (stdout = '') and a claimed line count of 0 (end_line - start_line = 0).
// runner_on_start, runner_on_ok, and a few other events have an actual line count
// of 1 (stdout = '') and a claimed line count of 0 (end_line - start_line = 0).
// Since a zero-length string has an actual line count of 1, they'll still get
// rendered as blank lines unless we intercept them and add some special
// handling to remove them.