summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Estabrook <jestabro@sentrium.io>2019-11-21 12:12:41 -0600
committerJohn Estabrook <jestabro@sentrium.io>2019-11-21 14:33:00 -0600
commitb1ec270d9d1c2695815debe619ce186d84596c57 (patch)
treeb9c9d5cfc2009ff7175af6b03431ead28e6932b6
parent7f0e880400df72d103efb02263658da576a56b80 (diff)
downloadvyos-1x-b1ec270d9d1c2695815debe619ce186d84596c57.tar.gz
vyos-1x-b1ec270d9d1c2695815debe619ce186d84596c57.zip
T1818: Print name of migration script on failure
-rw-r--r--python/vyos/migrator.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/python/vyos/migrator.py b/python/vyos/migrator.py
index 06db5a6df..86e1af183 100644
--- a/python/vyos/migrator.py
+++ b/python/vyos/migrator.py
@@ -125,8 +125,9 @@ class Migrator(object):
self._config_file])
except FileNotFoundError:
pass
- except subprocess.CalledProcessError as err:
- print("Called process error: {}.".format(err))
+ except Exception as err:
+ print("\nMigration script error: {0}: {1}."
+ "".format(migrate_script, err))
sys.exit(1)
if log: