infoblox backend, TypeError: format requires a mapping

Bug #1730194 reported by Junbo Jiang
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Designate
Fix Released
Undecided
Junbo Jiang

Bug Description

With infoblox backend, failed to delete zone when the zone already delete in infoblox, the designate-worker display error

Traceback (most recent call last):
  File "/usr/lib64/python2.7/logging/__init__.py", line 851, in emit
    msg = self.format(record)
  File "/usr/lib64/python2.7/logging/__init__.py", line 724, in format
    return fmt.format(record)
  File "/usr/lib/python2.7/site-packages/oslo_log/formatters.py", line 362, in format
    return logging.Formatter.format(self, record)
  File "/usr/lib64/python2.7/logging/__init__.py", line 464, in format
    record.message = record.getMessage()
  File "/usr/lib64/python2.7/logging/__init__.py", line 328, in getMessage
    msg = msg % self.args
TypeError: format requires a mapping
Logged from file object_manipulator.py, line 199

there is a wrong args in designate/backend/impl_infoblox/object_manipulator.py file

190 def _delete_infoblox_object(self, obj_type, payload):
191 ib_object_ref = None
192 warn_msg = _('Infoblox %(obj_type)s will not be deleted because'
193 ' it cannot be found: %(payload)s')
194 try:
195 ib_object_ref = self._get_infoblox_object_or_none(obj_type,
196 payload)
197 if not ib_object_ref:
198 LOG.warning(warn_msg, obj_type, payload)

wrong args in LOG.warning, should be LOG.warning(warn_msg, {'obj_type': obj_type, 'payload' :payload})

Junbo Jiang (junbo)
Changed in designate:
assignee: nobody → junbo (junbo)
Changed in designate:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to designate (master)

Reviewed: https://review.openstack.org/517823
Committed: https://git.openstack.org/cgit/openstack/designate/commit/?id=33836169590c01c6236921f540b9c2798043bc81
Submitter: Zuul
Branch: master

commit 33836169590c01c6236921f540b9c2798043bc81
Author: junbo <email address hidden>
Date: Sun Nov 5 22:39:54 2017 +0800

    correct LOG.warning args in object_manipulator.py

    Change-Id: Ifa054afd6e0342f805eb7eccd08c921f740342c9
    Closes-Bug: #1730194

Changed in designate:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/designate 6.0.0.0b2

This issue was fixed in the openstack/designate 6.0.0.0b2 development milestone.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to designate (stable/pike)

Fix proposed to branch: stable/pike
Review: https://review.openstack.org/539436

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to designate (stable/pike)

Reviewed: https://review.openstack.org/539436
Committed: https://git.openstack.org/cgit/openstack/designate/commit/?id=62853fe28aba8ba0805614a738b86cce8a9edad6
Submitter: Zuul
Branch: stable/pike

commit 62853fe28aba8ba0805614a738b86cce8a9edad6
Author: junbo <email address hidden>
Date: Sun Nov 5 22:39:54 2017 +0800

    correct LOG.warning args in object_manipulator.py

    Change-Id: Ifa054afd6e0342f805eb7eccd08c921f740342c9
    Closes-Bug: #1730194
    (cherry picked from commit 33836169590c01c6236921f540b9c2798043bc81)

tags: added: in-stable-pike
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/designate 5.0.2

This issue was fixed in the openstack/designate 5.0.2 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.