Message346107
I implemented an onerror callback for tempfile.TemporaryDirectory() and confirmed that it cannot be used to unmount a mount point. Attempting to unmount the mount point from within the callback results in a resource busy error. It may be related to shutil.rmtree() holding an open file descriptor to the parent directory of the mount point.
I uploaded the program I used for testing on macOS (test-mounted-image.py). The subprocess.run() calls can be modified to run it on other platforms. |
|
Date |
User |
Action |
Args |
2019-06-20 08:04:55 | Jeffrey.Kintscher | set | recipients:
+ Jeffrey.Kintscher, giampaolo.rodola, tarek, riccardomurri, josh.r |
2019-06-20 08:04:55 | Jeffrey.Kintscher | set | messageid: <1561017895.23.0.435588102528.issue36422@roundup.psfhosted.org> |
2019-06-20 08:04:55 | Jeffrey.Kintscher | link | issue36422 messages |
2019-06-20 08:04:55 | Jeffrey.Kintscher | create | |
|