POST
|
Hello! I'm having an issue with a GP service that runs a Python script. The script works fine in ArcGIS toolbox, but it fails when I run it as a GP Service. Is failing when tries to list the dataframes of the mxd in this line df = arcpy.mapping.ListDataFrames(mxd)[0] part of the script that fails: TemplateMXD = r"\\kl-fs-003\GIS_Storage\Ancillary\Templates\Map_Document_Templates\Task_Based\Land_Registry_SketchUp_DrawingTemplate.mxd" mxd = arcpy.mapping.MapDocument(TemplateMXD) df = arcpy.mapping.ListDataFrames(mxd)[0]
The exception is:
esriJobMessageTypeError: Traceback (most recent call last): File "D:\arcgissystem\arcgisinput\UK_I\ExportPropertySketchToShapefilePDF.GPServer\extracted\v101\afernandez\Land_Registry_SkectchUp_2016.py", line 170, in df = arcpy.mapping.ListDataFrames(mxd)[0] File "c:\program files\arcgis\server\arcpy\arcpy\utils.py", line 181, in fn_ return fn(*args, **kw) File "c:\program files\arcgis\server\arcpy\arcpy\mapping.py", line 1479, in ListDataFrames result = mixins.MapDocumentMixin(map_document).listDataFrames(wildcard) File "c:\program files\arcgis\server\arcpy\arcpy\arcobjects\mixins.py", line 728, in listDataFrames return list(reversed(list(self.dataFrames))) File "c:\program files\arcgis\server\arcpy\arcpy\arcobjects\mixins.py", line 695, in dataFrames return map(convertArcObjectToPythonObject, self.pageLayout.dataFrames) AttributeError: 'NoneType' object has no attribute 'dataFrames' For some reason seems that the GP service is not able to open the mxd correctly. TemplateMXD is a UNC path and this path is Accessible to ArcGIS Server (in ArcGIS Server Manage, I've added \\kl-fs-003\GIS_Storage\ as a Registered Folder) (see attached). The mxd is fine, and the layer that contains the mxd is correct, there is no problems or broken links in there. Any ideas of what could be wrong ?
... View more
12-09-2016
06:10 AM
|
0
|
1
|
1206
|
POST
|
Did you fix that issue? I have the same problem. I've tried what Andy suggested below and now the "401 Unauthorized" error disappeared but I get a very descriptive error: init.js:182 Error: Unable to complete operation.(…) I'm trying to create features on a SQL 2012 database using the editor widget. Any help ?
... View more
10-04-2016
09:59 AM
|
0
|
0
|
758
|
POST
|
I am using ArcGIS Viewer for Flex 3.6 and ArcGIS for Server 10.2.2 to create web maps for my organisation. Due to data licensing restrictions, I have had to restrict a few of the services using Web-Tier authentication with ArcGIS Web Adaptor and our internal Windows domain user groups. For those that have access to the restricted services the web application opens fine, but for those that do not, they get an error popup message for each service, saying: "SoandSo layer failed to load: Fault info: Unable to get token service url from (http://MyWebAdaptorDomain/arcgis/rest/info) Version 10.01+ required." Is there any way to stop these error messages popping up so that those who do not have access to the secure services do not receive error messages and simply do not see the restricted layers?
... View more
10-15-2014
03:10 AM
|
0
|
1
|
3241
|
Online Status |
Offline
|
Date Last Visited |
a month ago
|