improve karma error reporting