Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion Framework/Core/src/WorkflowSerializationHelpers.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -969,7 +969,18 @@ bool WorkflowSerializationHelpers::import(std::istream& s,
WorkflowImporter importer{workflow, metadata, command};
bool ok = reader.Parse(isw, importer);
if (ok == false) {
throw std::runtime_error("Error while parsing serialised workflow");
if (s.eof()) {
throw std::runtime_error("Error while parsing serialised workflow");
} else {
// clean up leftovers at the end of the input stream, e.g. [DEBUG] message from destructors
while (true) {
s.getline(buf, 1024, '\n');
if (s.eof()) {
break;
}
LOG(debug) << "following leftover line found in input stream after parsing workflow: " << buf;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not using a signpost, so that we actually can turn it on if needed?

}
}
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we could also just not print the lines

}
return true;
}
Expand Down