It seems that you do not need to fully write an option to a conda command.
For example you could write
conda install numpy --dr
or
conda install numpy --dry-r
and both these commands would be equivalent to
conda install numpy --dry-run
on the other hand if you write
conda install numpy --drgvwfgv
then you get an error.
I find this behavior quite odd and maybe a bit dangerous. Is this expected?
conda
uses argparse to parse command line arguments. This allows by default:
allow_abbrev – Allows long options to be abbreviated if the abbreviation is unambiguous. (default: True)
So this is expected behaviour. I don’t really see, how this is “dangerous” because it only works when you actually write a unique prefix of a long argument.
Whether or not this is “odd” is of course personal opinion, but seems to be generally acceptable enough that it is the default of pythons built-in argument parser
1