Hi all,

I am using Contrail 3.2.5.0.
I've noticed a Python exception logged in contrail-api.log when deleting a 
network or an IPAM:

The above is a description of an error in a Python program.  Here is the call 
trace:

Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/vnc_cfg_api_server/vnc_db.py", line 
323, in _dbe_subscribe_callback
    self._dbe_delete_notification(oper_info)
  File "/usr/lib/python2.7/site-packages/vnc_cfg_api_server/vnc_db.py", line 
425, in _dbe_delete_notification
    r_class.dbe_delete_notification(obj_info, obj_dict)
  File "/usr/lib/python2.7/site-packages/vnc_cfg_api_server/vnc_cfg_types.py", 
line 1475, in dbe_delete_notification
    cls.addr_mgmt.net_delete_notify(obj_ids, obj_dict)
  File "/usr/lib/python2.7/site-packages/vnc_cfg_api_server/vnc_addr_mgmt.py", 
line 785, in net_delete_notify
    if obj_id in self._subnet_objs:
TypeError: unhashable type: 'dict'

In both cases, the error happens when trying to execute the following line from 
vnc_cfg_api_server/vnc_addr_mgmt.py:
if obj_id in self._subnet_objs:

This line appears in the following functions:
net_delete_notify
ipam_delete_notify

I've added some logs and I have noticed that obj_id is a dictionary and it 
can't be a key in the dictionary self._subnet_objs.
The exception appears because a dictionary is mutable in Python and it can't be 
used as a key for another dictionary.

However, even if the exception occurs, the network/IPAM is successfully deleted.

Thanks,
Anda
_______________________________________________
Dev mailing list
[email protected]
http://lists.opencontrail.org/mailman/listinfo/dev_lists.opencontrail.org

Reply via email to