fix event_data, better error logging