diff options
-rw-r--r-- | lib/spack/spack/cmd/common/arguments.py | 2 | ||||
-rw-r--r-- | lib/spack/spack/cmd/find.py | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/lib/spack/spack/cmd/common/arguments.py b/lib/spack/spack/cmd/common/arguments.py index 53e75a4f2c..f091b9cf75 100644 --- a/lib/spack/spack/cmd/common/arguments.py +++ b/lib/spack/spack/cmd/common/arguments.py @@ -75,7 +75,7 @@ class ConstraintAction(argparse.Action): _arguments['constraint'] = Args( - 'constraint', nargs='*', action=ConstraintAction, + 'constraint', nargs=argparse.REMAINDER, action=ConstraintAction, help='Constraint to select a subset of installed packages') _arguments['module_type'] = Args( diff --git a/lib/spack/spack/cmd/find.py b/lib/spack/spack/cmd/find.py index ab0b29c30e..ecd6ae2822 100644 --- a/lib/spack/spack/cmd/find.py +++ b/lib/spack/spack/cmd/find.py @@ -117,7 +117,8 @@ def find(parser, args): # Exit early if no package matches the constraint if not query_specs and args.constraint: - msg = "No package matches the query: {0}".format(args.constraint) + msg = "No package matches the query: {0}".format( + ' '.join(args.constraint)) tty.msg(msg) return |