Show More
@@ -2675,10 +2675,11 b' class InteractiveShell(SingletonConfigurable):' | |||
|
2675 | 2675 | # 0 |
|
2676 | 2676 | # For other exit status, we show the exception unless |
|
2677 | 2677 | # explicitly silenced, but only in short form. |
|
2678 |
if |
|
|
2679 | raise | |
|
2680 | if status.code and not kw['exit_ignore']: | |
|
2681 | self.showtraceback(exception_only=True) | |
|
2678 | if status.code: | |
|
2679 | if kw['raise_exceptions']: | |
|
2680 | raise | |
|
2681 | if not kw['exit_ignore']: | |
|
2682 | self.showtraceback(exception_only=True) | |
|
2682 | 2683 | except: |
|
2683 | 2684 | if kw['raise_exceptions']: |
|
2684 | 2685 | raise |
@@ -345,7 +345,8 b' class InteractiveShellApp(Configurable):' | |||
|
345 | 345 | # default to python, even without extension |
|
346 | 346 | self.shell.safe_execfile(full_filename, |
|
347 | 347 | self.shell.user_ns, |
|
348 |
shell_futures=shell_futures |
|
|
348 | shell_futures=shell_futures, | |
|
349 | raise_exceptions=True) | |
|
349 | 350 | finally: |
|
350 | 351 | sys.argv = save_argv |
|
351 | 352 | |
@@ -415,9 +416,8 b' class InteractiveShellApp(Configurable):' | |||
|
415 | 416 | try: |
|
416 | 417 | self._exec_file(fname, shell_futures=True) |
|
417 | 418 | except: |
|
418 | self.log.warn("Error in executing file in user namespace: %s" % | |
|
419 | fname) | |
|
420 | self.shell.showtraceback() | |
|
419 | self.shell.showtraceback(tb_offset=4) | |
|
420 | self.exit(1) | |
|
421 | 421 | |
|
422 | 422 | def _run_module(self): |
|
423 | 423 | """Run module specified at the command-line.""" |
General Comments 0
You need to be logged in to leave comments.
Login now