Closed NatalieCampos closed 6 years ago
I can reproduce this issue also - works at 1.4, broken at 2.0 - I was using the tutorial/test data from https://github.com/Esri/military-tools-geoprocessing-toolbox/tree/dev/testdata
Same error:
PYTHON ERRORS:
Traceback info:
File "C:\MyFiles\Work\Github\military-tools-geoprocessing-toolbox\toolboxes\scripts\VisibilityUtilities.py", line 656, in makeProfileGraph
arcpy.SetParameter(1,inputFeatures)
Error Info:
Object: Error in setting parameter
ArcPy ERRORS:
Start Time: Thursday, June 29, 2017 12:02:36 PM
Succeeded at Thursday, June 29, 2017 12:02:36 PM (Elapsed Time: 0.22 seconds)
You do get the map output - it looks like just the profile graph is affected:
After further testing, this is no longer an issue. Issue possibly fixed due to the migration to PYT. But I did find the need for parameters checks (defense checks). Not adding either an observer or target inputs causes the tool to crash and occasionally ArcGIS Pro to crash as well. We need parameter checks for:
I will add a new issue for these checks.
The LLOS sight tool fails in Pro 2.0. The tool was tested in the following two ways.
Running script LinearLineOfSight... Projecting Observers and Targets to Input Surface spatial reference NAD_1983_UTM_Zone_10N Building 3D observer points... Adding surface info for prjObservers Adding field ObsSPOT with alias ObsSPOT Building 3D target points... Adding surface info for prjTargets Adding field TgtSPOT with alias TgtSPOT Constructing Sight Lines between observers and targets... Building minimum bounding rectangle of sight lines for analysis mask... Building Line Of Sight... Joining attribute results... Attributing output Observer features... Calculating frequency on Target features... Building profile graph... Found 9 unique sight line IDs ... Building graphs for lines ... Building graph from observer 1 to target 1 ... Building graph from observer 1 to target 2 ... Building graph from observer 1 to target 3 ... Building graph from observer 2 to target 1 ... Building graph from observer 2 to target 2 ... Building graph from observer 2 to target 3 ... Building graph from observer 3 to target 1 ... Building graph from observer 3 to target 2 ... Building graph from observer 3 to target 3 ... Enabling attachments ... Building match table ... Attaching profile graphs to sightlines ... PYTHON ERRORS:Traceback info: File "C:\git\military-tools-geoprocessing-toolbox\toolboxes\scripts\VisibilityUtilities.py", line 656, in makeProfileGraph arcpy.SetParameter(1,inputFeatures)Error Info:Object: Error in setting parameter ArcPy ERRORS:Start Time: Thursday, June 29, 2017 8:26:09 AMSucceeded at Thursday, June 29, 2017 8:26:09 AM (Elapsed Time: 0.08 seconds) Removing intermediate datasets... Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\prjObservers Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\prjTargets Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\dddObservers Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\dddTargets Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\dddSightLines Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\llosObstructionPoints Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\llosStartVertex Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\llosEndVertex Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\targetStats Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile1.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile2.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile3.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile4.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile5.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile6.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile7.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile8.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile9.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\matchTable Done Completed script LinearLineOfSight... Failed to execute (LinearLineOfSight). Failed at Thursday, June 29, 2017 8:26:15 AM (Elapsed Time: 36.32 seconds)
The LLOS tool was also tested without the use of the Add Linear Line of Sight Fields tool.
` Adding field ObsSPOT with alias ObsSPOT Building 3D target points... Adding surface info for prjTargets Adding field TgtSPOT with alias TgtSPOT Constructing Sight Lines between observers and targets... Building minimum bounding rectangle of sight lines for analysis mask... Building Line Of Sight... Joining attribute results... Attributing output Observer features... Calculating frequency on Target features... Building profile graph... Found 9 unique sight line IDs ... Building graphs for lines ... Building graph from observer 1 to target 1 ... Building graph from observer 1 to target 2 ... Building graph from observer 1 to target 3 ... Building graph from observer 2 to target 1 ... Building graph from observer 2 to target 2 ... Building graph from observer 2 to target 3 ... Building graph from observer 3 to target 1 ... Building graph from observer 3 to target 2 ... Building graph from observer 3 to target 3 ... Enabling attachments ... Building match table ... Attaching profile graphs to sightlines ... PYTHON ERRORS: Traceback info: File "C:\git\military-tools-geoprocessing-toolbox\toolboxes\scripts\VisibilityUtilities.py", line 656, in makeProfileGraph arcpy.SetParameter(1,inputFeatures)
Error Info: Object: Error in setting parameter ArcPy ERRORS: Start Time: Thursday, June 29, 2017 8:30:59 AM Succeeded at Thursday, June 29, 2017 8:30:59 AM (Elapsed Time: 0.07 seconds) Removing intermediate datasets... Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\prjObservers Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\prjTargets Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\dddObservers Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\dddTargets Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\dddSightLines Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\llosObstructionPoints Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\llosStartVertex Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\llosEndVertex Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\targetStats Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile1.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile2.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile3.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile4.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile5.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile6.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile7.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile8.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile9.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\matchTable Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\prjObservers Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\prjTargets Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\dddObservers Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\dddTargets Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\dddSightLines Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\llosObstructionPoints Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\llosStartVertex Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\llosEndVertex Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\targetStats Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile1.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile2.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile3.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile4.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile5.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile6.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile7.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile8.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\scratch\profile9.png Removing: C:\Users\nata7004\Documents\ArcGIS\Projects\MyProject1\MyProject1.gdb\matchTable Done Completed script LinearLineOfSight... Failed to execute (LinearLineOfSight). Failed at Thursday, June 29, 2017 8:31:04 AM (Elapsed Time: 35.58 seconds) `
Unsure whether this issue is related to #235 in ArcMAP