def put(dct, entry):
 id = int(entry['id'])
 if (id in dct):
  if (entry == dct[id]):
   pass
  else:
   print entry
   print dct[id]
   assert False
 else:
  dct[id] = entry

def put ( dct , entry ) : id = int ( entry [ 'id' ] ) if ( id in dct ) : if ( entry == dct [ id ] ) : pass else : print entry print dct [ id ] assert False else : dct [ id ] = entry
default function for handling put requests .