From 3ead0cb6ebffcb0e67ee35e387cde6019c2ab89a Mon Sep 17 00:00:00 2001 From: Tim Rakowski Date: Mon, 12 Mar 2018 20:29:20 +0100 Subject: [PATCH] Fixed 'pip install --user catkin_tools' (#488) pip passes `--user --prefix=` when the user calls `pip install --user`, which conflicted with the mutually_exclusive_group being used to parse these arguments. The mutually_exclusive_group is not necessary since pip prevents the user from passing `--user` together with `--prefix` anyhow. By not checking it here again, we can accept pip passing `--user --prefix=` to us. --- setup.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/setup.py b/setup.py index b463d6be..59845771 100644 --- a/setup.py +++ b/setup.py @@ -99,9 +99,8 @@ def run(self): 'catkin_tools-completion.bash'))) parser = argparse.ArgumentParser(add_help=False) -prefix_group = parser.add_mutually_exclusive_group() -prefix_group.add_argument('--user', '--home', action='store_true') -prefix_group.add_argument('--prefix', default=None) +parser.add_argument('--user', '--home', action='store_true') +parser.add_argument('--prefix', default=None) opts, _ = parser.parse_known_args(sys.argv) userbase = site.getuserbase() if opts.user else None