-
Notifications
You must be signed in to change notification settings - Fork 89
Description
Launching the script after downloading repo fails with AssertionError:
Traceback (most recent call last): File "/<REDACTED>/tools/onedrive_user_enum/./onedrive_enum.py", line 1087, in <module> main() File "/<REDACTED>/tools/onedrive_user_enum/./onedrive_enum.py", line 816, in main args = parser.parse_args() File "/usr/lib/python3.10/argparse.py", line 1845, in parse_args args, argv = self.parse_known_args(args, namespace) File "/usr/lib/python3.10/argparse.py", line 1878, in parse_known_args namespace, args = self._parse_known_args(args, namespace) File "/usr/lib/python3.10/argparse.py", line 2091, in _parse_known_args start_index = consume_optional(start_index) File "/usr/lib/python3.10/argparse.py", line 2031, in consume_optional take_action(action, args, option_string) File "/usr/lib/python3.10/argparse.py", line 1955, in take_action action(self, namespace, argument_values, option_string) File "/usr/lib/python3.10/argparse.py", line 1118, in __call__ parser.print_help() File "/usr/lib/python3.10/argparse.py", line 2579, in print_help self._print_message(self.format_help(), file) File "/usr/lib/python3.10/argparse.py", line 2563, in format_help return formatter.format_help() File "/usr/lib/python3.10/argparse.py", line 295, in format_help help = self._root_section.format_help() File "/usr/lib/python3.10/argparse.py", line 226, in format_help item_help = join([func(*args) for func, args in self.items]) File "/usr/lib/python3.10/argparse.py", line 226, in <listcomp> item_help = join([func(*args) for func, args in self.items]) File "/usr/lib/python3.10/argparse.py", line 350, in _format_usage assert ' '.join(opt_parts) == opt_usage AssertionError
WORKAROUND:
This can be resolved by removing the empty metavar string from the end of most of the argparse arguments.