<?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: Geoprocessing service works when run in Experience Builder or Pro, fails as task? in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1718756#M75361</link>
    <description>&lt;P&gt;Can you try setting up a Windows Scheduled Task outside of Pro to see if you can get it to run in that environment?&amp;nbsp; You would need to have it run whether user is logged on or not and with highest privileges.&lt;/P&gt;&lt;P&gt;I would also suggest calling the python script (exported from the geoprocessing tool) from a bat file in this scenario with logging from both that bat file that calls the python script and from within the script itself.&amp;nbsp; In&amp;nbsp; this way you can tell if the bat file is running but somehow the python portion is not if logging from the python script does not get written.&lt;/P&gt;</description>
    <pubDate>Wed, 05 Aug 2026 17:57:47 GMT</pubDate>
    <dc:creator>ShareUser</dc:creator>
    <dc:date>2026-08-05T17:57:47Z</dc:date>
    <item>
      <title>Geoprocessing service works when run in Experience Builder or Pro, fails as task?</title>
      <link>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1718721#M75359</link>
      <description>&lt;P&gt;I have a geoprocessing service that basically does a bunch of field calculations.&lt;/P&gt;&lt;P&gt;It has one input parameter, which the user does not see. This parameter takes a json file that points the tool to the right tables. When tool was published as a service, that json file went with it.&lt;/P&gt;&lt;P&gt;I got it uploaded and it works great. I'm using it in Experience Builder.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AlfredBaldenweck_0-1783697520540.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/155279i1BAB77ED717AD6CF/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AlfredBaldenweck_0-1783697520540.png" alt="AlfredBaldenweck_0-1783697520540.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;In Pro, when I open the tool from the Portal, it displays that input parameter and it shows the original file path, rather than what that file should be on the Portal's server.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AlfredBaldenweck_1-1783697967558.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/155280iF89CB206B42D9365/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AlfredBaldenweck_1-1783697967558.png" alt="AlfredBaldenweck_1-1783697967558.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;In any case, the GP service works great in Pro, too.&lt;/P&gt;&lt;P&gt;However.&lt;/P&gt;&lt;P&gt;I heard that you can make an automated task via Pro by clicking the dropdown on the Run button. So I did that, and set it to run every night at midnight.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AlfredBaldenweck_2-1783698038980.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/155281i44C67723E355735C/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AlfredBaldenweck_2-1783698038980.png" alt="AlfredBaldenweck_2-1783698038980.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;(Note that the exclamation points are from my project not being saved)&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AlfredBaldenweck_3-1783698119071.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/155282i81610C23CA105E27/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AlfredBaldenweck_3-1783698119071.png" alt="AlfredBaldenweck_3-1783698119071.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unfortunately, when I go to check the task the next morning, it has always failed.&lt;BR /&gt;I was able to change the time a touch (from like 5AM to 5:15) and that appeared to largely work, but when I changed the time to 5:30, it didn't work anymore&lt;/P&gt;&lt;P&gt;What's the deal, here?&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/t5/arcgis-online-ideas/tasks-show-any-print-statements-add-messages-etc/idi-p/1718795/jump-to/first-unread-message" target="_self"&gt;On a related note, how can I get more information about the task's run? Only seeing "Succeeded" or "Failed" is really not helpful, and I have print statements (or even a specific error) would be helpful.&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AlfredBaldenweck_0-1785946618433.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/156314i5E844E8505BF552B/image-size/large?v=v2&amp;amp;px=999" role="button" title="AlfredBaldenweck_0-1785946618433.png" alt="AlfredBaldenweck_0-1785946618433.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 05 Aug 2026 19:46:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1718721#M75359</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2026-08-05T19:46:47Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing service works when run in Experience Builder or Pro, fails as task?</title>
      <link>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1718756#M75361</link>
      <description>&lt;P&gt;Can you try setting up a Windows Scheduled Task outside of Pro to see if you can get it to run in that environment?&amp;nbsp; You would need to have it run whether user is logged on or not and with highest privileges.&lt;/P&gt;&lt;P&gt;I would also suggest calling the python script (exported from the geoprocessing tool) from a bat file in this scenario with logging from both that bat file that calls the python script and from within the script itself.&amp;nbsp; In&amp;nbsp; this way you can tell if the bat file is running but somehow the python portion is not if logging from the python script does not get written.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Aug 2026 17:57:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1718756#M75361</guid>
      <dc:creator>ShareUser</dc:creator>
      <dc:date>2026-08-05T17:57:47Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing service works when run in Experience Builder or Pro, fails as task?</title>
      <link>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1718796#M75362</link>
      <description>&lt;P&gt;Update: I've added an Idea to give us more details on a task's run&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/t5/arcgis-online-ideas/tasks-show-any-print-statements-add-messages-etc/idi-p/1718795/jump-to/first-unread-message" target="_blank"&gt;Tasks: Show any print statements/add messages, etc... - Esri Community&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 05 Aug 2026 19:47:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1718796#M75362</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2026-08-05T19:47:24Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing service works when run in Experience Builder or Pro, fails as task?</title>
      <link>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1718799#M75363</link>
      <description>&lt;P&gt;The bat file is actually exactly what I'm trying to avoid.&amp;nbsp;&lt;/P&gt;&lt;P&gt;We do all of our GIS work on a virtual desktop, so I don't think windows tasks would work for me? So instead we generally do them via scheduled bat file (I don't know how they make that work), which can run hourly or daily or semi-daily depending on the file. The issue with the bat file is that my thing would get stuck behind several other workflows and end up getting delayed by several hours. Versus for a portal task, I can just set it up to run every day at 6AM and call it good. There are not any other scheduled portal tasks running on this portal right now, and honestly I don't anticipate having too many more, so provided I can make this work, it reduces a lot of busywork for us in making this process run.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Aug 2026 19:50:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1718799#M75363</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2026-08-05T19:50:54Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing service works when run in Experience Builder or Pro, fails as task?</title>
      <link>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1719323#M75365</link>
      <description>&lt;P&gt;Weird enough, it failed yet again as a task. Also failed in Map Viewer online, but no real error message given.&lt;/P&gt;&lt;P&gt;Worked great when I ran the web tool in Pro this morning, though.&lt;/P&gt;</description>
      <pubDate>Fri, 07 Aug 2026 18:06:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/geoprocessing-service-works-when-run-in-experience/m-p/1719323#M75365</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2026-08-07T18:06:07Z</dc:date>
    </item>
  </channel>
</rss>

