Hi Boya, This is indeed an argparse glitch. I am not aware of a way to specify an option so that the next CL argument must be considered as an argument for that option. https://stackoverflow.com/a/16175115/11350445 confirms this behavior and recommends using an '=' sign to specify an option's argument in that case. Prepending a space to the argument as you did also is a valid workaround.
I believe this behavior is not directly specified by argparse as "--an-option '--foo bar'" will fail if --foo is a valid option and succeed if not while "--an-option '--foo' will always fail, whether foo is a valid argument or not (according to my very rapid testing). This might be a bug so if you feel like doing a little more testing, you could fill an issue on the python bug tracker. Best, Gabriel _______________________________________________ gem5-users mailing list -- gem5-users@gem5.org To unsubscribe send an email to gem5-users-le...@gem5.org %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s