Get a list of values from a list of dictionaries in python,[d['key'] for d in l if 'key' in d]