Updated error handling - scanner should be finally (mostly) completed now...