More error handling, use timeouts

Add another error handler, and make them all use setTimeout to delay the
retry for 1 second.

SetTimeout doesn't seem to be delaying properly, however.