<?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: Issue saving a geo Pandas DataFrame to Feature Class in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390705#M79752</link>
    <description>&lt;P&gt;Unfortunately cannot remove posts so replying again with the solution&lt;BR /&gt;&lt;BR /&gt;As of Panda's 2.2.x&lt;BR /&gt;pandas calls json.dumps as json.udumps&lt;BR /&gt;&lt;BR /&gt;In order to get .to_featureclass, arcgis is now reliant on pandas version 2.1.x or older&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;!pip install pandas == 2.1

df_points = gpd.GeoDataFrame.from_dict(all_results)

df_points['lon'] = df_points['lon'].astype(float)
df_points['lat'] = df_points['lat'].astype(float)

df_points['geometry'] = [shapely.geometry.Point(xy) for xy in zip(df_points.lon, df_points.lat)]

gdf = df_points
sedf = arcgis.GeoAccessor.from_geodataframe(gdf)

sedf.spatial.to_featureclass(r'...\MyProject.gbd\sample')&lt;/LI-CODE&gt;</description>
    <pubDate>Mon, 04 Mar 2024 20:26:51 GMT</pubDate>
    <dc:creator>RobertKleisley</dc:creator>
    <dc:date>2024-03-04T20:26:51Z</dc:date>
    <item>
      <title>Issue saving a geo Pandas DataFrame to Feature Class</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390621#M79738</link>
      <description>&lt;P&gt;I am currently pulling data from an api that is in a json format.&amp;nbsp;&lt;BR /&gt;I convert this into a geodataframe using the lat lon columns provided in the dataset.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;df_points = gpd.GeoDataFrame.from_dict(all_results)

df_points['lon'] = df_points['lon'].astype(float)
df_points['lat'] = df_points['lat'].astype(float)

df_points['geometry'] = [shapely.geometry.Point(xy) for xy in zip(df_points.lon, df_points.lat)]

gdf = df_points
sedf = arcgis.GeoAccessor.from_geodataframe(gdf)&lt;/LI-CODE&gt;&lt;P&gt;This part works fine even if it may not be elegant.&amp;nbsp;&lt;BR /&gt;From here I can save it off as a shapefile no problem&lt;BR /&gt;I would like to send it directly to my GeoDatabase as a Feature Class&lt;BR /&gt;&lt;BR /&gt;however when I attempt to I get an error.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;sedf.spatial.to_featureclass(r'...\MyProject.gbd\sample')

--------------------------
AttributeError      Traceback(most recent call last)
In[23]:
Line 1: sedf.spatial.to_featureclass(r'...\MyProject.gbd\sample')

File ...\site-packages\arcgis\feature\geo\_accesspr.py, in to_featureclass:
Line 2668: result = to_featureclass(

File ...\site-packages\arcgis\features\geo\_io\fileops.py, in to_featureclass"
Line 1262: raise e

File ...\site-packages\arcgis\features\geo\_io\fileops.py, in to_featureclass:
Line 1075: "point": pd.io.json.dumps(

AttributeError: module 'pandas.io.json' has no attribute 'dumps'
-----------------------&lt;/LI-CODE&gt;&lt;P&gt;Any thoughts why I am seeing this.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I do thought it might be conflicting with the json library but I removed it and it is still popping this error.&lt;/P&gt;</description>
      <pubDate>Mon, 04 Mar 2024 18:53:22 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390621#M79738</guid>
      <dc:creator>RobertKleisley</dc:creator>
      <dc:date>2024-03-04T18:53:22Z</dc:date>
    </item>
    <item>
      <title>Re: Issue saving a geo Pandas DataFrame to Feature Class</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390626#M79739</link>
      <description>&lt;P&gt;Hey &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/772180"&gt;@RobertKleisley&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Do you happen to have anything named json.py or json.x (x being any extension)? I've had this exact issue before due to it picking up something named json.&lt;/P&gt;&lt;P&gt;I'd attempt to move this to a different location and give it another shot to see!&lt;/P&gt;&lt;P&gt;Hope that helps!&lt;/P&gt;&lt;P&gt;Cody&lt;/P&gt;</description>
      <pubDate>Mon, 04 Mar 2024 18:59:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390626#M79739</guid>
      <dc:creator>CodyPatterson</dc:creator>
      <dc:date>2024-03-04T18:59:49Z</dc:date>
    </item>
    <item>
      <title>Re: Issue saving a geo Pandas DataFrame to Feature Class</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390643#M79743</link>
      <description>&lt;P&gt;I'm unsure what you mean.&amp;nbsp;&lt;BR /&gt;something named json saved anywhere in the GDB?&lt;/P&gt;&lt;P&gt;anything named json in my Python3 directory where my packages are installed?&lt;/P&gt;</description>
      <pubDate>Mon, 04 Mar 2024 19:25:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390643#M79743</guid>
      <dc:creator>RobertKleisley</dc:creator>
      <dc:date>2024-03-04T19:25:05Z</dc:date>
    </item>
    <item>
      <title>Re: Issue saving a geo Pandas DataFrame to Feature Class</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390675#M79745</link>
      <description>&lt;P&gt;Digging into this&amp;nbsp; a bit.&lt;BR /&gt;&lt;BR /&gt;I have figured out that I am using pandas 2.2.x&lt;BR /&gt;as of this version pandas imports json.udumps not json.dumps&lt;/P&gt;</description>
      <pubDate>Mon, 04 Mar 2024 19:53:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390675#M79745</guid>
      <dc:creator>RobertKleisley</dc:creator>
      <dc:date>2024-03-04T19:53:59Z</dc:date>
    </item>
    <item>
      <title>Re: Issue saving a geo Pandas DataFrame to Feature Class</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390705#M79752</link>
      <description>&lt;P&gt;Unfortunately cannot remove posts so replying again with the solution&lt;BR /&gt;&lt;BR /&gt;As of Panda's 2.2.x&lt;BR /&gt;pandas calls json.dumps as json.udumps&lt;BR /&gt;&lt;BR /&gt;In order to get .to_featureclass, arcgis is now reliant on pandas version 2.1.x or older&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;!pip install pandas == 2.1

df_points = gpd.GeoDataFrame.from_dict(all_results)

df_points['lon'] = df_points['lon'].astype(float)
df_points['lat'] = df_points['lat'].astype(float)

df_points['geometry'] = [shapely.geometry.Point(xy) for xy in zip(df_points.lon, df_points.lat)]

gdf = df_points
sedf = arcgis.GeoAccessor.from_geodataframe(gdf)

sedf.spatial.to_featureclass(r'...\MyProject.gbd\sample')&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 04 Mar 2024 20:26:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/issue-saving-a-geo-pandas-dataframe-to-feature/m-p/1390705#M79752</guid>
      <dc:creator>RobertKleisley</dc:creator>
      <dc:date>2024-03-04T20:26:51Z</dc:date>
    </item>
  </channel>
</rss>

