improve error reporting and add rolling timeout