Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 91e7753

Browse files
committed
[Bug #233259] Ugly traceback for DistutilsPlatformError
Fixed by catching all exceptions that are subclasses of DistutilsError, so only the error message will be printed. You can still get the whole traceback by enabling the Distutils debugging mode.
1 parent 706867c commit 91e7753

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

Lib/distutils/core.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -145,9 +145,7 @@ class found in 'cmdclass' is used in place of the default, which is
145145
else:
146146
raise SystemExit, error
147147

148-
except (DistutilsExecError,
149-
DistutilsFileError,
150-
DistutilsOptionError,
148+
except (DistutilsError,
151149
CCompilerError), msg:
152150
if DEBUG:
153151
raise

0 commit comments

Comments
 (0)