better error reporting when sending