GnuPG's `--debug-level` ints are only required to be ≥ 1.

They aren't required to be ≤ 9, as the previous check in
`gnupg._meta.GPGBase._make_args()` ensured. That is, calling GnuPG from
the commandline, doing:

  $ gpg --debug-level=100000 …

is valid, so we should also accept 10000 (even though everything > 8
means the same debug level anyway).
fix/44-verbose-arg
Isis Lovecruft 2014-09-24 22:07:42 +00:00
parent 7c56dd5864
commit d5fe2d7cc4
No known key found for this signature in database
GPG Key ID: 18C16EC5F9F1D673
1 changed files with 1 additions and 1 deletions

View File

@ -482,7 +482,7 @@ class GPGBase(object):
cmd.append('--debug-all')
if ((isinstance(self.verbose, str) and
self.verbose in ['basic', 'advanced', 'expert', 'guru'])
or (isinstance(self.verbose, int) and (1<=self.verbose<=9))):
or (isinstance(self.verbose, int) and (self.verbose>=1))):
cmd.append('--debug-level %s' % self.verbose)
return cmd