This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author brett.cannon
Recipients Nophke, brett.cannon
Date 2019-06-03.18:58:59
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1559588339.78.0.495909885096.issue37130@roundup.psfhosted.org>
In-reply-to
Content
The inconsistency is a bit weird. Looking at https://github.com/python/cpython/blob/master/Lib/pathlib.py#L825 the question is why is self.name not being set for '.' but it is for '..'. I suspect there's special-casing for '.' somewhere that sets self.name to '' for '.' but leaves it alone in all other instances.

Based on what with_name() is supposed to do I would argue that '..' shouldn't work since without a filename the with_name() method makes no sense.
History
Date User Action Args
2019-06-03 18:58:59brett.cannonsetrecipients: + brett.cannon, Nophke
2019-06-03 18:58:59brett.cannonsetmessageid: <1559588339.78.0.495909885096.issue37130@roundup.psfhosted.org>
2019-06-03 18:58:59brett.cannonlinkissue37130 messages
2019-06-03 18:58:59brett.cannoncreate