Hello Community!
I'm hoping to get your help with the following error I get when solving a route, specifically where the resulting route passes through road segments that have true curves (circular arcs, etc).
{
"error": {
"code": 400,
"extendedCode": -2147220870,
"message": "Unable to complete operation.",
"details": [
"Cannot convert polylines or polygons with curves to JSON format."
]
}
}
When I solve a route that does not pass through any true curves, I don't get the error and the solve result is returned correctly.
I also only have this problem when I publish the network analyst service through ArcPro. When I publish the service using ArcMap, I do not get the error. Am I missing some kind of configuration option in ArcPro when I publish the service? In case it matters, the network dataset is stored in a file geodatabase which was automatically copied to the server during publish.
I've tried publishing on multiple versions of ArcGIS Server (10.7.1, 10.8.1, 11) and I still get the error.
Here are the parameters that were supplied to the solve (see below). I tried changing the outputLines parameter from esriNAOutputLineTrueShapeWithMeasure to other values like esriNAOutputLineStraight and esriNAOutputLineNone, but this did not have any effect.
f=json
&accumulateAttributeNames=Length,Minutes
&attributeParameterValues=[{"attributeName":"Oneway","parameterName":"Restriction+Usage","value":-1}]
&barriers=
&directionsLanguage=en-US
&directionsLengthUnits=esriNAUMiles
&directionsOutputType=esriDOTFeatureSets
&directionsStyleName=NA+Desktop
&directionsTimeAttributeName=Minutes
&findBestSequence=false
&ignoreInvalidLocations=true
&impedanceAttributeName=Minutes
&outSR={"wkid":102100,"latestWkid":3857}
&outputGeometryPrecision=0
&outputGeometryPrecisionUnits=esriMeters
&outputLines=esriNAOutputLineTrueShapeWithMeasure
&preserveFirstStop=false
&preserveLastStop=false
&preserveObjectID=true
&restrictUTurns=esriNFSBAtDeadEndsAndIntersections
&restrictionAttributeNames=Oneway
&returnBarriers=false
&returnDirections=true
&returnPolygonBarriers=true
&returnPolylineBarriers=true
&returnRoutes=true
&returnStops=true
&returnZ=false
&startTime=none
&startTimeIsUTC=true
&stops={"features":[{"geometry":{"x":-10786022.828108414,"y":3914510.7541814947,"spatialReference":{"wkid":102100,"latestWkid":3857}},"attributes":{"Name":"Start"}},{"geometry":{"x":-10778430.977528103,"y":3912218.040570303,"spatialReference":{"wkid":102100,"latestWkid":3857}},"attributes":{"Name":"End"}}]}
&timeWindowsAreUTC=true
&useHierarchy=false
&useTimeWindows=false
Any ideas or suggestions?
Thank you,
David
Solved! Go to Solution.
Hi David,
This seems like a bug in the network analysis service published from ArcGIS Pro which uses a different runtime during execution as compared to a network analysis service that is published from ArcMap.
As this bug is specific to the street data that you are using, can you send me a copy of the network dataset you are using for this service?
You can send me the data at dmandloi@esri.com or if the data is quite large, send me an email and I can provide you instructions on how to upload the data to a secure website managed by Esri.
Thanks
Deelesh
Hi David,
This seems like a bug in the network analysis service published from ArcGIS Pro which uses a different runtime during execution as compared to a network analysis service that is published from ArcMap.
As this bug is specific to the street data that you are using, can you send me a copy of the network dataset you are using for this service?
You can send me the data at dmandloi@esri.com or if the data is quite large, send me an email and I can provide you instructions on how to upload the data to a secure website managed by Esri.
Thanks
Deelesh
Deelesh,
Thank you for your reply. I have sent the GDB file to you as requested. Please let me know if you need any more information!
-David
Just to close the loop on this post, Deelesh confirmed that this is a bug in the network analyst service published from ArcGIS Pro, that pops up when generating driving directions of output type esriDOTFeatureSets. This happens to be the case with my application, which is developed using the ArcGIS Runtime SDK for .NET, which requests the driving directions in esriDOTFeatureSets format. Unfortunately I can't change that behavior through my code but we are still able to publish our network analyst service from ArcMap. So we'll use that workaround until a fix becomes available.
Thanks again for your help Deelesh!
This bug is fixed in ArcGIS Server 11.1 or later for routing services that are published from ArcGIS Pro.