Skip to content

Commit

Permalink
Remove 'import traceback'.
Browse files Browse the repository at this point in the history
This module isn't in the production build.o

Addresses issue #426.
  • Loading branch information
Andy Chu committed Jul 15, 2019
1 parent d4b268b commit 339d0d1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
6 changes: 4 additions & 2 deletions core/comp_ui.py
Expand Up @@ -93,8 +93,10 @@ def PrintCandidates(self, *args):
try:
self._PrintCandidates(*args)
except Exception as e:
import traceback
traceback.print_exc()
if 0:
import traceback
traceback.print_exc()


def Reset(self):
"""Call this in between commands."""
Expand Down
5 changes: 3 additions & 2 deletions core/completion.py
Expand Up @@ -1132,8 +1132,9 @@ def __call__(self, unused_word, state):
# So this may never happen?
ui.Stderr('Ctrl-C in completion')
except Exception as e: # ESSENTIAL because readline swallows exceptions.
import traceback
traceback.print_exc()
if 0:
import traceback
traceback.print_exc()
ui.Stderr('osh: Unhandled exception while completing: %s', e)
self.debug_f.log('Unhandled exception while completing: %s', e)
except SystemExit as e:
Expand Down

0 comments on commit 339d0d1

Please sign in to comment.