uvacw / inca

24 stars 6 forks source link

merge_weekend now passes empty list first #497

Closed mariekevh closed 5 years ago

mariekevh commented 5 years ago

Following error occured in softcosine analysis: Trying to find first element in the list, while list can be empty.

    if group[0]['_source'][sourcedate].weekday()==6:
IndexError: list index out of range 

Fixed by first passing if list is empty before trying to find first element in the list group.