<?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: Error executing tool. GP Server Script Tool Fails in ArcGIS Enterprise Questions</title>
    <link>https://community.esri.com/t5/arcgis-enterprise-questions/error-executing-tool-gp-server-script-tool-fails/m-p/1309316#M36550</link>
    <description>&lt;P&gt;Did you ever find out a solution? I am having the same issue as well.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;aprx_path = os.environ["APRX_PATH"]
arcpy.AddMessage('APRX_PATH: {}'.format(aprx_path))
if os.path.exists(aprx_path):
    arcpy.AddMessage('aprx_path exists')
else:
    arcpy.AddMessage('aprx_path DNE')
aprx = arcpy.mp.ArcGISProject(aprx_path)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;BR /&gt;In my case I have verified that the path exists when run from a service, and it is still giving me an OSError, despite working fine when I run manually in Pro (3.1).&lt;/P&gt;</description>
    <pubDate>Tue, 18 Jul 2023 23:23:29 GMT</pubDate>
    <dc:creator>VincentLantaca</dc:creator>
    <dc:date>2023-07-18T23:23:29Z</dc:date>
    <item>
      <title>Error executing tool. GP Server Script Tool Fails</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-questions/error-executing-tool-gp-server-script-tool-fails/m-p/1285681#M35790</link>
      <description>&lt;P&gt;I have created a python script to automate the output of several maps that are created weekly.&lt;/P&gt;&lt;P&gt;For the past year it has worked without any problems, and now it seems that for some reason it is not working properly.&lt;BR /&gt;The script is uploaded to ArcGIS Server (version 10.9.1), locally and through ArcGIS Pro (3.0.3 version), the script runs and works correctly.&lt;/P&gt;&lt;P&gt;However, when I run the script from REST on the server, I get the following error:&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Error executing tool. Script Job ID: ja80780b469e54e149b0c59cf5b8fa0f6 : Traceback (most recent call last): File "D:\arcgisserver\directories\arcgissystem\arcgisinput\WNV\WNV_MapOutput.GPServer\extracted\p20\script\WNF.py", line 14, in &amp;lt;module&amp;gt; aprx = arcpy.mp.ArcGISProject(folder + '/' + 'WNV_WeeklyMaps' + '/' + 'WNF_Maps.aprx') File "C:\Program Files\ArcGIS\Server\framework\runtime\ArcGIS\Resources\ArcPy\arcpy\_mp.py", line 346, in __init__ self._arc_object = arcgisscripting._mapping.ArcGISProject(*gp_fixargs((aprx_path,), True)) OSError: //zvgis.ecdcdmz.europa.eu/SharedData/MapProjects/WNV/WNV_WeeklyMaps/WNF_Maps.aprx Failed to execute (Script).&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any idea how to fix it?&lt;BR /&gt;I've changed the script several times, the paths and I've also resubbed it, and it still doesn't work.&lt;/P&gt;&lt;P&gt;Attached&amp;nbsp;is a screenshot with part of the code&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="CaptureWNV.PNG" style="width: 856px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/69869i89E03D76C00097EE/image-size/large?v=v2&amp;amp;px=999" role="button" title="CaptureWNV.PNG" alt="CaptureWNV.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 04 May 2023 14:53:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-questions/error-executing-tool-gp-server-script-tool-fails/m-p/1285681#M35790</guid>
      <dc:creator>iolea</dc:creator>
      <dc:date>2023-05-04T14:53:57Z</dc:date>
    </item>
    <item>
      <title>Re: Error executing tool. GP Server Script Tool Fails</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-questions/error-executing-tool-gp-server-script-tool-fails/m-p/1309316#M36550</link>
      <description>&lt;P&gt;Did you ever find out a solution? I am having the same issue as well.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;aprx_path = os.environ["APRX_PATH"]
arcpy.AddMessage('APRX_PATH: {}'.format(aprx_path))
if os.path.exists(aprx_path):
    arcpy.AddMessage('aprx_path exists')
else:
    arcpy.AddMessage('aprx_path DNE')
aprx = arcpy.mp.ArcGISProject(aprx_path)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;BR /&gt;In my case I have verified that the path exists when run from a service, and it is still giving me an OSError, despite working fine when I run manually in Pro (3.1).&lt;/P&gt;</description>
      <pubDate>Tue, 18 Jul 2023 23:23:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-questions/error-executing-tool-gp-server-script-tool-fails/m-p/1309316#M36550</guid>
      <dc:creator>VincentLantaca</dc:creator>
      <dc:date>2023-07-18T23:23:29Z</dc:date>
    </item>
    <item>
      <title>Re: Error executing tool. GP Server Script Tool Fails</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-questions/error-executing-tool-gp-server-script-tool-fails/m-p/1309393#M36553</link>
      <description>&lt;P&gt;No, sorry, I haven't found a solution yet, but after a lot of testing, it seems that there is an incompatibility issue between the version of ArcGIS Pro I have installed (3.0) and the server version (version 10.9.1).&lt;/P&gt;&lt;P&gt;Some Esri colleagues&amp;nbsp; have told me that the best solution is to upgrade the server I have from enterprise to version 11.&lt;BR /&gt;On the other hand, I have tested on a virtual machine with ArcGIS Pro version 2.9 and my current server with version 10.9.1 and it works. So, it seems to be the problem. However, I don't want to run an older version of ArcGIS Pro as I have done projects with version 3.&lt;BR /&gt;I hope this helps.&lt;BR /&gt;Regards&lt;/P&gt;</description>
      <pubDate>Wed, 19 Jul 2023 07:25:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-questions/error-executing-tool-gp-server-script-tool-fails/m-p/1309393#M36553</guid>
      <dc:creator>iolea</dc:creator>
      <dc:date>2023-07-19T07:25:27Z</dc:date>
    </item>
  </channel>
</rss>

