Skip to content
This repository has been archived by the owner on Aug 30, 2024. It is now read-only.

sshconnection cmd() should give option to separate or combine stderr/stdout #252

Open
nephomaniac opened this issue Feb 19, 2014 · 0 comments

Comments

@nephomaniac
Copy link
Contributor

Currently sshconnection.cmd() currently combines stdout and stderr. This was originally done to simplify test scripts and debugging output. This is now a limiting function. For example:
It is currently preventing further dev/testing of sudo prefixed commands. When sudo prefixed commands are executed, warnings related to localhost resolution, etc. to stderr prevent output to stdout from being parsed correctly.
Recommending:
1)Make combining stderr w/ stdout an option for cmd() and probably false by default. stderr should be provided as separate item in the returned dict.

2)Make both stdout and stderr accessible to any ssh cmd callbacks provided to the cmd.

3)sshconnection.sys() can expose this flag but by default should only show stderr as the result of a CommandExitCodeException in the exception.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant