Public bug reported:

In nova/nova/virt/vmwareapi/vm_util.py, function get_cluster_ref_by_name has a 
Potential bug
    all_clusters = get_all_cluster_mors(session)
    for cluster in all_clusters:
if all_clusters in None, then this code may cause error: TypeError: 'NoneType' 
object is not iterable.
so,you must judge all_clusters is not None type, then do the code : for cluster 
in all_clusters, otherwise return {}

** Affects: nova
     Importance: Undecided
     Assignee: linbing (hawkerous)
         Status: Fix Released

** Changed in: nova
     Assignee: (unassigned) => linbing (hawkerous)

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1525797

Title:
  vmwareapi get clusters error

Status in OpenStack Compute (nova):
  Fix Released

Bug description:
  In nova/nova/virt/vmwareapi/vm_util.py, function get_cluster_ref_by_name has 
a Potential bug
      all_clusters = get_all_cluster_mors(session)
      for cluster in all_clusters:
  if all_clusters in None, then this code may cause error: TypeError: 
'NoneType' object is not iterable.
  so,you must judge all_clusters is not None type, then do the code : for 
cluster in all_clusters, otherwise return {}

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1525797/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp

Reply via email to