Merge pull request #2449 from ryanpetrello/noisy-check-migrations

silence the noisy error that's printed w/ `awx-manage check_migrations`

Reviewed-by: https://github.com/softwarefactory-project-zuul[bot]
This commit is contained in:
softwarefactory-project-zuul[bot] 2018-10-16 18:04:05 +00:00 committed by GitHub
commit 6c868c7552
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -126,7 +126,8 @@ def _ctit_db_wrapper(trans_safe=False):
bottom_stack.close()
# Log the combined stack
if trans_safe:
logger.warning('Database settings are not available, using defaults, error:\n{}'.format(tb_string))
if 'check_migrations' not in sys.argv:
logger.warning('Database settings are not available, using defaults, error:\n{}'.format(tb_string))
else:
logger.error('Error modifying something related to database settings.\n{}'.format(tb_string))
finally: