Skip to content

Commit

Permalink
Capture ImportTestRun specifically
Browse files Browse the repository at this point in the history
  • Loading branch information
GeigerJ2 committed May 17, 2024
1 parent be0db3c commit 2bc6f5e
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/aiida/cmdline/commands/cmd_archive.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
from aiida.common.exceptions import CorruptStorage, IncompatibleStorageSchema, UnreachableStorage
from aiida.common.links import GraphTraversalRules
from aiida.common.log import AIIDA_LOGGER
from aiida.tools.archive.exceptions import ImportTestRun

EXTRAS_MODE_EXISTING = ['keep_existing', 'update_existing', 'mirror', 'none']
EXTRAS_MODE_NEW = ['import', 'none']
Expand Down Expand Up @@ -521,6 +522,12 @@ def _import_archive_and_migrate(
)
else:
_echo_exception(f'an exception occurred while trying to import the archive {archive}', exception)
except ImportTestRun:
echo.echo_success(
f'Import dry-run of archive {archive} terminated successfully. Profile storage unmodified.'
)
return

except Exception as exception:
_echo_exception(f'an exception occurred while trying to import the archive {archive}', exception)

Expand Down

0 comments on commit 2bc6f5e

Please sign in to comment.