Don't fail if exos can't configure cli columns (#51364)

* Don't fail if exos can't configure cli columns

Signed-off-by: Misha Komarovskiy <zombah@gmail.com>
This commit is contained in:
Misha Komarovskiy 2019-09-12 18:12:44 +03:00 committed by Nathaniel Case
parent 6691527799
commit c3c54302af

View file

@ -49,7 +49,11 @@ class TerminalModule(TerminalBase):
def on_open_shell(self):
try:
for cmd in (b'disable clipaging', b'configure cli columns 256'):
self._exec_cli_command(cmd)
self._exec_cli_command(b'disable clipaging')
except AnsibleConnectionFailure:
raise AnsibleConnectionFailure('unable to set terminal parameters')
try:
self._exec_cli_command(b'configure cli columns 256')
except AnsibleConnectionFailure:
self._connection.queue_message('warning', 'Unable to configure cli columns, command responses may be truncated')