Fix _find_related_obj() RuntimeError output

When _find_related_obj() raises a RuntimeError, the output
is something like this:

RuntimeError: (u'revises_on_change relationships must have
                 load_on_pending set to True to bump parent
                 revisions on create: %s', 'networks')

Should be using a % to print the message correctly.

Trivialfix

Change-Id: I90f9ef7c6de00ae388adb303c0e22a2a6c112e88
This commit is contained in:
Brian Haley 2019-02-14 15:18:19 -05:00
parent 3b8d3b6f1b
commit f4eeac73e3
1 changed files with 2 additions and 2 deletions

View File

@ -105,8 +105,8 @@ class RevisionPlugin(service_base.ServicePluginBase):
if not rel.load_on_pending:
raise RuntimeError(_("revises_on_change relationships must "
"have load_on_pending set to True to "
"bump parent revisions on create: %s"),
relationship_col)
"bump parent revisions on create: %s")
% relationship_col)
def _clear_rev_bumped_flags(self, session):
"""This clears all flags on commit/rollback to enable rev bumps."""