Message382095
Ok, so I just made a patch implementing this using os.access. It adds the following methods to pathlib.Path
- can_read = Returns True if the user can read the path
- can_write = Returns True if the user can write on the path
- can_execute = Returns True if the user can execute the path
These are implemented via
- return os.access(str(self), os.R_OK)
- return os.access(str(self), os.W_OK)
- return os.access(str(self), os.X_OK)
respectively. |
|
Date |
User |
Action |
Args |
2020-11-29 21:46:04 | ThatXliner | set | recipients:
+ ThatXliner, steven.daprano |
2020-11-29 21:46:04 | ThatXliner | set | messageid: <1606686364.4.0.743817463192.issue42497@roundup.psfhosted.org> |
2020-11-29 21:46:04 | ThatXliner | link | issue42497 messages |
2020-11-29 21:46:04 | ThatXliner | create | |
|