I’m using Odoo and I would like to make a comparison between two dictionaries without using any library. This comparison should return a dictionary with the differences. So here are my two dictionaries :
list1 = {
'Office Furniture':
[
{
'name': 'Office chairs can harm your floor: protect it.',
'qty': 3
},
]
}
list2 = {
'Office Furniture':
[
{
'name': 'Office chairs can harm your floor: protect it.',
'qty': 3
},
{
'name': '160x80cm, with large legs.',
'qty': 1
}
],
'Services':
[
{
'name': 'designing',
'qty': 1
}
]
}
I would like, without any library, to got the differences between those two dictionaries like this:
differences = {
'Office Furniture':
[
{
'name': '160x80cm, with large legs.',
'qty': 1
}
],
'Services':
[
{
'name': 'designing',
'qty': 1
}
]
}
Thanks a lot for your help !