From a601f8ddd7b8cd3a9cecbdb7fb16788becadb667 Mon Sep 17 00:00:00 2001 From: drebs Date: Fri, 19 Aug 2016 14:51:58 -0300 Subject: [pkg] log errors and continue with next db in couch schema migration script --- scripts/migration/0.8.2/migrate_couch_schema/__init__.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'scripts/migration') diff --git a/scripts/migration/0.8.2/migrate_couch_schema/__init__.py b/scripts/migration/0.8.2/migrate_couch_schema/__init__.py index c3eb9c3d..c9ec4910 100644 --- a/scripts/migration/0.8.2/migrate_couch_schema/__init__.py +++ b/scripts/migration/0.8.2/migrate_couch_schema/__init__.py @@ -77,8 +77,12 @@ def migrate(args, target_version): logger.warning("skipping not migrateable user db: %s" % dbname) continue logger.info("starting migration of user db: %s" % dbname) - _migrate_user_db(db, args.do_migrate) - logger.info("finished migration of user db: %s" % dbname) + try: + _migrate_user_db(db, args.do_migrate) + logger.info("finished migration of user db: %s" % dbname) + except: + logger.exception('Error migrating user db: %s' % dbname) + logger.error('Continuing with next database.') logger.info('finished couch schema migration to %s' % target_version) -- cgit v1.2.3