Enable flake8-bugbear linting and fix raised issues

Signed-off-by: Alfred Wingate <parona@protonmail.com>
This commit is contained in:
Alfred Wingate
2023-11-16 06:25:40 +02:00
parent 49f1fbbad1
commit 443b5f62fd
4 changed files with 5 additions and 6 deletions

View File

@ -283,8 +283,8 @@ def parse_args():
# apply getopts to command line, show partial help on failure
try:
opts, args = getopt.getopt(sys.argv[1:], short_opts, long_opts)
except getopt.GetoptError:
raise ParseArgsError(opts_mode + "-options")
except getopt.GetoptError as exc:
raise ParseArgsError(opts_mode + "-options") from exc
# set options accordingly
option_switch(opts)