HomePhabricator

[python linting] enforce E722: do not use bare except

Description

[python linting] enforce E722: do not use bare except

Summary:
Generally using except: is a mistake since it catches everything
including SystemExit / KeyboardInterrupt / etc.... When we really
do want such a catch we should explicitly use except BaseException:,
otherwise we normally want except Exception: or even better, name
the specific exception that might occur.

Depends on D5204 D5206

Test Plan:

arc lint --everything
ninja check-all

Reviewers: #bitcoin_abc, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

Differential Revision: https://reviews.bitcoinabc.org/D5208

Details

Provenance
Mark Lundeberg <markblundeberg@users.noreply.github.com>Authored on Feb 7 2020, 16:46
FabienPushed on Feb 7 2020, 21:12
Reviewer
Restricted Project
Differential Revision
D5208: [python linting] enforce E722: do not use bare except
Parents
rSTAGINGc7af8f0ab549: Merge #13823: qa: quote path in authproxy for external multiwallets
Branches
Unknown
Tags
Unknown