<?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: featureLayerCollection overwrite &amp;quot;Job failed&amp;quot; in ArcGIS API for Python Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-python-questions/featurelayercollection-overwrite-quot-job-failed/m-p/802176#M2092</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I ran into this error and eventually worked out it's because the Feature Layers I'm wanting to overwrite have outstanding replicas present. Once I unregistered the replicas it worked.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 02 Jul 2020 04:58:12 GMT</pubDate>
    <dc:creator>Anonymous User</dc:creator>
    <dc:date>2020-07-02T04:58:12Z</dc:date>
    <item>
      <title>featureLayerCollection overwrite "Job failed"</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/featurelayercollection-overwrite-quot-job-failed/m-p/802175#M2091</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi. I am trying to update/overwrite a hosted feature layer, following the logic given near the end of a tutorial on learn.arcgis (&lt;A href="https://learn.arcgis.com/en/projects/update-real-time-data-with-python/"&gt;Update Real-Time Data With Python&lt;/A&gt;). It uses the following to overwrite the feature layer:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;# Replace file&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt; manager = arcgis.features.FeatureLayerCollection.fromitem(item).manager&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt; status = manager.overwrite(updated_sd)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Everything else is working except this step, which returns an error:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;status = manager.overwrite(updated_sd)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;Traceback (most recent call last):&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;File "&amp;lt;ipython-input-45-b7a0406a969f&amp;gt;", line 1, in &amp;lt;module&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt; status = manager.overwrite(updated_sd)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\features\managers.py", line 1269, in overwrite&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt; published_item = related_data_item.publish(publish_parameters, overwrite=True)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\gis\__init__.py", line 8780, in publish&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt; serviceitem_id = self._check_publish_status(ret, folder)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;File "C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\gis\__init__.py", line 9007, in _check_publish_status&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt; raise Exception("Job failed.")&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;Exception: Job failed.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have found a couple of relevant threads about this, &lt;A _jive_internal="true" href="https://community.esri.com/thread/206364-intermittent-504-gateway-timeouts-with-hosted-feature-layers"&gt;one&lt;/A&gt; says it's a bug (Phil Larkin, Dec. 12, 2018 2:31PM:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; padding-left: 30px;"&gt;This is in fact associated with the bug. The severity is logged as low.&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; padding-left: 30px;"&gt;&lt;SPAN style="border: 0px; font-weight: inherit;"&gt;&lt;STRONG style="border: 0px; font-weight: bold; font-size: 11pt;"&gt;BUG-000115253: When using the overwrite method from arcgis.features.managers.FeatureLayerCollectionManager, ArcGIS API for Python returns the error "Exception: Job Failed.''&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; padding-left: 30px;"&gt;&lt;A href="https://support.esri.com/en/bugs/nimbus/QlVHLTAwMDExNTI1Mw==" rel="nofollow" style="color: #287433; border: 0px; font-weight: inherit; text-decoration: none; padding: 0px calc(12px + 0.35ex) 0px 0px;" target="_blank"&gt;BUG-000115253: When using the overwrite method from arcgis.features..&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" href="https://community.esri.com/thread/215975-featurelayercollectionmanager-references-a-missing-function-in-overwrite"&gt;Another thread&lt;/A&gt; (very last comment) says:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;While I was trying these solutions, I was simultaneously working with ESRI Support, and we came up with a different workflow which publishes a new SD file. That is working well, so I won't need to pursue this solution, though it appears it would be a simpler script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anyone point me to a workaround, or the 'different workflow which publishes a new SD file' referred to here?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Len&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2020 13:48:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/featurelayercollection-overwrite-quot-job-failed/m-p/802175#M2091</guid>
      <dc:creator>LenBalthis</dc:creator>
      <dc:date>2020-01-15T13:48:33Z</dc:date>
    </item>
    <item>
      <title>Re: featureLayerCollection overwrite "Job failed"</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/featurelayercollection-overwrite-quot-job-failed/m-p/802176#M2092</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I ran into this error and eventually worked out it's because the Feature Layers I'm wanting to overwrite have outstanding replicas present. Once I unregistered the replicas it worked.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Jul 2020 04:58:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/featurelayercollection-overwrite-quot-job-failed/m-p/802176#M2092</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2020-07-02T04:58:12Z</dc:date>
    </item>
  </channel>
</rss>

