Title: timeit accepts -c/--clock and -t/--time without any functionality
Type: Stage:
Components: Library (Lib) Versions: Python 3.11, Python 3.10
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: lemburg
Priority: normal Keywords:

Created on 2021-11-29 14:15 by lemburg, last changed 2021-11-29 14:15 by lemburg.

Messages (1)
msg407276 - (view) Author: Marc-Andre Lemburg (lemburg) * (Python committer) Date: 2021-11-29 14:15
From the code:

        opts, args = getopt.getopt(args, "n:u:s:r:tcpvh",
                                   ["number=", "setup=", "repeat=",
                                    "time", "clock", "process",
                                    "verbose", "unit=", "help"])

but the options -c and -t are not used in the subsequent code.

This can lead to situations where if you mistype e.g. -s as -c, you get completely wrong results (see for an example).
Date User Action Args
2021-11-29 14:15:45lemburgcreate