Message373269
Use case: I want to see if a Path is a descendent of /tmp.
if filepath.parents[-2] == Path('tmp'):
turns into
if filepath.parents[len(filepath.parents)-2] == Path('tmp'): |
|
Date |
User |
Action |
Args |
2020-07-08 01:41:55 | maxballenger | set | recipients:
+ maxballenger, barry, pitrou, r.david.murray, akira, mdk, thejcannon, ju-sh, victorg |
2020-07-08 01:41:55 | maxballenger | set | messageid: <1594172515.46.0.545809771467.issue21041@roundup.psfhosted.org> |
2020-07-08 01:41:55 | maxballenger | link | issue21041 messages |
2020-07-08 01:41:55 | maxballenger | create | |
|