[issue45179] List.sort ERROR

2021-09-12 Thread Steven D'Aprano
Steven D'Aprano added the comment: Wait, are you talking about the list appearing to be empty during the sort? That's expected behaviour and not a bug: https://docs.python.org/3/library/stdtypes.html#list.sort I'm going to close this issue as Not A Bug. If the problem is something else, ple

[issue45179] List.sort ERROR

2021-09-12 Thread Steven D'Aprano
Steven D'Aprano added the comment: Sorry, it is not clear what you think is the bug. What output do you expect? When I run the code, F and G are correctly sorted. -- nosy: +steven.daprano ___ Python tracker ___

[issue45179] List.sort ERROR

2021-09-12 Thread meng_xiaohui
New submission from meng_xiaohui <1294886...@qq.com>: There is a bug in this method: L.sort(key=None, reverse=False) -> None L is an instance of list. Argument key is a function. If L is in the body of argument key, L is always an empty list in test case, which is wrong = Run