error and faulty input handling