mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
Clean up debug logging around _low_level_execute_command
We were logging the command to be executed many times, which made debug logs very hard to read. Now we do it only once. Also makes the logged ssh command line cut-and-paste-able (the lack of which has confused a number of people by now; the problem being that we pass the command as a single argument to execve(), so it doesn't need an extra level of quoting as it does when you try to run it by hand).
This commit is contained in:
@@ -319,7 +319,7 @@ class Connection(ConnectionBase):
|
||||
Starts the command and communicates with it until it ends.
|
||||
'''
|
||||
|
||||
display_cmd = map(pipes.quote, cmd[:-1]) + [cmd[-1]]
|
||||
display_cmd = map(pipes.quote, cmd)
|
||||
display.vvv('SSH: EXEC {0}'.format(' '.join(display_cmd)), host=self.host)
|
||||
|
||||
# Start the given command. If we don't need to pipeline data, we can try
|
||||
|
||||
Reference in New Issue
Block a user