Catch OSError(errno.ENOSPC) and PermissionError

When the destination drive is not writable or has insufficient space,
these exceptions are raised during `run_installer`. Unless they are
caught and dealt with, `aqtinstall` requests that the user file a bug
report. This change catches these errors and prints a nice error message
instead of requesting a bug report.
This commit is contained in:
Dave Dalcino
2023-03-13 17:47:09 -07:00
parent 702a0246ac
commit 8dd56ff461
3 changed files with 55 additions and 7 deletions

View File

@@ -102,3 +102,11 @@ class UpdaterError(AqtException):
class OutOfMemory(AqtException):
pass
class OutOfDiskSpace(AqtException):
pass
class DiskAccessNotPermitted(AqtException):
pass