Q1
1 |
2019-07-31 17:23:44,663 - jms_perm.py - INFO - perm_key: (['名字(zhi.ming)'], ['v-hostname.hx(10.10.100.100)']) |
A1
Python dict的key必须为hashable
问题中key中包含list或dict类型,所以报错.
可哈希的元素有:int, float, str, tuple
不可哈希的元素有:list, set, dict
简单说在元素生命周期中,元素值会发布变动的为unhashable
近期评论