From 79cc6ec897626f9601bc8af0060cf53872d84026 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Thu, 25 Jun 2020 09:47:59 +0200 Subject: [PATCH] Also report failure if the file system can't handle the archive contents For instance if the file name is too long for this file system, if the computer is running out of disk space or if there is a general failure to write here. Fixes Sentry issue CURA-YQ. --- cura/Backups/Backup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cura/Backups/Backup.py b/cura/Backups/Backup.py index 44e1feef30..61f1aa686c 100644 --- a/cura/Backups/Backup.py +++ b/cura/Backups/Backup.py @@ -169,7 +169,7 @@ class Backup: Logger.log("d", "Extracting backup to location: %s", target_path) try: archive.extractall(target_path) - except PermissionError: - Logger.logException("e", "Unable to extract the backup due to permission errors") + except (PermissionError, EnvironmentError): + Logger.logException("e", "Unable to extract the backup due to permission or file system errors.") return False return True