improved error handling in Mojo::IOLoop::Client