csv selection error handling fixed