Merge pull request #5836 from ryanpetrello/migrate-error

fix scary error message on initial (install time) awx-manage migrate

Reviewed-by: https://github.com/apps/softwarefactory-project-zuul
This commit is contained in:
softwarefactory-project-zuul[bot] 2020-02-06 17:31:40 +00:00 committed by GitHub
commit 96bbbdd5c9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -87,7 +87,7 @@ def _ctit_db_wrapper(trans_safe=False):
yield
except DBError:
if trans_safe:
if 'check_migrations' not in sys.argv:
if 'migrate' not in sys.argv and 'check_migrations' not in sys.argv:
logger.exception('Database settings are not available, using defaults.')
else:
logger.exception('Error modifying something related to database settings.')