Shape field for layer returns as VISIBLE in arcpy even if hidden. Confirmed bug for a long time, but not fixed

03-15-2022 01:34 PM
Occasional Contributor

This is a duplicate of this issue posted in 2017:

Bug report here:

I need to publish a webmap to Online from Pro with hundreds of layers. In Pro, I need to turn the "Shape" field visible, since I can't publish as a Webmap unless the Shape fields are visible

So, I tried to use arcpy to turn the "Shape" fields visibility to "VISIBLE"



for m in aprx.listMaps():
     for lyr in m.listLayers():
          if not lyr.isGroupLayer:
               desc = arcpy.Describe(lyr)
               for i in range(0,desc.fieldInfo.count):
                    if desc.fieldInfo.getFieldName(i) == "Shape":



 This returns VISIBLE for all "Shape" fields in all layers, even if they're not in Fields view.

Any way to avoid going through each layer and updating visibility by hand?

The bug report indicates that it was updated last week, but it doesn't seem like there's any plan to fix this.

Application Developer, GeoMarvel
0 Kudos
1 Reply
MVP Esteemed Contributor

NIM101408: The fieldinfo.getvisible method always returns Visib.. (

Will Not Be Addressed

The development team has considered the issue or request and concluded it will not be addressed. The issue's Additional Information section may contain further explanation.

Additional Information
We apologize that we were unable to address this issue within the current product support cycle. If the issue continues to affect your work in a supported release, please contact Technical Support.

I would contact tech support and see if they can provide an answer as to why this is not possible

... sort of retired...
0 Kudos