Skip to content

Commit

Permalink
Turn on debug loggin by default
Browse files Browse the repository at this point in the history
By default cliff suppresses stack traces on unhandled exceptions in order
to keep the output cleaner for users. But in practice this has caused more
confusion for stestr users since often the error messages aren't really
descriptive enough to indicate what's going wrong (or that it's even a
bug in stestr). This is often because exception messages are written
assuming the context of the stack trace for debugging, not to be user
facing messages. Cliff offers the --debug flag to enable printing the
full stack traces. This commit turns that flag on by default when stestr
initializes the cliff App object to ensure that it always prints the
full stack trace on an unhandled exception.

Fixes #220
  • Loading branch information
mtreinish committed Jan 30, 2019
1 parent 18d6150 commit 300f0b2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions stestr/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ def __init__(self):
)

def initialize_app(self, argv):
self.options.debug = True
self.LOG.debug('initialize_app')

def prepare_to_run_command(self, cmd):
Expand Down

0 comments on commit 300f0b2

Please sign in to comment.