[Python-ideas] Dunder method to make object str-like

Ethan Furman ethan at stoneleaf.us
Mon Apr 11 11:10:24 EDT 2016

On 04/11/2016 07:57 AM, Random832 wrote:

> Also, where is the .path attribute? It's documented
> <https://docs.python.org/3/library/pathlib.html#pathlib.PurePath.path>,
> but...
>>>> pathlib.Path(".").path
> Traceback (most recent call last):
>    File "<stdin>", line 1, in <module>
> AttributeError: 'PosixPath' object has no attribute 'path'

pathlib is provisional -- `.path` has been committed and will be 
available with the next releases (assuming we don't change it out for 
the protocol version).


More information about the Python-ideas mailing list