Skip to content

Monkey-patch catchall except: statements so they at least don't catch KeyboardInterrupt errors #11310

@jdemeyer

Description

@jdemeyer

There are a lot places in the Sage library which use

except:

This is bad because it catches non-errors like KeyboardInterrupt.


Then the patch attachment: 11310_auto.patch has ben auto-generated to replace all instances of

except:

by

except StandardError:

and all instances of

raise Exception

by

raise RuntimeError

Apply attachment: trac_11310.patch and attachment: 11310_auto.patch and attachment: 11310_psage.patch.

Depends on #13109

CC: @kini

Component: misc

Author: Jeroen Demeyer, Volker Braun

Reviewer: Keshav Kini

Merged: sage-5.3.beta1

Issue created by migration from https://trac.sagemath.org/ticket/11310

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions