fix xpath error reporting