mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
Catch environment errors when reading 3MF archive metadata
The file could get deleted in the meanwhile. Fixes Sentry issue CURA-1CK.
This commit is contained in:
parent
9ffc6bc705
commit
b740fda491
1 changed files with 3 additions and 0 deletions
|
@ -805,6 +805,9 @@ class ThreeMFWorkspaceReader(WorkspaceReader):
|
|||
except zipfile.BadZipFile:
|
||||
Logger.logException("w", "Unable to retrieve metadata from {fname}: 3MF archive is corrupt.".format(fname = file_name))
|
||||
return result
|
||||
except EnvironmentError as e:
|
||||
Logger.logException("w", "Unable to retrieve metadata from {fname}: File is inaccessible. Error: {err}".format(fname = file_name, err = str(e)))
|
||||
return result
|
||||
|
||||
metadata_files = [name for name in archive.namelist() if name.endswith("plugin_metadata.json")]
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue