Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
nomad-lab
nomad-FAIR
Commits
4b527494
Commit
4b527494
authored
Mar 07, 2019
by
Markus Scheidgen
Browse files
Improved exception handling to recover from rare unexpected errors.
parent
e5c345db
Pipeline
#44894
canceled with stages
in 5 minutes and 23 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
nomad/migration.py
View file @
4b527494
...
...
@@ -588,6 +588,7 @@ class NomadCOEMigration:
try
:
package_report
=
self
.
migrate_package
(
package
,
local
=
local
,
delete_local
=
delete_local
)
except
Exception
as
e
:
package_report
=
Report
()
logger
.
error
(
'unexpected exception while migrating packages'
,
exc_info
=
e
)
...
...
@@ -805,7 +806,11 @@ class NomadCOEMigration:
report
.
migrated_calcs
+=
1
calc_logger
=
logger
.
bind
(
calc_id
=
calc
[
'calc_id'
],
mainfile
=
calc
[
'mainfile'
])
if
not
self
.
_validate
(
calc
,
source_calc_with_metadata
,
calc_logger
):
try
:
if
not
self
.
_validate
(
calc
,
source_calc_with_metadata
,
calc_logger
):
report
.
calcs_with_diffs
+=
1
except
Exception
as
e
:
logger
.
warning
(
'unexpected exception during validation'
,
exc_info
=
e
)
report
.
calcs_with_diffs
+=
1
else
:
calc_logger
.
info
(
'processed a calc that has no source'
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment