[issue32040] Sorting pahtlib.Paths does give the same order as sorting the (string) filenames of that pathlib.Paths
QbLearningPython
report at bugs.python.org
Thu Nov 16 11:12:43 EST 2017
QbLearningPython <quibizo at hotmail.com> added the comment:
Thanks, serhiy.storchaka, for your answer.
I am not fully convinced.
You have described the current behaviour of the pathlib package.
But let me ask: should be this the desired behaviour?
Since string filenames and pathlib.Paths are different ways to refer to the same object (a path in a filesystem), should not be they behaved in the same way when sorting?
You pointed out that the current behaviour is "more natural order" for pathlib.Paths. I am not truly sure about that. Can you please provide any citation or additional information about that?
Thank you.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue32040>
_______________________________________
More information about the Python-bugs-list
mailing list