nicer error message for failed string parsing