<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Describe() breaks on coverages in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1249523#M66590</link>
    <description>&lt;P&gt;I ended up just resetting the environment to the original directory after appending all the feature classes.&lt;/P&gt;</description>
    <pubDate>Thu, 19 Jan 2023 16:18:27 GMT</pubDate>
    <dc:creator>AlfredBaldenweck</dc:creator>
    <dc:date>2023-01-19T16:18:27Z</dc:date>
    <item>
      <title>Describe() breaks on coverages</title>
      <link>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1249108#M66587</link>
      <description>&lt;P&gt;Hi all,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am running into something really weird and I was wondering if anyone could tell me what's happening here.&lt;/P&gt;&lt;P&gt;I have a coverage that I'm trying to describe.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AlfredBaldenweck_0-1674057934991.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/60648i1B787D78CBDFC473/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AlfredBaldenweck_0-1674057934991.png" alt="AlfredBaldenweck_0-1674057934991.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt; fdList = arcpy.ListDatasets()

# Print feature classes in Datasets   
    if fdList:
        for fd in fdList:
            print(fd)
            desc= (arcpy.da.Describe(fd))
            #print(desc)
            print(desc['catalogPath'], desc['datasetType'])
            if desc['datasetType'] == "FeatureDataset":
                print("true")

''' Yields:'''
# T:\...\nhd FeatureDataset
# true
# T:\...\nhdpt FeatureDataset
# true
# T:\...\nhdduu FeatureDataset
# true&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;However, if I try to do anything with it, I get an error:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;    if fdList:
        for fd in fdList:
            #print(fd)
            desc= (arcpy.da.Describe(fd))
            #print(desc)
            print(desc['catalogPath'], desc['datasetType'])
            if desc['datasetType'] == "FeatureDataset":
                print("true")
                
            if desc['datasetType'] == "FeatureDataset":
                arcpy.env.workspace = os.path.join(dirP, fd)
                fdFCList =arcpy.ListFeatureClasses()
                if fdFCList:
                    for fc in fdFCList:
                        fList.append([os.path.join(dirP, fd, fc)])
'''Yields:''
# T:\...\nhd FeatureDataset
# true
# ---------------------------------------------------------------------------
# ValueError                                Traceback (most recent call last)
Line 4:    desc= (arcpy.da.Describe(fd))

ValueError: Object: Error in accessing describe&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;In short, it'll do the first one or two feature datasets, then it'll break somehow.&lt;/P&gt;&lt;P&gt;Sometimes it does just the first, sometimes it does the first two.&lt;/P&gt;&lt;P&gt;Has anyone encountered anything like this before?&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Edit: It looks like it has to do with setting the environment. How do I fix this? It worked fine for feature datasets in GDBs.&lt;/P&gt;</description>
      <pubDate>Wed, 18 Jan 2023 16:22:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1249108#M66587</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2023-01-18T16:22:08Z</dc:date>
    </item>
    <item>
      <title>Re: Describe() breaks on coverages</title>
      <link>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1249523#M66590</link>
      <description>&lt;P&gt;I ended up just resetting the environment to the original directory after appending all the feature classes.&lt;/P&gt;</description>
      <pubDate>Thu, 19 Jan 2023 16:18:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1249523#M66590</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2023-01-19T16:18:27Z</dc:date>
    </item>
    <item>
      <title>Re: Describe() breaks on coverages</title>
      <link>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1383965#M69909</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/458875"&gt;@AlfredBaldenweck&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I encountered the same error message with you in my Python script that previously worked fine with the same code. Could you explain how to reset the environment within the script?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Donghee&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 19 Feb 2024 08:07:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1383965#M69909</guid>
      <dc:creator>dongheekim</dc:creator>
      <dc:date>2024-02-19T08:07:10Z</dc:date>
    </item>
    <item>
      <title>Re: Describe() breaks on coverages</title>
      <link>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1384393#M69919</link>
      <description>&lt;P&gt;Yeah of course. It's just doing this:&lt;/P&gt;&lt;LI-CODE lang="python"&gt;arcpy.env.workspace = 'path to your desired geodatabase'&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/arcpy/geoprocessing_and_python/using-environment-settings.htm" target="_blank" rel="noopener"&gt;Environment settings in Python—ArcGIS Pro | Documentation&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Feb 2024 15:42:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1384393#M69919</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2024-02-20T15:42:46Z</dc:date>
    </item>
    <item>
      <title>Re: Describe() breaks on coverages</title>
      <link>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1384701#M69923</link>
      <description>&lt;P&gt;Thank you for sharing the code.&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I realized the error message was related to the arcpy environment from your solution. However, I also encountered an error message about the kernel in the code below:&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;arcpy.management.CreateFileGDB()&lt;/LI-CODE&gt;&lt;P&gt;In my case, I was able to resolve the same error message by downgrading ArcGIS Pro's version from 3.2 to 3.1.&lt;/P&gt;&lt;P&gt;Appreciate your assistance!&lt;/P&gt;</description>
      <pubDate>Wed, 21 Feb 2024 00:14:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/describe-breaks-on-coverages/m-p/1384701#M69923</guid>
      <dc:creator>dongheekim</dc:creator>
      <dc:date>2024-02-21T00:14:13Z</dc:date>
    </item>
  </channel>
</rss>

