Merge lp:~javier.collado/utah/bug1035227 into lp:utah
Status: | Merged | ||||
---|---|---|---|---|---|
Merged at revision: | 633 | ||||
Proposed branch: | lp:~javier.collado/utah/bug1035227 | ||||
Merge into: | lp:utah | ||||
Diff against target: |
47 lines (+19/-0) (has conflicts) 2 files modified
utah/provisioning/provisioning.py (+4/-0) utah/run.py (+15/-0) Text conflict in utah/run.py |
||||
To merge this branch: | bzr merge lp:~javier.collado/utah/bug1035227 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Max Brustkern (community) | Approve | ||
Javier Collado (community) | Needs Resubmitting | ||
Review via email: mp+119327@code.launchpad.net |
Description of the change
When an ssh command returns a failure code, it's logged as a warning (we might want to ignore it). However, when the client fails, then an error message is printed to sys.stderr and run_utah_tests.py exits. If we decide to ignore some client return codes and continue for some other return codes, this can be easily updated though.
Example output:
INFO: Running command through SSH: doesnotexist -r /tmp/master.run -o /var/log/
WARNING: Return code: 127
utah failed with return code: 127
INFO: Running command through SSH: rm -f /var/log/
utah@xps8300:
Note that the error message isn't the last one printed to the console because the 'rm' command is executed later in a finally clause.
I think I'd like to get that error into a log rather than just using sys.stderr.print. How about using machine. logger. error for that? I think this is definitely a good change either way, since it'll provide more useful error info. If you agree with changing the logging method, you can either change the branch, or just let me know and I'll make the change when I do the merge.