Ajoutez à une liste de valeurs ldictionnaires

#list.append returns None, since it is an in-place operation and you are 
#assigning it back to dic[key]. So, the next time when you do 
#dic.get(key, []).append you are actually doing None.append. 
#That is why it is failing. Instead, you can simply do
dates_dict.setdefault(key, []).append(date)
#or 
from collections import defaultdict
dates_dict = defaultdict(list)
for key, date in cur:
    dates_dict[key].append(date)
Real Raccoon