Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Use sort for the choices of '-s'
  • Loading branch information
matrixise committed Oct 17, 2018
commit fef9db20d34da61602fbf2b2de80f39ed9758dc2
2 changes: 1 addition & 1 deletion Lib/cProfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ def main():
parser.add_option('-s', '--sort', dest="sort",
help="Sort order when printing to stdout, based on pstats.Stats class",
default=-1,
choices=list(pstats.Stats.sort_arg_dict_default))
choices=sorted(pstats.Stats.sort_arg_dict_default))
parser.add_option('-m', dest="module", action="store_true",
help="Profile a library module", default=False)

Expand Down