improved error reporting for console applications