AnsweredAssumed Answered

Arcpy Exist Gives Inconsistent results

Question asked by Paolo.Succi on Mar 31, 2020
Latest reply on Mar 31, 2020 by bixb0012

Since upgrading from 10.2 to 10.6 one of my scripts no longer works when it tries to use the CollectEvents tool. It has an issue reaching one of the layers saying it doesn't exist.

 

Sure enough, arcpy.Exists() returns False BUT the layer is grabbed using ListLayers() and it is one of two layers. I notice that if the layer is copied in two data frames, ListLayers() will grab both layers, but Exists() will only return True for one of them.

 

I can reproduce this issue with a new document and completely different datasets:

 

Is this a known bug or am I doing something wrong?

 

Thanks in advance!

Outcomes