Make the event thread more robust

  - if it fails, log and restart after a delay
  - replace the assert (which would look like silent failure) with an error message