fixed parsing and bettered error reporting