diff --git a/cis_proc.py b/cis_proc.py index f8fe118..e4776a6 100755 --- a/cis_proc.py +++ b/cis_proc.py @@ -74,11 +74,10 @@ def main(argv=None): if not op.isfile(args.config): raise ValueError('Argument "config" must be an existing file.') - try: - n_procs = int(args.n_procs) - except: + if args.n_procs < 1: raise ValueError('Argument "n_procs" must be positive integer greater ' 'than zero.') + n_procs = args.n_procs with open(args.config, 'r') as fo: config_options = json.load(fo)