Skip to content

Commit 4f2a88d

Browse files
authored
Use exit 2 on crash to signal this is no ordinary error (#5987)
The wrapper script we use to run mypy at Dropbox will greatly benefit from this -- it will be able to distinguish between a crash and type-checking errors.
1 parent a2f45dc commit 4f2a88d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

mypy/errors.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -612,4 +612,5 @@ def report_internal_error(err: Exception, file: Optional[str], line: int,
612612
print('{}: note: use --pdb to drop into pdb'.format(prefix), file=sys.stderr)
613613

614614
# Exit. The caller has nothing more to say.
615-
raise SystemExit(1)
615+
# We use exit code 2 to signal that this is no ordinary error.
616+
raise SystemExit(2)

0 commit comments

Comments
 (0)