samba-tool: do not force a traceback on CommandError
authorDouglas Bagnall <douglas.bagnall@catalyst.net.nz>
Thu, 1 Sep 2022 01:16:53 +0000 (01:16 +0000)
committerDouglas Bagnall <dbagnall@samba.org>
Tue, 6 Sep 2022 21:12:36 +0000 (21:12 +0000)
commitf580c8b0427d5aa4f63b5c6704d9c7819a0c61c4
tree10f5d63a4543e8742b368c616bc93a5eb0f6223d
parent90780936202c3233e33fc6e2a8fac53680cdf63b
samba-tool: do not force a traceback on CommandError

When a CommandError has an 'inner exception', we have been printing
drowning out the error message with a long traceback of the exception
we tried to catch.

People who really want to see tracebacks can use -d3.

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
python/samba/netcmd/__init__.py