File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1259,7 +1259,12 @@ def check_vendored_status(self):
12591259
12601260def parse_args (args ):
12611261 """Parse the command line arguments that the python script needs."""
1262- parser = argparse .ArgumentParser (add_help = False )
1262+
1263+ # Pass allow_abbrev=False to remove support for inexact matches (e.g.,
1264+ # `--json` turning on `--json-output`). The argument list here is partial,
1265+ # most flags are matched in the Rust bootstrap code. This prevents the the
1266+ # default ambiguity checks in argparse from functioning correctly.
1267+ parser = argparse .ArgumentParser (add_help = False , allow_abbrev = False )
12631268 parser .add_argument ("-h" , "--help" , action = "store_true" )
12641269 parser .add_argument ("--config" )
12651270 parser .add_argument ("--build-dir" )
Original file line number Diff line number Diff line change @@ -616,4 +616,9 @@ pub const CONFIG_CHANGE_HISTORY: &[ChangeInfo] = &[
616616 severity : ChangeSeverity :: Warning ,
617617 summary : "`x.py test --no-doc` is renamed to `--all-targets`. Additionally `--tests` is added which only executes unit and integration tests." ,
618618 } ,
619+ ChangeInfo {
620+ change_id : 154508 ,
621+ severity : ChangeSeverity :: Info ,
622+ summary : "`x.py` stopped accepting partial argument names. Use full names to avoid errors." ,
623+ } ,
619624] ;
You can’t perform that action at this time.
0 commit comments