<?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: gis.content.add fails with large shapefiles in ArcGIS API for Python Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-python-questions/gis-content-add-fails-with-large-shapefiles/m-p/1170085#M7356</link>
    <description>&lt;P&gt;Could you try reading the shapefile into a GeoAccessor first, then &lt;A href="https://developers.arcgis.com/python/api-reference/arcgis.features.toc.html#arcgis.features.GeoAccessor.to_featurelayer" target="_self"&gt;creating the feature service from that&lt;/A&gt;?&lt;/P&gt;</description>
    <pubDate>Tue, 03 May 2022 13:11:47 GMT</pubDate>
    <dc:creator>jcarlson</dc:creator>
    <dc:date>2022-05-03T13:11:47Z</dc:date>
    <item>
      <title>gis.content.add fails with large shapefiles</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/gis-content-add-fails-with-large-shapefiles/m-p/1170082#M7355</link>
      <description>&lt;P&gt;I want to add a compressed shapefile with gis.content.add. This works great with shapefiles except large shapefiles.&amp;nbsp;&lt;/P&gt;&lt;P&gt;If i try to add a large shapefile the following error message appears:&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Traceback (most recent call last):&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;File "xxx\publishgeodata.py", line 236, in &amp;lt;module&amp;gt;&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;shpfile = gis.content.add(item_properties={'type':'Shapefile', 'licenseinfo':license_text, 'commentsEnabled':False, 'title':m_data['titel'], 'description':m_data['beschreibung'], 'tags':m_data['stichworte']}, upload_size=1e7, data=shp_fullname)&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\gis\__init__.py", line 5124, in add&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;folder=folder,&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\gis\__init__.py", line 4773, in _add_by_part&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;os.remove(ffile)&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;PermissionError: [WinError 32] Der Prozess kann nicht auf die Datei zugreifen, da sie von einem anderen Prozess verwendet wird: 'C:\\Users\\MUELLE~1\\AppData\\Local\\Temp\\split00de.part2'&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;checking the&amp;nbsp;&lt;EM&gt;split00de.part2 file shows, that the file was blocked by python, so it is not possible to delete this file.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Has someone else the same problem. Is there a workaround?&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;thanks&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Armin&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 03 May 2022 13:05:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/gis-content-add-fails-with-large-shapefiles/m-p/1170082#M7355</guid>
      <dc:creator>MichaelNüßlein</dc:creator>
      <dc:date>2022-05-03T13:05:13Z</dc:date>
    </item>
    <item>
      <title>Re: gis.content.add fails with large shapefiles</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/gis-content-add-fails-with-large-shapefiles/m-p/1170085#M7356</link>
      <description>&lt;P&gt;Could you try reading the shapefile into a GeoAccessor first, then &lt;A href="https://developers.arcgis.com/python/api-reference/arcgis.features.toc.html#arcgis.features.GeoAccessor.to_featurelayer" target="_self"&gt;creating the feature service from that&lt;/A&gt;?&lt;/P&gt;</description>
      <pubDate>Tue, 03 May 2022 13:11:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/gis-content-add-fails-with-large-shapefiles/m-p/1170085#M7356</guid>
      <dc:creator>jcarlson</dc:creator>
      <dc:date>2022-05-03T13:11:47Z</dc:date>
    </item>
  </channel>
</rss>

