Bug #13062
CommandFailedError should include command output
0%
Description
Knowing that a test failed is not as valuable as knowing why a test failed. Include the command output in the error message so we have that information.
History
#1 Updated by Zack Cerza over 8 years ago
- Status changed from New to Need More Info
- Assignee set to Joe Julian
By default, when teuthology runs a command, its output is logged. The output can optionally be stored in a file-like object so that the job can process it, in which case it isn't automatically logged. This is consistent with standard python libraries like subprocess
.
It isn't at all practical to add the output of a command to the exception text as sometimes we run commands with very large amounts of output.
So, if you're seeing a command which should be logging more information, or a case where a more helpful exception should be used, that needs to be handled on a case-by-case basis. We would need to know exactly where you see the problem.