commit 6fbddcb4b629608a6b5ff556990c13563a36f858
Author: ZhiQiang Fan <email address hidden>
Date: Mon Mar 24 15:29:01 2014 +0800
Avoid AttributeError in servers.Server.__repr__
servers.Server represents various object now, and some of them may
don't have attribute 'name', for example, the interface_list() result
object. It will cause AttributeError when we try to format string with
such object, so I add a check for the 'name' attribute in __repr__
method, it will use 'unknown-name' instead when 'name' is not found.
Reviewed: https:/ /review. openstack. org/82443 /git.openstack. org/cgit/ openstack/ python- novaclient/ commit/ ?id=6fbddcb4b62 9608a6b5ff55699 0c13563a36f858
Committed: https:/
Submitter: Jenkins
Branch: master
commit 6fbddcb4b629608 a6b5ff556990c13 563a36f858
Author: ZhiQiang Fan <email address hidden>
Date: Mon Mar 24 15:29:01 2014 +0800
Avoid AttributeError in servers. Server. __repr_ _
servers.Server represents various object now, and some of them may
don't have attribute 'name', for example, the interface_list() result
object. It will cause AttributeError when we try to format string with
such object, so I add a check for the 'name' attribute in __repr__
method, it will use 'unknown-name' instead when 'name' is not found.
Change-Id: If4757d5d737217 74543d58a4cc875 710a6013f34
Closes-Bug: #1280453