Message257593
I thought about it some more, and personally I'd prefer each function to do `str(path)` internally rather than `if hasattr(p, 'path'): p = p.path`. Even if it means we'll have to deal with "where did that file named '<type object at ...>' come from?!" errors. I think it's clumsy that the path protocol is to access `path.path`. We already have a protocol for getting a string out of an object and it's `str(object)`. I think we should use it even if it makes debugging harder in the case where someone mistakenly passes a non-path object to a function that wants a path. (And without using `isinstance` either.) |
|
Date |
User |
Action |
Args |
2016-01-06 09:38:47 | cool-RR | set | recipients:
+ cool-RR, gvanrossum, barry, brett.cannon, georg.brandl, pitrou, bronger, ezio.melotti, Arfrever, r.david.murray, daniel.ugra, tshepang |
2016-01-06 09:38:47 | cool-RR | set | messageid: <1452073127.82.0.264182529507.issue22570@psf.upfronthosting.co.za> |
2016-01-06 09:38:47 | cool-RR | link | issue22570 messages |
2016-01-06 09:38:47 | cool-RR | create | |
|