fix handling of existence error in trace mode